CN110221854A - A kind of multi-process data-updating method, device, medium and electronic equipment - Google Patents

A kind of multi-process data-updating method, device, medium and electronic equipment Download PDF

Info

Publication number
CN110221854A
CN110221854A CN201910460174.9A CN201910460174A CN110221854A CN 110221854 A CN110221854 A CN 110221854A CN 201910460174 A CN201910460174 A CN 201910460174A CN 110221854 A CN110221854 A CN 110221854A
Authority
CN
China
Prior art keywords
data
updating
instruction
update
updated
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201910460174.9A
Other languages
Chinese (zh)
Other versions
CN110221854B (en
Inventor
曾磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Douyin Vision Co Ltd
Beijing Volcano Engine Technology Co Ltd
Douyin Vision Beijing Co Ltd
Original Assignee
Beijing ByteDance Network Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing ByteDance Network Technology Co Ltd filed Critical Beijing ByteDance Network Technology Co Ltd
Priority to CN201910460174.9A priority Critical patent/CN110221854B/en
Publication of CN110221854A publication Critical patent/CN110221854A/en
Application granted granted Critical
Publication of CN110221854B publication Critical patent/CN110221854B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

Present disclose provides a kind of multi-process data-updating method, device, medium and electronic equipment, which includes: service processes monitor whether have data more new command in real time, if listening to the more new command, the more new command is sent to host process;The host process determines the more fresh target of the more new command according to the more new command, and the more fresh target includes at least one progress of work;The more fresh target will need the parameter updated to be sent to corresponding memory storehouse according to the more new command;The memory storehouse obtains the data of update from data warehouse, completes the update of corresponding process data.This method can actively be updated and non-passive or periodically update with the quick replacement problem of effective solution code, can be with prestissimo by newest code update to server;This method can also realize the code update of specified process, need to be a kind of effective solution scheme under the scene for treating process with a certain discrimination update for certain.

Description

Multi-process data updating method, device, medium and electronic equipment
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a method, an apparatus, a medium, and an electronic device for updating multiprocess data.
Background
In the application process of the computer program, certain data modules in the computer program are required to be updated. In order to ensure the continuity and stability of the service, the service provider often performs code update during the idle period of the code (for example, at night).
The general data updating method includes:
one problem with service backup/active-standby switching is that additional costs (hardware costs and deployment costs) need to be provided, which undoubtedly increases the operational costs.
And secondly, periodically updating the code, namely updating by using the dynamic language characteristics, for example, presetting an interface in the code, periodically checking a timestamp of the file, and triggering an updating logic after the file is updated. For example, java is implemented as: the interface class is defined first, and then the class's actual loading work is completed by using the loadClass method of the class loader class.
The above method has the following defects:
firstly, updating cannot be performed in real time, as described above, the mainstream dynamic code updating schemes are all preset interfaces, a periodic check rule is set to update the codes, and the codes are updated and then the updating is performed until the next updating period is reached.
Secondly, it is impossible to specify a process to perform a row update individually, usually we will create many processes in a service by means of fork (duplication or derivation), each process serves a client, for example, a network server in a socket usually serves multiple clients simultaneously with fork, a parent process is specially responsible for monitoring ports, and fork serves a child process to serve the client specifically every time a new client connection is received. If we only want to update the code only for a certain process, no code update is performed by other fork processes, and this time, the existing scheme cannot support.
BRIEF SUMMARY OF THE PRESENT DISCLOSURE
The present disclosure is directed to a multi-process data updating method, apparatus, medium, and electronic device, which can solve at least one of the above-mentioned technical problems. The specific scheme is as follows:
according to a specific implementation manner of the present disclosure, in a first aspect, the present disclosure provides a multi-process data updating method, including:
the service process monitors whether a data updating instruction exists in real time, and if the data updating instruction is monitored, the service process sends the updating instruction to the main process;
the main process determines an update target of the update instruction according to the update instruction, wherein the update target comprises at least one work process;
the updating target sends the parameters to be updated to the corresponding memory stack according to the updating instruction;
and the memory stack acquires updated data from the data warehouse to complete the updating of the corresponding process data.
Optionally, the service process monitors whether there is a data update instruction in real time, and if it is monitored that there is the update instruction, sends the update instruction to the host process, including:
the service process monitors whether a data updating instruction exists from a network interface in real time;
if the updating instruction is monitored, sending the updating instruction to an internal communication pool, wherein the internal communication pool is used for realizing the communication between the main process and different working processes and/or service processes through respective communication interfaces;
and the internal communication pool informs the main process of updating data.
Optionally, the sending, by the update target, the parameter to be updated to the corresponding memory stack according to the update instruction includes:
the at least one working process receives the updating instruction through the corresponding communication interface;
determining parameters needing to be updated according to the updating instruction;
and sending the parameters needing to be updated to the corresponding memory stacks.
Optionally, the obtaining, by the memory stack, updated data from the data warehouse to complete updating of corresponding process data includes:
the memory stack calls a parameter updating module;
the parameter updating module sends the characteristics of the parameters needing to be updated to a data warehouse according to different language characteristics;
and the data warehouse returns updated data to the memory stack, so that the at least one working process is updated, and the updating of the corresponding process data is completed.
Optionally, the method further includes:
and after the data updating is finished, sending a callback instruction to the network interface, wherein the callback instruction is used for explaining that the updating is finished.
Optionally, the parameters include a module name, a process name, a download url, and a server ip, which specify the code that needs to be updated.
According to a second aspect, the present disclosure provides a multi-process data updating apparatus, including:
the monitoring unit is used for monitoring whether a data updating instruction exists in real time in the service process, and if the data updating instruction is monitored, the monitoring unit sends the updating instruction to the main process;
the determining unit is used for determining an update target of the update instruction according to the update instruction by the main process, wherein the update target comprises at least one working process;
the sending unit is used for sending the parameters to be updated to the corresponding memory stacks by the updating target according to the updating instruction;
and the updating unit is used for acquiring updated data from the data warehouse by the memory stack and finishing the updating of the corresponding process data.
Optionally, the listening unit is further configured to:
the service process monitors whether a data updating instruction exists from a network interface in real time;
if the updating instruction is monitored, sending the updating instruction to an internal communication pool, wherein the internal communication pool is used for realizing the communication between the main process and different working processes and/or service processes through respective communication interfaces;
and the internal communication pool informs the main process of updating data.
According to a third aspect, the present disclosure provides a computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the method of any one of the above.
According to a fourth aspect thereof, the present disclosure provides an electronic device, comprising: one or more processors; storage means for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to carry out a method as claimed in any preceding claim.
Compared with the prior art, the scheme of the embodiment of the disclosure at least has the following beneficial effects: by providing the multi-process data updating method, the multi-process data updating device, the multi-process data updating medium and the electronic equipment, the method can effectively solve the problem of quick updating of codes, actively updates the codes instead of passively or periodically, and can update the latest codes to the server at the highest speed; the method can also realize the code updating of the appointed process, and is an effective solution for some scenes needing to treat updating differently for the process.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and together with the description, serve to explain the principles of the disclosure. It is to be understood that the drawings in the following description are merely exemplary of the disclosure, and that other drawings may be derived from those drawings by one of ordinary skill in the art without the exercise of inventive faculty. In the drawings:
FIG. 1 shows a flow diagram of a multi-process data update method according to an embodiment of the present disclosure;
FIG. 2 illustrates a flowchart execution diagram of a multi-process data update method according to an embodiment of the present disclosure;
FIG. 3 is a schematic diagram of a multi-process data updating apparatus according to an embodiment of the present disclosure;
fig. 4 shows an electronic device connection structure schematic according to an embodiment of the present disclosure.
Detailed Description
To make the objects, technical solutions and advantages of the present disclosure clearer, the present disclosure will be described in further detail with reference to the accompanying drawings, and it is apparent that the described embodiments are only a part of the embodiments of the present disclosure, rather than all embodiments. All other embodiments, which can be derived by one of ordinary skill in the art from the embodiments disclosed herein without making any creative effort, shall fall within the scope of protection of the present disclosure.
The terminology used in the embodiments of the present disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. As used in the disclosed embodiments and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise, and "a plurality" typically includes at least two.
It should be understood that the term "and/or" as used herein is merely one type of association that describes an associated object, meaning that three relationships may exist, e.g., a and/or B may mean: a exists alone, A and B exist simultaneously, and B exists alone. In addition, the character "/" herein generally indicates that the former and latter related objects are in an "or" relationship.
It should be understood that although the terms first, second, third, etc. may be used to describe … … in embodiments of the present disclosure, these … … should not be limited to these terms. These terms are used only to distinguish … …. For example, the first … … can also be referred to as the second … … and, similarly, the second … … can also be referred to as the first … … without departing from the scope of embodiments of the present disclosure.
The words "if", as used herein, may be interpreted as "at … …" or "at … …" or "in response to a determination" or "in response to a detection", depending on the context. Similarly, the phrases "if determined" or "if detected (a stated condition or event)" may be interpreted as "when determined" or "in response to a determination" or "when detected (a stated condition or event)" or "in response to a detection (a stated condition or event)", depending on the context.
It is also noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that an article or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such article or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in the article or device in which the element is included.
Alternative embodiments of the present disclosure are described in detail below with reference to the accompanying drawings.
Example 1
As shown in fig. 1, according to a specific embodiment of the present disclosure, in a first aspect, the present disclosure provides a flowchart of a multi-process data updating method.
Data update (data update) is a process of replacing a new data item or record with a corresponding old data item or record in a data file or database. Including local data updates and full data updates.
The method is suitable for the hot updating of data in a multi-process working mode, wherein the hot updating refers to updating the data at any time, only one or a plurality of processes needing to be updated are updated during updating, and the rest processes can still work normally. The method specifically comprises the following steps:
step S102: and the service process monitors whether a data updating instruction exists in real time, and if the data updating instruction is monitored, the service process sends the updating instruction to the main process.
A service process (ServerProcess) is a service type process that runs in the background. Service processes may typically provide some functionality to users locally and over a network, such as client/server applications, Web servers, database servers, and other server-based applications. The service process may run without the user logging in and the user having logged out.
The ServerProcess process belongs to a network monitoring process in the embodiment, and is responsible for receiving a network post and receiving a code updating instruction transmitted from a network end so as to support immediate updating.
The main process (MainProcess) is a master process, holds a work process (WorkProcess) instance and a service process instance, and can distribute interprocess messages (IPC messages) to different processes.
Optionally, the service process monitors whether there is a data update instruction in real time, and if it is monitored that there is the update instruction, sends the update instruction to the host process, including:
the service process monitors whether a data updating instruction exists from a network interface in real time; if the update instruction is monitored (step 0: obtaining the update instruction), sending the update instruction to an internal communication pool (step 1: UpdateIPCMessage), wherein the internal communication pool is used for realizing communication between the main process and different work processes and/or service processes through respective communication interfaces; the internal communication pool informs the main process of data updating, and the internal communication pool (IPC MessagePool) is used for storing communication messages and communicating among the internal processes. As shown in fig. 2.
Step S104: and the main process determines an update target of the update instruction according to the update instruction, wherein the update target comprises at least one work process.
The work process: the system is responsible for carrying out direct working logic, a new process can be generated through fork to be connected with a new service, and each workProcess process has a process serial number of the workProcess.
The main process distributes an update instruction (step 2: distribution), the update instruction is an instruction obtained through a network interface, the update instruction comprises specific parameters of update and updates one or more processes, after receiving the update instruction, the main process analyzes the contents and then sends the update instruction to a corresponding work process through a communication interface (ProcessHandler) (step 3: IPCMessage). And the rest processes which do not receive the updating instruction still execute the program of the original process.
Step S106: and the updating target sends the parameters to be updated to the corresponding memory stack according to the updating instruction (4 steps: OnUPdateMessage).
Optionally, the sending, by the update target, the parameter to be updated to the corresponding memory stack according to the update instruction includes:
the at least one work process receives the updating instruction through a corresponding communication interface (ProcessHandler); determining parameters needing to be updated (such as updating pointer class or certain variable parameters) according to the updating instruction; and sending the parameters needing to be updated to the corresponding memory stacks.
The memory stack is a temporary module unit used for storing parameter contents needing to be updated, and has different updating methods for different languages.
Optionally, the parameters include a module name, a process name, a download url, and a server ip, which specify the code that needs to be updated.
Step S108: and the memory stack acquires updated data from the data warehouse to complete the updating of the corresponding process data.
Optionally, the obtaining, by the memory stack, updated data from the data warehouse to complete updating of corresponding process data includes:
the memory stack calls a parameter updating module (step 5: UPdatestack); the parameter updating module sends the parameters to be updated to a data warehouse according to different language characteristics according to the characteristics of the parameters to be updated (step 5.1: updateImpII); the data warehouse returns the updated data to the memory stack (step 5.2: netGet), and then updates the at least one working process (step 5.3: doupdatestack), completing the update of the corresponding process data (step 6: new coderun), as shown in fig. 2.
Optionally, the method further includes: and after the data updating is finished, sending a callback instruction to the network interface, wherein the callback instruction is used for explaining that the updating is finished.
The method can effectively solve the problem of quick update of the codes, actively updates instead of passively or periodically, and can update the latest codes to the server at the highest speed; the method can also realize the code updating of the appointed process, and is an effective solution for some scenes needing to treat updating differently for the process.
Example 2
As shown in fig. 3, this embodiment is similar to embodiment 1 in the explanation of embodiment 1 based on the same name and meaning, and has the same technical effect as embodiment 1 when the embodiment is applied to embodiment 1 to implement the method steps as described in embodiment 1, and thus, the description thereof is omitted here
Data update (data update) is a process of replacing a new data item or record with a corresponding old data item or record in a data file or database. Including local data updates and full data updates.
The device described in this embodiment is suitable for hot update of data in a multi-process operating mode, where the hot update refers to updating data at any time, and only one or some processes that need to be updated are updated during update, and the rest processes can still work normally. According to a specific embodiment of the present disclosure, the present disclosure provides a multiprocess data update apparatus, including: the monitoring unit 302, the determining unit 304, the sending unit 306, and the updating unit 308 are as follows:
the listening unit 302: and the service process monitors whether a data updating instruction exists in real time, and if the data updating instruction is monitored, the service process sends the updating instruction to the main process.
A service process (ServerProcess) is a service type process that runs in the background. Service processes may typically provide some functionality to users locally and over a network, such as client/server applications, Web servers, database servers, and other server-based applications. The service process may run without the user logging in and the user having logged out.
The ServerProcess process belongs to a network monitoring process in the embodiment, and is responsible for receiving a network post and receiving a code updating instruction transmitted from a network end so as to support immediate updating.
The main process (MainProcess) is a master process, holds a work process (WorkProcess) instance and a service process instance, and can distribute interprocess messages (IPC messages) to different processes.
Optionally, the service process monitors whether there is a data update instruction in real time, and if it is monitored that there is the update instruction, sends the update instruction to the host process, including:
the service process monitors whether a data updating instruction exists from a network interface in real time; if the update instruction is monitored (step 0: obtaining the update instruction), sending the update instruction to an internal communication pool (step 1: UpdateIPCMessage), wherein the internal communication pool is used for realizing communication between the main process and different work processes and/or service processes through respective communication interfaces; the internal communication pool informs the main process of data updating, and the internal communication pool (IPC MessagePool) is used for storing communication messages and communicating among the internal processes. As shown in fig. 2.
The determination unit 304: and the main process determines an update target of the update instruction according to the update instruction, wherein the update target comprises at least one work process.
The work process: the system is responsible for carrying out direct working logic, a new process can be generated through fork to be connected with a new service, and each workProcess process has a process serial number of the workProcess.
The main process distributes an update instruction (step 2: distribution), the update instruction is an instruction obtained through a network interface, the update instruction comprises specific parameters of update and updates one or more processes, after receiving the update instruction, the main process analyzes the contents and then sends the update instruction to a corresponding work process through a communication interface (ProcessHandler) (step 3: IPCMessage). And the rest processes which do not receive the updating instruction still execute the program of the original process.
The transmission unit 306: and the updating target sends the parameters to be updated to the corresponding memory stack according to the updating instruction (4 steps: OnUPdateMessage).
Optionally, the sending, by the update target, the parameter to be updated to the corresponding memory stack according to the update instruction includes:
the at least one work process receives the updating instruction through a corresponding communication interface (ProcessHandler); determining parameters needing to be updated (such as updating pointer class or certain variable parameters) according to the updating instruction; and sending the parameters needing to be updated to the corresponding memory stacks.
The memory stack is a temporary module unit used for storing parameter contents needing to be updated, and has different updating methods for different languages.
Optionally, the parameters include a module name, a process name, a download url, and a server ip, which specify the code that needs to be updated.
The updating unit 308: and the memory stack acquires updated data from the data warehouse to complete the updating of the corresponding process data.
Optionally, the obtaining, by the memory stack, updated data from the data warehouse to complete updating of corresponding process data includes:
the memory stack calls a parameter updating module (step 5: UPdatestack); the parameter updating module sends the parameters to be updated to a data warehouse according to different language characteristics according to the characteristics of the parameters to be updated (step 5.1: updateImpII); the data warehouse returns the updated data to the memory stack (step 5.2: netGet), and then updates the at least one working process (step 5.3: doupdatestack), completing the update of the corresponding process data (step 6: new coderun), as shown in fig. 2.
Optionally, the method further includes: and after the data updating is finished, sending a callback instruction to the network interface, wherein the callback instruction is used for explaining that the updating is finished.
The multi-process data updating device can effectively solve the problem of quick updating of codes, actively updates instead of passively or periodically, and can update the latest codes to a server at the highest speed; the method can also realize the code updating of the appointed process, and is an effective solution for some scenes needing to treat updating differently for the process.
Example 3
As shown in fig. 4, the present embodiment provides an electronic device, which is configured to provide a data service, and includes: at least one processor; and a memory communicatively coupled to the at least one processor; wherein,
the memory stores instructions executable by the one processor to cause the at least one processor to perform the method steps of the above embodiments.
Example 4
The disclosed embodiments provide a non-volatile computer storage medium having stored thereon computer-executable instructions that may perform the method steps as described in the embodiments above.
Example 5
Referring now to FIG. 4, shown is a schematic diagram of an electronic device suitable for use in implementing embodiments of the present disclosure. The terminal device in the embodiments of the present disclosure may include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (personal digital assistant), a PAD (tablet computer), a PMP (portable multimedia player), a vehicle terminal (e.g., a car navigation terminal), and the like, and a stationary terminal such as a digital TV, a desktop computer, and the like. The electronic device shown in fig. 4 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present disclosure.
As shown in fig. 4, the electronic device may include a processing means (e.g., a central processing unit, a graphics processor, etc.) 401 that may perform various appropriate actions and processes according to a program stored in a Read Only Memory (ROM)402 or a program loaded from a storage means 408 into a Random Access Memory (RAM) 403. In the RAM 403, various programs and data necessary for the operation of the electronic apparatus are also stored. The processing device 401, the ROM 402, and the RAM 403 are connected to each other via a bus 405. An input/output (I/O) interface 405 is also connected to bus 405.
Generally, the following devices may be connected to the I/O interface 405: input devices 406 including, for example, a touch screen, touch pad, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; output devices 405 including, for example, a Liquid Crystal Display (LCD), speakers, vibrators, or the like; storage 408 including, for example, tape, hard disk, etc.; and a communication device 405. The communication means 405 may allow the electronic device to communicate wirelessly or by wire with other devices to exchange data. While fig. 4 illustrates an electronic device having various means, it is to be understood that not all illustrated means are required to be implemented or provided. More or fewer devices may alternatively be implemented or provided.
In particular, according to an embodiment of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network via the communication device 405, or may be installed from the storage device 408, or may be installed from the ROM 402. The computer program performs the above-described functions defined in the methods of the embodiments of the present disclosure when executed by the processing device 401.
It should be noted that the computer readable medium in the present disclosure can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present disclosure, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In contrast, in the present disclosure, a computer readable signal medium may comprise a propagated data signal with computer readable program code embodied therein, either in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: electrical wires, optical cables, RF (radio frequency), etc., or any suitable combination of the foregoing.
The computer readable medium may be embodied in the electronic device; or may exist separately without being assembled into the electronic device.
Computer program code for carrying out operations for aspects of the present disclosure may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C + +, and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a Local Area Network (LAN) or a Wide Area Network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet service provider).
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The units described in the embodiments of the present disclosure may be implemented by software or hardware. Where the name of an element does not in some cases constitute a limitation on the element itself.

