CN103957258B - A kind of transregional data communications method and system - Google Patents

A kind of transregional data communications method and system Download PDF

Info

Publication number
CN103957258B
CN103957258B CN201410183228.9A CN201410183228A CN103957258B CN 103957258 B CN103957258 B CN 103957258B CN 201410183228 A CN201410183228 A CN 201410183228A CN 103957258 B CN103957258 B CN 103957258B
Authority
CN
China
Prior art keywords
data
time
information
temporal information
unit
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.)
Active
Application number
CN201410183228.9A
Other languages
Chinese (zh)
Other versions
CN103957258A (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.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
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 Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN201410183228.9A priority Critical patent/CN103957258B/en
Publication of CN103957258A publication Critical patent/CN103957258A/en
Application granted granted Critical
Publication of CN103957258B publication Critical patent/CN103957258B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Telephonic Communication Services (AREA)

Abstract

The present invention provides a kind of transregional data communications method and system, wherein, the method includes:Obtain data;Timeliness judgement is carried out to the data of acquisition according to stream compression time and data effective period, obtains valid data;Data processing is carried out to the valid data;To treated, valid data add in timestamp information;The valid data for adding in temporal information are sent.It is all that system is realized automatically in entire communication process that the technical program, which allows the timeliness of data to judge, without manual intervention, ensure that the data transmitted and handled between each application are all effective in timeliness.

Description

A kind of transregional data communications method and system
Technical field
The present invention relates to field of data communication, more particularly to a kind of transregional data communications method and system further include one kind Data age control device and method for synchronizing time.
Background technology
With the sustainable development of IT industry, more affairs are included into IT system and are handled in enterprise, each inside IT system There are more and more communications between a server to connect.Since the processing of each application is all that time-effectiveness controls, hair As soon as the instruction gone out fails to be handled in predefined time range, data originating end will be considered that the data have failed. But since data need to flow through multiple processing links, when performance fault occur in wherein one or more links, will cause between application The timeliness for being transmitted the communication packet of processing has failed, and can still need to using the thing processed, and the final data that generate differ Cause or production development accident.
Such as:Bank ATM initiates a transaction of withdrawing the money, if since host is busy, this data processing request is in master Overlong time in machine processing waiting list, alreadys exceed the business processing term of validity, and ATM is because time-out has been abandoned waiting for, specifically Transaction data ought to be discarded.But according to currently used data age treatment mechanism, this transaction data is finally still by host It manages and carries out button account, this withdrawal data are still handled in each intermediate links, are judged as in ATM machine by ATM until returning This withdrawal data have timed, out and discard.In addition, ATM also needs to automatically initiate the positive request of a punching again, to allow host The button account update completed before retracting.So currently used data age treatment mechanism waste efficient resource.
In addition, also by taking ATM withdraws the money as an example, after the positive transaction of ATM withdrawals is sent out, withdrawal data lag, which reaches, because of various reasons leads Machine, and before positive transaction data of withdrawing the money reaches host, ATM is because wait for time-out to have issued the positive request of withdrawal punching, due to each The treatment mechanism of node is different, and correction data request is rushed in withdrawal to reach host earlier than positive transaction of withdrawing the money, then this punching of withdrawing the money Correction data request meeting processing failure (because can not find the positive transaction record of this withdrawal on host), the withdrawal then reached is just merchandised But account is carried out by host and is had updated, the positive transaction of punching is there will be no in this withdrawal, causes to cause account mistake.
Existing data age control function, is typically limited to only internal system, it is impossible to which cross-system operation needs outer The supports such as portion's clock synchronization.This data control mode, in the data handling procedure across time zone or each intermediate-node services During the Time Inconsistency of device, it is difficult to ensure the timeliness of data.Therefore, it is necessary to a kind of new data age control device and do Method in the data handling procedure of various scenes, can carry out self-correcting, ensure the energy saving correct invalid report of identification of each communication link Text.
Invention content
To solve the above problems, the present invention proposes a kind of transregional data communications method and system, to overcome current all kinds of clothes Business device can not effectively judge the timeliness of data when carrying out data interaction, caused by causing all kinds of invalid data processings The problem of low and wrong data update of efficiency leads to account.
To achieve the above object, the present invention provides a kind of transregional data communications method, the method includes:
Obtain data;
Timeliness judgement is carried out to the data of acquisition according to stream compression time and data effective period, obtains significant figure According to;
Data processing is carried out to the valid data;
To treated, valid data add in timestamp information;
The valid data for adding in temporal information are sent.
Optionally, in an embodiment of the present invention, the stream compression time is more than the data effective period, then described Data are invalid datas;The stream compression time is less than or equal to the data effective period, then the data are to meet timeliness Property requirement valid data.
Optionally, in an embodiment of the present invention, the stream compression time is according to local zone time, time zone conversion, time Timestamp information in difference and data obtains.
Optionally, in an embodiment of the present invention, time-zone information, sheet where the timestamp information includes transmission data end Ground sending time, data effective periods.
To achieve the above object, the present invention provides another transregional data communications method, the method includes:
Initiate transaction data;
Timestamp information is added in the data of initiation;
The data for adding in timestamp information are sent to other back end to handle;
Obtain treated data;
Timeliness judgement is carried out to the data of acquisition according to stream compression time and data effective period, obtains significant figure According to;
The valid data are shown according to functional requirement.
To achieve the above object, the present invention also provides a kind of transregional data communication system, the system comprises:
First data receipt unit, for obtaining data;
First timeliness judging unit, during for being carried out according to stream compression time and data effective period to the data of acquisition Effect property judges, obtains valid data;
Data processing unit, for carrying out data processing to the valid data;
Stamp information unit at the first time, for valid data to add in timestamp information to treated;
First transmitting element, for the valid data for adding in temporal information to be sent.
Optionally, in an embodiment of the present invention, the first timeliness judging unit judges that the stream compression time is big The data effective period, then the data are invalid datas;The first timeliness judging unit judges the stream compression Time is less than or equal to the data effective period, then the data are to meet the valid data of timeliness requirement.
Optionally, in an embodiment of the present invention, the stream compression time root that the first timeliness judging unit uses It is obtained according to the timestamp information in local zone time, time zone conversion, time difference and data.
Optionally, in an embodiment of the present invention, the timestamp information packet that the first time stamp information unit uses Include time-zone information where transmission data end, local sending time, data effective periods.
To achieve the above object, the present invention also provides another transregional data communication system, the system comprises:
Data initiate unit, for initiating transaction data;
Second timestamp information unit, for adding in timestamp information to the data of initiation;
Second transmitting element is handled for the data for adding in timestamp information to be sent to other back end;
Second data receipt unit, for obtaining treated data;
Second timeliness judging unit, during for being carried out according to stream compression time and data effective period to the data of acquisition Effect property judges, obtains valid data;
Display unit, for showing the valid data according to functional requirement.
To achieve the above object, the present invention provides a kind of data age control device, including:
Initial handshake unit, the back end for communicating with other needs carry out application layer and shake hands, exchange mutual Temporal information, in the data age control device other units carry out initialization process, obtain communicating pair when Between information;
Server time acquiring unit, for obtaining server current time and corresponding time-zone information;
Time-out information acquiring unit, for obtaining predefined information data effective period of merchandising;
Temporal information storage unit, for recording the temporal information of all kinds of transaction data, the temporal information includes described The temporal information for the communicating pair that initial handshake unit obtains;
Timeliness control unit, including timestamp processing module and timeliness judgment module, the timestamp processing module is used for Timestamp information is added in the data that needs are sent;Wherein, the timestamp information is obtained including the server time The information that unit and the time-out information acquiring unit obtain;The timeliness judgment module be used for according in the data of acquisition when Between the temporal information that records in information and temporal information storage unit timeliness judgement is carried out to the data of acquisition.
Optionally, in an embodiment of the present invention, it further includes:Temporal information synchronization unit;
The temporal information synchronization unit is sent to other back end for tissue message, reacquires communicating pair Temporal information, carry out automatic synchronization and correction to the temporal information of communicating pair, and by the time information renovation of acquisition to institute State temporal information storage unit.
To achieve the above object, the present invention provides a kind of method for synchronizing time, and this method is based on above-mentioned data age Property control device carry out, the method for synchronizing time includes:
Configuration file is read by the time-out information acquiring unit, completes the initial of the data age control device Change operation;
Initial handshake unit carries out shaking hands for application layer with communication counterpart, the time needed described in both sides during exchanging operation Information, and the temporal information of acquisition is written to temporal information storage unit;
Temporal information synchronization unit periodically starts, and is exchanged with communication counterpart, obtains new temporal information, and will obtain Time information renovation to the temporal information storage unit.
Optionally, in an embodiment of the present invention, the initial handshake unit carries out shaking hands for application layer with communication counterpart The step of include:
The side that communicates initiates handshake request to communication counterpart;
The communication counterpart returns to response to one side of the communication;
The response sending application that one root of the communication is returned according to communication counterpart is referred to as to the communication counterpart;
Local time information is sent to one side of the communication by the communication counterpart;
One side of the communication registers the temporal information of the communication counterpart, and local time information is sent to the communication Other side;
The temporal information of the communication counterpart registration one side of the communication.
Above-mentioned technical proposal has the advantages that:The technical program allows the timeliness of data to judge to communicate entirely All it is that system is realized automatically in journey, without manual intervention, ensure that the data transmitted and handled between each application in timeliness All it is effective.
Description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, to embodiment or will show below There is attached drawing needed in technology description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this Some embodiments of invention, for those of ordinary skill in the art, without creative efforts, can be with Other attached drawings are obtained according to these attached drawings.
Fig. 1 is a kind of one of transregional data communications method flow chart provided by the invention;
Fig. 2 is the two of a kind of transregional data communications method flow chart provided by the invention;
Fig. 3 is a kind of one of transregional data communication system block diagram provided by the invention;
Fig. 4 is the two of a kind of transregional data communication system block diagram provided by the invention;
Fig. 5 is a kind of one of 500 block diagram of data age control device provided by the invention;
Fig. 6 is the two of a kind of 500 block diagram of data age control device provided by the invention;
Fig. 7 is the two of a kind of method for synchronizing time flow chart provided by the invention;
Fig. 8 is the transregional data communication system structure diagram of the present embodiment;
Fig. 9 is the function logic structure chart of the data age control device of the present embodiment;
Figure 10 is the realization flow chart of the time synchronization part of the data age control device of the present embodiment;
Figure 11 is the handshake procedure schematic diagram of an actual motion of the present embodiment;
Figure 12 is that a complete data validity of the present embodiment judges process chart.
Specific embodiment
Below in conjunction with the attached drawing in the embodiment of the present invention, the technical solution in the embodiment of the present invention is carried out clear, complete Site preparation describes.Obviously, described embodiment is only part of the embodiment of the present invention, instead of all the embodiments.It is based on Embodiment in the present invention, those of ordinary skill in the art are obtained every other without making creative work Embodiment shall fall within the protection scope of the present invention.
As shown in Figure 1, for the present invention provides a kind of transregional data communications method flow charts.The method includes:
Step 101):Obtain data;
Step 102):Timeliness judgement is carried out to the data of acquisition according to stream compression time and data effective period, is obtained Obtain valid data;
Step 103):Data processing is carried out to the valid data;
Step 104):To treated, valid data add in timestamp information;
Step 105):The valid data for adding in temporal information are sent.
Optionally, in an embodiment of the present invention, the stream compression time is more than the data effective period, then described Data are invalid datas;The stream compression time is less than or equal to the data effective period, then the data are to meet timeliness Property requirement valid data.
Optionally, in an embodiment of the present invention, the stream compression time is according to local zone time, time zone conversion, time Timestamp information in difference and data obtains.
Optionally, in an embodiment of the present invention, time-zone information, sheet where the timestamp information includes transmission data end Ground sending time, data effective periods.
As shown in Fig. 2, for the present invention provides the two of a kind of transregional data communications method flow chart.The method includes:
Step 201):Initiate transaction data;
Step 202):Timestamp information is added in the data of initiation;
Step 203):The data for adding in timestamp information are sent to other back end to handle;
Step 204):Obtain treated data;
Step 205):Timeliness judgement is carried out to the data of acquisition according to stream compression time and data effective period, is obtained Obtain valid data;
Step 206):The valid data are shown according to functional requirement.
As shown in figure 3, for a kind of one of transregional data communication system block diagram provided by the invention.The system comprises:
First data receipt unit 301, for obtaining data;
First timeliness judging unit 302, for according to stream compression time and data effective period to the data of acquisition into Row timeliness judges, obtains valid data;
Data processing unit 303, for carrying out data processing to the valid data;
Stamp information unit 304 at the first time, for valid data to add in timestamp information to treated;
First transmitting element 305, for the valid data for adding in temporal information to be sent.
Optionally, in an embodiment of the present invention, the first timeliness judging unit 302 judges the stream compression time More than the data effective period, then the data are invalid datas;The first timeliness judging unit 302 judges the data The time circulate less than or equal to the data effective period, then the data are to meet the valid data of timeliness requirement.
Optionally, in an embodiment of the present invention, the stream compression time root that the first timeliness judging unit 302 uses It is obtained according to the timestamp information in local zone time, time zone conversion, time difference and data.
Optionally, in an embodiment of the present invention, the timestamp information that the first time stamp information unit 304 uses Including time-zone information where transmission data end, local sending time, data effective periods.
As shown in figure 4, two for a kind of transregional data communication system block diagram provided by the invention.The system comprises:
Data initiate unit 401, for initiating transaction data;
Second timestamp information unit 402, for adding in timestamp information to the data of initiation;
Second transmitting element 403 is handled for the data for adding in timestamp information to be sent to other back end;
Second data receipt unit 404, for obtaining treated data;
Second timeliness judging unit 405, for according to stream compression time and data effective period to the data of acquisition into Row timeliness judges, obtains valid data;
Display unit 406, for showing the valid data according to functional requirement.
As shown in figure 5, for a kind of one of 500 block diagram of data age control device provided by the invention.Including:
Initial handshake unit 501, the back end for communicating with other needs carry out application layer and shake hands, exchange mutual Temporal information, in the data age control device other units carry out initialization process, obtain communicating pair Temporal information;
Server time acquiring unit 502, for obtaining server current time and corresponding time-zone information;
Time-out information acquiring unit 503, for obtaining predefined information data effective period of merchandising;
Temporal information storage unit 504, for recording the temporal information of all kinds of transaction data, the temporal information includes institute State the temporal information of the communicating pair of initial handshake unit acquisition;
Timeliness control unit 505, including timestamp processing module 5051 and timeliness judgment module 5052, at the timestamp Reason module 5051 is used to add in timestamp information to the data that needs are sent;Wherein, the timestamp information includes described The information that server time acquiring unit and the time-out information acquiring unit obtain;The timeliness judgment module 5052 is used for root According to the temporal information recorded in the temporal information in the data of acquisition and temporal information storage unit 504 to the data of acquisition into Row timeliness judges.
As shown in fig. 6, two for a kind of 500 block diagram of data age control device provided by the invention.On the basis of Fig. 5 On, it further includes:Temporal information synchronization unit 506;
The temporal information synchronization unit 506 is sent to other back end for tissue message, it is double to reacquire communication The temporal information of side carries out automatic synchronization and correction, and the time information renovation of acquisition is arrived to the temporal information of communicating pair The temporal information storage unit 504.
As shown in fig. 7, for a kind of method for synchronizing time flow chart provided by the invention.Number of this method based on above-mentioned Fig. 6 It is carried out according to timeliness control device, the method for synchronizing time includes:
Step 701):Configuration file is read by the time-out information acquiring unit 503, completes the data age control The initialization operation of device processed;
Step 702):Initial handshake unit 501 carries out shaking hands for application layer with communication counterpart, exchanges both sides institute during operation The temporal information of needs is stated, and the temporal information of acquisition is written to temporal information storage unit 504;
Step 703):Temporal information synchronization unit 506 periodically starts, and is exchanged with communication counterpart, obtains the new time Information, and by the time information renovation of acquisition to the temporal information storage unit 504.
Optionally, in an embodiment of the present invention, the initial handshake unit 501 carries out holding for application layer with communication counterpart The step of hand, includes:
The side that communicates initiates handshake request to communication counterpart;
The communication counterpart returns to response to one side of the communication;
The response sending application that one root of the communication is returned according to communication counterpart is referred to as to the communication counterpart;
Local time information is sent to one side of the communication by the communication counterpart;
One side of the communication registers the temporal information of the communication counterpart, and local time information is sent to the communication Other side;
The temporal information of the communication counterpart registration one side of the communication.
Embodiment:
The present embodiment is in data handling procedure is carried out to application system, is added in shown in Fig. 6 in each node server Device, the device when data are sent, in data the write time stab information, which includes but not limited to:It should Time-zone information where client, local sending time, data effective periods etc..One can the header of actual motion set up meter separately Example is as follows:
When server-side receives data, data age control device judges the timeliness of data, so as to abandon nothing in time The data of effect.Further, the present apparatus does not depend on external condition, can be shaken hands in startup stage by application (using interlayer phase Interchangeable operation information needed) temporal information of other side is perceived for calculating correct timestamp, and during continuous service, lead to It crosses and automatically periodically initiates the validity that probe messages carry out retention time information, so as to fulfill the self-correcting of temporal information.
The technical solution is described in detail in control attached drawing below:
As shown in figure 8, the transregional data communication system structure diagram for the present embodiment.Including:Data processing equipment 1, First data age control device 2, the first data sending device 3, the first data sink 4, the second data age control Device 5 processed, the second data sending device 6, the second data sink 7, data originating end 8.Relevant apparatus is described as follows:
Data processing equipment 1 can be mainframe computer or medium and small computer, be mainly responsible for receiving Data are handled, such as:Accounting data table in withdrawal request is updated, registers transaction register etc., data processing Detail and data timeliness control device it is unrelated.
First data age control device 2 is identical with 5 internal structure function of the second data age control device, is this The core component of embodiment, data age control device can carry out the time synchronization between system, and add in data transmission procedure The information such as angle of incidence stamp carry out timeliness judgement after data receiver.The device will be described in more detail in fig.9.
The major function of first data sending device 3 and the second data sending device 6 be transfer data to it is other One processing node.
The major function of second data sink 4 and the second data sink 7 is to receive other node to pass over Data.
Data originating end 8 can be the self-service device of client or similar ATM, and request data is generated in data originating end 8 Afterwards, it reaches data processing equipment 1 through processing units multiple in figure and carries out actual treatment.
As shown in figure 9, the function logic structure chart of the data age control device for the present embodiment.Data age control Device 20 processed includes:Initial handshake unit 21, temporal information synchronization unit 22, timestamp processing unit 23, temporal information storage Unit 24, server time acquiring unit 25, time-out information acquiring unit 26.
Wherein, initial handshake unit 21 for the back end communicated being needed to carry out shaking hands for application layer with other, exchanges Mutual temporal information, the other processing units of initialization, and the temporal information for acquisition of shaking hands is registered in temporal information storage Unit 24, temporal information include being not limited to:Time zone, both sides' time difference etc.,.
Temporal information synchronization unit 22 is backstage resident service, is periodically started, and tissue specific message is sent to communication New time information renovation to temporal information so as to reacquire the temporal information of communication two party, and is stored list by the opposing party Member 24 in, so as to fulfill temporal information self synchronize and correct, avoid communication two party local system time changed after, The problem of temporal information long-time numerical behavior in data message is inaccurate.
Timestamp processing unit 23 is the computing module of data age control device, and all data of platform application are both needed to Elapsed time stabs the processing of processing unit 23.If current this data needs are sent, timestamp processing unit 23 dispatch server time acquisition units 25, time-out information acquiring unit 26 obtain required temporal information, temporal information packet It includes and is not limited to:Current server time, predefined message time-out time, local time zone etc., and correlation time information is filled out It is charged in transmission data;If current this data are read, time of the timestamp processing unit 23 in data Information, as the temporal information recorded in sending time, local zone time and temporal information storage unit 24 carries out timeliness judgement.
Temporal information storage unit 24, for recording all kinds of event informations, including being not limited to:Time zone, time difference etc. supply Each unit is inquired when carrying out Effective judgement.
Server time acquiring unit 25, for obtaining system local zone time and time-zone information.Such as:Pass through C language Localtime functions in API (Application Programming Interface, application programming interfaces) obtain.
Time-out information acquiring unit 26, for obtaining predefined information data effective period of merchandising.It such as will be predefined Data information effective period is recorded in the configuration file of XML format, then passes through analysis configuration file acquisition.
Data age control device is described above, a kind of data age is discussed in detail with reference to Figure 10 and Figure 11 Property control method.This method does not depend on external condition, and time zone is different between each application, also can be correct in environment of time irreversibility Calculate the validity of data.
As shown in Figure 10, the realization flow chart for the time synchronization part of the data age control device of the present embodiment, The flow includes the following steps:
Step 300:Data age control device 2 starts, this can be manual operations, also automatically starting.Service is opened After dynamic, configuration file, the initialization operation of finishing device are read by time-out information reading unit 26.
Step 301:Initial handshake unit 21 carries out shaking hands for application layer with communication other side, exchanges during running needed for both sides Information, including initial time difference information.As shown in figure 11, it is the handshake procedure signal of an actual motion of the present embodiment Figure.Including:
The side that communicates initiates handshake request to communication counterpart;
The communication counterpart returns to response to one side of the communication;
The response sending application that one root of the communication is returned according to communication counterpart is referred to as to the communication counterpart;
Local time information is sent to one side of the communication by the communication counterpart;
One side of the communication registers the temporal information of the communication counterpart, and local time information is sent to the communication Other side;
The temporal information of the communication counterpart registration one side of the communication.
Inside the step, data sending terminal and receiving terminal have been exchanged with each other temporal information, these temporal informations include It is not limited to:Local zone time, time-zone information.It, will be in its information access time information memory cell 24 after shaking hands.
Step 302:Initial handshake unit 21 starts other function modules.
Step 303:Temporal information synchronization unit 22 periodically starts and communication other side is linked up, and obtains new time letter Breath, and update into time information memory cell 24, so as to fulfill the self-correcting of temporal information.One can actual motion please The design of EDI messages example asked and responded is as follows:
Request message:
Type Length Remarks
int 4 Ask classification.Such as 1001 expression request time information
long 8 Local zone time is empty in request message
int 4 Time-zone information is empty in request message
Back message:
Step 304:The temporal information write time information memory cell that initial handshake unit 21 will be got in step 301 24.Meanwhile the temporal information that regularly updates of temporal information synchronization unit is also in access time information memory cell 24.
As shown in figure 12, judge process chart for a complete data validity of the present embodiment.This method includes Following steps:
Step 400:Data originating end 8 starts to initiate data;
Step 401:Second data age control device 5 carries out timeliness processing to communication packet, is added in data Temporal information.
In this step, the internal module server time acquiring unit 25 of data age device will pass through system API obtains local zone time, the information such as time zone, and time-out time acquiring unit 26 is by having by analysis configuration file acquisition data Cycle information is imitated, then above-mentioned temporal information is uniformly written in related data device;
Step 402:Second data sending device 6 sends data;
Step 403:First data sink 3 receives data;
Step 404:First data age control device 2 carries out timeliness judgement to the data received, when not meeting The data of effect property will be abandoned.It is a sample calculation as follows:
Timestamp in stream compression time=local zone time+time zone conversion+time difference-data
If the stream compression time is more than the data effective period in data, then it is assumed that this data are invalid datas;It is false If the stream compression time is less than the data effective period in data, then it is assumed that this data are valid data.
Step 405:The data for meeting timeliness requirement are handled by data processing equipment 1;
Step 406:After the processing of data processing equipment 1, the data of return data originating end 8 are needed, it will be again by the first data Timeliness control device 2 carries out timeliness processing, inserts temporal information;
Step 407:First data sending device, 4 transmission data;
Step 408:Second data sink 7 receives data;
Step 409:Second data age processing unit 5 carries out timeliness judgement to receiving data, does not meet timeliness The data of property will be abandoned.It is a sample calculation as follows:
Timestamp in stream compression time=local zone time+time zone conversion+time difference-data
If the stream compression time is more than the data effective period in data, then it is assumed that this data are invalid datas;It is false If the stream compression time is less than the data effective period in data, then it is assumed that this data are valid data.
Step 410:Data that data originating end 8 receives that treated, for the functions such as specifically showing.
This embodiment reduces the resource consumption that server handles invalid data, and server is reduced because handling invalid number According to the inconsistent risk of the data brought.ATM retransmits the positive request of punching after a data effective period is waited for, even if withdrawal request Host is reached after specific impulse just request, withdrawal request message is as be decidedly superior to effective period and abandoned by host, account It will not be updated, across time zone or each node server time irreversibility, in the case of discrepant, ensure that application system Robustness, ensure that the validity of data.
Finally it should be noted that:It is above-mentioned to be only to illustrate the present invention and not limit technical solution described in the invention; Although this specification to present invention has been detailed description, those skilled in the art still can be to the present invention It modifies or equivalent replacement, all do not depart from the technical solution of the spirit and scope of the present invention and its improvement, should all cover In scope of the presently claimed invention.

