EFFICIENT STATE RECONCILIATION
First Claim
1. A computer-implemented method for pushing state data to a client, the method comprising:
- receiving a state update at a server;
in response to receiving the state update, altering the state at the server;
hashing the state at the server;
generating a token on the server, wherein the token is the hash of the state;
receiving a token from the client;
determining if the token on the server and the received token from the client differ; and
if the token on the server and the received token from the client differ, pushing state data with the token on the server to the client.
2 Assignments
0 Petitions
Accused Products
Abstract
The embodiments described herein generally relate to methods and systems for using a token as a bi-directional parameter of a long polling request for state updates. A client polls a server for state updates, in which updates may be the result of a server event. Server state data is hashed to generate a token/hash representing the current state data. The server compares this token/hash to the token/hash received from the client in the polling request. If the tokens differ, the server sends the actual state data with the server token to the client. By using tokens as request parameters, unnecessary state updates are avoided, and client/server synchronization is achieved more quickly by restricting the pushing of data to state updates. Further, the client may force a response to a poll by sending an empty or random/default value for the token request parameter.
80 Citations
20 Claims
-
1. A computer-implemented method for pushing state data to a client, the method comprising:
-
receiving a state update at a server; in response to receiving the state update, altering the state at the server; hashing the state at the server; generating a token on the server, wherein the token is the hash of the state; receiving a token from the client; determining if the token on the server and the received token from the client differ; and if the token on the server and the received token from the client differ, pushing state data with the token on the server to the client. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9)
-
-
10. One or more computer storage media storing computer-executable instructions that when executed by a processor perform a method for polling a server for state data, the method comprising:
-
sending, by a client, a first request for the state data at the server, wherein the first request comprises a first token; receiving the state data with a second token; comparing the first token and the second token to determine if the received state data differs from state data stored at the client; and if the first token and the second token differ, updating the state data stored at the client. - View Dependent Claims (11, 12, 13, 14, 15, 16)
-
-
17. A system for pushing state data at a server to a client via a token mechanism, the system comprising:
-
a processor; and memory coupled to the processor, the memory comprising computer program instructions executable by the processor to provide; a management module within the server, wherein the management module is configured to; receive a state update; in response to receiving the state update, alter the state; hash the state; generate a token on the server, wherein the token is the hash of the state; receive a token from the client; determine if the token on the server and the received token from the client differ; and if the token on the server and the received token from the client differ, push state data with the token on the server to the client. - View Dependent Claims (18, 19, 20)
-
Specification