Claims (10)

1. A multi-process data updating method is characterized by comprising the following steps:
the service process monitors whether a data updating instruction exists in real time, and if the data updating instruction is monitored, the service process sends the updating instruction to the main process;
the main process determines an update target of the update instruction according to the update instruction, wherein the update target comprises at least one work process;
the updating target sends the parameters to be updated to the corresponding memory stack according to the updating instruction;
and the memory stack acquires updated data from the data warehouse to complete the updating of the corresponding process data.
2. The method of claim 1, wherein the service process monitors whether there is a data update command in real time, and if the data update command is monitored, the service process sends the data update command to a host process, including:
the service process monitors whether a data updating instruction exists from a network interface in real time;
if the updating instruction is monitored, sending the updating instruction to an internal communication pool, wherein the internal communication pool is used for realizing the communication between the main process and different working processes and/or service processes through respective communication interfaces;
and the internal communication pool informs the main process of updating data.
3. The method of claim 2, wherein the updating target sends the parameters to be updated to the corresponding memory stack according to the update instruction, comprising:
the at least one working process receives the updating instruction through the corresponding communication interface;
determining parameters needing to be updated according to the updating instruction;
and sending the parameters needing to be updated to the corresponding memory stacks.
4. The method of claim 3, wherein the memory stack obtaining updated data from the data warehouse and completing the update of the corresponding process data comprises:
the memory stack calls a parameter updating module;
the parameter updating module sends the characteristics of the parameters needing to be updated to a data warehouse according to different language characteristics;
and the data warehouse returns updated data to the memory stack, so that the at least one working process is updated, and the updating of the corresponding process data is completed.
5. The method of claim 4, further comprising:
and after the data updating is finished, sending a callback instruction to the network interface, wherein the callback instruction is used for explaining that the updating is finished.
6. The method of claim 1, wherein the parameters include a module name, a process name, a download url, and a server ip that specify code that needs to be updated more.
7. A multiprocess data update apparatus, comprising:
the monitoring unit is used for monitoring whether a data updating instruction exists in real time in the service process, and if the data updating instruction is monitored, the monitoring unit sends the updating instruction to the main process;
the determining unit is used for determining an update target of the update instruction according to the update instruction by the main process, wherein the update target comprises at least one working process;
the sending unit is used for sending the parameters to be updated to the corresponding memory stacks by the updating target according to the updating instruction;
and the updating unit is used for acquiring updated data from the data warehouse by the memory stack and finishing the updating of the corresponding process data.
8. The apparatus of claim 7, wherein the listening unit is further to:
the service process monitors whether a data updating instruction exists from a network interface in real time;
if the updating instruction is monitored, sending the updating instruction to an internal communication pool, wherein the internal communication pool is used for realizing the communication between the main process and different working processes and/or service processes through respective communication interfaces;
and the internal communication pool informs the main process of updating data.
9. A computer-readable storage medium, on which a computer program is stored, which program, when being executed by a processor, carries out the method according to any one of claims 1 to 6.
10. An electronic device, comprising:
one or more processors;
storage means for storing one or more programs which, when executed by the one or more processors, cause the one or more processors to carry out the method of any one of claims 1 to 6.
CN201910460174.9A 2019-05-30 2019-05-30 Multi-process data updating method, device, medium and electronic equipment Active CN110221854B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910460174.9A CN110221854B (en) 2019-05-30 2019-05-30 Multi-process data updating method, device, medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910460174.9A CN110221854B (en) 2019-05-30 2019-05-30 Multi-process data updating method, device, medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN110221854A true CN110221854A (en) 2019-09-10
CN110221854B CN110221854B (en) 2023-02-28

