CN103024049A - System capable of achieving browser data synchronization - Google Patents

System capable of achieving browser data synchronization Download PDF

Info

Publication number
CN103024049A
CN103024049A CN2012105487645A CN201210548764A CN103024049A CN 103024049 A CN103024049 A CN 103024049A CN 2012105487645 A CN2012105487645 A CN 2012105487645A CN 201210548764 A CN201210548764 A CN 201210548764A CN 103024049 A CN103024049 A CN 103024049A
Authority
CN
China
Prior art keywords
information
client
server
browser
socket
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN2012105487645A
Other languages
Chinese (zh)
Other versions
CN103024049B (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.)
Beijing Qihoo Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Qizhi Software Beijing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Qihoo Technology Co Ltd, Qizhi Software Beijing Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201210548764.5A priority Critical patent/CN103024049B/en
Publication of CN103024049A publication Critical patent/CN103024049A/en
Application granted granted Critical
Publication of CN103024049B publication Critical patent/CN103024049B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The invention relates to a system capable of achieving browser data synchronization. The system comprises a cloud storage server side, a push server, a plurality of browser client sides and a socket server, wherein the cloud storage server side is used for issuing condition information and command information to the push server when data are updated; the push server is used for determining the target client side from the plurality of browser client sides according to the condition information and transmitting the command information to the socket server which is connected with the target client side; the target client side is used for achieving data synchronization between the target client side and the cloud storage server side according to the command information; and the socket server is used for transmitting the command information coming from the push server to the corresponding target client side. By the aid of the system, the high-efficiency transmission of synchronous data can be achieved, the execution time can be shortened, the resource consumption can be reduced, the system efficiency can be improved, and the instantaneity of services can be improved.

Description

Realize the synchronous system of browser data
Technical field
The present invention relates to the information technology data field of synchronization, relate in particular to a kind of system that realizes that browser data is synchronous.
Background technology
At present, along with the development of network technology, the Internet is as huge information resources, becomes the most convenient of people's obtaining information, approach efficiently.At present, the user uses personal computer access internet (Internet) usually, and browser (Browser) accessed web page by installing in the personal computer, obtains the information that needs.Along with the development of mobile communication technology, the user can also access internet by the portable terminal of supporting browser function, for example mobile phone, personal digital assistant (PersonalDigital Assistant is called for short PDA).
Yet, no matter be browser on the personal computer or the browser on the portable terminal, Push Service generally is not provided, server end depends on being connected of client initiation with the information interaction of client, server end can't send to client with information on one's own initiative, thereby can't realize the real-time synchronization of the information between server end and the browser client.
In the prior art, the synchronous mode of the most frequently used realization browser client and server end browser data is that browser client sends request with certain frequency to server end, as once in a week or per month once, if having the renewal of relevant information, service end obtains these information.Yet the applicant finds that there is following technological deficiency in this kind data method of synchronization: efficient is lower, take resource real real-time synchronizations many, that can not accomplish content upgrades.
In addition, in the prior art, between server and client, connect and often use socket (socket) service, so-called socket is a kind of exchange way of client and server in the network, when will connecting, server and client go forward side by side line number when reportedly sending, server and the client that need to connect (destination client) need to be docked, and socket can be regarded as this docking " docking number ", only have " docking number " of server and destination client identical, can connect to transmit data.And sockets services is exactly the docking service that connects confession for the server and client side.Yet, common sockets services adopts the isochronous schedules mode when realization is carried out data-pushing to a plurality of clients, namely after socket server sends a message to client, wait for that this client receives and confirms, then to next client push message.And general sockets services adopts the http agreement, and the http consultation takies more system resource, can cause the quick consumption of resource when traffic carrying capacity is large, thereby reduces the synchronous real-time of data.
Summary of the invention
In view of the above problems, the present invention has been proposed in order to a kind of synchronous system of realization browser data that overcomes the problems referred to above or address the above problem at least in part is provided.
The present invention proposes a kind of system that realizes that browser data is synchronous, this system comprises: cloud storage server end, push server and a plurality of browser client and socket server, wherein said cloud storage server end is used for issuing conditional information and command information to described push server when Data Update is arranged; Described push server is used for determining the destination client according to this conditional information at described a plurality of browser clients, and described command information is sent to described destination client; And described destination client, be used for realizing that according to described command information the data of itself and cloud storage server end are synchronous; Described socket server is used for sending to from the command information of push server corresponding destination client.
Alternatively, described socket server comprises link block, this link block is used for setting up socket with described browser client and is connected, wherein, when described browser client is initiated with being connected of described socket server, described link block is accepted this connection, and obtains the resource identifier of this connection.
According to a kind of embodiment of the present invention, described link block also is used for receiving the connection identifier (CID that sends from described browser client via described connection; Described socket server also comprises authentication module, and described authentication module is used for: when receiving the connection identifier (CID that sends from described browser client, inquiry distribution information database is to verify whether this connection identifier (CID is present in this distribution information database.
According to a kind of embodiment of the present invention, described authentication module also is used for: when described connection identifier (CID is present in this distribution information database, deposit described resource identifier in described distribution information database.
According to a kind of embodiment of the present invention, described authentication module also is used for: when described connection identifier (CID is not present in this distribution information database, indicate described link block to disconnect described connection.
According to a kind of embodiment of the present invention, described socket server also comprises an enquiry module, when described push server sends to the socket server that distributes into the destination client with conditional information and command information, described enquiry module according to described conditional information inquiry distribution information database to determine the destination client.
According to a kind of embodiment of the present invention, this link block is determined the destination client according to conditional information query resource identifier in the distribution information database.
According to a kind of embodiment of the present invention, when described socket server has received command information and determined the destination client according to conditional information, and during more than one of destination client, described link block sends after the command messages one of them client, does not wait for that its confirmation of receipt just directly sends command messages to next client.
According to a kind of embodiment of the present invention, described link block employing transmission control protocol is connected the transmission with command information with described browser client.
Alternatively, this system also comprises distributor, is used for distributing connected socket server to browser client; Described distributor also comprises: the distribution information database is used for storage and distributes relevant information with socket server
Can find out from technique scheme, the present invention has following beneficial effect:
(1) by socket server, distributor and distribution information database, realized that smoothly cloud storage server end, push server be connected connection with the destination client;
(2) socket server of the present invention adopts the asynchronous schedule mode, thereby reaches the efficient transmission of data, and then shortens the time of implementation, improves system effectiveness and reduces the time difference that different clients receives message, improves professional real-time.
(3) the present invention adopts the more transmission control protocol agreement of bottom (Transmission Control Protocol) when realizing socket server, thereby realize reducing of resource consumption, under limited resources supplIes, improve the traffic handing capacity of system.
Above-mentioned explanation only is the general introduction of technical solution of the present invention, for can clearer understanding technological means of the present invention, and can be implemented according to the content of specification, and for above and other objects of the present invention, feature and advantage can be become apparent, below especially exemplified by the specific embodiment of the present invention.
Description of drawings
By reading hereinafter detailed description of the preferred embodiment, various other advantage and benefits will become cheer and bright for those of ordinary skills.Accompanying drawing only is used for the purpose of preferred implementation is shown, and does not think limitation of the present invention.And in whole accompanying drawing, represent identical parts with identical reference symbol.In the accompanying drawings:
Fig. 1 is for realizing according to an embodiment of the invention the structural representation of the system that browser data is synchronous;
Fig. 2 is for realizing in accordance with another embodiment of the present invention the structural representation of the system that browser data is synchronous;
Fig. 3 is the schematic diagram of the process that browser client and socket server connect in the synchronous system of realization browser data shown in Figure 2;
Fig. 4 is the schematic diagram that carries out the process of information pushing in the synchronous system of realization browser data shown in Figure 2 under first kind scene to the destination client;
Fig. 5 is the schematic diagram that carries out the process of information pushing in the synchronous system of realization browser data shown in Figure 2 under the Equations of The Second Kind scene to the destination client;
Fig. 6 is the schematic diagram that carries out the process of information pushing in the synchronous system of realization browser data shown in Figure 2 under the 3rd class scene to the destination client;
Fig. 7 is the flow chart according to the synchronous method of the realization browser data of the embodiment of the invention;
Fig. 8 is the structural representation according to the synchronous browser client of the realization browser data of the embodiment of the invention;
Fig. 9 is the structural representation according to the socket server of the embodiment of the invention;
Figure 10 is the flow chart according to the sockets services method that is applied to socket server of the embodiment of the invention.
Embodiment
Exemplary embodiment of the present disclosure is described below with reference to accompanying drawings in more detail.Although shown exemplary embodiment of the present disclosure in the accompanying drawing, yet should be appreciated that and to realize the disclosure and the embodiment that should do not set forth limits here with various forms.On the contrary, it is in order to understand the disclosure more thoroughly that these embodiment are provided, and can with the scope of the present disclosure complete convey to those skilled in the art.
In one exemplary embodiment of the present invention, provide a kind of system that realizes that browser data is synchronous.As shown in Figure 1, the synchronous system of this realization browser data comprises: cloud storage server end 1, push server 2 and a plurality of browser client 3,4.Wherein, cloud storage server end 1 is used for issuing conditional information and command information to push server when Data Update is arranged; Push server 2 is used for determining the destination client according to conditional information at a plurality of browser clients, and this command information is pushed to destination client 3; Destination client 3 is used for synchronous according to the data of this command information realize target client and cloud storage server end.
In the embodiment shown in fig. 1, by independent push server 2 is set, under news occurs more in the data content of cloud storage server end storage, in time command information is sent to the destination client by push server, thereby has realized simply, efficiently service end information and client real-time synchronization.
As shown in Figure 1, include starting client 4 and destination client 3 in a plurality of browser clients.Wherein, starting client 4 is used for the data that are stored in cloud storage server end 1 are upgraded.This starting client 4 and destination client 3 can belong to same user, also can belong to different users.This starting client 4 is with the main application scenarios of situation that destination client 3 belongs to same user: same user uses different equipment (for example mobile phone and PC) login browser, one of them (for example PC) changes collection, needs so this renewal is synchronized to another equipment (mobile phone) of same user.The application scenarios that this starting client 4 and destination client 3 do not belong to same user's situation for example is the information communication between the different browsers client.
Certainly, the present invention also can be by the renewal of cloud storage server end self initiation to the data content, and in this case, 4 of the initiation browser clients among Fig. 1 can not exist.The scene of this situation for example is: system pushes news messages or weather forecast to all browser clients; Or system initiates to upgrade indication to the browser client of all certain versions.
Because the dotted line frame is existing in the existing browser with interior cloud storage server end 1, destination client 3 and starting client 4 among Fig. 1, therefore adding on this basis push server can effectively utilize original system architecture, reduces and realizes cost of the present invention.
For the connection that realizes that cloud storage server end 1, push server 2 are connected with the destination client, as shown in Figure 2, realize that the synchronous system of browser client and cloud storage server end data can also comprise a plurality of socket servers (socket server), distributor.
According to the present invention, in order to improve the data synchronization efficiency of realizing browser client and cloud storage server end, proposed to be exclusively used in the socket server that sockets services is provided between push server and the cloud storage server end.Socket server is used for setting up socket with a plurality of browser clients and is connected, and when receiving conditional information and command information, from a plurality of browser clients, determine the destination client according to this conditional information, and command information is sent to the destination client.
Described socket server is a kind of virtual server, can be configured realization to the existing server of sockets services that provides, also can be by being that software or the software module with standalone feature realizes.
Distributor is used for after receiving the connection request of client, for it distributes corresponding socket server and connection identifier (CID, and user totem information and connection identifier (CID is stored to the distribution information database.Detailed connection is set up process as shown in Figure 3, comprising:
Step S301, browser client is submitted connection request to distributor, at least comprise user totem information in this connection request, for login user, its user totem information can comprise user name, and for non-login user, its user totem information can comprise user's machine identification.
For login user, this user totem information can be a character string.Wherein, this character string also comprises the information such as login time and checking character except the user name of login user.User's unique sign of user by name number, namely a numeral is used for representing a user.The checking character generates according to user name, can judge whether user totem information is modified by the checking character.
For non-login user, this user totem information can comprise the machine identification of non-login user, and wherein machine identification is the machine unique identification, for client generates by Hash such as subscriber set hardware, system configuration.
In addition, for the screening of follow-up destination client, this connection request can also comprise user's characteristic information, for example: IP address information, browser version information, or the user's characteristic information such as user's classified information.Wherein, browser version number, user's classified information, or the user's characteristic information such as IP address information can be used for follow-up client Select to use.
Step S302, distributor uses preset algorithm to calculate a numerical value based on this user totem information, distributes socket server according to this numerical value for the browser client of submitting connection request to; This numerical value is that the overall situation is unique, i.e. connection identifier (CID; Distributor is sent to the browser client of submitting request to the link information such as the IP address of this socket server, port and connection identifier (CID;
In this step, use default algorithm to calculate above-mentioned numerical value according to the user name of login user.For non-login user, directly adopt the machine identification of non-login user to calculate above-mentioned numerical value, this algorithm can be cyclic redundancy check (CRC) (CRC) 32 algorithms.
Step S303, browser client connects with corresponding socket server according to the IP address of the socket server that receives and port numbers, this connection can be that transmission control protocol (TCP, Transmission Control Protocol) connects.When browser client and socket server connected, this socket server obtained identifying the resource identifier of this socket server and browser client annexation.The connection that the browser client utilization has been set up transmits the connection identifier (CID that it receives to this socket server.
Step S304 after socket server receives connection identifier (CID, verifies this connection identifier (CID to distributor, if be proved to be successful, then keep with browser client between set up be connected, if verify unsuccessfully, then disconnect the connection of having set up.
Step S305, distributor is stored in user totem information (user name of login user or the machine identification of non-login user), user's characteristic information (if any) and connection identifier (CID in the distribution information database, and socket server also is stored in resulting resource identifier in this distribution information database.
Need to prove, chaotic in order to prevent that server end from changing the distribution cause, browser client need to connect re-executing step S301-step S304 after a period of time.
In addition, for each socket server, in the distribution information database, all there is corresponding independent tables of data, to reduce the scale of tables of data, accelerates to push stage, the inquiry velocity of socket server at follow-up.
By increasing distributor and socket server, and the distribution information database is set in distributor, make it possible to user totem information, connection identifier (CID, resource identifier and user's characteristic information etc. are stored in the distribution information database in the stage of connecting, thereby realized the propelling movement of push server to the data content of goal-selling client.
In the information pushing stage: push server is used for conditional information and command information are sent to socket server; Socket server is used for the information that push server pushes is forwarded to corresponding destination client.The following minute three class scenes of detailed information pushing process are elaborated.
(1) initiated by starting client when this real-time synchronization, and starting client and when receiving client and belonging to same user, comprise user totem information in the conditional information.By way of example, as shown in Figure 4, this information pushing process comprises:
Step S401, starting client initiate the data that are stored in the storage of cloud storage server end are upgraded;
In this step, it is one of following that the data of cloud storage server end storage comprise: other possible information of collection information, history information, browser configuration information, note information, login house keeper information, prompting message information, key information etc.
Step S402, cloud storage server end sends conditional information and command information to push server, this conditional information comprises user totem information, the for example user name of login user or not the machine hardware sign of login user, and also comprise the resource identifier of the connection of the socket server that this starting client of sign is corresponding with it in this conditional information;
Step S403, push server by with distributor in same algorithm calculate a numerical value according to user totem information, thereby obtain the socket server into the destination client distribution, this numerical value is that the overall situation is unique, be connection identifier (CID, and conditional information and command information are sent to the socket server that this distributes for the destination client;
Step S404, socket server is according to the distribution information database in the inquiry of the user totem information in the conditional information distributor, determine the resource identifier corresponding with the destination client, wherein got rid of the resource identifier of the connection that identifies the starting client socket server corresponding with it;
Step S405, socket server according to this resource identifier with being connected of this destination client (one or more) in send this command information to this client.
(2) initiated by starting client when this real-time synchronization, and starting client namely comprises user totem information in the conditional information when receiving client and belong to different login user, as shown in Figure 5, this information pushing process comprises:
Step S501, starting client initiate the data that are stored in the storage of cloud storage server end are upgraded;
In this step, it is one of following that the data of cloud storage server end storage comprise: information that collection information, history information, browser configuration information, note information, login house keeper information, prompting message information, key information, news information and/or user generate etc.
Step S502, cloud storage server end sends conditional information and command information to push server, and wherein this conditional information can comprise user totem information, for example user name of login user or not the machine hardware sign of login user;
Step S503, push server by with distributor in same algorithm calculate a numerical value according to user totem information, thereby obtain the socket server into the destination client distribution, this numerical value is that the overall situation is unique, be connection identifier (CID, and conditional information and command information are sent to the socket server that this distributes for the destination client;
Step S504, socket server determine the resource identifier of destination client according to the distribution information database in the inquiry of the user totem information in the conditional information distributor;
Step S505, corresponding socket server be according to this resource identifier, with being connected of destination client (one or more) in send this notification message to this client, so far, the information pushing process finishes.
(3) initiatively initiated by cloud storage server end when this real-time synchronization, and comprise the Feature Selection information of destination client in the conditional information, and do not comprise user totem information, wherein Feature Selection information also can be sky,
In this case, connecting establishment stage, submitted in the connection request to distributor by browser client also to comprise Feature Selection information, it is with corresponding such as the front user's characteristic information of preserving in the distribution information database.
As shown in Figure 6, this information pushing process comprises:
Step S601, cloud storage server end issues in conditional information and the command information to push server, the Feature Selection information (for example version number of certain browser) that comprises the destination client in the conditional information, this command information for example are the instructions of notice customer upgrade;
Step S602, push server is pushed to all socket servers with conditional information and command information;
Step S603, each socket server submit query requests to the distribution information database of distributor respectively, comprise Feature Selection information in this query requests; The distribution information database is according to the user's characteristic information of each browser client in the Feature Selection condition query distribution information database, determine to satisfy the resource identifier of the destination client of this Feature Selection condition, and this resource identifier is back to each socket server of initiating inquiry;
Step S604, each socket server sends command information according to the resource identifier that receives to corresponding client, and so far, the information pushing process finishes.
Based on the synchronous system of the realization browser data of Figure 1 and Figure 2, the present invention provides again a kind of method that realizes that browser data is synchronous.As shown in Figure 7, the synchronous method of this realization browser data comprises:
Step S710, cloud storage server end issues conditional information and command information to push server when Data Update is arranged;
Step S720, push server is determined the destination client according to this conditional information in a plurality of browser clients, and this command information is sent to the destination client;
Step S730, the destination client realizes that according to command information the data of itself and cloud storage server end are synchronous.
Further, also comprise that setting up socket between browser client and the socket server is connected before the step S710, this establishment of connection process just repeats no more as shown in Figure 3 here.
Further, step S710 cloud storage server end issues in the step of conditional information and command information to push server when Data Update is arranged, if comprise the login user user name of destination client or the machine identification of login user not in the conditional information, comprise following two kinds of situations:
Situation one: starting client and reception client belong to same user, this user uses different equipment (for example mobile phone and PC) login browser, one of them (for example PC) changes collection, needs so this renewal is synchronized to another equipment (mobile phone) of same user;
In this situation, starting client is at first initiated being stored in relevant configuration, function or the information of collection or the modification of other information in the cloud storage server end.Then cloud storage server end sends conditional information and command information to push server, this command information comprises content-message and notification message, push server will send to the destination client with this command information according to conditional information by socket server, and wherein starting client has been got rid of in this destination client.Information pushing process in this kind situation also repeats no more as shown in Figure 4 here.
Situation two: starting client and receive client and do not belong to same user, thus realize between the different user information interaction by client.
Specifically, a user's client is sent to cloud storage server end with conditional information and content-message, it is sent to pusher to cloud storage server end with conditional information and related notification message, pusher is sent to the purpose client according to conditional information with notification message, and then the purpose client can be accessed cloud storage server end to obtain content.Information pushing process in this case also repeats no more as shown in Figure 5 here.
In addition, if do not comprise the user totem information of destination client in the conditional information, and can comprise Feature Selection information, then also comprise following situation:
Situation three: cloud storage server end self has Data Update, needs browser client and cloud storage server end to carry out data synchronous, and cloud storage server end initiatively issues conditional information and command information to push server, for example:
1, cloud storage server end initiates to upgrade indication to all browser clients of certain version, so that all browser clients of this version upgrade to redaction, wherein, command information is the notification message that upgrades to redaction, condition is the client of certain version browser, and namely wherein Feature Selection information is the version number of browser client.Then push server comprises the destination client that this command information sends in a plurality of browser clients according to this conditional information: the notification message that push server will upgrade to redaction sends to all browser clients of certain version.
2, cloud storage server end pushes news messages to all browser clients, and its conditional is all browser clients, and namely Feature Selection information is empty, and command information is the content-message that comprises news messages; Then push server comprises the destination client that this command information sends in a plurality of browser clients according to this conditional information: the content-message that push server will comprise news messages sends to all browser clients.Should be appreciated that, transmission also can be notification message.
3, cloud storage server end pushes weather forecast to the browser client of different regions, and its conditional is the browser client in a certain area, and namely Feature Selection information is this IP section corresponding to a certain area, and command information is the content-message that comprises weather forecast; Then push server comprises the destination client that this command information sends in a plurality of browser clients according to this conditional information: the content-message that push server will comprise weather forecast sends to the browser client in a certain area.Should be appreciated that, transmission also can be notification message.
Information pushing process in this case also repeats no more as shown in Figure 6 here.
Based on the synchronous system of the realization browser data of Figure 1 and Figure 2, the present invention provides again a kind of browser client of realizing that browser data is synchronous.As shown in Figure 8, this browser client comprises: link block is used for establishing a connection by distributor and socket server, and receives command information from corresponding socket server; Application module is used for according to this command information, carries out its corresponding application operating.Wherein, described command information is notification message or content-message.
As shown in Figure 8, link block comprises again: distributor connexon module, be used for submitting connection request to described distributor, comprise at least user totem information in this connection request, and receive link information and the connection identifier (CID of the socket server that is assigned with that is returned by distributor; Socket connexon module is used for setting up the socket connection according to link information and the described connection identifier (CID of the socket server that receives with corresponding socket server, and receives command information by this socket connection from corresponding socket server.Wherein, described user totem information is the user name of login user or the machine hardware sign of non-login user.
As shown in Figure 8, can also comprise in the above-mentioned browser client: cloud storing communication module, the application operating for the response application module communicates with cloud storage server end.
As previously mentioned, can play the effect of key during the information pushing of socket server before realizing cloud storage server and destination client.Fig. 9 is the structural representation according to the socket server of the embodiment of the invention.As shown in Figure 9, described socket server all needs to comprise link block usually, and this link block is used for setting up socket with a plurality of browser clients and is connected, and carries out information interaction with the browser client that connects.
As previously mentioned, described link block is used for setting up socket with browser clients and is connected, specifically, when browser client is initiated with being connected of socket server, described link block is accepted this connection, and obtaining the resource identifier of this connection, resource identifier is the identifier that is connected that is used for this browser client of sign and this socket server that the system of socket server generates.
In a kind of embodiment, browser client is submitted connection request to distributor, this connection request comprises user totem information at least, distributor uses preset algorithm to calculate a numerical value by this user totem information, distribute socket server according to this numerical value for the browser client of submitting connection request to, this numerical value is that the overall situation is unique, i.e. connection identifier (CID; Distributor then sends to the browser client of submitting connection request to link information and the connection identifier (CID of socket server, and the browser client of submitting connection request to connects with the link block of corresponding socket server according to the link information of the socket server that receives and connection identifier (CID.
As previously mentioned, in the browser data synchro system distribution information database can be set, according to a kind of embodiment, when system comprised distributor, this distribution information database can be arranged in the distributor.Store user totem information in the distribution information database, set up in the process that socket connects above-mentioned, submit to the browser client of request also can transmit connection identifier (CID to corresponding socket server according to the link information of the socket server that receives.At this moment, socket server also can comprise an authentication module, verifies with the connection identifier (CID that this is received.When verifying, this authentication module is this connection identifier (CID of inquiry in the distribution information database, verifying whether this connection identifier (CID is present in this distribution information database, thereby verify whether this request and this socket server carry out the browser client that socket is connected legal.
When authentication module verified that this connection identifier (CID is present in the described distribution information database, socket server was stored in this resource identifier in the distribution information database.When authentication module verified that this connection identifier (CID is not present in the described distribution information database, the disconnection of authentication module indication link block was connected with this browser client.
As previously mentioned, when push server sends to the socket server that distributes into the destination client with conditional information and command information, socket server according to described conditional information inquiry distribution information database to determine the destination client.When comprising user totem information in the conditional information, socket server is inquired about according to this user totem information.When also preserving resource identifier in the distribution information database, socket server is determined the destination client according to conditional information query resource identifier in the distribution information database.At this moment, socket server also comprises an enquiry module, and this enquiry module is finished above-mentioned query script.Socket server of the present invention adopts the pattern of asynchronous schedule when sending command information to the destination client.That is to say, when socket server has received command information, and determined to adopt asynchronous system to send command information to the destination client after the destination client according to conditional information.So-called asynchronous system refers to, when more than one of destination client, link block sends after command messages one of them client, does not wait for that its confirmation of receipt just directly sends command messages to next client.Thereby this process carries out reaching efficient transmission continuously, and then shortens the time of implementation, the time difference of the message that raising system effectiveness and the different clients that reduces receive, improves professional real-time.
10 pairs of embodiments that are applied to the sockets services method of socket server are specifically described with reference to the accompanying drawings.According to above-mentioned description for socket server as can be known, the sockets services method that is applied in the socket server of the present invention comprises step S1010 at least: when browser client is initiated with being connected of described socket server, socket server is accepted this connection, and obtains the resource identifier of this connection.
According to a kind of embodiment of the present invention, after step S1010, the sockets services method also comprises step S1020: socket server receives the connection identifier (CID that sends from described browser client via described connection, and inquiry distribution information database is to verify whether this connection identifier (CID is present in this distribution information database.After step S1020, preferably, the sockets services method also comprises step S1030: when described connection identifier (CID was present in this distribution information database, socket server deposited described resource identifier in described distribution information database; When described connection identifier (CID was not present in this distribution information database, socket server disconnected described connection.
According to another embodiment of the present invention, the sockets services method also comprises step S1040: when described push server sent to the socket server that distributes into the destination client with conditional information and command information, this socket server was inquired about described distribution information database to determine the destination client according to described conditional information.
Step S1040 is preferably: this socket server is determined the destination client according to conditional information query resource identifier in the distribution information database.
According to another embodiment of the present invention, the sockets services method also comprises: when socket server has received command information and determined the destination client according to conditional information, and during more than one of destination client, this socket server sends after the command messages one of them client, does not wait for that its confirmation of receipt just directly sends command messages to next client.By the explanation of front as can be known, a socket server among the present invention may be connected with a plurality of browser clients simultaneously, and each browser client may be not identical with connection status between the socket server yet.And the specified destination client of different conditional informations also may be different.Therefore, in the sockets services method of the present invention, for each different browser client, according to carrying out different steps in response to the different condition information from push server with command information.
When the above-mentioned socket server with asynchronous schedule mode of specific implementation and sockets services method thereof, can use the javascript language to develop at Linux-CentOS environment NodeJS socket server, and the link block of socket server adopt transmission control protocol (TCP) to be connected transmission with command information with browser client.Than the web socket of common employing http agreement, employing Tcp agreement can reduce the resource consumption of system, improves the traffic handing capacity of system.
For further conserve system resources, the command information that is pushed to browser client 3 by push server 2 is notification message.In this case, browser client also is used for connecting with cloud storage server end behind the notification message that receives the push server propelling movement, download the data content that renewal occurs from cloud storage server end, carry out the synchronous of local data content according to the data content of downloading.Can reduce the transmission data volume by transmitting notification message, reduce system resource and take.
Certainly, the command information that is pushed to the destination client by push server also can be content-message, namely comprise the data content that renewal occurs in this content-message, in this case, the destination client is behind the content-message that receives the push server propelling movement, from this content-message, extract the data content that renewal occurs, carry out the synchronous of local data content according to the data content that extracts.Can directly content-message be pushed to client by transmitting content-message, the information transmission is quick, and step is simple.
In order to realize calling to multilingual support, easily text, adopt the HTTP interface between push server and the cloud storage server end, also can be other suitable interfaces, the present invention does not limit this.
In sum, the synchronous system of this realization browser data provided by the invention, by independent push server is set, under news occurs more in the browser related content of cloud storage server end storage, can be in time command information be sent to destination client in a plurality of browser clients by this push server, solved can't be simply and effectively with the problem of browser client and cloud storage server end data real-time synchronization, thereby the data that realized simply, efficiently browser client and cloud storage server end are synchronous.Thus, can make on the basis of original framework browser client can be efficiently, on one's own initiative, resources conservation ground is information and cloud storage server end real-time synchronization.This system and method can also be realized on the basis of original system framework, effectively utilizes original framework, realizes that cost is effective.
Intrinsic not relevant with any certain computer, virtual system or miscellaneous equipment with demonstration at this algorithm that provides.Various general-purpose systems also can be with using based on the teaching at this.According to top description, it is apparent constructing the desired structure of this type systematic.In addition, the present invention is not also for any certain programmed language.Should be understood that and to utilize various programming languages to realize content of the present invention described here, and the top description that language-specific is done is in order to disclose preferred forms of the present invention.
In the specification that provides herein, a large amount of details have been described.Yet, can understand, embodiments of the invention can be in the situation that there be these details to put into practice.In some instances, be not shown specifically known method, structure and technology, so that not fuzzy understanding of this description.
Similarly, be to be understood that, in order to simplify the disclosure and to help to understand one or more in each inventive aspect, in the description to exemplary embodiment of the present invention, each feature of the present invention is grouped together in single embodiment, figure or the description to it sometimes in the above.Yet the method for the disclosure should be construed to the following intention of reflection: namely the present invention for required protection requires the more feature of feature clearly put down in writing than institute in each claim.Or rather, as following claims reflected, inventive aspect was to be less than all features of the disclosed single embodiment in front.Therefore, follow claims of embodiment and incorporate clearly thus this embodiment into, wherein each claim itself is as independent embodiment of the present invention.
Those skilled in the art are appreciated that and can adaptively change and they are arranged in one or more equipment different from this embodiment the module in the equipment among the embodiment.Can be combined into a module or unit or assembly to the module among the embodiment or unit or assembly, and can be divided into a plurality of submodules or subelement or sub-component to them in addition.In such feature and/or process or unit at least some are mutually repelling, and can adopt any combination to disclosed all features in this specification (comprising claim, summary and the accompanying drawing followed) and so all processes or the unit of disclosed any method or equipment make up.Unless in addition clearly statement, disclosed each feature can be by providing identical, being equal to or the alternative features of similar purpose replaces in this specification (comprising claim, summary and the accompanying drawing followed).
In addition, those skilled in the art can understand, although embodiment more described herein comprise some feature rather than further feature included among other embodiment, the combination of the feature of different embodiment means and is within the scope of the present invention and forms different embodiment.For example, in the following claims, the one of any of embodiment required for protection can be used with compound mode arbitrarily.
All parts embodiment of the present invention can realize with hardware, perhaps realizes with the software module of moving at one or more processor, and perhaps the combination with them realizes.It will be understood by those of skill in the art that and to use in practice microprocessor or digital signal processor (DSP) to realize according to some or all some or repertoire of parts in the relevant device of the embodiment of the invention.The present invention can also be embodied as be used to part or all equipment or the device program (for example, computer program and computer program) of carrying out method as described herein.Such realization program of the present invention can be stored on the computer-readable medium, perhaps can have the form of one or more signal.Such signal can be downloaded from internet website and obtain, and perhaps provides at carrier signal, perhaps provides with any other form.
It should be noted above-described embodiment the present invention will be described rather than limit the invention, and those skilled in the art can design alternative embodiment in the situation of the scope that does not break away from claims.In the claims, any reference symbol between bracket should be configured to limitations on claims.Word " comprises " not to be got rid of existence and is not listed in element or step in the claim.Being positioned at word " " before the element or " one " does not get rid of and has a plurality of such elements.The present invention can realize by means of the hardware that includes some different elements and by means of the computer of suitably programming.In having enumerated the unit claim of some devices, several in these devices can be to come imbody by same hardware branch.The use of word first, second and C grade does not represent any order.Can be title with these word explanations.

Claims (10)

1. system that realizes that browser data is synchronous, this system comprises: cloud storage server end, push server and a plurality of browser client and socket server, wherein:
Described cloud storage server end is used for issuing conditional information and command information to described push server when Data Update is arranged;
Described push server is used for determining the destination client according to this conditional information at described a plurality of browser clients, and described command information is sent to the socket server that is connected with described destination client; And
Described destination client is used for realizing that according to described command information the data of itself and cloud storage server end are synchronous;
Described socket server is used for sending to from the command information of push server corresponding destination client.
2. the system as claimed in claim 1, wherein, described socket server comprises link block, this link block is used for setting up socket with described browser client and is connected, wherein, when described browser client was initiated with being connected of described socket server, described link block was accepted this connection, and obtains the resource identifier of this connection.
3. system as claimed in claim 2, wherein,
Described link block also is used for receiving the connection identifier (CID that sends from described browser client via described connection;
Described socket server also comprises authentication module, and described authentication module is used for: when receiving the connection identifier (CID that sends from described browser client, inquiry distribution information database is to verify whether this connection identifier (CID is present in this distribution information database.
4. system as claimed in claim 3, wherein, described authentication module also is used for:
When described connection identifier (CID is present in this distribution information database, deposit described resource identifier in described distribution information database.
5. system as claimed in claim 3, wherein, described authentication module also is used for:
When described connection identifier (CID is not present in this distribution information database, indicate described link block to disconnect described connection.
6. system as claimed in claim 3, wherein, described socket server also comprises an enquiry module, when described push server sends to the socket server that distributes into the destination client with conditional information and command information, described enquiry module according to described conditional information inquiry distribution information database to determine the destination client.
7. system as claimed in claim 6, wherein, this link block is determined the destination client according to conditional information query resource identifier in the distribution information database.
8. system as claimed in claim 2, wherein, when described socket server has received command information and determined the destination client according to conditional information, and during more than one of destination client, described link block sends after the command messages one of them client, does not wait for that its confirmation of receipt just directly sends command messages to next client.
9. system as claimed in claim 2, wherein, described link block adopts transmission control protocol to be connected transmission with command information with described browser client.
10. such as each described system in the claim 1 to 9, this system also comprises:
Distributor is used for distributing connected socket server to browser client; Described distributor also comprises: the distribution information database is used for storage and distributes relevant information with socket server.
CN201210548764.5A 2012-12-17 2012-12-17 Realize the system that browser data is synchronous Active CN103024049B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210548764.5A CN103024049B (en) 2012-12-17 2012-12-17 Realize the system that browser data is synchronous

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210548764.5A CN103024049B (en) 2012-12-17 2012-12-17 Realize the system that browser data is synchronous

Publications (2)

Publication Number Publication Date
CN103024049A true CN103024049A (en) 2013-04-03
CN103024049B CN103024049B (en) 2016-03-30

Family

ID=47972173

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210548764.5A Active CN103024049B (en) 2012-12-17 2012-12-17 Realize the system that browser data is synchronous

Country Status (1)

Country Link
CN (1) CN103024049B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103389797A (en) * 2013-07-16 2013-11-13 贝壳网际(北京)安全技术有限公司 instruction synchronization method, terminal and system
CN110515575A (en) * 2018-05-21 2019-11-29 北京仁光科技有限公司 Device and method for being interacted to the computer in a subnet
CN110830744A (en) * 2018-08-10 2020-02-21 北京仁光科技有限公司 Safety interaction system
CN110830423A (en) * 2018-08-10 2020-02-21 北京仁光科技有限公司 Secure network data interaction system and method
CN111176863A (en) * 2019-12-31 2020-05-19 浪潮软件股份有限公司 Message reminding system and method based on nodejs

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1620012A (en) * 2003-11-19 2005-05-25 国际商业机器公司 Method and system for updating/reloading the content of pages browsed over a network
CN101247349A (en) * 2008-03-13 2008-08-20 华耀环宇科技(北京)有限公司 Network flux fast distribution method
CN101431516A (en) * 2008-12-04 2009-05-13 成都市华为赛门铁克科技有限公司 Method for implementing distributed security policy, client terminal and communication system thereof
US20100082977A1 (en) * 2008-09-30 2010-04-01 Avaya Inc. SIP Signaling Without Constant Re-Authentication
CN102006322A (en) * 2010-11-18 2011-04-06 广州广联数字家庭产业技术研究院 Method and system for remote meter reading on basis of internet

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1620012A (en) * 2003-11-19 2005-05-25 国际商业机器公司 Method and system for updating/reloading the content of pages browsed over a network
CN101247349A (en) * 2008-03-13 2008-08-20 华耀环宇科技(北京)有限公司 Network flux fast distribution method
US20100082977A1 (en) * 2008-09-30 2010-04-01 Avaya Inc. SIP Signaling Without Constant Re-Authentication
CN101431516A (en) * 2008-12-04 2009-05-13 成都市华为赛门铁克科技有限公司 Method for implementing distributed security policy, client terminal and communication system thereof
CN102006322A (en) * 2010-11-18 2011-04-06 广州广联数字家庭产业技术研究院 Method and system for remote meter reading on basis of internet

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103389797A (en) * 2013-07-16 2013-11-13 贝壳网际(北京)安全技术有限公司 instruction synchronization method, terminal and system
CN103389797B (en) * 2013-07-16 2016-08-31 贝壳网际(北京)安全技术有限公司 instruction synchronization method, terminal and system
CN110515575A (en) * 2018-05-21 2019-11-29 北京仁光科技有限公司 Device and method for being interacted to the computer in a subnet
CN110515575B (en) * 2018-05-21 2021-08-24 北京仁光科技有限公司 Apparatus and method for interacting computers within a subnet
CN110830744A (en) * 2018-08-10 2020-02-21 北京仁光科技有限公司 Safety interaction system
CN110830423A (en) * 2018-08-10 2020-02-21 北京仁光科技有限公司 Secure network data interaction system and method
CN110830744B (en) * 2018-08-10 2021-10-15 北京仁光科技有限公司 Safety interaction system
CN111176863A (en) * 2019-12-31 2020-05-19 浪潮软件股份有限公司 Message reminding system and method based on nodejs
CN111176863B (en) * 2019-12-31 2023-08-11 浪潮软件股份有限公司 Message reminding system and method based on nodejs

Also Published As

Publication number Publication date
CN103024049B (en) 2016-03-30

Similar Documents

Publication Publication Date Title
CN102984278B (en) Realize the system and method that browser data synchronizes
CN103024052A (en) System and method for achieving browser data synchronization
CN109522330B (en) Cloud platform data processing method, device, equipment and medium based on block chain
CN103024050B (en) Distributor and the method that multiple server is distributed
CN101136938B (en) Centralized management method and platform system for mobile internet application
CN101127947B (en) A method, system and device for logging in chat room based on mobile terminal
CN102984277B (en) Prevent the system and method that malice connects
CN112860451A (en) Multi-tenant data processing method and device based on SaaS
CN103765423A (en) Gathering transaction data associated with locally stored data files
CN103024049B (en) Realize the system that browser data is synchronous
CN103841134A (en) API-based method for sending and receiving information, API-based apparatus, and API-based system
CN102347847A (en) Contact state releasing method and system
CN102984276B (en) For the distributor distributed multiple socket server and distribution method
CN102185701A (en) Method and system for realizing group information interaction
CN103024051B (en) A kind of device, method and corresponding system carrying out server distribution
CN103036989A (en) Socket server and socket service method
CN105635222A (en) Cloud terminal upgrading method and system, network management server and proxy server
CN103064899B (en) A kind of distribution information database system
CN103621047A (en) A method to synchronize content across networks
CN105792009A (en) Multi-screen interaction type remote input method, mobile terminal, and intelligent device
CN103036990B (en) A kind of browser client
CN100561921C (en) The system and method for client and server quick exchange data
CN112804291B (en) Remote equipment auditing method, device and system
CN103179565A (en) Safety information interaction system, terminal, server and method based on thin terminal mode
CN112949326B (en) Information query method, device, equipment and computer readable medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right

Effective date of registration: 20220725

Address after: Room 801, 8th floor, No. 104, floors 1-19, building 2, yard 6, Jiuxianqiao Road, Chaoyang District, Beijing 100015

Patentee after: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Address before: 100088 room 112, block D, 28 new street, new street, Xicheng District, Beijing (Desheng Park)

Patentee before: BEIJING QIHOO TECHNOLOGY Co.,Ltd.

Patentee before: Qizhi software (Beijing) Co.,Ltd.

TR01 Transfer of patent right