CN104184626B - Realize method, user equipment, server and the system of data syn-chronization mutual exclusion - Google Patents
Realize method, user equipment, server and the system of data syn-chronization mutual exclusion Download PDFInfo
- Publication number
- CN104184626B CN104184626B CN201310196274.8A CN201310196274A CN104184626B CN 104184626 B CN104184626 B CN 104184626B CN 201310196274 A CN201310196274 A CN 201310196274A CN 104184626 B CN104184626 B CN 104184626B
- Authority
- CN
- China
- Prior art keywords
- user equipment
- account number
- detection pattern
- chronization
- server
- 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
Links
Abstract
The present invention discloses a kind of method for realizing data syn-chronization mutual exclusion, user equipment, server and system.Wherein in the method for realizing data syn-chronization mutual exclusion, detect and whether there is the data syn-chronization business associated with the register account number of the user equipment in user equipment, when detecting the presence of the data syn-chronization business, and the synchronous detection pattern type of the user equipment is network detection pattern, and synchronization request is sent to server.When the permission sync response information for receiving server transmission, the data syn-chronization business is performed.When data syn-chronization business is completed, sent to server and synchronously complete instruction, so that server deletes the synchronization association relation.By detecting that the synchronous detection pattern and user terminal of user terminal register the service condition of account number, it just can realize that synchronization and mutex is operated.So as to save terminal device system resources consumption, it is ensured that the synchronous mutual exclusion operation of same Account Data under being applied many equipment more.
Description
Technical field
The present invention relates to the communications field, more particularly to a kind of method for realizing data syn-chronization mutual exclusion, user equipment, server
And system.
Background technology
As network speed is more and more faster, mobile phone terminal is stronger and stronger, and mobile Internet will turn into one bigger emerging
Market.There is 11% to be surfed the Net using mobile phone and digital card in Chinese 4.2 hundred million netizens, the user that intelligent terminal is surfed the Net has been used now
The 10%-50% of Internet user's number is accounted for, after so calculating 9 years, the number of users of mobile Internet will exceed fixed internet and use
Amount.The mobile Internets such as the mobile phone searching of current China, game, reading, music, interactive community and payment application shop
A hundred flowers blossom for service, shows vigorous development vitality.In order to adapt to and meet same terminal user to the use need applied more
Ask, increasing Account Administration application is arisen at the historic moment, i.e., one user need to only register one system account of establishment, so that it may simultaneously
Using multiple application services under the system, the problem introduced therewith is exactly, same under multiple application programs in order to ensure
The uniformity of user account data and property as newest as possible, it is necessary to which each application program is provided and platform(Or server)It
Between data syn-chronization function.
Synchronously can be understood as data in holding multiple equipment, unanimously, demand is probably derived from following several frequently seen scene:
(1) user continually uses USB(Universal Serial Bus, USB)Import and export data, such as scheme
The file datas such as piece, film and music;(2) user needs to ensure that the data between many equipment are consistent, and newest number is called at any time
According to many people can also collaborative editing identical file;(3) after equipment is lost or updated, data also may lose therewith, by number
According to being synchronized to the webserver, it is ensured that the safety of data.
Data syn-chronization can be divided into Pull(Draw)And Push(Push)Two kinds of application models.Pull is that teledata is synchronous
To local, and Push is to be synchronized to local data remotely.Therefore more than many equipment using realizing same account user data
During synchronizing function, it is necessary to assure some when inscribe only one of which using synchronizing function to account data so that ability
Ensure the correctness and property as newest as possible of many lower user data of application.
The content of the invention
The technical problem to be solved in the present invention is to provide a kind of method for realizing data syn-chronization mutual exclusion, user equipment, service
Device and system., just can be real by detecting that the synchronous detection pattern and user terminal of user terminal register the service condition of account number
Existing synchronization and mutex operation.So that interprocess communication complicated between avoiding many applications and the operation dimension of management by synchronization application program
Shield, saves terminal device system resources consumption, it is ensured that the synchronous mutual exclusion operation of same Account Data under being applied many equipment more.
According to an aspect of the present invention there is provided a kind of method for realizing data syn-chronization mutual exclusion, including:
Detect and whether there is the data syn-chronization business associated with the register account number of the user equipment in user equipment;
When detecting the presence of the data syn-chronization business, judge the user equipment synchronous detection pattern type whether
For network detection pattern;
If the synchronous detection pattern type of the user equipment is network detection pattern, synchronization request is sent to server;
The response message that the reception server is sent;
Whether judge response message is to allow sync response information;
If response message performs the data syn-chronization business to allow sync response information;Wherein server is described
When the registration account number of user terminal is not with miscellaneous equipment synchronization association, the registration account number of the user terminal and the user are set up
The synchronization association relation of terminal, and send permission sync response information to the user equipment;
When data syn-chronization business is completed, sent to server and synchronously complete instruction, so that server deletes the synchronization
Incidence relation.
According to another aspect of the present invention there is provided a kind of method for realizing data syn-chronization mutual exclusion, including:
When receive user equipment transmission synchronization request when, judge the user equipment registration account number whether with it is other
Equipment synchronization association;Wherein described user equipment is with the data syn-chronization business associated with registration account number and the use
When the synchronous detection pattern of family equipment is network detection pattern, synchronization request is sent to server;
If the registration account number of the user terminal not with miscellaneous equipment synchronization association, set up the registration of the user terminal
Account number and the synchronization association relation of the user terminal;
Being sent to the user terminal allows sync response information, so that the user terminal is performed and the user equipment
The associated data syn-chronization business of register account number;
When receiving that the user equipment sends when synchronously completing instruction, delete the registration account number of the user terminal with
The synchronization association relation of the user terminal.
According to another aspect of the present invention there is provided a kind of user equipment for realizing data syn-chronization mutual exclusion, including business detection
Unit, mode checking unit, the first transmitting element, the first receiving unit, response recognition unit and synchronous service execution unit, its
In:
Business detection unit, for detecting in user equipment with the presence or absence of associated with the register account number of the user equipment
Data syn-chronization business;
Mode checking unit, for the testing result according to business detection unit, if detecting the presence of the data syn-chronization
Business, whether the synchronous detection pattern type for judging the user equipment is network detection pattern;
First transmitting element, for the judged result according to mode checking unit, if the synchronous detection of the user equipment
Mode type is network detection pattern, and synchronization request is sent to server;For the instruction according to synchronous service execution unit, to
Server sends and synchronously completes instruction;
First receiving unit, the response message sent for the reception server;
Recognition unit is responded, for judging whether response message is to allow sync response information;
Synchronous service execution unit, for the judged result according to response recognition unit, if response message is synchronous to allow
Response message, then perform the data syn-chronization business;Wherein server is not set in the registration account number of the user terminal with other
During standby synchronization association, the registration account number of the user terminal and the synchronization association relation of the user terminal are set up, and to described
User equipment, which is sent, allows sync response information;When data syn-chronization business is completed, indicate that the first transmitting element is sent out to server
Send and synchronously complete instruction, so that server deletes the synchronization association relation.
According to another aspect of the present invention there is provided a kind of server for realizing data syn-chronization mutual exclusion, including second receives single
Member, synchronization association detection unit, synchronization association set up unit, the second transmitting element and synchronization association and delete unit, wherein:
Second receiving unit, the synchronization request for receiving user equipment transmission is additionally operable to receive the user equipment hair
That send synchronously completes instruction;
Synchronization association detection unit, for when the second receiving unit receives the synchronization request that user equipment is sent, sentencing
Break the user equipment registration account number whether with miscellaneous equipment synchronization association;Wherein described user equipment is with registering account
Number associated data syn-chronization business and when the synchronous detection pattern of the user equipment is network detection pattern, to service
Device sends synchronization request;
Synchronization association sets up unit, for the testing result according to synchronization association detection unit, if the user terminal
Account number is registered not with miscellaneous equipment synchronization association, then the registration account number for setting up the user terminal is synchronous with the user terminal
Incidence relation, indicating that the second transmitting element is sent to the user terminal allows sync response information;
Second transmitting element, the instruction for setting up unit according to synchronization association, being sent to the user terminal allows together
Response message is walked, so that the user terminal performs the data syn-chronization business associated with the register account number of the user equipment;
Synchronization association deletes unit, for synchronously completing finger when what the second receiving unit received that the user equipment sends
When showing, the registration account number of the user terminal and the synchronization association relation of the user terminal are deleted.
According to another aspect of the present invention there is provided a kind of system for realizing data syn-chronization mutual exclusion, including any of the above-described implementation
User equipment and server that example is related to.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing
There is the accompanying drawing used required in technology description to be briefly described, it should be apparent that, drawings in the following description are only this
Some embodiments of invention, for those of ordinary skill in the art, without having to pay creative labor, may be used also
To obtain other accompanying drawings according to these accompanying drawings.
Fig. 1 realizes the schematic diagram of data syn-chronization mutual exclusion method one embodiment for the present invention.
Fig. 2 realizes the schematic diagram of another embodiment of data syn-chronization mutual exclusion method for the present invention.
Fig. 3 logs in the schematic diagram of broadcast message one embodiment for present invention processing.
Fig. 4 nullifies the schematic diagram of broadcast message one embodiment for present invention processing.
Fig. 5 realizes the schematic diagram of data syn-chronization mutual exclusion method one embodiment for the present invention.
Fig. 6 sends the schematic diagram for logging in broadcast message one embodiment for the present invention.
Fig. 7 sends the schematic diagram for nullifying broadcast message one embodiment for the present invention.
Fig. 8 realizes the schematic diagram of user equipment one embodiment of data syn-chronization mutual exclusion for the present invention.
Fig. 9 realizes the schematic diagram of another embodiment of user equipment of data syn-chronization mutual exclusion for the present invention.
Figure 10 realizes the schematic diagram of server one embodiment of data syn-chronization mutual exclusion for the present invention.
Figure 11 realizes the schematic diagram of another embodiment of server of data syn-chronization mutual exclusion for the present invention.
Figure 12 realizes the schematic diagram of system one embodiment of data syn-chronization mutual exclusion for the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete
Site preparation is described, it is clear that described embodiment is only a part of embodiment of the invention, rather than whole embodiments.Below
Description only actually at least one exemplary embodiment is illustrative, is never used as to the present invention and its application or makes
Any limitation.Based on the embodiment in the present invention, those of ordinary skill in the art are not making creative work premise
Lower obtained every other embodiment, belongs to the scope of protection of the invention.
Unless specifically stated otherwise, the part and positioned opposite, the digital table of step otherwise illustrated in these embodiments
Do not limited the scope of the invention up to formula and numerical value.
Simultaneously, it should be appreciated that for the ease of description, the size of the various pieces shown in accompanying drawing is not according to reality
Proportionate relationship draw.
It may be not discussed in detail for technology, method and apparatus known to person of ordinary skill in the relevant, but suitable
In the case of, the technology, method and apparatus should be considered as authorizing a part for specification.
In shown here and discussion all examples, any occurrence should be construed as merely exemplary, without
It is as limitation.Therefore, the other examples of exemplary embodiment can have different values.
It should be noted that:Similar label and letter represents similar terms in following accompanying drawing, therefore, once a certain Xiang Yi
It is defined, then it need not be further discussed in subsequent accompanying drawing in individual accompanying drawing.
Fig. 1 realizes the schematic diagram of data syn-chronization mutual exclusion method one embodiment for the present invention.It is preferred that, the side of the embodiment
Method step can be performed by user equipment.
Step 101, it is same with the presence or absence of associated with the register account number of user equipment data in detection user equipment
Step business.
Step 102, when detecting the presence of the data syn-chronization business, the synchronous detection pattern of the user equipment is judged
Whether type is network detection pattern.
Step 103, if the synchronous detection pattern type of the user equipment is network detection pattern, send same to server
Step request.
Step 104, the response message that the reception server is sent.
Step 105, whether judge response message is to allow sync response information.
Step 106, if response message performs the data syn-chronization business to allow sync response information.
Wherein server sets up the user when the registration account number of the user terminal is not with miscellaneous equipment synchronization association
The registration account number of terminal and the synchronization association relation of the user terminal, and being sent to the user equipment allows sync response to believe
Breath.
Step 107, when data syn-chronization business is completed, sent to server and synchronously complete instruction, so that server is deleted
The synchronization association relation.
Data syn-chronization mutual exclusion method is realized based on what the above embodiment of the present invention was provided, by the synchronization for detecting user terminal
Detection pattern and user terminal register the service condition of account number, just can realize that synchronization and mutex is operated.So as to avoid many applications
Between complicated interprocess communication and the operation maintenance of management by synchronization application program, save terminal device system resources consumption,
Ensure that the synchronous mutual exclusion operation of same Account Data under applying many equipment more.
It is preferred that, if response message is refusal sync response information, refusal performs the data syn-chronization business.Refusal is held
Row may include to wait or abandon data syn-chronization business.
Wherein server is when the registration account number of the user terminal is with miscellaneous equipment synchronization association, to the user terminal
Send refusal sync response information.
Fig. 2 realizes the schematic diagram of another embodiment of data syn-chronization mutual exclusion method for the present invention.As shown in Fig. 2 in above-mentioned step
In rapid 102, if the synchronous detection pattern type of the user equipment is local detection pattern, following steps are performed:
Step 201, if the synchronous detection pattern type of the user equipment is local detection pattern, detect that the user sets
It whether there is exclusive file in standby.If there is exclusive file in the user equipment, step 202 is performed;Otherwise step is performed
203。
Step 202, refusal performs the data syn-chronization business.Afterwards, other steps of the present embodiment are no longer performed.
Step 203, exclusive file is set up, the data syn-chronization business is performed.
Step 204, when data syn-chronization business is completed, exclusive file is deleted.
When in local detection pattern, without being networked, the execution efficiency of synchronous detection was both improved, turn avoid
Complicated interprocess communication between many applications.
Fig. 3 logs in the schematic diagram of broadcast message one embodiment for present invention processing.
Step 301, the login broadcast message that the reception server is sent.
Wherein server receive any appliance transmission logging request when, record any appliance registration account number and
Device identification, sends to the armamentarium of the registration account number of the currently used any appliance and logs in broadcast message, wherein logging in
Broadcast message includes the device identification of the armamentarium.
Step 302, when receiving the login broadcast message of server transmission, judge to log in and whether only wrapped in broadcast message
Include the device identification of the user equipment.If logging in broadcast message only includes the device identification of the user equipment, step is performed
Rapid 303;If logging in also includes the device identification of miscellaneous equipment in broadcast message, step 304 is performed.
Step 303, the synchronous detection pattern type of the user equipment is set to local detection pattern.Afterwards, no longer
Perform other steps of the present embodiment.
Step 304, the synchronous detection pattern type of the user equipment is set to network detection pattern.
Fig. 4 nullifies the schematic diagram of broadcast message one embodiment for present invention processing.
Step 401, the cancellation broadcast message that the reception server is sent.
When wherein server receives the de-registration request of any appliance transmission, delete any appliance registration account number and
Device identification, sends to the armamentarium of the registration account number of the currently used any appliance and nullifies broadcast message, wherein nullifying
Broadcast message includes the device identification of the armamentarium.
Step 402, when receiving the cancellation broadcast message of server transmission, judge to nullify and whether only wrapped in broadcast message
Include the device identification of the user equipment.
Step 403, if nullifying in broadcast message only includes the device identification of the user equipment, by the user equipment
Synchronous detection pattern type be set to local detection pattern.
Fig. 5 realizes the schematic diagram of data syn-chronization mutual exclusion method one embodiment for the present invention.It is preferred that, the side of the present embodiment
Method step can be performed by server.
Step 501, when receiving the synchronization request of user equipment transmission, judging the registration account number of the user equipment is
No and miscellaneous equipment synchronization association.
Wherein described user equipment is with registering the associated data syn-chronization business of account number and the user equipment
Synchronous detection pattern be network detection pattern when, to server send synchronization request.
Step 502, if the registration account number of the user terminal not with miscellaneous equipment synchronization association, set up the user whole
The registration account number at end and the synchronization association relation of the user terminal.
Step 503, to the user terminal send allow sync response information, so as to the user terminal perform with it is described
The associated data syn-chronization business of the register account number of user equipment.
Step 504, when receiving when synchronously completing instruction of the user equipment transmission, the note of the user terminal is deleted
Volume account number and the synchronization association relation of the user terminal.
Data syn-chronization mutual exclusion method is realized based on what the above embodiment of the present invention was provided, by the synchronization for detecting user terminal
Detection pattern and user terminal register the service condition of account number, just can realize that synchronization and mutex is operated.So as to avoid many applications
Between complicated interprocess communication and the operation maintenance of management by synchronization application program, save terminal device system resources consumption,
Ensure that the synchronous mutual exclusion operation of same Account Data under applying many equipment more.
It is preferred that, if the registration account number of the user terminal and miscellaneous equipment synchronization association, send out to the user terminal
Refusal sync response information is sent, so that user terminal refusal performs the data syn-chronization business.
Fig. 6 sends the schematic diagram for logging in broadcast message one embodiment for the present invention.
Step 601, when receive any appliance transmission logging request when, record any appliance registration account number and
Device identification.
Step 602, sent to the armamentarium of the registration account number of the currently used any appliance and log in broadcast message, its
The middle broadcast message that logs in includes the device identification of the armamentarium.
, will to receive the equipment for logging in broadcast message when only including the device identification of itself in logging in broadcast message
The synchronous detection pattern type of itself is set to local detection pattern, if logging in broadcast message also includes the equipment of miscellaneous equipment
Mark, network detection pattern is set to by the synchronous detection pattern type of itself.
Fig. 7 sends the schematic diagram for nullifying broadcast message one embodiment for the present invention.
Step 701, when receiving the de-registration request of any appliance transmission, delete any appliance registration account number and
Device identification.
Step 702, sent to the armamentarium of the registration account number of the currently used any appliance and nullify broadcast message, its
Middle broadcast message of nullifying includes the device identification of the armamentarium.
, will to receive the equipment for nullifying broadcast message when only including the device identification of itself in nullifying broadcast message
The synchronous detection pattern type of itself is set to local detection pattern.
Below by specific example, the present invention will be described.
When equipment devA is logged in account number account01, server is in Registry accountLoginInfo_
Insertion record " account01 devA " in table.Because now only equipment devA is logged in account number account01, therefore clothes
Device be engaged in equipment devA transmission login broadcast messages, wherein logging in broadcast message only includes equipment devA mark.Equipment
DevA is received after login broadcast message, the synchronous detection pattern of itself is set into local detection pattern, i.e.,
SyncCheckMode=Local.
When equipment devB is also logged in account number account01, server is in Registry accountLoginInfo_
Insertion record " account01 devB " in table.Because now equipment devA and equipment devB are stepped on account number account01
Record, therefore server sends login broadcast message to equipment devA and equipment devB, wherein logging in broadcast message includes equipment
DevA and equipment devB mark.Equipment devA and equipment devB are received after login broadcast message, and the synchronization of itself is detected
Pattern is set to network detection pattern, i.e. syncCheckMode=Net.
When equipment devA be in local detection pattern when, if now exist carry out data syn-chronization business, for example using
App_A01, then further detection whether there is account01 exclusive file in such as storage device of SD storage cards.If
There is exclusive file, then mean currently there is other application to carry out the data syn-chronization associated with account01, now refusal is held
Row data synchronous service.If in the absence of exclusive file, exclusive file syncProcessing_ is set up on SD
Account01.txt, app_A01 start the data syn-chronization business to account01.When business is completed, exclusive file is deleted
syncProcessing_account01.txt。
When equipment devA is in network detection pattern, if now there is the business for carrying out data syn-chronization, example in equipment devA
App_A01, equipment devA is such as applied to send synchronization request to server.Server is in synchronizing information table syncInfo_table
Judge that account01 is not related not to the synchronous applications of miscellaneous equipment with miscellaneous equipment synchronization association, i.e. account01
Connection, then insertion record " account01 devA app_A01 ", and to equipment devA send allow sync response information.Equipment
DevA is received after permission sync response information, performs data syn-chronization business.
If now devB also sends synchronization request to server, the synchronous service associated with account01 is asked.Service
Device inquires account01 and devA synchronization associations in synchronizing information table, then sends refusal sync response information to devB.
After devA completes data syn-chronization business, sent to server and synchronously complete instruction, server is in synchronizing information table
Middle deletion record " account01 devA app_A01 ", and sent to devA and synchronously complete confirmation.
If now devB asks the synchronous service associated with account01, server is inquired in synchronizing information table
Account01 not with miscellaneous equipment synchronization association, then insert relative recording, and being sent to equipment devB allows sync response to believe
Breath.Equipment devB is received after permission sync response information, performs data syn-chronization business.
If account01 login is nullified in devA requests, de-registration request is sent to server.Server deletes registration letter
Cease record " the account01 devA ", and sent to devA and nullify and successfully confirm in table.Server lookup simultaneously is used
The armamentarium that account01 is logged in(Including devB), and it is used as terminal set of records ends to the mark of above-mentioned armamentarium
TerminalSet, which is sent, nullifies broadcast message.When devB receives cancellation broadcast message, judging to nullify in broadcast message is
It is no only to include devB itself device identification.If nullifying in broadcast message only includes devB itself device identification, show this
When only devB oneself logged in using account01, devB synchronous detection pattern is at this moment set to local detection pattern.
If including the device identification of miscellaneous equipment, then table in addition to the device identification including devB itself in cancellation broadcast message
It is bright now to also have multiple equipment to be logged in account01, now still keep devB synchronous detection pattern to be set to network detection
Pattern.
Fig. 8 realizes the schematic diagram of user equipment one embodiment of data syn-chronization mutual exclusion for the present invention.As shown in figure 8, with
Family equipment includes business detection unit 801, mode checking unit 802, the first transmitting element 803, the first receiving unit 804, sound
Answer recognition unit 805 and synchronous service execution unit 806.Wherein:
Business detection unit 801, for detecting in user equipment with the presence or absence of the register account number phase with the user equipment
The data syn-chronization business of association.
Mode checking unit 802, for the testing result according to business detection unit 801, if detecting the presence of the number
According to synchronous service, whether the synchronous detection pattern type for judging the user equipment is network detection pattern.
First transmitting element 803, for the judged result according to mode checking unit 802, if the user equipment is same
It is network detection pattern to walk detection pattern type, and synchronization request is sent to server;For according to synchronous service execution unit 806
Instruction, to server send synchronously complete instruction.
First receiving unit 804, the response message sent for the reception server.
Recognition unit 805 is responded, for judging whether response message is to allow sync response information.
Synchronous service execution unit 806, for the judged result according to response recognition unit 805, if response message is fair
Perhaps sync response information, then perform the data syn-chronization business;Wherein server the user terminal registration account number not with
During miscellaneous equipment synchronization association, the registration account number of the user terminal and the synchronization association relation of the user terminal are set up, and
Being sent to the user equipment allows sync response information;When data syn-chronization business is completed, indicate the first transmitting element 803 to
Server sends and synchronously completes instruction, so that server deletes the synchronization association relation.
The user equipment for realizing data syn-chronization mutual exclusion provided based on the above embodiment of the present invention, by detecting user terminal
Synchronous detection pattern and user terminal register account number service condition, just can realize synchronization and mutex operate.So as to avoid
Complicated interprocess communication and the operation maintenance of management by synchronization application program, save terminal device system resource between many applications
Consumption, it is ensured that the synchronous mutual exclusion operation of same Account Data under being applied many equipment more.
It is preferred that, synchronous service execution unit 806 is additionally operable to the judged result according to response recognition unit 805, if response
Information is refusal sync response information, then refusal performs the data syn-chronization business, and wherein server is in the user terminal
When registering account number with miscellaneous equipment synchronization association, refusal sync response information is sent to the user terminal.
Fig. 9 realizes the schematic diagram of another embodiment of user equipment of data syn-chronization mutual exclusion for the present invention.With implementing shown in Fig. 8
Example is compared, in the embodiment shown in fig. 9, and user equipment also includes exclusive file detection unit 901, exclusive file and sets up unit
902 and exclusive file delete unit 903.Wherein:
Exclusive file detection unit 901, for the testing result according to mode checking unit 802, if the user equipment
Synchronous detection pattern type be local detection pattern, detect and whether there is exclusive file in the user equipment;If described use
There is exclusive file in the equipment of family, it indicates that the refusal of synchronous service execution unit 806 performs the data syn-chronization business.
Exclusive file sets up unit 902, for the testing result according to exclusive file detection unit 901, if the user
Exclusive file is not present in equipment, then sets up exclusive file, indicates that synchronous service execution unit 806 performs the data syn-chronization industry
Business.
Exclusive file deletes unit 903, for when synchronous service execution unit 806 completes data syn-chronization business, deleting
Exclusive file.
It is preferred that, user equipment also includes log messages recognition unit 904 and mode setting unit 905.Wherein:
First receiving unit 804 is additionally operable to the login broadcast message of the reception server transmission.
Wherein server receive any appliance transmission logging request when, record any appliance registration account number and
Device identification, sends to the armamentarium of the registration account number of the currently used any appliance and logs in broadcast message, wherein logging in
Broadcast message includes the device identification of the armamentarium.
Log messages recognition unit 904, the login broadcast for receiving server transmission when the first receiving unit 804 disappears
During breath, judge log in broadcast message whether only include the device identification of the user equipment.
Mode setting unit 905, for the judged result according to log messages recognition unit 904, if logging in broadcast message
In only include the device identification of the user equipment, the synchronous detection pattern type of the user equipment is set to local detection
Pattern;If logging in broadcast message also includes the device identification of miscellaneous equipment, by the synchronous detection pattern class of the user equipment
Type is set to network detection pattern.
It is preferred that, user equipment also includes logout message recognition unit 906.Wherein:
First receiving unit 804 is additionally operable to the cancellation broadcast message of the reception server transmission.
When wherein server receives the de-registration request of any appliance transmission, delete any appliance registration account number and
Device identification, sends to the armamentarium of the registration account number of the currently used any appliance and nullifies broadcast message, wherein nullifying
Broadcast message includes the device identification of the armamentarium.
Logout message recognition unit 906, the cancellation broadcast for receiving server transmission when the first receiving unit 804 disappears
During breath, judge nullify in broadcast message whether only include the device identification of the user equipment.
Mode setting unit 905 is additionally operable to the judged result according to logout message recognition unit 906, if nullifying broadcast message
In only include the device identification of the user equipment, then the synchronous detection pattern type of the user equipment is set to local inspection
Survey pattern.
Figure 10 realizes the schematic diagram of server one embodiment of data syn-chronization mutual exclusion for the present invention.As shown in Figure 10, take
Business device includes the second receiving unit 1001, synchronization association detection unit 1002, synchronization association and sets up the transmission list of unit 1003, second
Member 1004 and synchronization association delete unit 1005.Wherein:
Second receiving unit 1001, the synchronization request for receiving user equipment transmission is additionally operable to receive the user and set
What preparation was sent synchronously completes instruction.
Synchronization association detection unit 1002, the synchronization for receiving user equipment transmission when the second receiving unit 1001 please
When asking, judge the user equipment registration account number whether with miscellaneous equipment synchronization association;Wherein described user equipment with
The data syn-chronization business associated with the registering account number and synchronous detection pattern of the user equipment is network detection pattern
When, send synchronization request to server.
Synchronization association sets up unit 1003, for the testing result according to synchronization association detection unit 1002, if described use
The registration account number of family terminal is not with miscellaneous equipment synchronization association, then registration account number and the user for setting up the user terminal are whole
The synchronization association relation at end, indicating that the second transmitting element 1004 is sent to the user terminal allows sync response information.
Second transmitting element 1004, the instruction for setting up unit 1003 according to synchronization association is sent out to the user terminal
Permission sync response information is sent, so that the user terminal execution data associated with the register account number of the user equipment are same
Step business.
Synchronization association deletes unit 1005, for receiving the same of the user equipment transmission when the second receiving unit 1001
When step completes to indicate, the registration account number of the user terminal and the synchronization association relation of the user terminal are deleted.
The server for realizing data syn-chronization mutual exclusion provided based on the above embodiment of the present invention, by detecting user terminal
Synchronous detection pattern and user terminal register the service condition of account number, just can realize that synchronization and mutex is operated.It is many so as to avoid
Using a complicated interprocess communication and the operation maintenance of management by synchronization application program, save terminal device system resource and disappear
Consumption, it is ensured that the synchronous mutual exclusion operation of same Account Data under being applied many equipment more.
It is preferred that, the second transmitting element 1004 is additionally operable to detect the user terminal in synchronization association detection unit 1002
When registering account number with miscellaneous equipment synchronization association, refusal sync response information is sent to the user terminal, so as to the user
Terminal refusal performs the data syn-chronization business.
Figure 11 realizes the schematic diagram of another embodiment of server of data syn-chronization mutual exclusion for the present invention.With implementing shown in Figure 10
Example is compared, in the embodiment shown in fig. 11, and server also includes log-on message recording unit 1101.Wherein:
Log-on message recording unit 1101, the login for receiving any appliance transmission when the second receiving unit 1001 please
When asking, registration account number and the device identification of any appliance are recorded.
Second transmitting element 1004 is additionally operable to the armamentarium transmission to the registration account number of the currently used any appliance
Broadcast message is logged in, wherein logging in broadcast message includes the device identification of the armamentarium, is disappeared to receive login broadcast
The synchronous detection pattern type of itself is set to by the equipment of breath when only including the device identification of itself in logging in broadcast message
Local detection pattern, if logging in broadcast message also includes the device identification of miscellaneous equipment, by the synchronous detection pattern class of itself
Type is set to network detection pattern.
It is preferred that, server also includes log-off message processing unit 1102.Wherein:
Log-off message processing unit 1102, the cancellation for receiving any appliance transmission when the second receiving unit 1101 please
When asking, registration account number and the device identification of any appliance are deleted.
Second transmitting element 1004 is additionally operable to the armamentarium transmission to the registration account number of the currently used any appliance
Broadcast message is nullified, wherein nullifying broadcast message includes the device identification of the armamentarium;Disappear to receive cancellation broadcast
The synchronous detection pattern type of itself is set to by the equipment of breath when only including the device identification of itself in nullifying broadcast message
Local detection pattern.
Figure 12 realizes the schematic diagram of system one embodiment of data syn-chronization mutual exclusion for the present invention.As shown in figure 12, system
Including user equipment 1201 and server 1202.Wherein:The user that user equipment 1201 is related to for any embodiment in accompanying drawing 8-9
Equipment, the server that server 1202 is related to for any embodiment in accompanying drawing 10-11.
Compared to prior art, the present invention combines local file detection and networking two kinds of synchronous detection modes of detection, to same
The situation that one account number is only logged in a station terminal equipment only needs to carry out local file detection without networking, has both improved synchronous inspection
The execution efficiency of survey, turn avoid interprocess communication complicated between applying more;The many station terminal equipment of same account number are logged in simultaneously
Situation, need to only network detection, whether in other equipment or other application line number is entered from the current account number of server end acquisition
According to synchronous service, interprocess communication complicated between many applications and the operation maintenance of management by synchronization application program are equally avoided,
Saving terminal device system resources consumption, it is ensured that the synchronous mutual exclusion operation of same Account Data under being applied many equipment more.
One of ordinary skill in the art will appreciate that realizing that all or part of step of above-described embodiment can be by hardware
To complete, the hardware of correlation can also be instructed to complete by program, described program can be stored in a kind of computer-readable
In storage medium, storage medium mentioned above can be read-only storage, disk or CD etc..
Description of the invention is provided for the sake of example and description, and is not exhaustively or by the present invention
It is limited to disclosed form.Many modifications and variations are obvious for the ordinary skill in the art.Select and retouch
State embodiment and be more preferably to illustrate the principle and practical application of the present invention, and one of ordinary skill in the art is managed
The solution present invention is so as to design the various embodiments with various modifications suitable for special-purpose.
Claims (19)
1. a kind of method for realizing data syn-chronization mutual exclusion, it is characterised in that including:
Detect and whether there is the data syn-chronization business associated with the register account number of the user equipment in user equipment;
When detecting the presence of the data syn-chronization business, whether the synchronous detection pattern type for judging the user equipment is net
Network detection pattern;
If the synchronous detection pattern type of the user equipment is network detection pattern, synchronization request is sent to server;
The response message that the reception server is sent;
Whether judge response message is to allow sync response information;
If response message performs the data syn-chronization business to allow sync response information;Wherein server is in the user
When the registration account number of equipment is not with miscellaneous equipment synchronization association, the registration account number and the user equipment of the user equipment are set up
Synchronization association relation, and to the user equipment send allow sync response information;
When data syn-chronization business is completed, sent to server and synchronously complete instruction, so that server deletes the synchronization association
Relation.
2. according to the method described in claim 1, it is characterised in that also include:
If response message is refusal sync response information, refusal performs the data syn-chronization business, and wherein server is described
When the registration account number of user equipment is with miscellaneous equipment synchronization association, refusal sync response information is sent to the user equipment.
3. method according to claim 1 or 2, it is characterised in that also include:
If the synchronous detection pattern type of the user equipment is local detection pattern, detects and whether there is in the user equipment
Exclusive file;
If there is exclusive file in the user equipment, refusal performs the data syn-chronization business;
If exclusive file is not present in the user equipment, exclusive file is set up, the data syn-chronization business is performed;
When data syn-chronization business is completed, exclusive file is deleted.
4. method according to claim 1 or 2, it is characterised in that also include:
The login broadcast message that the reception server is sent, when wherein server receives the logging request of any appliance transmission, note
Registration account number and the device identification of any appliance are recorded, to the armamentarium of the registration account number of the currently used any appliance
Send and log in broadcast message, wherein logging in broadcast message includes the device identification of the armamentarium;
When receiving the login broadcast message of server transmission, judge whether only set in login broadcast message including the user
Standby device identification;
If logging in broadcast message only includes the device identification of the user equipment, by the synchronous detection pattern of the user equipment
Type is set to local detection pattern;
If logging in broadcast message also includes the device identification of miscellaneous equipment, by the synchronous detection pattern type of the user equipment
It is set to network detection pattern.
5. method according to claim 1 or 2, it is characterised in that also include:
The cancellation broadcast message that the reception server is sent, when wherein server receives the de-registration request of any appliance transmission, is deleted
Except the registration account number of any appliance and device identification, to the armamentarium of the registration account number of the currently used any appliance
Send and nullify broadcast message, wherein nullifying broadcast message includes the device identification of the armamentarium;
When receiving the cancellation broadcast message of server transmission, judge whether only set in cancellation broadcast message including the user
Standby device identification;
If nullifying in broadcast message only includes the device identification of the user equipment, by the synchronous detection mould of the user equipment
Formula type is set to local detection pattern.
6. a kind of method for realizing data syn-chronization mutual exclusion, it is characterised in that including:
When receive user equipment transmission synchronization request when, judge the user equipment registration account number whether with miscellaneous equipment
Synchronization association;Wherein described user equipment with registration the associated data syn-chronization business of account number and the user set
When standby synchronous detection pattern is network detection pattern, synchronization request is sent to server;
If the registration account number of the user equipment not with miscellaneous equipment synchronization association, set up the registration account number of the user equipment
With the synchronization association relation of the user equipment;
Being sent to the user equipment allows sync response information, so that the user equipment performs the note with the user equipment
The associated data syn-chronization business of volume account;
When receiving that the user equipment sends when synchronously completing instruction, delete the registration account number of the user equipment with it is described
The synchronization association relation of user equipment.
7. method according to claim 6, it is characterised in that
If the registration account number of the user equipment and miscellaneous equipment synchronization association, the synchronous sound of refusal is sent to the user equipment
Information is answered, so that user equipment refusal performs the data syn-chronization business.
8. the method according to claim 6 or 7, it is characterised in that also include:
When receiving the logging request of any appliance transmission, registration account number and the device identification of any appliance are recorded;
Sent to the armamentarium of the registration account number of the currently used any appliance and log in broadcast message, disappeared wherein logging in broadcast
Breath includes the device identification of the armamentarium, so that the equipment for receiving login broadcast message is only wrapped in broadcast message is logged in
When including the device identification of itself, the synchronous detection pattern type of itself is set to local detection pattern, if logging in broadcast message
In also include the device identification of miscellaneous equipment, the synchronous detection pattern type of itself is set to network detection pattern.
9. the method according to claim 6 or 7, it is characterised in that also include:
When receiving the de-registration request of any appliance transmission, registration account number and the device identification of any appliance are deleted;
Sent to the armamentarium of the registration account number of the currently used any appliance and nullify broadcast message, disappeared wherein nullifying broadcast
Breath includes the device identification of the armamentarium;So that the equipment for receiving cancellation broadcast message is only wrapped in broadcast message is nullified
When including the device identification of itself, the synchronous detection pattern type of itself is set to local detection pattern.
10. a kind of user equipment for realizing data syn-chronization mutual exclusion, it is characterised in that including business detection unit, mode detection list
Member, the first transmitting element, the first receiving unit, response recognition unit and synchronous service execution unit, wherein:
Business detection unit, the number associated with the register account number of the user equipment is whether there is for detecting in user equipment
According to synchronous service;
Mode checking unit, for the testing result according to business detection unit, if detecting the presence of the data syn-chronization business,
Whether the synchronous detection pattern type for judging the user equipment is network detection pattern;
First transmitting element, for the judged result according to mode checking unit, if the synchronous detection pattern of the user equipment
Type is network detection pattern, and synchronization request is sent to server;For the instruction according to synchronous service execution unit, to service
Device sends and synchronously completes instruction;
First receiving unit, the response message sent for the reception server;
Recognition unit is responded, for judging whether response message is to allow sync response information;
Synchronous service execution unit, for the judged result according to response recognition unit, if response message is permission sync response
Information, then perform the data syn-chronization business;Wherein server is same not with miscellaneous equipment in the registration account number of the user equipment
During step association, the registration account number of the user equipment and the synchronization association relation of the user equipment are set up, and to the user
Equipment, which is sent, allows sync response information;When data syn-chronization business is completed, indicate that the first transmitting element sends same to server
Step completes to indicate, so that server deletes the synchronization association relation.
11. user equipment according to claim 10, it is characterised in that
Synchronous service execution unit is additionally operable to the judged result according to response recognition unit, if response message is refusal sync response
Information, then refuse to perform the data syn-chronization business, wherein registration account number and miscellaneous equipment of the server in the user equipment
During synchronization association, refusal sync response information is sent to the user equipment.
12. the user equipment according to claim 10 or 11, it is characterised in that the user equipment also includes exclusive file
Detection unit, exclusive file set up unit and exclusive file deletes unit, wherein:
Exclusive file detection unit, for the testing result according to mode checking unit, if the synchronous detection of the user equipment
Mode type is local detection pattern, detects and whether there is exclusive file in the user equipment;If being deposited in the user equipment
In exclusive file, it indicates that synchronous service execution unit refusal performs the data syn-chronization business;
Exclusive file sets up unit, for the testing result according to exclusive file detection unit, if not deposited in the user equipment
In exclusive file, then exclusive file is set up, indicate that synchronous service execution unit performs the data syn-chronization business;
Exclusive file deletes unit, for when synchronous service execution unit completes data syn-chronization business, deleting exclusive file.
13. the user equipment according to claim 10 or 11, it is characterised in that the user equipment also includes log messages
Recognition unit and mode setting unit, wherein:
First receiving unit is additionally operable to the login broadcast message of the reception server transmission, and wherein server receives any appliance hair
During the logging request sent, registration account number and the device identification of any appliance are recorded, to the currently used any appliance
The armamentarium for registering account number sends login broadcast message, wherein logging in broadcast message includes the equipment mark of the armamentarium
Know;
Log messages recognition unit, when the login for receiving server transmission when the first receiving unit broadcasts the message, judges
Whether log in broadcast message only includes the device identification of the user equipment;
Mode setting unit, for the judged result according to log messages recognition unit, if logging in only includes institute in broadcast message
The device identification of user equipment is stated, the synchronous detection pattern type of the user equipment is set to local detection pattern;If stepping on
Also include the device identification of miscellaneous equipment in record broadcast message, the synchronous detection pattern type of the user equipment is set to net
Network detection pattern.
14. user equipment according to claim 13, it is characterised in that the user equipment also includes logout message and recognized
Unit, wherein:
First receiving unit is additionally operable to the cancellation broadcast message of the reception server transmission, and wherein server receives any appliance hair
During the de-registration request sent, registration account number and the device identification of any appliance are deleted, to the currently used any appliance
The armamentarium for registering account number sends cancellation broadcast message, wherein nullifying broadcast message includes the equipment mark of the armamentarium
Know;
Logout message recognition unit, when the cancellation for receiving server transmission when the first receiving unit broadcasts the message, judges
Whether nullify in broadcast message only includes the device identification of the user equipment;
Mode setting unit is additionally operable to the judged result according to logout message recognition unit, if nullifying only includes institute in broadcast message
The device identification of user equipment is stated, then the synchronous detection pattern type of the user equipment is set to local detection pattern.
15. a kind of server for realizing data syn-chronization mutual exclusion, it is characterised in that detected including the second receiving unit, synchronization association
Unit, synchronization association set up unit, the second transmitting element and synchronization association and delete unit, wherein:
Second receiving unit, the synchronization request for receiving user equipment transmission is additionally operable to receive what the user equipment was sent
Synchronously complete instruction;
Synchronization association detection unit, for when the second receiving unit receives the synchronization request that user equipment is sent, judging institute
State user equipment registration account number whether with miscellaneous equipment synchronization association;Wherein described user equipment is with registering account number phase
When the data syn-chronization business of association and the synchronous detection pattern of the user equipment are network detection pattern, sent out to server
Send synchronization request;
Synchronization association sets up unit, for the testing result according to synchronization association detection unit, if the registration of the user equipment
Account number not with miscellaneous equipment synchronization association, then set up the registration account number of the user equipment and the synchronization association of the user equipment
Relation, indicating that the second transmitting element is sent to the user equipment allows sync response information;
Second transmitting element, the instruction for setting up unit according to synchronization association, being sent to the user equipment allows synchronous ring
Information is answered, so that the user equipment performs the data syn-chronization business associated with the register account number of the user equipment;
Synchronization association deletes unit, for synchronously completing instruction when what the second receiving unit received that the user equipment sends
When, delete the registration account number of the user equipment and the synchronization association relation of the user equipment.
16. server according to claim 15, it is characterised in that
Second transmitting element is additionally operable to detect the registration account number and miscellaneous equipment of the user equipment in synchronization association detection unit
During synchronization association, refusal sync response information is sent to the user equipment, so that user equipment refusal performs the number
According to synchronous service.
17. the server according to claim 15 or 16, it is characterised in that also including log-on message recording unit, wherein:
Log-on message recording unit, for when the second receiving unit receives the logging request that any appliance is sent, recording institute
State registration account number and the device identification of any appliance;
Second transmitting element, which is additionally operable to send to the armamentarium of the registration account number of the currently used any appliance, logs in broadcast
Message, wherein logging in broadcast message includes the device identification of the armamentarium, to receive the equipment for logging in broadcast message
When only including the device identification of itself in logging in broadcast message, the synchronous detection pattern type of itself is set to local detection
Pattern, if logging in broadcast message also includes the device identification of miscellaneous equipment, the synchronous detection pattern type of itself is set to
Network detection pattern.
18. the server according to claim 15 or 16, it is characterised in that also including log-off message processing unit, wherein:
Log-off message processing unit, for when the second receiving unit receives the de-registration request that any appliance is sent, deleting institute
State registration account number and the device identification of any appliance;
Second transmitting element, which is additionally operable to send to the armamentarium of the registration account number of the currently used any appliance, nullifies broadcast
Message, wherein nullifying broadcast message includes the device identification of the armamentarium;To receive the equipment for nullifying broadcast message
When only including the device identification of itself in nullifying broadcast message, the synchronous detection pattern type of itself is set to local detection
Pattern.
19. a kind of system for realizing data syn-chronization mutual exclusion, it is characterised in that including user equipment and server, wherein:
User equipment is the user equipment that any one of claim 10-14 is related to;
Server is the server that any one of claim 15-18 is related to.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310196274.8A CN104184626B (en) | 2013-05-24 | 2013-05-24 | Realize method, user equipment, server and the system of data syn-chronization mutual exclusion |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310196274.8A CN104184626B (en) | 2013-05-24 | 2013-05-24 | Realize method, user equipment, server and the system of data syn-chronization mutual exclusion |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104184626A CN104184626A (en) | 2014-12-03 |
CN104184626B true CN104184626B (en) | 2017-09-29 |
Family
ID=51965386
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310196274.8A Active CN104184626B (en) | 2013-05-24 | 2013-05-24 | Realize method, user equipment, server and the system of data syn-chronization mutual exclusion |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104184626B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115086999A (en) * | 2022-07-14 | 2022-09-20 | 中国联合网络通信集团有限公司 | Measuring method, measuring device, storage medium and equipment |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101009694A (en) * | 2006-01-25 | 2007-08-01 | 宇龙计算机通信科技(深圳)有限公司 | Cooperation system among the handset, computer and synchronization server and its method |
CN102752294A (en) * | 2012-06-19 | 2012-10-24 | 中国科学院计算技术研究所 | Method and system for synchronizing data of multiple terminals on basis of equipment capacity |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20120254949A1 (en) * | 2011-03-31 | 2012-10-04 | Nokia Corporation | Method and apparatus for generating unique identifier values for applications and services |
-
2013
- 2013-05-24 CN CN201310196274.8A patent/CN104184626B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101009694A (en) * | 2006-01-25 | 2007-08-01 | 宇龙计算机通信科技(深圳)有限公司 | Cooperation system among the handset, computer and synchronization server and its method |
CN102752294A (en) * | 2012-06-19 | 2012-10-24 | 中国科学院计算技术研究所 | Method and system for synchronizing data of multiple terminals on basis of equipment capacity |
Also Published As
Publication number | Publication date |
---|---|
CN104184626A (en) | 2014-12-03 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103064584B (en) | Method of attaching and device | |
CN104468551B (en) | A kind of method and device saving flow based on Ad blocking | |
CN105120299B (en) | Video pushing method and device | |
CN108124173A (en) | A kind of one-to-many throw shields display methods, system and storage medium | |
CN102831537B (en) | A kind of method and device obtaining network advertisement information | |
CN100579121C (en) | Method for securing special line user access network | |
CN101483676B (en) | Network for securing special line user to access to network | |
CN105450778B (en) | Information transmission system | |
CN104283926B (en) | A kind of method of data synchronization, device and server | |
CN107659850B (en) | Media information processing method and device | |
CN104283769B (en) | The user oriented instant message service based on project interested | |
CN103823801B (en) | A kind of method, apparatus and system realized webpage in the terminal and shared | |
CN103647701B (en) | The control method and device of instantaneous communication system message forwarding | |
CN105933846A (en) | Business processing method, device, terminal and business system | |
CN104821929A (en) | Multimedia data sharing method and terminal | |
CN104484486A (en) | Information recommending method and electronic device | |
TW201430709A (en) | Method, intelligent terminal, service platform and system for changing application type of intelligent card | |
CN102664831B (en) | Method, client and the system of file data are transmitted by instant messaging tools | |
CN104539509B (en) | The method and apparatus that notification channel starts broadcasting | |
CN106231235B (en) | Long-distance video meets with method and system under a kind of constrained environment | |
CN104601416A (en) | Family group management, business sharing and personalized information sharing method and equipment | |
CN104184626B (en) | Realize method, user equipment, server and the system of data syn-chronization mutual exclusion | |
CN108415908A (en) | A kind of processing method and server of multi-medium data | |
CN105791445A (en) | Self-service method and device | |
CN103873631B (en) | Method and device for displaying call interface of mobile terminal |
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 |