Family

ID=67818860

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910460174.9A Active CN110221854B (en) 2019-05-30 2019-05-30 Multi-process data updating method, device, medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN110221854B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111191249A (en) * 2019-12-31 2020-05-22 奇安信科技集团股份有限公司 Safeguarding method for a safeguarding device, safeguarding device and readable storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103838761A (en) * 2012-11-23 2014-06-04 阿里巴巴集团控股有限公司 Metadata updating method and device
CN106909128A (en) * 2015-12-23 2017-06-30 中国科学院沈阳自动化研究所 A kind of motion control method for supporting motion-control module online upgrading
US20180060568A1 (en) * 2016-08-23 2018-03-01 Qualcomm Incorporated System And Method Of Dynamically Updating Stack Canaries
CN108241496A (en) * 2016-12-23 2018-07-03 北京奇虎科技有限公司 The smooth upgrading method and device of application program
CN108388431A (en) * 2018-02-13 2018-08-10 广东欧珀移动通信有限公司 The newer control method of application program heat, device, storage medium and mobile terminal
CN108809838A (en) * 2018-06-28 2018-11-13 北京顺丰同城科技有限公司 A kind of service discovery processing method and processing device based on tree structure

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103838761A (en) * 2012-11-23 2014-06-04 阿里巴巴集团控股有限公司 Metadata updating method and device
CN106909128A (en) * 2015-12-23 2017-06-30 中国科学院沈阳自动化研究所 A kind of motion control method for supporting motion-control module online upgrading
US20180060568A1 (en) * 2016-08-23 2018-03-01 Qualcomm Incorporated System And Method Of Dynamically Updating Stack Canaries
CN108241496A (en) * 2016-12-23 2018-07-03 北京奇虎科技有限公司 The smooth upgrading method and device of application program
CN108388431A (en) * 2018-02-13 2018-08-10 广东欧珀移动通信有限公司 The newer control method of application program heat, device, storage medium and mobile terminal
CN108809838A (en) * 2018-06-28 2018-11-13 北京顺丰同城科技有限公司 A kind of service discovery processing method and processing device based on tree structure

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111191249A (en) * 2019-12-31 2020-05-22 奇安信科技集团股份有限公司 Safeguarding method for a safeguarding device, safeguarding device and readable storage medium
CN111191249B (en) * 2019-12-31 2022-04-22 奇安信科技集团股份有限公司 Safeguarding method for a safeguarding device, safeguarding device and readable storage medium

