CN106202176A - A kind of method and system realizing website version heat upgrading - Google Patents
A kind of method and system realizing website version heat upgrading Download PDFInfo
- Publication number
- CN106202176A CN106202176A CN201610478499.6A CN201610478499A CN106202176A CN 106202176 A CN106202176 A CN 106202176A CN 201610478499 A CN201610478499 A CN 201610478499A CN 106202176 A CN106202176 A CN 106202176A
- Authority
- CN
- China
- Prior art keywords
- state table
- website
- server
- client
- function
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/90—Details of database functions independent of the retrieved data types
- G06F16/95—Retrieval from the web
- G06F16/958—Organisation or management of web site content, e.g. publishing, maintaining pages or automatic linking
- G06F16/986—Document structures and storage, e.g. HTML extensions
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44568—Immediately runnable code
- G06F9/44573—Execute-in-place [XIP]
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Data Mining & Analysis (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The invention discloses a kind of method and system realizing website version heat upgrading, the method includes: when S1 website loads first, front end or rear end create client-cache, all functions of website are reached an agreement on into the functional status table of consolidation form by front-end and back-end, functional status table is sent to front end by server, and is stored in client-cache as local state table;S2 client initiates heart beating at interval of certain time to server, the server state table of acquisition request server;Server state table is contrasted by S3 client with local state table, it is judged that local state table is the most consistent with server state table, if unanimously, then returns step S2;If inconsistent, then perform the power function that server state table is corresponding, the corresponding function of website is updated;S4 judges that the function renewal of website is the most successful, if being updated successfully, then updates consistent by this locality state table with server state table, and is saved in client-cache;If not being updated successfully, then return step S2.
Description
Technical field
The present invention relates to webcast website's version updating field, be specifically related to a kind of method realizing the upgrading of website version heat and
System.
Background technology
The purpose of Web caching function is to improve web site performance, alleviates and frequently accesses data and bring to data base
Pressure.Client-cache is broadly divided into three aspects, respectively cookie, static resource and session, and cookie refers to some website
In order to distinguish user identity, carry out session tracking and be stored in the data on user local terminal, such as user's pet name and function
Switch etc., static resource is the file being sent directly to client, such as picture, script and pattern etc., session be safeguard user with
Same user sends the situation of association between different request,
In prior art, there are the following problems: 1, website orientation New function, and website user's not refresh page cannot be seen newly
Function;2, website user's Website login, session is not in the case of i.e. user does not exit, and user have modified individual's letter
Breath, if website user does not refresh website, it is impossible to see the renewal of personal information on website in time;3, some functions of website
Logic need etc. pending by after could perform, if not waiting cache invalidation, website user cannot be it will be seen that up-to-date
Effect.
Summary of the invention
For defect present in prior art, it is an object of the invention to provide and a kind of realize website version heat upgrading
Method and system, efficiently solve local cache and caching resource update slowly or cannot more news, do not refreshing visitor
In the case of the end Website page of family, website completes automatically to upgrade, and reduces server stress.
For reaching object above, the present invention adopts the technical scheme that:
A kind of method realizing website version heat upgrading, comprises the steps:
S1, when website loads first, front end or rear end create client-cache, and front-end and back-end are by all functions of website
Reaching an agreement on into the functional status table of consolidation form, the functional status table of website is sent to front end by server, and is stored in client
As local state table in caching;
S2, client initiates heart beating at interval of certain time to server, the server state table of acquisition request server;
S3, server state table is contrasted by client with local state table, it is judged that local state table and server shape
State table is the most consistent, if unanimously, then returns step S2;If inconsistent, then perform the power function corresponding to server state table,
The corresponding function of website is updated;
S4, it is judged that the function renewal of website is the most successful, if the corresponding function of website is updated successfully, then by this locality state table
Update consistent with server state table, and be saved in client-cache;If the corresponding function of website is not updated successfully, then return
Step S2.
On the basis of technique scheme, described method also includes that forcing to update client by physics version number delays
Deposit.
On the basis of technique scheme, described client-cache includes cookie cache, static resource caching and meeting
Words caching.
On the basis of technique scheme, the interval time of separated in time is 1s.
On the basis of technique scheme, described power function is Update () function, uses Update () function real
The now function renewal to website.
On the basis of technique scheme, server state table and local state table are carried out the step contrasted by client
It is as follows,
Client obtains server state table from server interval time;
Server state table is resolved to object type array by client, and object type array includes the function code name of website and is somebody's turn to do
The version number that function code name is corresponding;
Server state table after client will resolve contrasts with local state table.
On the basis of technique scheme, it is judged that the function renewal of website the most successfully step is as follows:
User end to server initiates Asynchronous Request;
If the request of server customer in response end, then judge the function renewal success of website;
If the request of server non-customer in response end, then judge that the function of website is not updated successfully.
A kind of system of the method realizing website version heat upgrading, including:
Client-cache unit, is used for creating client-cache, and the local state table of storage in client-cache;
Contrast unit, for server state table and the contrast of local state table, it is judged that server state table and local shape
State table is the most consistent;
Updating block, when server state table is inconsistent with local state table, performs corresponding to server state table
Power function, is updated the corresponding function of website, after the corresponding function of website is updated successfully, then by this locality state table with
Server state table updates consistent.
On the basis of technique scheme, also include: physics version number updating block, for strong by physics version number
System updates client-cache.
On the basis of technique scheme, described client-cache includes cookie, static resource and session.
Compared with prior art, it is an advantage of the current invention that:
(1) a kind of method of website version heat upgrading that realizes of the present invention is by the local state table of contrast and server state
Table, if local state table is inconsistent with server state table, then performs function set in advance and the function of website is carried out strategy
Updating, policy update is by developer's sets itself as required in actual exploitation, and technical scheme is suitable for
Process and update local cookie cache, session updates, local updating content of pages, refresh page surface skin or update picture etc., tool
Having usage range wide, in the case of not refreshing the client terminal website page, website completes automatically to upgrade, and reduces server stress,
Promote user experience.
(2) a kind of method realizing website version heat upgrading of the present invention also includes being delayed client by physics version number
Deposit pressure to update, owing to cookie cache and session updates are all variablees, and the file great majority during static resource is cached
Cached by browser or server, when the version number of file does not updates, and the caching of file also will not be updated, and
Use physics version number to force renewal can realize file to update.
Accompanying drawing explanation
Fig. 1 is the method flow diagram of the embodiment of the present invention;
Fig. 2 is the system block diagram of present example.
Detailed description of the invention
Below in conjunction with drawings and Examples, the present invention is described in further detail.
Shown in Figure 1, the embodiment of the present invention provides a kind of method realizing website version heat upgrading, including walking as follows
Rapid:
S1, when website loads first, front end or rear end create client-cache, client-cache include cookie cache,
Static resource caching and session cache.All functions of website are reached an agreement on into the functional status table of consolidation form by front-end and back-end.
The functional status table of website is sent to front end by server, and is stored in the cookie cache of client-cache as local shape
State table, local state table resolves to object type array, and object type array includes that the function code name of website is corresponding with this function code name
Version number.
S2, client initiates heart beating at interval of certain time to server, the server state table of acquisition request server,
In the present embodiment, interlude is 1s, it is also possible to according to actually used situation sets itself;
S3, client obtains server state table from server interval time;Server state table is resolved to by client
Object type array, object type array includes the version number that the function code name of website is corresponding with this function code name;Client will resolve
After server state table contrast with local state table.Judge that local state table is the most consistent with server state table, if
Unanimously, then return step S2, wait that heart beating next time processes;If inconsistent, then perform the function corresponding to server state table
Function, power function is Update () function, power function according to developer under development need sets itself, use
Update () function realizes the function renewal of website.
S4, user end to server is initiated Asynchronous Request, and then is judged that the function renewal of website is the most successful;If server
The request of customer in response end, then judge the function renewal success of website;If the request of server non-customer in response end, then judge net
The function stood is not updated successfully.If the corresponding function of website is not updated successfully, then returns step S2, wait at heart beating next time
Reason;If the corresponding function of website is updated successfully, then this locality state table is updated consistent with server state table, and be saved in client
In the cookie cache of end caching.
The method also includes forcing to update client-cache by physics version number.
Shown in Figure 2, the present embodiment provides a kind of system realizing website version heat upgrading, including:
Client-cache unit, is used for creating client-cache, and the local state table of storage in client-cache;
Contrast unit, for server state table and the contrast of local state table, it is judged that server state table and local shape
State table is the most consistent;
Updating block, when server state table is inconsistent with local state table, performs corresponding to server state table
Power function, is updated the corresponding function of website, after the corresponding function of website is updated successfully, then by this locality state table with
Server state table updates consistent;
Physics version number updating block, for forcing to update client-cache by physics version number.
Client-cache includes cookie, static resource and session.
The present invention is not limited to above-mentioned embodiment, for those skilled in the art, without departing from
On the premise of the principle of the invention, it is also possible to make some improvements and modifications, these improvements and modifications are also considered as the protection of the present invention
Within the scope of.The content not being described in detail in this specification belongs to prior art known to professional and technical personnel in the field.
Claims (10)
1. the method realizing website version heat upgrading, it is characterised in that comprise the steps:
S1, when website loads first, front end or rear end create client-cache, and all functions of website are reached an agreement on by front-end and back-end
Becoming the functional status table of consolidation form, the functional status table of website is sent to front end, and is stored in client-cache by server
Middle as local state table;
S2, client initiates heart beating at interval of certain time to server, the server state table of acquisition request server;
S3, server state table is contrasted by client with local state table, it is judged that local state table and server state table
The most consistent, if unanimously, then return step S2;If inconsistent, then perform the power function corresponding to server state table, to net
The corresponding function stood is updated;
S4, it is judged that the function renewal of website is the most successful, if the corresponding function of website is updated successfully, then by this locality state table and clothes
Business device state table updates consistent, and is saved in client-cache;If the corresponding function of website is not updated successfully, then return step
S2。
A kind of method realizing website version heat upgrading, it is characterised in that: described method also includes
Force to update client-cache by physics version number.
A kind of method realizing website version heat upgrading, it is characterised in that: described client-cache
Including cookie cache, static resource caching and session cache.
A kind of method realizing website version heat upgrading, it is characterised in that: separated in time
Interval time is 1s.
A kind of method realizing website version heat upgrading, it is characterised in that: described power function is
Update () function, uses Update () function to realize the function renewal to website.
A kind of method realizing website version heat upgrading, it is characterised in that: client is by server
The step that state table carries out contrasting with local state table is as follows,
Client obtains server state table from server interval time;
Server state table is resolved to object type array by client, and object type array includes function code name and this function of website
The version number that code name is corresponding;
Server state table after client will resolve contrasts with local state table.
A kind of method realizing website version heat upgrading, it is characterised in that judge the function of website
Update the most successfully step as follows:
User end to server initiates Asynchronous Request;
If the request of server customer in response end, then judge the function renewal success of website;
If the request of server non-customer in response end, then judge that the function of website is not updated successfully.
The system of a kind of method realizing website version heat upgrading, it is characterised in that including:
Client-cache unit, is used for creating client-cache, and the local state table of storage in client-cache;
Contrast unit, for server state table and the contrast of local state table, it is judged that server state table and local state table
The most consistent;
Updating block, when server state table is inconsistent with local state table, performs the function corresponding to server state table
Function, is updated the corresponding function of website, after the corresponding function of website is updated successfully, then by this locality state table and service
Device state table updates consistent.
A kind of system realizing website version heat upgrading, it is characterised in that also include: physical version
This number updating block, for forcing to update client-cache by physics version number.
A kind of system realizing website version heat upgrading, it is characterised in that: described client is delayed
Bag deposit includes cookie, static resource and session.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610478499.6A CN106202176A (en) | 2016-06-27 | 2016-06-27 | A kind of method and system realizing website version heat upgrading |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610478499.6A CN106202176A (en) | 2016-06-27 | 2016-06-27 | A kind of method and system realizing website version heat upgrading |
Publications (1)
Publication Number | Publication Date |
---|---|
CN106202176A true CN106202176A (en) | 2016-12-07 |
Family
ID=57462127
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610478499.6A Pending CN106202176A (en) | 2016-06-27 | 2016-06-27 | A kind of method and system realizing website version heat upgrading |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106202176A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106789249A (en) * | 2016-12-22 | 2017-05-31 | 北京五八信息技术有限公司 | Hot update method, client and server |
CN110442395A (en) * | 2019-07-29 | 2019-11-12 | 微民保险代理有限公司 | Dissemination method, device, front-end server and the back-end server of product configuration data |
CN111061977A (en) * | 2018-09-28 | 2020-04-24 | 北京国双科技有限公司 | Website updating method, device and system |
CN113704518A (en) * | 2021-08-09 | 2021-11-26 | 国电南瑞科技股份有限公司 | Distributed graphic version management system and method suitable for network |
Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101453481A (en) * | 2007-12-07 | 2009-06-10 | 北京闻言科技有限公司 | Method for implementing notification through cache |
CN101997927A (en) * | 2010-11-18 | 2011-03-30 | 厦门市美亚柏科信息股份有限公司 | Method and system for caching data of WEB platform |
CN102158478A (en) * | 2011-01-31 | 2011-08-17 | 北京开心人信息技术有限公司 | Updating method for network advertisement and system thereof |
CN102195971A (en) * | 2011-03-24 | 2011-09-21 | 北京思创银联科技股份有限公司 | Website access control method |
CN102281326A (en) * | 2011-07-14 | 2011-12-14 | 西安和利德软件有限公司 | Data automatically synchronizing and updating method based on WEB server procedures |
CN102880654A (en) * | 2012-08-28 | 2013-01-16 | 深圳Tcl新技术有限公司 | Method for dynamically updating favorites of information terminal browser |
CN103207902A (en) * | 2013-03-27 | 2013-07-17 | 交通银行股份有限公司 | Method and system for updating financial client side data |
CN103379015A (en) * | 2012-04-12 | 2013-10-30 | 阿里巴巴集团控股有限公司 | Website server and IM client data transmission method, apparatus and system |
CN103532920A (en) * | 2012-07-06 | 2014-01-22 | 腾讯科技(深圳)有限公司 | Cookie update method and cookie update system |
CN104881505A (en) * | 2015-06-26 | 2015-09-02 | 成都梦旅程网络科技有限公司 | Rapid web page updating system |
CN105205010A (en) * | 2014-06-03 | 2015-12-30 | 上海联影医疗科技有限公司 | Basic data caching method and device |
-
2016
- 2016-06-27 CN CN201610478499.6A patent/CN106202176A/en active Pending
Patent Citations (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101453481A (en) * | 2007-12-07 | 2009-06-10 | 北京闻言科技有限公司 | Method for implementing notification through cache |
CN101997927A (en) * | 2010-11-18 | 2011-03-30 | 厦门市美亚柏科信息股份有限公司 | Method and system for caching data of WEB platform |
CN102158478A (en) * | 2011-01-31 | 2011-08-17 | 北京开心人信息技术有限公司 | Updating method for network advertisement and system thereof |
CN102195971A (en) * | 2011-03-24 | 2011-09-21 | 北京思创银联科技股份有限公司 | Website access control method |
CN102281326A (en) * | 2011-07-14 | 2011-12-14 | 西安和利德软件有限公司 | Data automatically synchronizing and updating method based on WEB server procedures |
CN103379015A (en) * | 2012-04-12 | 2013-10-30 | 阿里巴巴集团控股有限公司 | Website server and IM client data transmission method, apparatus and system |
CN103532920A (en) * | 2012-07-06 | 2014-01-22 | 腾讯科技(深圳)有限公司 | Cookie update method and cookie update system |
CN102880654A (en) * | 2012-08-28 | 2013-01-16 | 深圳Tcl新技术有限公司 | Method for dynamically updating favorites of information terminal browser |
CN103207902A (en) * | 2013-03-27 | 2013-07-17 | 交通银行股份有限公司 | Method and system for updating financial client side data |
CN105205010A (en) * | 2014-06-03 | 2015-12-30 | 上海联影医疗科技有限公司 | Basic data caching method and device |
CN104881505A (en) * | 2015-06-26 | 2015-09-02 | 成都梦旅程网络科技有限公司 | Rapid web page updating system |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106789249A (en) * | 2016-12-22 | 2017-05-31 | 北京五八信息技术有限公司 | Hot update method, client and server |
CN106789249B (en) * | 2016-12-22 | 2019-12-10 | 北京五八信息技术有限公司 | Hot updating method, client and server |
CN111061977A (en) * | 2018-09-28 | 2020-04-24 | 北京国双科技有限公司 | Website updating method, device and system |
CN110442395A (en) * | 2019-07-29 | 2019-11-12 | 微民保险代理有限公司 | Dissemination method, device, front-end server and the back-end server of product configuration data |
CN113704518A (en) * | 2021-08-09 | 2021-11-26 | 国电南瑞科技股份有限公司 | Distributed graphic version management system and method suitable for network |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106202176A (en) | A kind of method and system realizing website version heat upgrading | |
US11128621B2 (en) | Method and apparatus for accessing website | |
US20190050493A1 (en) | Page processing method and device thereof | |
US20180302492A1 (en) | Key resource prefetching using front-end optimization (FEO) configuration | |
Koashoek et al. | Dynamic documents: Mobile wireless access to the WWW | |
CN103765423B (en) | Gathering transaction data associated with locally stored data files | |
EP2653987B1 (en) | Displaying web pages without downloading static files | |
US8645453B2 (en) | Method and system of processing cookies across domains | |
CN106599239A (en) | Webpage content data acquisition method and server | |
CN109408750A (en) | Page display method, device, computer equipment and storage medium | |
CN105589956B (en) | A kind of method and device of user's portrait | |
US20110087848A1 (en) | Methods and systems for implementing a virtual storage network | |
CN103955495B (en) | The method for down loading and device of page child resource | |
CN106649395A (en) | Webpage updating method and apparatus | |
CN106649543A (en) | Reading progress recording method and device and terminal | |
CN111917833B (en) | Application method, device and system of client program in cloud environment | |
CA2996710C (en) | Systems and methods for prefetching dynamic urls | |
CN110166529A (en) | It keeps logging in state method, apparatus, equipment and storage medium | |
CN109582890A (en) | Page loading method, device, computer equipment and storage medium | |
CN104679824A (en) | Webpage generating method and webpage generating system of network platform | |
CN106446640B (en) | User knows method for distinguishing and server | |
CN104615597B (en) | The methods, devices and systems of cache file are removed in browser | |
CN105279034A (en) | Consistency cache control system and method | |
CN103051696A (en) | Cloud computation-based user registration service method and cloud computation-based user registration service system | |
CN101917461A (en) | Interface simulation system of mobile terminal and method |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination |