CN108429597A - Electronic equipment, method for synchronizing time and module - Google Patents
Electronic equipment, method for synchronizing time and module Download PDFInfo
- Publication number
- CN108429597A CN108429597A CN201810121325.3A CN201810121325A CN108429597A CN 108429597 A CN108429597 A CN 108429597A CN 201810121325 A CN201810121325 A CN 201810121325A CN 108429597 A CN108429597 A CN 108429597A
- Authority
- CN
- China
- Prior art keywords
- time
- local
- master
- node
- host node
- 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.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04J—MULTIPLEX COMMUNICATION
- H04J3/00—Time-division multiplex systems
- H04J3/02—Details
- H04J3/06—Synchronising arrangements
- H04J3/0635—Clock or time synchronisation in a network
- H04J3/0638—Clock or time synchronisation among nodes; Internode synchronisation
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Synchronisation In Digital Transmission Systems (AREA)
Abstract
The present embodiments relate to computer software technical fields, disclose a kind of electronic equipment, method for synchronizing time and module.Method includes:Time difference calculating process specifically includes, and obtains and asks to host node sending time, and records the local sending time of time acquisition request;The master time of host node feedback is received, and records the local reception time of master time;The master time of host node feedback is the master time at the feedback moment;According to local sending time, local reception time and the master time for feeding back the moment, calculate from node and host node in the time difference for feeding back the moment;Synchronizing process specifically includes:Obtain the local zone time at current time;According to the local zone time at current time and time difference, the master time at current time is calculated.The problem of being relied on the invention enables Distributed Application and itself realize time synchronization, business processing can be influenced to avoid the Time Inconsistency for leading to Distributed Application acquisition due to machine system Time Inconsistency.
Description
Technical field
The present embodiments relate to computer software technical fields, more particularly to electronic equipment, method for synchronizing time and mould
Block.
Background technology
With the development of technology, the application of distributed structure/architecture is more and more universal.In distributed deployment framework, each
Distributed Application (hereinafter referred to as component) obtain current time be all directly acquire machine that the Distributed Application is disposed be
It unites the time.In order to ensure that the component of distributed deployment can get close or consistent time, Jiu get Shi in synchronization
The system time for now disposing the machine of these components is consistent or close;Disposing the machine of these components must be periodically
System time synchronization.
Inventor has found that at least there are the following problems in the prior art:Since operation expanding either machine is replaced, if
New machine does not do system time synchronization, causes with the machine of other deployments distributed component there are the larger time difference, will
Lead to the Time Inconsistency that component is got, to influence business processing.
Invention content
Embodiment of the present invention is designed to provide a kind of electronic equipment, method for synchronizing time and module so that distribution
Formula application, which can rely on, itself realizes time synchronization, without the system time dependent on machine where Distributed Application, from
And business can be influenced to avoid the inconsistent Time Inconsistency for causing Distributed Application to get of the system time due to machine
The problem of processing.
In order to solve the above technical problems, embodiments of the present invention provide a kind of method for synchronizing time, including it is applied to
As the Distributed Application from node in distributed system, the method includes:Time difference calculating process, specifically includes, to institute
It states the Distributed Application sending time in distributed system as host node and obtains request, and record the time acquisition request
Local sending time;When receiving the master time of the host node feedback, and recording the local reception of the master time
Between;The master time of the wherein described host node feedback is the master time at the feedback moment;When according to the local transmission
Between, the master time of the local reception time and the feedback moment, calculate and described exist from node and the host node
The time difference at the feedback moment;Synchronizing process specifically includes, and obtains the local zone time at current time;According to it is described current when
It the local zone time at quarter and the time difference, calculates the master time at the current time and exists from node as described
The synchronization time at the current time.
Embodiments of the present invention additionally provide a kind of time synchronization module, including:Applied to conduct in distributed system
From the Distributed Application of node, the module includes:Time difference computational submodule, specifically includes, transmission unit, is used for described
It obtains and asks as the Distributed Application sending time of host node in distributed system, and record the sheet of the time acquisition request
Ground sending time;Receiving unit, the master time for receiving the host node feedback, and record the master time
The local reception time;The master time of the wherein described host node feedback is the master time at the feedback moment;First calculates
Unit, for according to the local sending time, the master time of the local reception time and the feedback moment, calculating
From node and the host node in the time difference for feeding back the moment described in going out;Synchronous submodule, specifically includes:Acquiring unit,
Local zone time for obtaining current time;Second computing unit, for according to the local zone time at the current time with it is described
Time difference, calculate the master time at the current time and as it is described from node the current time synchronization
Time.
Embodiments of the present invention additionally provide a kind of electronic equipment, including:At least one processor;With described at least one
The memory of a processor communication connection;And the Distributed Application in the memory is stored in instruction type;Wherein,
The instruction of the characterization Distributed Application stored in the memory can be executed by least one processor, the finger
It enables and being executed by least one processor, so that at least one processor is able to carry out above-mentioned method for synchronizing time.
Embodiments of the present invention additionally provide computer readable storage medium, are stored with computer program, the calculating
Machine program realizes above-mentioned method for synchronizing time when being executed by processor.
In terms of existing technologies, this method is applied in distributed system as from node embodiment of the present invention
Distributed Application;In time difference calculating process, from node calculate host node with from node synchronization time difference;
In synchronizing process, from node using the local zone time of calculated time difference and current time in time difference calculating process, calculate
Go out the master time at current time and as the synchronization time from node moment in this prior.The technical side of the application
In case, it can rely on and itself be obtained and host node one from the Distributed Application as host node as the Distributed Application from node
The time of cause, i.e. Distributed Application, which can rely on, itself realizes time synchronization, without machine where depending on Distributed Application
The system time of device, so as to avoid due to the system time of the machine inconsistent time for causing Distributed Application to get not
The problem of unanimously influencing business processing.
In addition, described according to the local sending time, the main section of the local reception time and the feedback moment
The point time, calculate it is described from node and the host node before the time difference at the feedback moment, further include:According to described
Local sending time and the local reception time, calculate request duration;Judge whether the request duration is overtime;If described
Request duration has not timed out, then enters described according to the local sending time, the local reception time and the feedback moment
Master time, calculate it is described from node and the host node in the time difference at the feedback moment the step of.This implementation
In example, the judgement to asking duration is increased, and the time difference could be only calculated in the case where decision request duration has not timed out,
It can lead to very much the problem of the master time inaccuracy at the feedback moment received long to avoid request delay.
In addition, the time difference calculating process is periodically repeated, to be updated periodically the time difference;Also,
It is described from node need obtain synchronization time when enter the synchronizing process.In the present embodiment, timing renewal time difference can be with
So that the calculated time consistency of subsequent synchronization processes is preferable;Also, due to only the when of obtaining synchronization time being needed to enter
The synchronizing process, i.e. time difference calculating process and synchronizing process are independent of each other, and calculating process timing renewal time time difference is poor,
Therefore when needing to obtain synchronization time, you can get the time difference of recent renewal, and then quickly calculate synchronization time.
In addition, the calculation of the time difference D is, D=T2- (T1+T3)/2;Wherein, T1 indicates the local transmission
Time, T2 indicate that the master time at the feedback moment, T3 indicate the local reception time;The main section at the current time
The calculation of point time T6 is T6=T5+D;Wherein, T5 indicates the local zone time at the current time.The present embodiment provides
A kind of specific calculation.
In addition, the host node is the Distributed Application for having in the distributed system configuration parameter management function.This
Embodiment provides a kind of selection mode of host node.
Description of the drawings
One or more embodiments are illustrated by the picture in corresponding attached drawing, these exemplary theorys
The bright restriction not constituted to embodiment, the element with same reference numbers label is expressed as similar element in attached drawing, removes
Non- to have special statement, composition does not limit the figure in attached drawing.
Figure 1A is the flow chart according to the method for synchronizing time of the application first embodiment;
Figure 1B is the schematic diagram at each time point in method for synchronizing time according to the application first embodiment;
Fig. 2 is the flow chart according to the method for synchronizing time of the application second embodiment;
Fig. 3 is the block diagram according to the time synchronization module of the application 3rd embodiment;
Fig. 4 is the block diagram according to the time synchronization module of the application fourth embodiment.
Specific implementation mode
In order to make the object, technical scheme and advantages of the embodiment of the invention clearer, below in conjunction with attached drawing to the present invention
Each embodiment be explained in detail.However, it will be understood by those skilled in the art that in each embodiment party of the present invention
In formula, in order to make the reader understand this application better, many technical details are proposed.But even if without these technical details
And various changes and modifications based on the following respective embodiments, it can also realize the application technical solution claimed.
The first embodiment of the present invention is related to a kind of method for synchronizing time, it is applied to be used as from node in distributed system
Distributed Application.Specifically, distributed system includes multiple Distributed Applications, each Distributed Application is deployed in a machine
On device (such as server or terminal), there will be the distribution for configuring parameter management function in the present embodiment in distributed system
Application settings are host node, other Distributed Applications are set as host node;It is same that the time is each carried out from host node from node
Step.Figure 1A and Figure 1B are please also refer to, Figure 1A is the flow chart of the method for synchronizing time of the present embodiment, wherein time synchronization side
Method includes time difference calculating process (step 101 to step 103) and synchronizing process (step 104 and step 105);Figure 1B is the time
The schematic diagram at each time point in synchronous method.
Step 101:It obtains and asks to host node sending time, and record the local sending time of time acquisition request.
That is, host node provides time interface to respectively from node calling.It obtains and asks from node to host node sending time, and
And the local sending time T1 of request is obtained from the nodes records time.Wherein, local sending time T1 refers to sending to be somebody's turn to do from node
Time obtains when asking from the system time on machine where node.
Step 102:The master time of host node feedback is received, and records the local reception time of master time.
Wherein, host node upon receiving a request, can feed back to the time (master time) of itself from node, from section
Point receives the master time of host node feedback;That is, the master time of host node feedback is when feeding back the host node at moment
Between T2.The local reception time T3 of master time is also recorded from node;Wherein, local reception time T3 refers to receive from node and be somebody's turn to do
From the system time on machine where node when the master time at feedback moment.
Step 103:According to local sending time, the local reception time and feed back the moment master time, calculate from
Node is with host node in the time difference for feeding back the moment.
Wherein, feedback the moment slave node local zone time T4 (i.e. feed back the moment slave node time T4) can be with table
It is shown as T4=(T1+T3)/2;Then D=can be expressed as in the master time at feedback moment and the time difference D from node time
T2-T4=T2- (T1+T3)/2.It is stored in from the memory of node from node by the time difference, for making when subsequent synchronization processes
With.
Step 101 as above is to 103 being time difference calculating process.Although time difference D herein is directly anti-from calculation formula
What is answered is master time and the time difference from node time at the feedback moment, still, it is however generally that, machine where host node
System time and the system time of machine where the node be considered at the uniform velocity timing, then time difference D
Master time and the time difference from node time at any one time can be characterized.
Preferably, the slave node in the present embodiment can periodically repeat the time difference calculating process, with periodically more
The new time difference.Update cycle can be set as needed, such as the update cycle can be set to 5S;Then think at least one
In a update cycle, the system time of machine where host node and the system time from machine where node are at the uniform velocity timing
, which can be as the master time of any moment in this period and from the time difference of node time;Wherein more
Newly cycle set is smaller, and time difference update is more frequent, and the calculated time consistency of subsequent synchronization processes can be made better.
Step 104:Obtain the local zone time at current time.
Specifically, when needing to obtain synchronization time in business processing from node, into synchronizing process.It is obtained from node
Take the local zone time T5 at current time, wherein the local zone time T5 at current time refers to current time from machine where node
System time.
Step 105:According to the local zone time at current time and time difference, calculates the master time at current time and incite somebody to action
Its as from node current time synchronization time.
By step 103 it is found that at any one time, master time-is from node time=time difference, therefore, a period of time in office
It carves, master time=from node time+time difference;That is, the master time T6 at current time can be expressed as, T6=T5
+ D=T5+T2- (T1+T3)/2;I.e. using the master time at current time as from node current time synchronization time;And
The synchronization time at the current time is applied to business processing.
As above step 104,105 are synchronizing process.Wherein, in the time difference calculating process in the present embodiment, the time difference=
Master time-is from node time;Right the present embodiment is not intended to be limited in any this, in other examples, can also, the time difference=
From node time-master time, i.e., in step 103, time difference D=T4-T2=(T1+T3)/2-T2, corresponding, step 105
In current time master time T6=T5-D=T5- (T1+T3)/2+T2;It is found that different modes, finally calculates
Result (the master time T6 at current time) be identical, only calculating process is slightly different.
It should be noted that in the present embodiment, time difference calculating process can be periodically carried out from node, with periodically
The time difference is updated, and the when of obtaining synchronization time is being needed to enter synchronizing process;Right the present embodiment is not intended to be limited in any this;
Can also be entry time difference calculating process and synchronizing process from node when needing to obtain synchronization time in other examples.
Embodiment of the present invention in terms of existing technologies, is applied in distributed system as the distribution from node
Using this method includes time difference calculating process and synchronizing process;In time difference calculating process, host node is calculated from node
With from node synchronization time difference;In synchronizing process, when utilizing calculated in time difference calculating process from node
Between difference and current time local zone time, calculate the master time at current time and as this from node in this prior
The synchronization time at moment.It, can be by itself from as master as the Distributed Application from node in the technical solution of the application
The Distributed Application of node obtains the time consistent with host node, i.e., Distributed Application, which can rely on, itself realizes time synchronization,
Without the system time dependent on machine where Distributed Application, so as to avoid the system time due to machine from differing
The problem of causing the Time Inconsistency for causing Distributed Application to get and influencing business processing.
Second embodiment of the present invention is related to a kind of method for synchronizing time.Second embodiment is big with first embodiment
It causes identical, is in place of the main distinction:And in second embodiment of the invention, also request duration is judged, only
The time difference can be just calculated in the case where request has not timed out.
It is illustrated in figure 2 the flow chart of second embodiment, synchronizing process is similar to first embodiment, and the time difference calculated
Journey is slightly variant.As shown, step 101 in step 201, step 202, step 205 to step 207 and first embodiment,
Step 102, step 103 to step 105 correspond to similar respectively, and details are not described herein again, and difference lies in the time difference meters of the present embodiment
Further include during calculating:
Step 203:According to local sending time and local reception time, request duration is calculated.
Step 204:Judge to ask duration whether overtime;If it is not, then entering step 205;If then return to step 201.
Specifically, request time L can be expressed as L=T3-T1 (obtains request to receiving from node from sending time
The time difference of the master time of host node feedback).It can be preset there are one time threshold from intra-node, judge to ask duration
Whether L is more than the time threshold, if it does, indicating that request duration has timed out, then it represents that the master at the feedback moment this time obtained
Node time is invalid, can retransmit time acquisition request;If had not timed out, this data (local hair can be used
Send time, local reception time, the master time for feeding back the moment) calculate the time difference.Wherein, time threshold can be according to reality
Situation is set, for example, it can be set to being 10 milliseconds.
Second embodiment increases the judgement to asking duration, and only asked in judgement for first embodiment
Just assert that the master time at feedback moment is invalid in the case of asking duration to have not timed out, and calculate the time difference, so as to avoid
Request delay leads to very much the problem of the master time inaccuracy at the feedback moment received long.
The step of various methods divide above, be intended merely to describe it is clear, when realization can be merged into a step or
Certain steps are split, multiple steps are decomposed into, as long as including identical logical relation, all in the protection domain of this patent
It is interior;To either adding inessential modification in algorithm in flow or introducing inessential design, but its algorithm is not changed
Core design with flow is all in the protection domain of the patent.
Third embodiment of the invention is related to a kind of time synchronization module, is applied in distributed system as from node
Distributed Application.It is illustrated in figure 3 the schematic diagram of the time synchronization module of 3rd embodiment, time synchronization module includes:
Time difference computational submodule, specifically includes:
Transmission unit 101, for being obtained into the distributed system as the Distributed Application sending time of host node
Request, and record the local sending time of time acquisition request;
Receiving unit 102, the master time for receiving the host node feedback, and record the local of master time
Receiving time;The master time of the wherein described host node feedback is master time of the host node at the feedback moment;
First computing unit 103, when for according to the local sending time, the local reception time and the feedback
The master time at quarter, calculate it is described from node and the host node the feedback moment time difference;
Synchronous submodule, specifically includes:
Acquiring unit 201, the local zone time for obtaining current time;
Second computing unit 202 is used for the local zone time according to the current time and the time difference, calculates described
The master time at current time and as it is described from node the current time synchronization time.
Wherein, the time difference computing module is updated periodically the time difference, also, the synchronous submodule is connecing
Time of receipt (T of R) is triggered when obtaining order.
Wherein, the calculation of the time difference D is D=T2- (T1+T3)/2;Wherein, T1 indicates the local transmission
Time, T2 indicate that the master time at the feedback moment, T3 indicate the local reception time;
The calculation of the master time T6 at the current time is T6=T5+D;Wherein, when T5 indicates described current
The local zone time at quarter.
Wherein, the host node is the Distributed Application for having in the distributed system configuration parameter management function.
It is not difficult to find that present embodiment is system embodiment corresponding with first embodiment, present embodiment can be with
First embodiment is worked in coordination implementation.The relevant technical details mentioned in first embodiment still have in the present embodiment
Effect, in order to reduce repetition, which is not described herein again.Correspondingly, the relevant technical details mentioned in present embodiment are also applicable in
In first embodiment.
Four embodiment of the invention is related to a kind of time synchronization module.4th embodiment and third embodiment are substantially
It is identical, it is in place of the main distinction:And in four embodiment of the invention, also request duration is judged, only be existed
Request can just calculate the time difference in the case of having not timed out.
It is illustrated in figure 4 the block diagram of the time synchronization module of fourth embodiment.
First computing unit 103 is additionally operable to, according to the local sending time and the local reception time, calculate
Go out to ask duration;The time difference computational submodule further includes judging unit 104;The judging unit 104 is described for judging
Ask duration whether overtime;
First computing unit 103 is specifically used for when the judging unit 104 judges the request duration time-out, root
According to local zone time and the time difference at the current time, calculate the master time at the current time and as
It is described from node the current time synchronization time.
Since second embodiment is corresponded with present embodiment, present embodiment can be mutual with second embodiment
Match implementation.The relevant technical details mentioned in second embodiment are still effective in the present embodiment, implement second
The attainable technique effect of institute similarly may be implemented in the present embodiment in mode, no longer superfluous here in order to reduce repetition
It states.Correspondingly, the relevant technical details mentioned in present embodiment are also applicable in second embodiment.
It is noted that each module involved in above-mentioned module embodiment is logic module, actually answering
In, a logic unit can be a physical unit, can also be a part for a physical unit, can also be with multiple
The combination of physical unit is realized.In addition, in order to protrude the innovative part of the present invention, it will not be with solution originally in present embodiment
The less close unit of the technical issues of invention is proposed relationship introduces, but this does not indicate that there is no other in present embodiment
Unit.
Fifth embodiment of the invention is related to a kind of electronic equipment, including:
At least one processing;
The memory being connect at least one processor communication;And
It is stored in the Distributed Application in the memory with instruction type;
Wherein, the instruction of the characterization Distributed Application stored in the memory can be by least one processing
Device executes, so that at least one processor is able to carry out the method for synchronizing time as described in above-mentioned either method embodiment.
Wherein, which is, for example, terminal or server.Distributed Application, and described point are installed in electronic equipment
Cloth is applied and is stored in the memory with instruction type, and the Distributed Application is as the slave section in distributed system
Point.
Wherein, memory is connected with processor using bus mode, and bus may include the bus of any number of interconnection
And one or more processors and the various of memory are electrically connected to together by bridge, bus.Bus can also will be such as peripheral
The various other of equipment, voltage-stablizer and management circuit or the like are electrically connected to together, these are all well known in the art
, therefore, it will not be further described herein.Bus interface provides interface between bus and transceiver.Transceiver
Can be an element, can also be multiple element, such as multiple receivers and transmitter, provide for over a transmission medium with
The unit of various other device communications.The data handled through processor are transmitted on the radio medium by antenna, further,
Antenna also receives data and transfers data to processor.
Processor is responsible for bus and common processing, can also provide various functions, including periodically, peripheral interface,
Voltage adjusting, power management and other control functions.And memory can be used to store processor and execute operation when institute
The data used.
Sixth embodiment of the invention is related to a kind of computer readable storage medium, is stored with computer program.Computer
Above method embodiment is realized when program is executed by processor.
That is, it will be understood by those skilled in the art that implement the method for the above embodiments be can be with
Relevant hardware is instructed to complete by program, which is stored in a storage medium, including some instructions are making
It obtains an equipment (can be microcontroller, chip etc.) or processor (processor) executes side described in each embodiment of the application
The all or part of step of method.And storage medium above-mentioned includes:USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only
Memory), random access memory (RAM, Random Access Memory), magnetic disc or CD etc. are various can store journey
The medium of sequence code.
It will be understood by those skilled in the art that the respective embodiments described above are to realize specific embodiments of the present invention,
And in practical applications, can to it, various changes can be made in the form and details, without departing from the spirit and scope of the present invention.
Claims (12)
1. a kind of method for synchronizing time, which is characterized in that be applied in distributed system as the Distributed Application from node, institute
The method of stating includes:
Time difference calculating process, specifically includes,
It obtains and asks as the Distributed Application sending time of host node into the distributed system, and record the time and obtain
Take the local sending time of request;
The master time of the host node feedback is received, and records the local reception time of the master time;Wherein institute
The master time for stating host node feedback is the master time at the feedback moment;
According to the local sending time, the master time of the local reception time and the feedback moment, institute is calculated
It states from node and the host node in the time difference for feeding back the moment;
Synchronizing process specifically includes,
Obtain the local zone time at current time;
According to the local zone time at the current time and the time difference, calculates the master time at the current time and incite somebody to action
Its as it is described from node the current time synchronization time.
2. method for synchronizing time according to claim 1, which is characterized in that it is described according to the local sending time,
The master time of the local reception time and the feedback moment, calculate it is described from node with the host node described
Before the time difference for feeding back the moment, further include:
According to the local sending time and the local reception time, request duration is calculated;
Judge whether the request duration is overtime;If the request duration has not timed out, enter described according to the local transmission
The master time of time, the local reception time and the feedback moment calculate described from node and the host node
It is described feedback the moment time difference the step of.
3. method for synchronizing time according to claim 1, which is characterized in that the time difference calculating process is by periodically
It repeats, to be updated periodically the time difference;Also, it is described from node need obtain synchronization time when enter the synchronization
Process.
4. method for synchronizing time according to any one of claim 1 to 3, which is characterized in that the calculating of the time difference D
Mode is D=T2- (T1+T3)/2;Wherein, T1 indicates that the local sending time, T2 indicate the host node at the feedback moment
Time, T3 indicate the local reception time;
The calculation of the master time T6 at the current time is T6=T5+D;Wherein, T5 indicates the current time
Local zone time.
5. method for synchronizing time according to claim 1, which is characterized in that the host node is in the distributed system
Distributed Application with configuration parameter management function.
6. a kind of time synchronization module, which is characterized in that be applied in distributed system as the Distributed Application from node, institute
State module:
Time difference computational submodule, specifically includes,
Transmission unit is asked for being obtained into the distributed system as the Distributed Application sending time of host node, and
Record the local sending time of the time acquisition request;
Receiving unit, the master time for receiving the host node feedback, and the local for recording the master time connects
Between time receiving;The master time of the wherein described host node feedback is the master time at the feedback moment;
First computing unit, for according to the local sending time, the master of the local reception time and the feedback moment
Node time, calculate it is described from node and the host node the feedback moment time difference;
Synchronous submodule, specifically includes:
Acquiring unit, the local zone time for obtaining current time;
Second computing unit is used for the local zone time according to the current time and the time difference, when calculating described current
The master time at quarter and as it is described from node the current time synchronization time.
7. time synchronization module according to claim 6, which is characterized in that first computing unit is additionally operable to according to institute
Local sending time and the local reception time are stated, request duration is calculated;
The time difference computational submodule further includes judging unit;The judging unit is for judging whether the request duration surpasses
When;
First computing unit is specifically used for, when the judging unit judges that the request duration has not timed out, according to described being worked as
The local zone time at preceding moment and the time difference, calculate the master time at the current time and as described from section
Put the synchronization time at the current time.
8. time synchronization module according to claim 6, which is characterized in that the time difference computing module is periodically more
The new time difference, also, the synchronous submodule needs the when of obtaining synchronization time to be triggered described from node.
9. the time synchronization module according to any one of claim 6 to 8, which is characterized in that the calculating of the time difference D
Mode is D=T2- (T1+T3)/2;Wherein, T1 indicates that the local sending time, T2 indicate the host node at the feedback moment
Time, T3 indicate the local reception time;
The calculation of the master time T6 at the current time is T6=T5+D;Wherein, T5 indicates the current time
Local zone time.
10. time synchronization module according to claim 6, which is characterized in that the host node is the distributed system
In have configuration parameter management function Distributed Application.
11. a kind of electronic equipment, which is characterized in that including:
At least one processor;
The memory being connect at least one processor communication;And
It is stored in the Distributed Application in the memory with instruction type;
Wherein, the instruction of the characterization Distributed Application stored in the memory can be held by least one processor
Row, so that at least one processor is able to carry out the method for synchronizing time as described in any in claim 1 to 5.
12. a kind of computer readable storage medium, is stored with computer program, which is characterized in that the computer program is located
Manage the method for synchronizing time realized when device executes described in any one of claim 1 to 5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810121325.3A CN108429597A (en) | 2018-02-07 | 2018-02-07 | Electronic equipment, method for synchronizing time and module |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810121325.3A CN108429597A (en) | 2018-02-07 | 2018-02-07 | Electronic equipment, method for synchronizing time and module |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108429597A true CN108429597A (en) | 2018-08-21 |
Family
ID=63156748
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810121325.3A Pending CN108429597A (en) | 2018-02-07 | 2018-02-07 | Electronic equipment, method for synchronizing time and module |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108429597A (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110351164A (en) * | 2019-07-17 | 2019-10-18 | 深圳华锐金融技术股份有限公司 | Time delay measure, device, computer equipment and storage medium |
CN111934807A (en) * | 2020-08-17 | 2020-11-13 | 玖月音乐科技(北京)有限公司 | Ultra-low delay synchronization method for network teaching of small group musical instruments |
CN112740579A (en) * | 2020-12-28 | 2021-04-30 | 华为技术有限公司 | Data transmission method, device and related equipment |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103095389A (en) * | 2010-12-17 | 2013-05-08 | 微软公司 | Distributed robust clock synchronization |
CN105680975A (en) * | 2016-03-07 | 2016-06-15 | 浙江大学 | Time synchronization method of master-slave structure multi-node network |
-
2018
- 2018-02-07 CN CN201810121325.3A patent/CN108429597A/en active Pending
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103095389A (en) * | 2010-12-17 | 2013-05-08 | 微软公司 | Distributed robust clock synchronization |
CN105680975A (en) * | 2016-03-07 | 2016-06-15 | 浙江大学 | Time synchronization method of master-slave structure multi-node network |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110351164A (en) * | 2019-07-17 | 2019-10-18 | 深圳华锐金融技术股份有限公司 | Time delay measure, device, computer equipment and storage medium |
CN111934807A (en) * | 2020-08-17 | 2020-11-13 | 玖月音乐科技(北京)有限公司 | Ultra-low delay synchronization method for network teaching of small group musical instruments |
CN112740579A (en) * | 2020-12-28 | 2021-04-30 | 华为技术有限公司 | Data transmission method, device and related equipment |
CN112740579B (en) * | 2020-12-28 | 2022-06-14 | 华为技术有限公司 | Data transmission method, device and related equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108429597A (en) | Electronic equipment, method for synchronizing time and module | |
CN110380919B (en) | Processing method and device for block chain request, electronic equipment and readable storage medium | |
CN108664429B (en) | Master-slave configuration communication protocol, method for improving compatibility and electronic equipment | |
CN107193672B (en) | Cross-block asynchronous contract calling system | |
JPH11203240A (en) | Circuit and method for clock forwarding | |
CN109714757B (en) | Method and device for preparing eSIM card in shared mode | |
CN109902056A (en) | A kind of method, apparatus of serial transmission, equipment and computer readable storage medium | |
CN108475246A (en) | Bus mastership handoff technique | |
JPH09139973A (en) | Method and circuit device for frame synchronization in multiplex cell communication system | |
CN113727429A (en) | Cross-network-group clock synchronization method and device, storage medium and terminal | |
CN110740085B (en) | Communication method, communication device and terminal based on parallel operation system | |
CN110958139B (en) | Network control method, orchestrator, controller, and computer-readable storage medium | |
EP4350962A1 (en) | Multi-channel signal synchronization method, power supply modules, electronic device and power supply device | |
DE112011106026T5 (en) | Seitenbandinitialisierung | |
CN110221996B (en) | Controller configuration method and device in main control chip | |
US7058149B2 (en) | System for providing a calibrated clock and methods thereof | |
CN108737001A (en) | A kind of data processing method and relevant device | |
CN113961497A (en) | Communication circuit system, method, chip and storage medium | |
CN112069103A (en) | Method and system for communication between multiple modules and host | |
CN115277285B (en) | Communication method, communication device, communication system, and computer-readable storage medium | |
CN114546928B (en) | Method and device for synchronizing core cluster, control method and device, core and medium | |
KR100255382B1 (en) | Bus synchronous signal generation method for data bus of ipc network | |
US11736360B2 (en) | Communication system comprising a plurality of processors and at least one switch, and associated communication method | |
CN116483678B (en) | Information processing method and related device | |
CN111077941B (en) | Clock synchronization setting method, device and storage medium |
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 | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20180821 |