Also Published As

Publication number Publication date
CN110221854B (en) 2023-02-28

Similar Documents

Publication Publication Date Title
CN110909521B (en) Online document information synchronous processing method and device and electronic equipment
CN110166791B (en) Connection establishing method, device, equipment and storage medium
CN111694757B (en) Application program testing method and device, electronic equipment and computer readable storage medium
CN113900834B (en) Data processing method, device, equipment and storage medium based on Internet of things technology
CN109471647B (en) Data updating method and device, electronic equipment and readable medium
CN110221857A (en) The problem of application program restorative procedure, device, electronic equipment and storage medium
CN110554918A (en) Current limiting method, current limiting device, electronic equipment and computer readable storage medium
CN110221854B (en) Multi-process data updating method, device, medium and electronic equipment
CN107818027B (en) Method and device for switching main name node and standby name node and distributed system
CN111596992B (en) Navigation bar display method and device and electronic equipment
CN111538717B (en) Data processing method, device, electronic equipment and computer readable medium
CN112817701B (en) Timer processing method, device, electronic equipment and computer readable medium
CN111324386B (en) Method and device for starting split application program, electronic equipment and storage medium
CN114385096B (en) Display control method, device, terminal and storage medium
CN112799863B (en) Method and device for outputting information
CN112882921B (en) Fault simulation method and device
CN114398098B (en) Application script execution method, device, electronic equipment and computer readable medium
CN109582193B (en) Control display method of item cells in list management group and electronic equipment
CN116360710B (en) Data storage method applied to server cluster, electronic device and readable medium
CN110750242B (en) File deployment method, system, medium and electronic equipment
CN114513548B (en) Directional call information processing method and device
CN113094211B (en) Backup data processing method and device
CN111796802B (en) Function package generation method and device and electronic equipment
CN111949833B (en) Index construction method, data processing method, device, electronic equipment and medium
CN112749042B (en) Application running method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant
CP01 Change in the name or title of a patent holder
CP01 Change in the name or title of a patent holder

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee after: Douyin Vision Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee before: Tiktok vision (Beijing) Co.,Ltd.

Address after: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee after: Tiktok vision (Beijing) Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee before: BEIJING BYTEDANCE NETWORK TECHNOLOGY Co.,Ltd.

TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20230710

Address after: 100190 1309, 13th floor, building 4, Zijin Digital Park, Haidian District, Beijing

Patentee after: Beijing volcano Engine Technology Co.,Ltd.

Address before: 100041 B-0035, 2 floor, 3 building, 30 Shixing street, Shijingshan District, Beijing.

Patentee before: Douyin Vision Co.,Ltd.