CN103024049B - Realize the system that browser data is synchronous - Google Patents

Realize the system that browser data is synchronous Download PDF

Info

Publication number
CN103024049B
CN103024049B CN201210548764.5A CN201210548764A CN103024049B CN 103024049 B CN103024049 B CN 103024049B CN 201210548764 A CN201210548764 A CN 201210548764A CN 103024049 B CN103024049 B CN 103024049B
Authority
CN
China
Prior art keywords
client
information
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.)
Active
Application number
CN201210548764.5A
Other languages
Chinese (zh)
Other versions
CN103024049A (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

Abstract

The present invention relates to and a kind ofly realize the synchronous system of browser data, this system comprises: cloud storage server end, push server and multiple browser client and socket server, wherein: described cloud storage server end is used for issuing conditional information and command information when there being Data Update to described push server; Described push server is used in described multiple browser client, determining destination client according to this conditional information, and described command information is sent to the socket server be connected with described destination client; And described destination client is for realizing the data syn-chronization of itself and cloud storage server end according to described command information; Described socket server is used for the command information from push server to send to corresponding destination client.The present invention can realize the efficient transmission of synchrodata, shortens the time of implementation, reduces resource consumption, improves system effectiveness, improves the real-time of business.

Description

Realize the system that browser data is synchronous
Technical field
The present invention relates to information technology data field of synchronization, particularly relate to and a kind ofly realize the synchronous system of browser data.
Background technology
At present, along with the development of network technology, the Internet, as huge information resources, becomes the most convenient of people's obtaining information, efficiently approach.At present, user uses personal computer to access internet (Internet) usually, and browser (Browser) accessed web page by installing in personal computer, obtain the information needed.Along with the development of mobile communication technology, user can also by supporting the mobile terminal access internet of browser function, such as mobile phone, personal digital assistant (PersonalDigitalAssistant is called for short PDA).
But, no matter the browser on personal computer or the browser on mobile terminal, generally do not provide Push Service, the information interaction of server end and client depends on the connection that client is initiated, information cannot be sent to client by server end on one's own initiative, thus cannot realize the real-time synchronization of the information between server end and browser client.
In prior art, the most frequently used mode realizing browser client and server-side browser data syn-chronization is that browser client sends request to server end with certain frequency, as once in a week or monthly, if service end has the renewal of relevant information, obtain these information.But applicant finds that this kind of data syn-chronization mode exists following technological deficiency: efficiency comparison is low, take resource real real-time synchronization that is many, that can not accomplish content upgrades.
In addition, in the prior art, connect between server and client and often use socket (socket) to serve, so-called socket is a kind of exchange way of client and server in network, when server and client to connect go forward side by side line number reportedly send time, the client (destination client) by server and needs connect is needed to dock, and socket can be regarded as " docking number " of this docking, only have " dock number " of server and destination client identical, can carry out connecting to transmit data.And sockets services is exactly for server and client side connects the docking service of confession.But, common sockets services adopts isochronous schedules mode when realizing carrying out data-pushing to multiple client, namely, after socket server sends a message to client, wait for that this client carries out receiving and confirming, then to next client push message.Further, general sockets services adopts http agreement, and http consultation takies more system resource, can cause the quick consumption of resource when traffic carrying capacity is large, thus reduces the real-time of data syn-chronization.
Summary of the invention
In view of the above problems, propose the present invention in case provide a kind of overcome the problems referred to above or solve the problem at least in part realize the synchronous system of browser data.
The present invention proposes a kind ofly to realize the synchronous system of browser data, this system comprises: cloud storage server end, push server and multiple browser client and socket server, wherein said cloud storage server end, for issuing conditional information and command information when there being Data Update to described push server; Described push server is used in described multiple browser client, determining destination client according to this conditional information, and described command information is sent to described destination client; And described destination client, for realizing the data syn-chronization of itself and cloud storage server end according to described command information; Described socket server is used for the command information from push server to send to 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 initiates the connection with described socket server, described link block accepts this connection, and obtains the resource identifier of this connection.
According to a kind of embodiment of the present invention, described link block is also for connecting via described the connection identifier (CID receiving and send from described browser client; Described socket server also comprises authentication module, and described authentication module is used for: when receiving the connection identifier (CID sent from described browser client, and 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 for: when described connection identifier (CID is present in this distribution information database, by described resource identifier stored in described distribution information database.
According to a kind of embodiment of the present invention, described authentication module also 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 conditional information and command information to be sent to the socket server distributed into destination client by described push server, described enquiry module according to described conditional information inquiry distribution information database to determine destination client.
According to a kind of embodiment of the present invention, this link block determines destination client according to conditional information query resource identifier in distribution information database.
According to a kind of embodiment of the present invention, have received command information when described socket server and determine destination client according to conditional information, and during more than one of destination client, described link block does not wait for that its confirmation of receipt just sends command messages directly to next client after sending command messages to one of them client.
According to a kind of embodiment of the present invention, described link block adopts transmission control protocol and described browser client to carry out being connected the transmission with command information.
Alternatively, this system also comprises distributor, for distributing connected socket server to browser client; Described distributor also comprises: distribution information database, distributes relevant information for storing to socket server
As can be seen from technique scheme, the present invention has following beneficial effect:
(1) by socket server, distributor and distribution information database, the connection of cloud storage server end, push server and destination client is achieved smoothly;
(2) socket server of the present invention adopts asynchronous schedule mode, thus 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, improve the real-time of business.
(3) the present invention adopts the transmission control protocol agreement (TransmissionControlProtocol) of more bottom when realizing socket server, thus realize the reduction of resource consumption, under limited resources supplIes, improve the traffic handing capacity of system.
Above-mentioned explanation is only the general introduction of technical solution of the present invention, in order to technological means of the present invention can be better understood, and can be implemented according to the content of specification, and can become apparent, below especially exemplified by the specific embodiment of the present invention to allow above and other objects of the present invention, feature and advantage.
Accompanying drawing explanation
By reading hereafter detailed description of the preferred embodiment, various other advantage and benefit will become cheer and bright for those of ordinary skill in the art.Accompanying drawing only for illustrating the object of preferred implementation, and does not think limitation of the present invention.And in whole accompanying drawing, represent identical parts by identical reference symbol.In the accompanying drawings:
Fig. 1 is the structural representation realizing the synchronous system of browser data according to an embodiment of the invention;
Fig. 2 is the structural representation realizing the synchronous system of browser data in accordance with another embodiment of the present invention;
Fig. 3 is for realizing the schematic diagram of the process that browser client and socket server connect in the synchronous system of browser data shown in Fig. 2;
Fig. 4 is for realizing the schematic diagram of the process of carrying out information pushing in the synchronous system of browser data under first kind scene to destination client shown in Fig. 2;
Fig. 5 is for realizing the schematic diagram of the process of carrying out information pushing in the synchronous system of browser data under Equations of The Second Kind scene to destination client shown in Fig. 2;
Fig. 6 is for realizing the schematic diagram of the process of carrying out information pushing in the synchronous system of browser data under the 3rd class scene to destination client shown in Fig. 2;
Fig. 7 is the flow chart realizing the synchronous method of browser data according to the embodiment of the present invention;
Fig. 8 is the structural representation realizing the synchronous browser client of browser data according to the embodiment of the present invention;
Fig. 9 is the structural representation of the socket server according to the embodiment of the present invention;
Figure 10 is the flow chart being applied to the sockets services method of socket server according to the embodiment of the present invention.
Embodiment
Below with reference to accompanying drawings exemplary embodiment of the present disclosure is described in more detail.Although show exemplary embodiment of the present disclosure in accompanying drawing, however should be appreciated that can realize the disclosure in a variety of manners and not should limit by the embodiment set forth here.On the contrary, provide these embodiments to be in order to more thoroughly the disclosure can be understood, and complete for the scope of the present disclosure can be conveyed to those skilled in the art.
In one exemplary embodiment of the present invention, provide and a kind ofly realize the synchronous system of browser data.As shown in Figure 1, this system realizing browser data synchronous comprises: cloud storage server end 1, push server 2 and multiple browser client 3,4.Wherein, cloud storage server end 1, for issuing conditional information and command information when there being Data Update to push server; Push server 2, for determining destination client according to conditional information in multiple browser client, and pushes to destination client 3 by this command information; Destination client 3, for the data syn-chronization according to this command information realize target client and cloud storage server end.
In the embodiment shown in fig. 1, by arranging independent push server 2, the data content stored at cloud storage server end occurs more under news, in time command information is sent to destination client by push server, thus achieves service end information and client real-time synchronization simply, efficiently.
As shown in Figure 1, starting client 4 and destination client 3 is included in multiple browser client.Wherein, starting client 4, for upgrading the data be stored in cloud storage server end 1.This starting client 4 and destination client 3 can belong to same user, also can belong to different users.The application scenarios that this starting client 4 and destination client 3 belong to the situation of same user main is: same user uses different equipment (such as mobile phone and PC) to log in browser, one of them (such as PC) changes collection, so needs another equipment (mobile phone) this renewal being synchronized to same user.The application scenarios that this starting client 4 and destination client 3 do not belong to the situation of same user is such as the information communication between different browsers client.
Certainly, the present invention also can by the renewal of cloud storage server end self initiation to data content, and in this case, the initiation browser client in Fig. 14 can not exist.The scene of this situation is such as: system pushes news messages or weather forecast to all browser clients; Or system is initiated to upgrade instruction to the browser client of certain versions all.
Because the cloud storage server end 1 within dotted line frame in Fig. 1, destination client 3 and starting client 4 are existing in existing browser, therefore add push server on this basis and can effectively utilize original system architecture, reduce and realize cost of the present invention.
In order to realize the connection of cloud storage server end 1, push server 2 and destination client 3, as shown in Figure 2, realize the browser client system synchronous with cloud storage server end data and can also comprise multiple socket server (socketserver), distributor.
According to the present invention, in order to improve the data synchronization efficiency realizing browser client and cloud storage server end, proposing between push server and cloud storage server end and being exclusively used in the socket server that sockets services is provided.Socket server is used for setting up socket with multiple browser client and is connected, and when receiving conditional information and command information, from multiple browser client, determine destination client according to this conditional information, and command information is sent to 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 by being have the software of standalone feature or software module realizes.
Distributor, for after receiving the connection request of client, for it distributes corresponding socket server and connection identifier (CID, and is stored to distribution information database by user totem information and connection identifier (CID.Detailed connection establishment process as shown in Figure 3, comprising:
Step S301, browser client submits connection request to distributor, at least user totem information is comprised in this connection request, for login user, its user totem information can comprise user name, and for A non logged-on user, its user totem information can comprise the machine identification of user.
For login user, this user totem information can be a character string.Wherein, this character string, except the user name of login user, also comprises the information such as login time and checking character.User is called user's uniquely number of sign, i.e. a numeral, for representing a user.Checking character generates according to user name, namely judges whether user totem information is modified by authenticator symbol.
For A non logged-on user, this user totem information can comprise the machine identification of A non logged-on user, and wherein machine identification is machine unique identification, for client is generated by Hash such as subscriber set hardware, system configuration.
In addition, in order to the screening of follow-up destination client, this connection request can also comprise user's characteristic information, such as: IP address information, browser version information, or the user's characteristic information such as users classification information.Wherein, browser version number, users classification information, or the user's characteristic information such as IP address information may be used for follow-up client Select to use.
Step S302, distributor uses preset algorithm to carry out calculating a numerical value based on this user totem information, is submit to the browser client of connection request to distribute socket server according to this numerical value; This numerical value is that the overall situation is unique, i.e. connection identifier (CID; The link information such as IP address, port of this socket server and connection identifier (CID are sent to the browser client submitting request to by distributor;
In this step, default algorithm is used to calculate above-mentioned numerical value according to the user name of login user.For A non logged-on user, directly adopt the machine identification of A non logged-on user to calculate above-mentioned numerical value, this algorithm can be cyclic redundancy check (CRC) (CRC) 32 algorithm.
Step S303, browser client connects with corresponding socket server according to the IP address of the socket server received and port numbers, this connection can be that transmission control protocol (TCP, TransmissionControlProtocol) connects.When browser client and socket server connect, this socket server obtains the resource identifier identifying this socket server and browser client annexation.Browser client utilizes the connection of having set up to transmit its connection identifier (CID received to this socket server.
Step S304, after socket server receives connection identifier (CID, verifies to distributor this connection identifier (CID, if be proved to be successful, then keep the connection of setting up between browser client, if verify unsuccessful, then disconnects the connection of having set up.
Step S305, user totem information (user name of login user or the machine identification of A non logged-on user), user's characteristic information (if any) and connection identifier (CID are stored in distribution information database by distributor, and obtained resource identifier is also stored in this distribution information database by socket server.
It should be noted that, changing the distribution that causes chaotic in order to prevent server end, browser client needs to connect re-executing step S301-step S304 after a period of time.
In addition, for each socket server, in distribution information database, all there is corresponding independent tables of data, to reduce the scale of tables of data, accelerate to push the stage, the inquiry velocity of socket server at follow-up.
By increasing distributor and socket server, and distribution information database is set in distributor, make it possible in the stage of connecting, user totem information, connection identifier (CID, resource identifier and user's characteristic information etc. are stored in distribution information database, thus achieve the propelling movement of push server to the data content of goal-selling client.
In the information pushing stage: push server, for conditional information and command information are sent to socket server; Socket server, the information for push server being pushed is forwarded to corresponding destination client.Point three class scenes below detailed information pushing process are described in detail.
(1) when this real-time synchronization is initiated by starting client, and when starting client and reception client belong to same user, conditional information comprises user totem information.For example, as shown in Figure 4, this information pushing process comprises:
Step S401, the data that starting client is initiated being stored in the storage of cloud storage server end upgrade;
In this step, the data that cloud storage server end stores comprise one of following: collection information, history information, browser configuration information, note information, log in other possible information of house keeper's 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 user name of such as login user or the machine hardware mark of non-login user, and in this conditional information, also comprise the resource identifier of the connection of this starting client of mark socket server corresponding with it;
Step S403, push server calculates a numerical value by the algorithm same with distributor according to user totem information, thus the socket server obtained as destination client distribution, this numerical value is that the overall situation is unique, i.e. connection identifier (CID, and conditional information and command information are sent to this to be the socket server that destination client is distributed;
Step S404, socket server is according to the distribution information database in the user totem information inquiry distributor in conditional information, determine the resource identifier corresponding with destination client, wherein eliminate the resource identifier of the connection of the mark starting client socket server corresponding with it;
Step S405, socket server according to this resource identifier with the connection of this destination client (one or more) in send this command information to this client.
(2) when this real-time synchronization is initiated by starting client, and when starting client and reception client belong to different login user, namely conditional information comprises user totem information, and as shown in Figure 5, this information pushing process comprises:
Step S501, the data that starting client is initiated being stored in the storage of cloud storage server end upgrade;
In this step, the data that cloud storage server end stores comprise one of following: collection information, history information, browser configuration information, note information, log in information that house keeper's 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, the user name of such as login user or the machine hardware mark of non-login user;
Step S503, push server calculates a numerical value by the algorithm same with distributor according to user totem information, thus the socket server obtained as destination client distribution, this numerical value is that the overall situation is unique, i.e. connection identifier (CID, and conditional information and command information are sent to this to be the socket server that destination client is distributed;
Step S504, socket server, according to the distribution information database in the user totem information inquiry distributor in conditional information, determines the resource identifier of destination client;
Step S505, corresponding socket server according to this resource identifier, with the connection of destination client (one or more) in send this notification message to this client, so far, information pushing process terminates.
(3) when this real-time synchronization is initiatively initiated by cloud storage server end, and conditional information comprises the Feature Selection information of destination client, and does not comprise user totem information, and wherein Feature Selection information also can be empty,
In this case, in the connection establishment stage, to be submitted in connection request also comprise Feature Selection information by browser client to distributor, it is with such as front to distribute the user's characteristic information of preserving in information database corresponding.
As shown in Figure 6, this information pushing process comprises:
Step S601, cloud storage server end issues in conditional information and command information to push server, comprise the Feature Selection information (version number of such as certain browser) of destination client in conditional information, this command information is such as the instruction of notice customer upgrade;
Step S602, conditional information and command information are pushed to all socket servers by push server;
Step S603, each socket server submits inquiry request respectively to the distribution information database of distributor, comprises Feature Selection information in this inquiry request; Distribution information database is according to the user's characteristic information of each browser client in Feature Selection condition query distribution information database, determine the resource identifier of the destination client meeting 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 received to corresponding client, and so far, information pushing process terminates.
Based on realizing the synchronous system of browser data shown in Fig. 1 and Fig. 2, invention further provides and a kind ofly realize the synchronous method of browser data.As shown in Figure 7, this method realizing browser data synchronous comprises:
Step S710, cloud storage server end issues conditional information and command information when there being Data Update to push server;
Step S720, push server determines destination client according to this conditional information in multiple browser client, and this command information is sent to destination client;
Step S730, destination client realizes the data syn-chronization of itself and cloud storage server end according to command information.
Further, also comprise before step S710 and set up socket between browser client with socket server and be connected, this establishment of connection process as shown in Figure 3, just repeats no more here.
Further, step S710 cloud storage server end issues to push server when there being Data Update in the step of conditional information and command information, if comprise the login user user name of destination client or the machine identification of non-login user in conditional information, comprise following two kinds of situations:
Situation one: starting client and reception client belong to same user, this user uses different equipment (such as mobile phone and PC) to log in browser, one of them (such as PC) changes collection, so needs another equipment (mobile phone) this renewal being synchronized to same user;
In this situation, first starting client initiates the relevant configuration be stored in cloud storage server end, function or the information of collection or the amendment of other information.Then cloud storage server end sends conditional information and command information to push server, this command information comprises content-message and notification message, this command information will be sent to destination client according to conditional information by socket server by push server, and wherein this destination client eliminates starting client.Information pushing process in this kind of situation as shown in Figure 4, also repeats no more here.
Situation two: starting client and reception client do not belong to same user, thus realize the information interaction by client between different user.
Specifically, conditional information and content-message are sent to cloud storage server end by the client of a user, by conditional information and related notification message, it is sent to pusher to cloud storage server end, notification message is sent to object client according to conditional information by pusher, and then object client can access cloud storage server end to obtain content.Information pushing process in this case as shown in Figure 5, also repeats no more here.
In addition, if do not comprise the user totem information of destination client in conditional information, and Feature Selection information can be comprised, 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 syn-chronization, and cloud storage server end initiatively issues conditional information and command information to push server, such as:
1, cloud storage server end initiates to upgrade instruction to all browser clients of certain version, redaction is upgraded to make all browser clients of this version, wherein, command information is the notification message upgrading to redaction, condition is the client of certain version browser, and namely Feature Selection information is wherein the version number of browser client.Then this command information sends to the destination client in multiple browser client to comprise according to this conditional information by push server: the notification message upgrading to redaction is sent to all browser clients of certain version by push server.
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 comprising news messages; Then this command information sends to the destination client in multiple browser client to comprise according to this conditional information by push server: the content-message comprising news messages is sent to all browser clients by push server.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 the IP section of this certain area correspondence, and command information is the content-message comprising weather forecast; Then this command information sends to the destination client in multiple browser client to comprise according to this conditional information by push server: the content-message comprising weather forecast is sent to the browser client in a certain area by push server.Should be appreciated that, transmission also can be notification message.
Information pushing process in this case as shown in Figure 6, also repeats no more here.
Based on realizing the synchronous system of browser data shown in Fig. 1 and Fig. 2, invention further provides and a kind ofly realize the synchronous browser client of browser data.As shown in Figure 8, this browser client comprises: link block, for being established a connection by distributor and socket server, and receives command information from corresponding socket server; Application module, for according to this command information, performs the application operating of its correspondence.Wherein, described command information is notification message or content-message.
As shown in Figure 8, link block comprises again: distributor connexon module, for submitting connection request to described distributor, in this connection request, at least comprise user totem information, and receive link information and the connection identifier (CID of the socket server be assigned with returned by distributor; Socket connexon module, connects for setting up socket according to the link information of socket server received and described connection identifier (CID with corresponding socket server, and passes through the connection of this socket from corresponding socket server reception command information.Wherein, described user totem information is the user name of login user or the machine hardware mark of A non logged-on user.
As shown in Figure 8, can also comprise in above-mentioned browser client: cloud storing communication module, for the application operating of response application module, communicate with cloud storage server end.
As previously mentioned, socket server can play crucial effect when realizing the information pushing before cloud storage server and destination client.Fig. 9 is the structural representation of the socket server according to the embodiment of the present 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 multiple browser client and is connected, and carries out information interaction with the browser client connected.
As previously mentioned, described link block is used for setting up socket with browser clients and is connected, specifically, when browser client initiates the connection with socket server, described link block accepts this connection, and obtaining the resource identifier of this connection, resource identifier is the identifier of the connection for identifying this browser client and this socket server that the system of socket server generates.
In a kind of embodiment, browser client submits connection request to distributor, this connection request at least comprises user totem information, distributor uses preset algorithm to carry out calculating a numerical value by this user totem information, it is the browser client distribution socket server submitting connection request to according to this numerical value, this numerical value is that the overall situation is unique, i.e. connection identifier (CID; The link information of socket server and connection identifier (CID are then sent to the browser client submitting connection request to by distributor, submit to the browser client of connection request to connect with the link block of corresponding socket server according to the link information of the socket server received and connection identifier (CID.
As previously mentioned, can arrange distribution information database in browser data synchro system, according to a kind of embodiment, when system comprises distributor, this distribution information database can be arranged in distributor.User totem information is stored in distribution information database, set up in the process of socket connection above-mentioned, submit to the browser client of request also can transmit connection identifier (CID according to the link information of the socket server received to corresponding socket server.Now, socket server also can comprise an authentication module, verifies with the connection identifier (CID received this.When verifying, this authentication module inquires about this connection identifier (CID in distribution information database, whether to verify whether this connection identifier (CID is present in this distribution information database, thus it is legal to verify that this request and this socket server carry out the browser client that socket is connected.
When authentication module verifies that this connection identifier (CID is present in described distribution information database, this resource identifier is stored in distribution information database by socket server.When authentication module verifies that this connection identifier (CID is not present in described distribution information database, authentication module instruction link block disconnects the connection with this browser client.
As previously mentioned, when conditional information and command information to be sent to the socket server distributed into destination client by push server, socket server according to described conditional information inquiry distribution information database to determine destination client.When conditional information comprises user totem information, socket server is inquired about according to this user totem information.When also preserving resource identifier in distribution information database, socket server determines destination client according to conditional information query resource identifier in distribution information database.Now, socket server also comprises an enquiry module, and this enquiry module completes above-mentioned query script.Socket server of the present invention adopts the pattern of asynchronous schedule when sending command information to destination client.That is, when socket server have received command information, and after having determined destination client according to conditional information, adopt asynchronous system to send command information to destination client.So-called asynchronous system refers to, when more than one of destination client, link block does not wait for that its confirmation of receipt just sends command messages directly to next client after sending command messages to one of them client.This process is carried out continuously thus is reached efficient transmission, and then shortens the time of implementation, the time difference of the message that raising system effectiveness and minimizing different clients receive, improves the real-time of business.
10 the embodiment of the sockets services method being applied to socket server is specifically described with reference to the accompanying drawings.According to the above-mentioned description for socket server, the sockets services method be applied in socket server of the present invention at least comprises step S1010: when browser client initiates the connection with described socket server, socket server accepts this connection, and obtains the resource identifier of this connection.
According to a kind of embodiment of the present invention, after step S1010, sockets services method also comprises step S1020: socket server connects via described the connection identifier (CID receiving and send from described browser client, and inquiry distribution information database is to verify whether this connection identifier (CID is present in this distribution information database.After step S1020, preferably, sockets services method also comprises step S1030: when described connection identifier (CID is present in this distribution information database, socket server by described resource identifier stored in described distribution information database; When described connection identifier (CID is not present in this distribution information database, socket server disconnects described connection.
According to another embodiment of the present invention, sockets services method also comprises step S1040: when conditional information and command information to be sent to the socket server distributed into destination client by described push server, this socket server inquires about described distribution information database to determine destination client according to described conditional information.
Step S1040 is preferably: this socket server determines destination client according to conditional information query resource identifier in distribution information database.
According to another embodiment of the present invention, sockets services method also comprises: have received command information when socket server and determine destination client according to conditional information, and during more than one of destination client, this socket server does not wait for that its confirmation of receipt just sends command messages directly to next client after sending command messages to one of them client.From explanation above, a socket server in the present invention may be connected with multiple browser client simultaneously, and each browser client and the connection status between socket server also may not be identical.Further, the destination client specified by different conditional informations also may be different.Therefore, in sockets services method of the present invention, for the browser client that each are different, different steps can be performed according in response to from the different condition information of push server and command information.
Specific implementation is above-mentioned there is socket server and the sockets services method thereof of asynchronous schedule mode time, javascript language can be used to develop at Linux-CentOS environment NodeJS socket server, and the link block of socket server adopt transmission control protocol (TCP) to carry out being connected with browser client and the transmission of command information.Compared to the websocket usually adopting http agreement, adopt Tcp agreement can reduce the resource consumption of system, improve the traffic handing capacity of system.
In order to save system resource further, the command information being pushed to browser client 3 by push server 2 is notification message.In this case, browser client, also for after the notification message receiving push server propelling movement, connects with cloud storage server end, download the data content occurring to upgrade from cloud storage server end, carry out the synchronous of local data content according to the data content downloaded.Transmission data volume can be reduced by transmitting notification message, reducing system resource and taking.
Certainly, the command information being pushed to destination client by push server also can be content-message, namely the data content occurring to upgrade is comprised in this content-message, in this case, destination client is after the content-message receiving push server propelling movement, from this content-message, extract the data content occurring to upgrade, carry out the synchronous of local data content according to the data content extracted.Directly content-message can be pushed to client by transmitting content-message, information transmission is quick, and step is simple.
In order to realize multilingual support, call text easily, adopt HTTP interface between push server and cloud storage server end, also can be other suitable interfaces, the present invention limit this.
In sum, provided by the inventionly thisly realize the synchronous system of browser data, by arranging independent push server, the browser related content stored at cloud storage server end occurs more under news, in time command information can be sent to the destination client in multiple browser client by this push server, solve and simply and effectively by the problem of browser client and cloud storage server end data real-time synchronization, thus the data syn-chronization of browser client and cloud storage server end cannot be achieved simply, efficiently.Thus, can make on the basis of original framework browser client can efficiently, on one's own initiative, resources conservation by information and cloud storage server end real-time synchronization.This system and method can also realize on the basis of original system framework, effectively utilizes original framework, realizes cost effective.
Intrinsic not relevant to any certain computer, virtual system or miscellaneous equipment with display at this algorithm provided.Various general-purpose system also can with use based on together with this teaching.According to description above, the structure constructed required by this type systematic is apparent.In addition, the present invention is not also for any certain programmed language.It should be understood that and various programming language can be utilized to realize content of the present invention described here, and the description done language-specific is above to disclose preferred forms of the present invention.
In specification provided herein, describe a large amount of detail.But can understand, embodiments of the invention can be put into practice when not having these details.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 in each inventive aspect one or more, in the description above 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.But, the method for the disclosure should be construed to the following intention of reflection: namely the present invention for required protection requires feature more more than the feature clearly recorded in each claim.Or rather, as claims below reflect, all features of disclosed single embodiment before inventive aspect is to be less than.Therefore, the claims following embodiment are incorporated to this embodiment thus clearly, and wherein each claim itself is as independent embodiment of the present invention.
Those skilled in the art are appreciated that and adaptively can change the module in the equipment in embodiment and they are arranged in one or more equipment different from this embodiment.Module in embodiment or unit or assembly can be combined into a module or unit or assembly, and multiple submodule or subelement or sub-component can be put them in addition.Except at least some in such feature and/or process or unit be mutually repel except, any combination can be adopted to combine all processes of all features disclosed in this specification (comprising adjoint claim, summary and accompanying drawing) and so disclosed any method or equipment or unit.Unless expressly stated otherwise, each feature disclosed in this specification (comprising adjoint claim, summary and accompanying drawing) can by providing identical, alternative features that is equivalent or similar object replaces.
In addition, those skilled in the art can understand, although embodiments more described herein to comprise in other embodiment some included feature instead of further feature, the combination of the feature of different embodiment means and to be within scope of the present invention and to form different embodiments.Such as, in the following claims, the one of any of embodiment required for protection can use with arbitrary compound mode.
All parts embodiment of the present invention with hardware implementing, or can realize with the software module run on one or more processor, or realizes with their combination.It will be understood by those of skill in the art that the some or all functions that microprocessor or digital signal processor (DSP) can be used in practice to realize according to the some or all parts in the relevant device of the embodiment of the present invention.The present invention can also be embodied as part or all equipment for performing method as described herein or device program (such as, computer program and computer program).Realizing program of the present invention and can store on a computer-readable medium like this, or the form of one or more signal can be had.Such signal can be downloaded from internet website and obtain, or provides on carrier signal, or provides with any other form.
The present invention will be described instead of limit the invention to it should be noted above-described embodiment, and those skilled in the art can design alternative embodiment when not departing from the scope of 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 does not arrange element in the claims or step.Word "a" or "an" before being positioned at element is not got rid of and be there is multiple such element.The present invention can by means of including the hardware of some different elements and realizing by means of the computer of suitably programming.In the unit claim listing some devices, several in these devices can be carry out imbody by same hardware branch.Word first, second and third-class use do not represent any order.Can be title by these word explanations.

Claims (8)

1. realize the system that browser data is synchronous, this system comprises: cloud storage server end, distributor, push server and multiple browser client and socket server, wherein:
Described cloud storage server end is used for issuing conditional information and command information when there being Data Update to described push server;
Described push server is used in described multiple browser client, determining destination client according to this conditional information, and described command information is sent to the socket server be connected with described destination client; And
Described destination client is for realizing the data syn-chronization of itself and cloud storage server end according to described command information;
Described distributor, for after receiving the connection request of browser client, for it distributes corresponding socket server and connection identifier (CID; Described distributor also comprises: distribution information database, distributes relevant information for storing to socket server;
Described socket server is used for the command information from push server to send to corresponding destination client; Described socket server comprises link block, and this link block is used for setting up socket with described browser client and is connected; Wherein, described link block is also for connecting via described the connection identifier (CID receiving and send from described browser client; Described socket server also comprises authentication module, and described authentication module is used for: when receiving the connection identifier (CID sent from described browser client, and inquiry distribution information database is to verify whether this connection identifier (CID is present in this distribution information database.
2. the system as claimed in claim 1, wherein, when described browser client initiates the connection with described socket server, described link block accepts this connection, and obtains the resource identifier of this connection.
3. system as claimed in claim 2, wherein, described authentication module also for:
When described connection identifier (CID is present in this distribution information database, by described resource identifier stored in described distribution information database.
4. the system as claimed in claim 1, wherein, described authentication module also for:
When described connection identifier (CID is not present in this distribution information database, described link block is indicated to disconnect described connection.
5. the system as claimed in claim 1, wherein, described socket server also comprises an enquiry module, when conditional information and command information to be sent to the socket server distributed into destination client by described push server, described enquiry module according to described conditional information inquiry distribution information database to determine destination client.
6. system as claimed in claim 5, wherein, this link block determines destination client according to conditional information query resource identifier in distribution information database.
7. system as claimed in claim 2, wherein, have received command information when described socket server and determine destination client according to conditional information, and during more than one of destination client, described link block does not wait for that its confirmation of receipt just sends command messages directly to next client after sending command messages to one of them client.
8. system as claimed in claim 2, wherein, described link block adopts transmission control protocol and described browser client to carry out being connected the transmission with command information.
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 CN103024049A (en) 2013-04-03
CN103024049B true 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)

Families Citing this family (5)

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

Citations (2)

* 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

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8689301B2 (en) * 2008-09-30 2014-04-01 Avaya Inc. SIP signaling without constant re-authentication
CN101431516B (en) * 2008-12-04 2012-04-25 成都市华为赛门铁克科技有限公司 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

Patent Citations (2)

* 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

Also Published As

Publication number Publication date
CN103024049A (en) 2013-04-03

Similar Documents

Publication Publication Date Title
CN102984278B (en) Realize the system and method that browser data synchronizes
CN103024052B (en) Realize the system and method that browser data synchronizes
CN103024050B (en) Distributor and the method that multiple server is distributed
CN102984277B (en) Prevent the system and method that malice connects
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
CN103024049B (en) Realize the system that browser data is synchronous
CN103973461A (en) Notification message pushing method and message server
CN102075539B (en) Data delivery system and method
US7526300B2 (en) Short message management system using a VM application and a mobile communication terminal
CN103765423A (en) Gathering transaction data associated with locally stored data files
CN104333599A (en) Application sharing method and system and application service platform
US9258377B2 (en) Publish information on website
CN103841134A (en) API-based method for sending and receiving information, API-based apparatus, and API-based system
CN102984276B (en) For the distributor distributed multiple socket server and distribution method
CN103024051B (en) A kind of device, method and corresponding system carrying out server distribution
CN102185701A (en) Method and system for realizing group information interaction
CN103036989B (en) Socket server and sockets services method
CN101588359B (en) Software on-demand update method based on network and system thereof
CN104158899A (en) Mobile terminal information pushing method, device and system based on service-oriented architecture (SOA)
CN103064899B (en) A kind of distribution information database system
CN103621047A (en) A method to synchronize content across networks
CN111611308A (en) Information processing method, device and system
CN102685724A (en) Method, terminal and system for customizing content
CN112804291B (en) Remote equipment auditing method, device and system

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