Claims (7)

1. a kind of transregional data communications method, which is characterized in that the method includes:
Obtain data;
Timeliness judgement is carried out to the data of acquisition according to stream compression time and data effective period, obtains valid data;
Data processing is carried out to the valid data;
To treated, valid data add in timestamp information;
The valid data for adding in temporal information are sent, meanwhile, in the stage for starting transregional data communication, using interlayer phase Interchangeable operation information needed perceives the temporal information of other side, and in persistently transregional data communication period, by automatically fixed Phase initiates probe messages to keep the validity of the temporal information;
Timestamp information of the stream compression time in local zone time, time zone conversion, time difference and data obtains;
Time-zone information where the timestamp information includes transmission data end, local sending time, data effective periods.
2. the method as described in claim 1, which is characterized in that the stream compression time is more than the data effective period, Then the data are invalid datas;The stream compression time is less than or equal to the data effective period, then the data are symbols Close the valid data of timeliness requirement.
3. a kind of transregional data communication system, which is characterized in that the system comprises:
First data receipt unit, for obtaining data;
First timeliness judging unit, for carrying out timeliness to the data of acquisition according to stream compression time and data effective period Judge, obtain valid data;
Data processing unit, for carrying out data processing to the valid data;
Stamp information unit at the first time, for valid data to add in timestamp information to treated;
First transmitting element, for the valid data for adding in temporal information to be sent, meanwhile, starting transregional data communication Stage, be exchanged with each other operation information needed using interlayer to perceive the temporal information of other side, and in persistently transregional data communication Period keeps the validity of the temporal information by automatically periodically initiating probe messages;
The stream compression time that the first timeliness judging unit uses according to local zone time, time zone conversion, the time difference and Timestamp information in data obtains;
Time-zone information, local hair where the timestamp information that the first time stamp information unit uses includes transmission data end Send time, data effective periods.
4. system as claimed in claim 3, which is characterized in that when the first timeliness judging unit judges the stream compression Between be more than the data effective period, then the data are invalid datas;The first timeliness judging unit judges the data The time circulate less than or equal to the data effective period, then the data are to meet the valid data of timeliness requirement.
5. a kind of data age control device, which is characterized in that including:
Initial handshake unit, the back end for communicating with other needs carry out application layer and shake hands, and exchange the mutual time Information carries out initialization process to other units in the data age control device, obtains the time letter of communicating pair Breath;
Server time acquiring unit, for obtaining server current time and corresponding time-zone information;
Time-out information acquiring unit, for obtaining predefined information data effective period of merchandising;
Temporal information storage unit, for recording the temporal information of all kinds of transaction data, the temporal information includes described initial The temporal information for the communicating pair that handshake elements obtain;
Timeliness control unit, including timestamp processing module and timeliness judgment module, the timestamp processing module is used for needing The data to be sent add in timestamp information;Wherein, the timestamp information includes the server time acquiring unit The information obtained with the time-out information acquiring unit;The time that the timeliness judgment module is used in the data according to acquisition believes The temporal information recorded in breath and temporal information storage unit carries out timeliness judgement to the data of acquisition;
It further includes:Temporal information synchronization unit
The temporal information synchronization unit is sent to other back end for tissue message, reacquire communicating pair when Between information, carry out automatic synchronization and correction to the temporal information of communicating pair, and by the time information renovation of acquisition to it is described when Between information memory cell;
Time-zone information where the timestamp information includes transmission data end, local sending time, data effective periods.
6. a kind of method for synchronizing time, which is characterized in that this method is based on the data age control device described in claim 5 It carries out, the method for synchronizing time includes:
Configuration file is read by the time-out information acquiring unit, completes the initialization behaviour of the data age control device Make;
Initial handshake unit carries out shaking hands for application layer with communication counterpart, the time letter needed described in both sides during exchanging operation Breath, and the temporal information of acquisition is written to temporal information storage unit;
Temporal information synchronization unit periodically starts, and is exchanged with communication counterpart, reacquires the temporal information of communicating pair, right The temporal information of communicating pair carries out automatic synchronization and correction, and the time information renovation of acquisition is stored to the temporal information Unit.
7. method as claimed in claim 6, which is characterized in that the initial handshake unit carries out application layer with communication counterpart The step of shaking hands includes:
The side that communicates initiates handshake request to communication counterpart;
The communication counterpart returns to response to one side of the communication;
The response sending application that one root of the communication is returned according to communication counterpart is referred to as to the communication counterpart;
Local time information is sent to one side of the communication by the communication counterpart;
One side of the communication registers the temporal information of the communication counterpart, and local time information is sent to the communication pair Side;
The temporal information of the communication counterpart registration one side of the communication.
CN201410183228.9A 2014-04-30 2014-04-30 A kind of transregional data communications method and system Active CN103957258B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410183228.9A CN103957258B (en) 2014-04-30 2014-04-30 A kind of transregional data communications method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410183228.9A CN103957258B (en) 2014-04-30 2014-04-30 A kind of transregional data communications method and system

