Application process configuration updating method, system, terminal device and storage medium
Technical Field
The present application belongs to the field of configuration update, and in particular, to a method, a system, a terminal device, and a storage medium for updating an application process configuration.
Background
In the using process of the server, in order to meet the requirements of users, various application processes, such as a purchase management application process, a financial application process or a personnel management application process, are carried out. These application processes need to be run to load the configuration content of the application process to provide various functions and services to the user. Therefore, when the function of the application process needs to be updated, the configuration content of the application process needs to be updated.
However, in the existing application process configuration updating process, different application processes in the same server need to repeatedly load the same configuration updating file, which further causes higher memory loss in the server and reduces the data processing efficiency of the server.
Disclosure of Invention
The embodiment of the application process configuration updating method and system, terminal equipment and storage medium aims to solve the problem that in the existing application process configuration updating process, due to the fact that different application processes in the same server need to repeatedly load the same configuration updating file, the memory loss of the server is high.
In a first aspect, an embodiment of the present application provides an application process configuration updating method, where the method includes:
when a configuration updating instruction is received, inquiring a configuration updating file and a target server, and acquiring a monitoring process and a shared memory in the target server;
sending a sharing connection instruction to the shared memory to indicate the shared memory to share and connect with at least two application processes in the target server;
instructing the monitoring process to independently load the configuration update file so as to update the configuration information of the shared memory;
if the shared memory completes configuration updating, sending a configuration switching instruction to the shared memory to indicate the shared memory to perform configuration switching;
and if the shared memory completes configuration switching, sending a reading instruction to the application process to indicate the application process to perform configuration updating according to the updated configuration information of the shared memory.
Compared with the prior art, the embodiment of the application has the advantages that: the configuration updating file is loaded based on the monitoring process, so that the shared memory updates the configuration information, and the at least two different application processes are indicated to perform configuration updating according to the updated configuration information of the shared memory based on the mode of the shared memory, so that the at least two different application processes do not need to repeatedly load the configuration updating file, the memory loss in the target server is reduced, and the data processing efficiency of the target server is improved.
Further, the sending a configuration switching instruction to the shared memory to instruct the shared memory to perform configuration switching includes:
acquiring the updated configuration version number of the shared memory, and generating the configuration switching instruction according to the configuration version number;
and sending the configuration switching instruction to the monitoring process, and indicating the shared memory to perform configuration switching through the monitoring process.
Further, after sending a read instruction to the application process to instruct the application process to perform configuration update according to the updated configuration information of the shared memory if the shared memory completes configuration switching, the method includes:
acquiring the configuration version number of the monitoring process according to a preset time interval, and respectively carrying out version comparison on the configuration version number of each application process and the configuration version number in the monitoring process;
and if the configuration version number of any application process is different from the configuration version number of the monitoring process, sending a reading instruction to the application process to indicate the application process to perform configuration updating again according to the configuration information of the shared memory.
Further, the method further comprises:
if the monitoring process fails to load the configuration update file, sending a reload instruction to the monitoring process to instruct the monitoring process to reload the configuration update file;
and if the failure loading times of the monitoring process to the configuration updating file are larger than a time threshold value, sending a configuration updating error prompt aiming at the target server.
Further, the method further comprises:
and if the abnormal updating information sent by the shared memory is received, sending a configuration deleting instruction to the shared memory to indicate the shared memory to delete the configuration information generated by the configuration updating, and sending a configuration updating error prompt aiming at the target server.
Further, when the number of the target servers is greater than one, if the shared memory completes configuration update, sending a configuration switching instruction to the shared memory, including:
if update completion information sent by any one shared memory is received, the shared memory is marked with update success;
if update abnormal information sent by any one shared memory is received, carrying out update error marking on the shared memory;
obtaining the total number of the marks obtained after the successful updating marks and the wrong updating marks are accumulated, and if the total number of the marks is equal to the number of the target servers, sending a configuration switching instruction to different shared memories to indicate the shared memories to perform configuration switching;
and if the shared memory completes configuration switching, sending a reading instruction to the application process to indicate the application process to perform configuration updating according to the updated configuration information of the shared memory.
Further, the method further comprises:
if the sending times of sending the reading instruction to any application process within the preset time are greater than the preset times, marking the application process as an abnormal process, and performing abnormal prompt on the abnormal process;
if the process number of the abnormal processes in the target server is larger than the preset number, marking the shared memory as an abnormal memory, and performing abnormal prompt on the abnormal memory.
In a second aspect, an embodiment of the present application provides an application process configuration updating system, including:
the server query module is used for querying the configuration update file and the target server when receiving the configuration update instruction, and acquiring a monitoring process and a shared memory in the target server;
the shared indication module is used for sending a shared connection instruction to the shared memory so as to indicate the shared memory to share and connect with at least two application processes in the target server;
a configuration loading module, configured to instruct the monitoring process to independently load the configuration update file to update the configuration information of the shared memory;
a configuration switching indication module, configured to send a configuration switching instruction to the shared memory to indicate the shared memory to perform configuration switching if the shared memory completes configuration updating;
and the configuration updating indication module is used for sending a reading instruction to the application process to indicate the application process to perform configuration updating according to the updated configuration information of the shared memory if the shared memory completes configuration switching.
In a third aspect, an embodiment of the present application provides a terminal device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor executes the computer program to implement the method described above.
In a fourth aspect, the present application provides a storage medium storing a computer program, and when the computer program is executed by a processor, the computer program implements the method as described above.
In a fifth aspect, an embodiment of the present application provides a computer program product, which, when running on a terminal device, causes the terminal device to execute the application process configuration updating method described in any one of the above first aspects.
It is understood that the beneficial effects of the second aspect to the fifth aspect can be referred to the related description of the first aspect, and are not described herein again.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings used in the embodiments or the description of the prior art will be briefly described below.
Fig. 1 is a flowchart of an application process configuration updating method according to a first embodiment of the present application;
fig. 2 is a flowchart of an application process configuration updating method according to a second embodiment of the present application;
fig. 3 is a schematic structural diagram of an application process configuration updating system according to a third embodiment of the present application;
fig. 4 is a schematic structural diagram of a terminal device according to a fourth embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth, such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
As used in this specification and the appended claims, the term "if" may be interpreted contextually as "when", "upon" or "in response to" determining "or" in response to detecting ". Similarly, the phrase "if it is determined" or "if a [ described condition or event ] is detected" may be interpreted contextually to mean "upon determining" or "in response to determining" or "upon detecting [ described condition or event ]" or "in response to detecting [ described condition or event ]".
Furthermore, in the description of the present application and the appended claims, the terms "first," "second," "third," and the like are used for distinguishing between descriptions and not necessarily for describing or implying relative importance.
Reference throughout this specification to "one embodiment" or "some embodiments," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," or the like, in various places throughout this specification are not necessarily all referring to the same embodiment, but rather "one or more but not all embodiments" unless specifically stated otherwise. The terms "comprising," "including," "having," and variations thereof mean "including, but not limited to," unless expressly specified otherwise.
Example one
Please refer to fig. 1, which is a flowchart illustrating an application process configuration updating method according to a first embodiment of the present application, including the steps of:
step S10, when receiving the configuration updating command, inquiring the configuration updating file and the target server, and acquiring the monitoring process and the shared memory in the target server;
the application process configuration updating method is applied to any background with a configuration information issuing function, when the background receives a configuration updating instruction sent by a user, configuration information is inquired according to an instruction identifier stored in the configuration updating instruction, the inquired configuration information is set as a configuration updating file, preferably, the instruction identifier can be the name of the configuration information or the file inquiry path of the configuration information, further, a server identifier is stored in the configuration updating instruction, and the server identifier is matched with a server identifier table to inquire a corresponding target server.
Specifically, in this step, when the number of the queried target servers is greater than one, the path address of the monitor process and the memory address of the shared memory in each target server are respectively obtained, so as to achieve the effect of obtaining the monitor process and the shared memory in the target servers, where the monitor process and the shared memory in each target server are both in a data communication connection state, for example, when the queried target server includes server a1 and server a2, the path address of the monitor process in server a1 and server a2 and the memory address of the shared memory are respectively obtained, so as to correspondingly obtain path address b1, path address b2, memory address c1 and memory address c2, where the monitor process corresponding to path address b1 is monitor process d1, the monitor process corresponding to path address b2 is monitor process d2, and the shared memory corresponding to memory address c1 is shared memory e1, the shared memory corresponding to the memory address c2 is shared memory e 2.
Step S20, sending a shared connection instruction to the shared memory to instruct the shared memory to perform shared connection with at least two application processes in the target server;
for example, the shared connection instruction is sent to the memory address c1 and the memory address c2 to indicate that the shared memory e1 shares and connects with different application processes in the server a1, and indicate that the shared memory e2 shares and connects with different application processes in the server a 2.
Specifically, each target server is provided with at least two application processes, for example, when the server a1 is provided with an application process f1 and an application process f2, and the server a2 is provided with an application process f3 and an application process f4, the shared memory e1 is instructed to share and connect with the application process f1 and the application process f2, and the shared memory e2 is instructed to share and connect with the application process f3 and the application process f 4.
In some embodiments, the shared memory may also be indicated to share and connect with all the two application processes in the target server, so that all the two application processes in different servers can share and connect based on one shared memory, thereby reducing the number of shared memories.
Step S30, instructing the monitoring process to independently load the configuration update file to update the configuration information of the shared memory;
the configuration loading instruction is sent to each monitoring process respectively to instruct each monitoring process to independently load the configuration update file in the corresponding target server, so that each monitoring process updates the configuration information according to the loaded configuration update file and instructs each monitoring process to store the updated configuration information in the corresponding shared memory, and the effect of updating the configuration information of the shared memory is achieved.
For example, a configuration load instruction is sent to the listening process d1 and the listening process d2, respectively, to instruct the listening process d1 and the listening process d2 to independently load configuration update files in the server a1 and the server a2, and instruct the listening process d1 and the listening process d2 to store the updated configuration information in the shared memory e1 and the shared memory e2, so as to achieve the effect of updating the configuration information in the shared memory e1 and the shared memory e 2.
Preferably, in this embodiment, the monitor process may be a redis process, and by adopting the design that the redis process is used as the monitor process, a phenomenon that locking is required when updating exists in the shared memory is effectively overcome, and the update efficiency of the shared memory is improved.
Step S40, if the shared memory completes configuration update, sending a configuration switching instruction to the shared memory to instruct the shared memory to perform configuration switching;
the configuration switching instruction is sent to the shared memory by judging whether the configuration updating of each shared memory is finished or not, so that the phenomenon of configuration switching errors caused by incomplete configuration updating or abnormal configuration updating of the shared memory is effectively prevented.
Specifically, in this step, when update completion information sent by the shared memory is received, it is determined that the corresponding shared memory has completed configuration update, and a configuration switching instruction is sent to the shared memory to instruct the corresponding shared memory to perform configuration switching.
Step S50, if the shared memory completes configuration switching, sending a read instruction to the application process to instruct the application process to perform configuration updating according to the updated configuration information of the shared memory;
the configuration switching is respectively judged whether each shared memory completes the configuration switching or not so as to judge whether a reading instruction is sent to the application process corresponding to the shared memory or not, and errors of the application process in reading the configuration information caused by the fact that the shared memory does not complete the configuration switching or the configuration switching is abnormal are effectively prevented.
For example, when the shared memory e1 completes configuration switching, a read instruction is sent to the application process f1 and the application process f2, respectively, to instruct the application process f1 and the application process f2 to read the configuration information in the shared memory e1, and update the configuration information in the own process according to the read result, so that the application process f1 and the application process f2 do not need to load the configuration update file, and consumption of the memory in the server a1 is reduced.
In this embodiment, the configuration update file is loaded based on the monitoring process, so that the shared memory updates the configuration information, and the at least two different application processes are instructed to perform configuration update according to the updated configuration information of the shared memory based on the manner of the shared memory, so that the at least two different application processes do not need to repeatedly load the configuration update file, thereby reducing the memory loss in the target server and improving the data processing efficiency of the target server.
Example two
Please refer to fig. 2, which is a flowchart illustrating an application process configuration updating method according to a second embodiment of the present application, including the steps of:
step S11, when receiving the configuration updating command, inquiring the configuration updating file and the target server, and acquiring the monitoring process and the shared memory in the target server;
the application process configuration updating method is applied to any background with a configuration information issuing function, the number of inquired target servers can be multiple, and each target server is provided with a monitoring process and a shared memory.
Step S21, sending a shared connection instruction to the shared memory to instruct the shared memory to perform shared connection with at least two application processes in the target server;
wherein, each target server is at least provided with two application processes.
Step S31, instructing the monitoring process to independently load the configuration update file to update the configuration information of the shared memory;
and respectively instructing each monitoring process to independently load the configuration update file in the corresponding target server so as to update the configuration information of the corresponding shared memory.
Specifically, in this step, the method further includes:
step S310, if the monitoring process fails to load the configuration update file, a reload instruction is sent to the monitoring process to indicate the monitoring process to reload the configuration update file;
if it is detected that any monitoring process fails to load the configuration update file, a reload instruction is sent to the monitoring process which fails to load so as to indicate the monitoring process which fails to load the configuration update file again.
Step S311, if the failure loading times of the monitoring process to the configuration update file is greater than the time threshold, sending a configuration update error prompt aiming at the target server;
the method includes the steps of respectively obtaining the number of times of failed loading of each monitoring process on the configuration update file, and if it is detected that the number of times of failed loading corresponding to any monitoring process is greater than a number threshold, sending a configuration update error prompt to a target server corresponding to the monitoring process to prompt a corresponding user to manually update the configuration of the application process for the target server, where preferably, the number threshold may be set according to requirements, and for example, the number threshold may be set to 5 times, 6 times, 10 times, or the like.
Step S41, if receiving the update exception information sent by the shared memory, sending a configuration deletion instruction to the shared memory to instruct the shared memory to delete the configuration information generated by the configuration update, and sending a configuration update error prompt for the target server;
if the abnormal updating information sent by the shared memory is received, the corresponding abnormal updating of the shared memory configuration is judged, and the configuration updating abnormal is effectively played as an effect of rolling back the configuration information through the design of indicating the shared memory to delete the configuration information generated by the configuration updating, so that the abnormal phenomenon of the subsequent application process configuration updating caused by the abnormal configuration updating of the shared memory is prevented.
Further, in this step, if update exception information sent by any shared memory is received, a configuration update error prompt is sent for a target server corresponding to the shared memory with the update exception, so as to prompt a user to detect the shared memory in the target server.
Step S51, if the shared memory completes configuration update, acquiring a configuration version number of the updated shared memory, and generating the configuration switching instruction according to the configuration version number;
preferably, in this step, when the number of the target servers is greater than one, the method further includes:
if update completion information sent by any one shared memory is received, the shared memory is marked with update success;
if update abnormal information sent by any one shared memory is received, carrying out update error marking on the shared memory;
obtaining the total number of the marks obtained after the successful updating marks and the wrong updating marks are accumulated, and if the total number of the marks is equal to the number of the target servers, sending a configuration switching instruction to different shared memories to indicate the shared memories to perform configuration switching;
if the shared memory completes configuration switching, sending a reading instruction to the application process to indicate the application process to perform configuration updating according to the updated configuration information of the shared memory;
for example, when the marking result of the background to the shared memory includes 3 successful updating marks and 4 erroneous updating marks, the total number of the marks obtained by accumulation is 7, and whether the total number of the marks is equal to the number of the target servers is judged to determine whether to send the configuration switching instruction, so that the configuration switching of different shared memories can be effectively and synchronously controlled, the sending efficiency of the configuration switching instruction is improved, and the erroneous sending of the configuration switching instruction is prevented.
Step S61, sending the configuration switching instruction to the monitor process, and instructing the shared memory to perform configuration switching through the monitor process;
step S71, if the shared memory completes configuration switching, sending a read instruction to the application process to instruct the application process to perform configuration updating according to the updated configuration information of the shared memory;
step S81, acquiring the configuration version number of the monitoring process according to a preset time interval, and respectively comparing the configuration version number of each application process with the configuration version number in the monitoring process;
the method comprises the steps of respectively carrying out version comparison design on the configuration version number of each application process in the same target server and the configuration version number in the monitoring process, and judging whether the configuration information between the application process and the monitoring process after the configuration is updated is consistent or not in a mode based on the version numbers.
Step S91, if the configuration version number of any application process is different from the configuration version number of the monitoring process, sending a read instruction to the application process to instruct the application process to perform configuration updating again according to the configuration information of the shared memory;
if the configuration version number of any application process is different from the configuration version number of the corresponding monitoring process, the application process is instructed to perform configuration updating again according to the configuration information of the corresponding shared memory, so that the consistency of the configuration information in each application process is guaranteed.
Specifically, in this embodiment, if the configuration version number of any one of the application processes is different from the configuration version number of the monitoring process, after sending the read instruction to the application process, the method further includes:
if the sending times of sending the reading instruction to any application process within the preset time is greater than the preset times, marking the application process as an abnormal process, and performing abnormal prompt on the abnormal process, wherein the user is prompted to detect the abnormal process by sending the design of the abnormal prompt to the abnormal process;
if the number of the abnormal processes in the target server is larger than the preset number, the shared memory is marked as an abnormal memory, and abnormal prompt is conducted on the abnormal memory, wherein if the number of the abnormal processes in the target server is larger than the preset number, the shared memory in the target server is judged to be abnormal, and the abnormal memory is prompted to be detected by a user through the design of the abnormal prompt.
In the embodiment, the configuration information generated by the configuration update is deleted by sending a configuration deletion instruction to the abnormal shared memory, so that the abnormal shared memory is effectively deleted, the configuration update is effectively rolled back, the abnormal phenomenon of the subsequent application process configuration update caused by the abnormal configuration update of the shared memory is prevented, the consistency of the configuration information between each application process is improved by respectively comparing the configuration version number of each application process in the same target server with the configuration version number in the monitoring process and judging whether the configuration information between the updated application process and the monitoring process is consistent in a version number-based mode through the design of carrying out version comparison on the configuration version number of each application process in the same target server and the configuration version number in the monitoring process, and the configuration information of the shared memory is updated through loading the configuration update file based on the monitoring process, and indicating at least two different application processes to perform configuration updating according to the updated configuration information of the shared memory based on the mode of the shared memory, so that the at least two different application processes do not need to repeatedly load the configuration updating file, the memory loss in the target server is reduced, and the data processing efficiency of the target server is improved.
EXAMPLE III
Fig. 3 is a schematic structural diagram of an application process configuration updating system 100 according to a third embodiment of the present application, and for convenience of description, only the parts related to the embodiment of the present application are shown.
Referring to fig. 3, the system includes: a server query module 10, a sharing indication module 11, a configuration loading module 12, a configuration switching indication module 13, and a configuration update indication module 14, wherein:
and the server query module 10 is configured to query the configuration update file and the target server when receiving the configuration update instruction, and acquire a monitoring process and a shared memory in the target server.
A shared indication module 11, configured to send a shared connection instruction to the shared memory to indicate that the shared memory is in shared connection with at least two application processes in the target server.
A configuration loading module 12, configured to instruct the monitoring process to independently load the configuration update file, so as to update the configuration information of the shared memory.
Wherein the configuration loading module 12 is further configured to: if the monitoring process fails to load the configuration update file, sending a reload instruction to the monitoring process to instruct the monitoring process to reload the configuration update file;
and if the failure loading times of the monitoring process to the configuration updating file are larger than a time threshold value, sending a configuration updating error prompt aiming at the target server.
A configuration switching indication module 13, configured to send a configuration switching instruction to the shared memory to indicate the shared memory to perform configuration switching if the shared memory completes configuration updating.
Wherein, the configuration switching indication module 13 is further configured to: acquiring the updated configuration version number of the shared memory, and generating the configuration switching instruction according to the configuration version number;
and sending the configuration switching instruction to the monitoring process, and indicating the shared memory to perform configuration switching through the monitoring process.
A configuration update indicating module 14, configured to send a read instruction to the application process to indicate the application process to perform configuration update according to the updated configuration information of the shared memory if the shared memory completes configuration switching.
Wherein, when the number of the target servers is greater than one, the configuration update indication module 14 is further configured to: if update completion information sent by any one shared memory is received, the shared memory is marked with update success;
if update abnormal information sent by any one shared memory is received, carrying out update error marking on the shared memory;
obtaining the total number of the marks obtained after the successful updating marks and the wrong updating marks are accumulated, and if the total number of the marks is equal to the number of the target servers, sending a configuration switching instruction to different shared memories to indicate the shared memories to perform configuration switching;
and if the shared memory completes configuration switching, sending a reading instruction to the application process to indicate the application process to perform configuration updating according to the updated configuration information of the shared memory.
In addition, the application process configuration updating system 100 further includes:
a configuration comparison module 15, configured to obtain a configuration version number of the monitoring process according to a preset time interval, and perform version comparison between the configuration version number of each application process and the configuration version number in the monitoring process respectively;
and if the configuration version number of any application process is different from the configuration version number of the monitoring process, sending a reading instruction to the application process to indicate the application process to perform configuration updating again according to the configuration information of the shared memory.
A configuration deleting module 16, configured to send a configuration deleting instruction to the shared memory if the update exception information sent by the shared memory is received, so as to instruct the shared memory to delete the configuration information generated by the configuration update, and send a configuration update error prompt for the target server.
Preferably, the configuration update indication module 14 is further configured to: if the sending times of sending the reading instruction to any application process within the preset time are greater than the preset times, marking the application process as an abnormal process, and performing abnormal prompt on the abnormal process;
if the process number of the abnormal processes in the target server is larger than the preset number, marking the shared memory as an abnormal memory, and performing abnormal prompt on the abnormal memory.
In this embodiment, the configuration update file is loaded based on the monitoring process, so that the shared memory updates the configuration information, and the at least two different application processes are instructed to perform configuration update according to the updated configuration information of the shared memory based on the manner of the shared memory, so that the at least two different application processes do not need to repeatedly load the configuration update file, thereby reducing the memory loss in the target server and improving the data processing efficiency of the target server.
It should be noted that, for the information interaction, execution process, and other contents between the above-mentioned devices/modules, the specific functions and technical effects thereof are based on the same concept as those of the embodiment of the method of the present application, and reference may be made to the part of the embodiment of the method specifically, and details are not described here.
Fig. 4 is a schematic structural diagram of a terminal device 2 according to a fourth embodiment of the present application. As shown in fig. 4, the terminal device 2 of this embodiment includes: at least one processor 20 (only one processor is shown in fig. 4), a memory 21, and a computer program 22 stored in the memory 21 and executable on the at least one processor 20, the steps of any of the various method embodiments described above being implemented when the computer program 22 is executed by the processor 20.
The terminal device 2 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices. The terminal device may include, but is not limited to, a processor 20, a memory 21. Those skilled in the art will appreciate that fig. 4 is merely an example of the terminal device 2, and does not constitute a limitation of the terminal device 2, and may include more or less components than those shown, or combine some components, or different components, such as an input-output device, a network access device, and the like.
The Processor 20 may be a Central Processing Unit (CPU), and the Processor 20 may be other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The memory 21 may in some embodiments be an internal storage unit of the terminal device 2, such as a hard disk or a memory of the terminal device 2. The memory 21 may also be an external storage device of the terminal device 2 in other embodiments, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like, which are provided on the terminal device 2. Further, the memory 21 may also include both an internal storage unit and an external storage device of the terminal device 2. The memory 21 is used for storing an operating system, an application process, a BootLoader (BootLoader), data, and other programs, such as program codes of the computer program. The memory 21 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
An embodiment of the present application further provides a network device, where the network device includes: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, the processor implementing the steps of any of the various method embodiments described above when executing the computer program.
The embodiments of the present application further provide a computer-readable storage medium, where a computer program is stored, and when the computer program is executed by a processor, the computer program implements the steps in the above-mentioned method embodiments.
The embodiments of the present application provide a computer program product, which when running on a mobile terminal, enables the mobile terminal to implement the steps in the above method embodiments when executed.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, all or part of the processes in the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium and can implement the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer readable medium may include at least: any entity or device capable of carrying computer program code to a photographing apparatus/terminal apparatus, a recording medium, computer Memory, Read-Only Memory (ROM), random-access Memory (RAM), an electrical carrier signal, a telecommunications signal, and a software distribution medium. Such as a usb-disk, a removable hard disk, a magnetic or optical disk, etc. In certain jurisdictions, computer-readable media may not be an electrical carrier signal or a telecommunications signal in accordance with legislative and patent practice.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/network device and method may be implemented in other ways. For example, the above-described apparatus/network device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical division, and there may be other divisions when actually implementing, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not implemented. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not substantially depart from the spirit and scope of the embodiments of the present application and are intended to be included within the scope of the present application.