Publications (2)

Publication Number Publication Date
CN103957258A CN103957258A (en) 2014-07-30
CN103957258B true CN103957258B (en) 2018-06-15

Family

ID=51334481

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410183228.9A Active CN103957258B (en) 2014-04-30 2014-04-30 A kind of transregional data communications method and system

Country Status (1)

Country Link
CN (1) CN103957258B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109639522A (en) * 2018-12-10 2019-04-16 通号城市轨道交通技术有限公司 Method for detecting timeliness of message in rail transit system

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106559158B (en) * 2015-09-29 2018-12-04 国网智能电网研究院 A kind of mobile device data exchange method based on timestamp
CN106354839B (en) * 2016-08-31 2019-12-17 国信优易数据有限公司 Method and system for detecting timeliness of data
CN107919933A (en) * 2017-11-17 2018-04-17 深圳市泉眼网络科技有限公司 A kind of method, apparatus, mobile terminal and the storage medium of time renewal
CN110690936B (en) * 2018-07-06 2021-09-24 腾讯科技(深圳)有限公司 Time control method, system and computer system in service operation
CN109377679A (en) * 2018-09-03 2019-02-22 深圳壹账通智能科技有限公司 Withdrawal method and terminal device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101340436A (en) * 2008-08-14 2009-01-07 普天信息技术研究院有限公司 Method and apparatus implementing remote access control based on portable memory apparatus
US7980378B2 (en) * 2006-03-23 2011-07-19 Cummins-Allison Corporation Systems, apparatus, and methods for currency processing control and redemption
CN102299747A (en) * 2010-06-22 2011-12-28 上海云途信息技术有限公司 Device, system and method for performing safe data communication based on sound waves
CN102307216A (en) * 2011-03-15 2012-01-04 *** Peer-to-peer (P2P) stream media broadcast method and system for multimedia telephone

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102664726B (en) * 2012-04-26 2015-08-05 华为技术有限公司 Method, master-salve clock equipment and system that clock synchronization compliant with precision time protocol source switches

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7980378B2 (en) * 2006-03-23 2011-07-19 Cummins-Allison Corporation Systems, apparatus, and methods for currency processing control and redemption
CN101340436A (en) * 2008-08-14 2009-01-07 普天信息技术研究院有限公司 Method and apparatus implementing remote access control based on portable memory apparatus
CN102299747A (en) * 2010-06-22 2011-12-28 上海云途信息技术有限公司 Device, system and method for performing safe data communication based on sound waves
CN102307216A (en) * 2011-03-15 2012-01-04 *** Peer-to-peer (P2P) stream media broadcast method and system for multimedia telephone

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109639522A (en) * 2018-12-10 2019-04-16 通号城市轨道交通技术有限公司 Method for detecting timeliness of message in rail transit system
CN109639522B (en) * 2018-12-10 2020-11-10 通号城市轨道交通技术有限公司 Method for detecting timeliness of message in rail transit system

Also Published As

Publication number Publication date
CN103957258A (en) 2014-07-30

Similar Documents

Publication Publication Date Title
CN103957258B (en) A kind of transregional data communications method and system
CN106209948B (en) A kind of data push method and device
CN1996855A (en) A method and system for keeping data consistency
CN101595668A (en) Set up the method and system of the logical path between the server in the coordinated timing network
CN105446827B (en) Date storage method and equipment when a kind of database failure
CN107197036A (en) A kind of consistent processing method of information based on block chain and terminal
CN103139157B (en) A kind of based on the network communication method of socket, Apparatus and system
CN107832138A (en) A kind of implementation method of the High Availabitity namenode models of flattening
CN109547512A (en) A kind of method and device of the distributed Session management based on NoSQL
CN102609479A (en) Memory database node copying method
CN104866528B (en) Multi-platform data acquisition method and system
CN111708659B (en) Method for constructing Yun Yuansheng disaster recovery architecture based on kubernetes
CN108140035B (en) Database replication method and device for distributed system
CN111026769A (en) Working method of dual-core front-end system and related equipment thereof
CN108600284A (en) A kind of virtual machine high availability implementation method and system based on Ceph
CN107845013A (en) A kind of electric power transaction platform distributed application services calling processing method
CN113691600A (en) Synchronization method and device of equipment state information and computer readable storage medium
CN113812167B (en) Method for reading a fluid table
WO2020006893A1 (en) Receipt acquisition method, apparatus, computer device, and storage medium
CN108924096A (en) A kind of information synchronization method and device
CN107707645A (en) Telefile sychronisation and method for PDM
CN106953809A (en) A kind of device resource acquisition method based on 485 tdm communications
CN107734034B (en) Server docking system, method, computer-readable storage medium and front-end processor
CN115643271A (en) Method, device, server and medium for synchronizing multi-application data on cloud
CN109271454A (en) A kind of method and the network equipment that data are synchronous

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant