Movatterモバイル変換


[0]ホーム

URL:


CN107168963A - The page loading of client and caching method, system and the client of the page - Google Patents

The page loading of client and caching method, system and the client of the page
Download PDF

Info

Publication number
CN107168963A
CN107168963ACN201610127393.1ACN201610127393ACN107168963ACN 107168963 ACN107168963 ACN 107168963ACN 201610127393 ACN201610127393 ACN 201610127393ACN 107168963 ACN107168963 ACN 107168963A
Authority
CN
China
Prior art keywords
page
request message
caching
page data
client
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
Application number
CN201610127393.1A
Other languages
Chinese (zh)
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.)
Advanced New Technologies Co Ltd
Advantageous New Technologies Co Ltd
Original Assignee
Alibaba Group Holding 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 Alibaba Group Holding LtdfiledCriticalAlibaba Group Holding Ltd
Priority to CN201610127393.1ApriorityCriticalpatent/CN107168963A/en
Publication of CN107168963ApublicationCriticalpatent/CN107168963A/en
Pendinglegal-statusCriticalCurrent

Links

Classifications

Landscapes

Abstract

This application discloses a kind of loading of the page of client and page data caching method, system and client.Wherein, the page loading method of client includes:Obtain page request message;Query key is generated according to page request message;Caching query is carried out according to query key and judges whether caching page data corresponding with page request message;If it is determined that in the presence of caching page data corresponding with page request message, then loading caches page data;If it is determined that in the absence of caching page data corresponding with page request message, then sending page request message to server, and load the corresponding page data obtained from server.The embodiment of the present application can carry out effective management by query key to the caching page data being locally stored, and optimize the loading velocity of the page, reduce the consumption of flow.

Description

The page loading of client and caching method, system and the client of the page
Technical field
The application is related to Internet technical field, more particularly to the page loading method of client a kind of, system, client andCaching method, system and the client of the page.
Background technology
Generally, client (such as computer or mobile phone) and server in terms of data interaction in the way of Asynchronous Request based on,I.e. client is ready to show the page accordingly for the loading of data, such as the progress bar display effect for preparing a loading,It is rear to server send HTTP/HTTPS request, and then server response and back page data after, according to returnPage data complete the page is rendered.
In order to accelerate the speed of client loading page, and flow is saved, client can enter the page data that server is returnedRow caching so that client is direct by caching page data loading when loading again, without being obtained again from serverTake.But management of the client to caching page data deficiency effectively at present, it is impossible to effectively utilize and cache page data.
The content of the invention
The purpose of the application is intended at least solve one of above-mentioned technical problem to a certain extent.
Therefore, first purpose of the application is the page loading method for proposing a kind of client, this method passes through to localThe caching page data of storage is effectively managed, and optimizes the loading velocity of the page, reduces the consumption of flow.
Second purpose of the application is the page loading system for proposing a kind of client.
The 3rd purpose of the application is to propose a kind of client.
The 4th purpose of the application is to propose a kind of caching method of page data.
The 5th purpose of the application is to propose a kind of caching system of page data.
The 6th purpose of the application is to propose a kind of client.
For up to above-mentioned purpose, a kind of page loading method of the client proposed according to the application first aspect embodiment, includingFollowing steps:Obtain page request message;Query key is generated according to the page request message;Carried out according to the query keyCaching query judges whether caching page data corresponding with the page request message;If it is determined that in the presence of with the pageThe corresponding caching page data of face solicited message, then load the caching page data;If it is determined that being not present and the pageThe corresponding caching page data of solicited message, then send the page request message, and load from the server to serverThe corresponding page data obtained.
According to the page loading method of the client of the embodiment of the present application, according to page request message generation query key, and according toQuery key carries out caching query to judge whether the caching page data corresponding with page request message, if there is thenLoad the caching page data, if there is no then to server send page request message, and load from server obtainCorresponding page data.This method can accurately determine corresponding caching page data by query key, so as to thisThe caching page data of ground storage is effectively managed, and is optimized the loading velocity of the page, is reduced the consumption of flow.
For up to above-mentioned purpose, a kind of page loading system of the client proposed according to the second aspect embodiment of the application is wrappedClient and server is included, wherein, the client is believed for obtaining page request message, and according to the page requestBreath generation query key, and according to the query key carry out caching query judge whether it is corresponding with the page request messageCaching page data, wherein, when judging to have caching page data corresponding with the page request message, loading is describedPage data is cached, institute is sent to server when judging to be not present caching page data corresponding with the page request messagePage request message is stated, and loads the corresponding page data obtained from the server;The server, for according to instituteState page request message and send the corresponding page data to the client.
According to the page loading system of the client of the embodiment of the present application, according to page request message generation query key, and according toQuery key carries out caching query to judge whether the caching page data corresponding with page request message, if there is thenLoad the caching page data, if there is no then to server send page request message, and load from server obtainCorresponding page data.The system can accurately determine corresponding caching page data by query key, so as to thisThe caching page data of ground storage is effectively managed, and is optimized the loading velocity of the page, is reduced the consumption of flow.
For up to above-mentioned purpose, a kind of client that the application third aspect embodiment is proposed, including:First solicited message is obtainedModule, for obtaining page request message;First generation module, for generating query key according to the page request message;Judge module, delay corresponding with the page request message is judged whether for carrying out caching query according to the query keyDeposit page data;Load-on module, for being loaded when judging and there is caching page data corresponding with the page request messageThe caching page data, and when judging to be not present caching page data corresponding with the page request message, to clothesBusiness device sends the page request message, and loads the corresponding page data obtained from the server.
According to the client of the embodiment of the present application, query key is generated according to page request message, and cached according to query keyInquiry is to judge whether the caching page data corresponding with page request message, if there is then loading the caching pageData, if there is no then to server send page request message, and load from server obtain corresponding page data.The client can accurately determine corresponding caching page data by query key, so as to the caching page being locally storedFace data are effectively managed, and optimize the loading velocity of the page, reduce the consumption of flow.
For up to above-mentioned purpose, a kind of caching method for page data that the application fourth aspect embodiment is proposed, including:ObtainPage request message;The page request message is sent to server, and corresponding page data is obtained from the server;Query key is generated according to the page request message;The page data is cached, while recording corresponding query key.
According to the caching method of the page data of the embodiment of the present application, send the page request message got to server and obtainPage data is taken, and query key is generated according to page request message, and then page data is cached, while recording correspondenceQuery key.This method is easy to accurately determine by query key by recording the query key corresponding with caching page dataCorresponding caching page data, and then be easy to effectively manage the caching page data being locally stored.
For a kind of caching system of the page data proposed up to above-mentioned purpose, the aspect embodiment of the application the 5th, including clientAnd server, wherein, the client is asked for obtaining page request message, and sending the page to the serverInformation is sought, and page data is received from the server, and query key is generated according to the page request message, and willThe page data is cached, while recording corresponding query key;The server, for being believed according to the page requestCease to the client and send the corresponding page data.
A kind of caching system of the page data proposed according to the application, the page request message got is sent to server simultaneouslyPage data is obtained, and query key is generated according to page request message, and then page data is cached, while record pairThe query key answered.The system is easy to true exactly by query key by recording the query key corresponding with caching page dataFixed corresponding caching page data, and then be easy to effectively manage the caching page data being locally stored.
For another client proposed up to above-mentioned purpose, the aspect embodiment of the application the 6th, including the second acquisition module, useIn acquisition page request message;Interactive module, for sending the page request message to server, and from the serverObtain corresponding page data;Second generation module, for generating query key according to the page request message;Cache module,For the page data to be cached, while recording corresponding query key.
According to the client of the embodiment of the present application, send the page request message got to server and obtain page data,And query key is generated according to page request message, and then page data is cached, while recording corresponding query key.ShouldClient is easy to accurately determine corresponding caching by query key by recording the query key corresponding with caching page dataPage data, and then be easy to effectively manage the caching page data being locally stored.
The aspect and advantage that the application is added will be set forth in part in the description, and partly will become bright from the following descriptionIt is aobvious, or recognized by the practice of the application.
Brief description of the drawings
The above-mentioned and/or additional aspect and advantage of the application will be apparent from description of the accompanying drawings below to embodiment is combinedBe readily appreciated that, wherein:
Fig. 1 is the flow chart of the page loading method according to the client of the application one embodiment;
Fig. 2 is the exemplary plot loaded according to the page of the client of one specific embodiment of the application;
Fig. 3 is the flow chart of the page loading method of the client according to one specific embodiment of the application;
Fig. 4 is the structural representation of the page loading system according to the client of the application one embodiment;
Fig. 5 is the structural representation of the client according to the application one embodiment;
Fig. 6 is the structural representation of the client according to one specific embodiment of the application;
Fig. 7 is the structural representation of the client according to the application another specific embodiment;
Fig. 8 is the flow chart of the caching method of the page data according to the application one embodiment;
Fig. 9 is the structural representation of the caching system of the page data according to the application one embodiment;
Figure 10 is the structural representation of the client according to the application another specific embodiment;And
Figure 11 is the structural representation of the client according to the application another specific embodiment.
Embodiment
Embodiments herein is described below in detail, the example of the embodiment is shown in the drawings, wherein identical from beginning to endOr similar label represents same or similar element or the element with same or like function.Retouched below with reference to accompanying drawingThe embodiment stated is exemplary, it is intended to for explaining the application, and it is not intended that limitation to the application.
The page loading method for the client that the application is provided, is managed, i.e. basis and page according to query key to local cacheThe query key for asking corresponding is requested in person to judge either with or without caching page data corresponding thereto, if it is not, sending out to serverGive the page request, it is to avoid repeat to send page request, the waste of caused flow to server;When in the presence of corresponding theretoWhen the caching page data answered, page rendering directly is carried out according to the page cache data, page loading velocity is improved.The application scenarios that the page loading method of the client obtains webpage by browser, application program etc. suitable for user.
Fig. 1 is the flow chart of the page loading method according to the client of the application one embodiment.
As shown in figure 1, the page loading method of the client includes:
S110, obtains page request message.
In embodiments herein, client generates page request message according to the instruction of user, and the network address of such as user is defeatedEnter instruction, or link clicks triggering command etc..Further, after client generation page request message, interceptAnd obtain the page request message.In embodiments herein, client is webpage loading classes application program etc., such as clearLook at device.
S120, query key is generated according to page request message.
In one embodiment of the application, the page request message of client generation includes target interface and required parameter.Client can be easy to the caching page according to query key to caching according to the corresponding query key of page request message generation in the stepFace data are inquired about.Specifically, client can be serialized first to the required parameter in page request message, and to sequenceRequired parameter after rowization carries out signature processing to generate corresponding signature value, and generated according to target interface and signature valueQuery key.
In embodiments herein, the required parameter after serializing can be carried out at signature using existing signature algorithmReason, such as MD5 (Message-digest Algorithm 5, message digest algorithm) etc..It should be noted that the stepPurpose is that, according to page request message one unique query key of generation, the query key is used to identify corresponding caching page numberAccording to the generation method of above-mentioned query key is the specific embodiment of the application, and those skilled in the art can also be according to itThe uniquely generated query key of his mode, these other modes of texturing should be included within the scope of the embodiment of the present application.
Wherein, the process that query key is generated according to page request is illustrated, if required parameter is:
In order to realize in the case of the target interface and required parameter identical that page request is included, to required parameter according to unifiedRule process,, can be according to word in one embodiment of the application to cause obtained result that there is uniformityFemale order is serialized to above-mentioned required parameter, as follows:
Further, string forms are converted into order to generate the required parameter after query key handles above-mentioned serializing, andHandled using MD5 modes to generate signature value, it is specific as follows:
And then, the required parameter for being converted into string forms is carried out after parameter processing using MD5 methods, signature value is obtained such asUnder:
165760baec805842eabedf0c29b6709b
And then can be somebody's turn to do and signature value generation query key according to what is obtained.
It should be noted that the method for the processing that serializes and sign to required parameter above includes but is not limited to upper type,Differ a citing herein.
It is appreciated that the page data obtained from server is cached with embodiments herein, in client, and conductPage data is cached for inquiry.Wherein, there is unique query key in each caching page data, the query key by withThe page request message for obtaining the caching page data is obtained.Therefore, in embodiments herein, you can according to query keyInquiry whether there is corresponding caching page data in the client.
S130, carries out caching query according to query key and judges whether caching page data corresponding with page request message.
As described above, the embodiment of the present application is stored and read and write behaviour based on query key to caching page data in the clientMake.Therefore client is judged in client, it is necessary to inquired about according to query key before page request is sent to serverIn whether there is the caching page data corresponding with current page request.
S140, if it is determined that in the presence of caching page data corresponding with page request message, then loading caches page data.ToolBody, if client inquires corresponding caching page data according to query key in the caching of itself, client is directThe caching page data is loaded, so as to avoid asking the page data to server again, the waste of flow is caused.
In one embodiment of the application, in addition it is also necessary to determine whether whether caching page data is expired.Wherein, Mei GehuanThe timestamp that page data is deposited when having caching, can determine whether expired according to the timestamp.It is ageing higher for someThe page, such as news pages, if the time of caching page data is longer, the page data that should please be look for novelty to server.Therefore in embodiments herein, this method is after judging that caching page data is expired, in addition to further according to the pageSolicited message obtains page type, and according to page type judgement loading caching page data, or please be look for novelty to serverPage data.
S150, if it is determined that in the absence of caching page data corresponding with page request message, then sending the page to serverSolicited message, and load the corresponding page data obtained from server.
In one embodiment of the application, client is if it is determined that in the absence of the caching corresponding with current page solicited messagePage data, then show current page request to ask first, or the former corresponding caching page of the page request messageData are out of date, therefore send the page request message to server to obtain corresponding page data, and load from serverThe corresponding page data obtained.
Further, in one embodiment of the application, page data or locally deposit that client is returned according to serverThe caching page data of storage is rendered to the page.
In order that obtaining those skilled in the art is more apparent from the application, it is existing for example, Fig. 2 is according to the applicationThe exemplary plot of the page loading of the client of one specific embodiment, as shown in Fig. 2 getting the page of user in clientAfter solicited message, query key is generated according to page request message and the local cache (S210) of client is sent to;It is local slowWhether counterfoil has the caching page data corresponding to the query key according to the caching page Data Detection of storage, if then directly returningReturn caching page data and carry out the page and render, that is, perform step S240, if without if by the page request message send toServer end (S220);Server produces page data according to the page request message, and returns to local cache (S230);Local cache according to corresponding page request message generate query key, and according to query key and return page data create orLocal cache is updated, and returns to page data to the client of server transmission and carries out page rendering (S240).
By the page loading method of the client of the embodiment of the present application, according to page request message generation query key, and according toQuery key carries out caching query to judge whether the caching page data corresponding with page request message, if there is thenLoad the caching page data, if there is no then to server send page request message, and load from server obtainCorresponding page data.This method can accurately determine corresponding caching page data by query key, so as to thisThe caching page data of ground storage is effectively managed, and is optimized the loading velocity of the page, is reduced the consumption of flow.
Fig. 3 is the flow chart of the page loading method of the client according to one specific embodiment of the application.As shown in figure 3,On the basis of as shown in Figure 1, the page loading method of the client includes:
S310, obtains page request message.
S320, query key is generated according to page request message.
S330, carries out caching query according to query key and judges whether caching page data corresponding with page request message.
S340, if it is determined that in the presence of caching page data corresponding with page request message, then loading caches page data.
S350, if it is determined that in the absence of caching page data corresponding with page request message, then sending the page to server pleaseInformation is sought, and loads the corresponding page data obtained from server.
S360, the query key of page data is generated according to page request message, and enter page data as caching page dataRow caching, while recording corresponding query key.
In one embodiment of the application, the page request message of client generation includes target interface and required parameter.ToolBody, client can be serialized first to the required parameter in page request message, and to the required parameter after serializingSignature processing is carried out to generate corresponding signature value, and query key is generated according to target interface and signature value.Also, clientThe page data obtained from server is cached with end, and as caching page data for inquiry.Wherein, by page dataWhen caching as caching page data, corresponding query key is recorded, so as to each have in caching page dataUnique query key, the query key is obtained by the page request message with obtaining the caching page data.
It is appreciated that generating the query key of the page data based on page request message, and update or create based on the query keyLocal cache page data is built, and then is easy to inquire about the caching page number whether possessed for the page request according to the query keyAccording to.
By the page loading method of the client of the embodiment of the present application, corresponding query key is generated according to page request, andWhen memory buffers page data, corresponding query key is recorded, it is convenient that corresponding caching is accurately determined by query keyPage data, and then effective management can be carried out to the caching page data being locally stored, the loading velocity of the page is optimized,Reduce the consumption of flow.
In order to realize above-described embodiment, the application also proposed a kind of page loading system of client, and Fig. 4 is according to this ShenPlease one embodiment client page loading system structural representation, as shown in figure 4, the client the page loadingSystem includes:Client 400 and server 500.
Wherein, client 400 is used to obtain page request message, and generates query key, Yi Jigen according to page request messageCaching query, which is carried out, according to query key judges whether caching page data corresponding with page request message, wherein, judgingLoading caching page data during in the presence of caching page data corresponding with page request message, is judging to be not present and page requestInformation it is corresponding caching page data when to server 500 send page request message, and load from server 500 obtainCorresponding page data.
Server 500, for sending corresponding page data to client 400 according to page request message.
Specifically, in embodiments herein, client 400 generates page request message according to the instruction of user, for exampleThe network address input instruction of user, or link clicks triggering command etc..Further, please in the generation page of client 400Ask after message, intercept and obtain the page request message.In embodiments herein, client 400 loads for webpageClass application program etc., such as browser.
Further, client 400 generates query key, in one embodiment of the application, client according to page requestThe page request message of 400 generations includes target interface and required parameter.Client 400 can be according to the page in this stepSolicited message generates corresponding query key and is easy to inquire about the caching page data of caching according to query key.Specifically, it is objectiveFamily end 400 first can be serialized to the required parameter in page request message, and the required parameter after serializing is carried outSignature processing generates query key to generate corresponding signature value, and according to target interface and signature value.
In embodiments herein, the page data obtained from server 500 is cached with client 400, and as slowPage data is deposited for inquiry.Wherein, there is unique query key in each caching page data, the query key passes through with obtainingThe page request message of the caching page data is taken to obtain.Therefore, in embodiments herein, you can looked into according to query keyAsk and whether there is corresponding caching page data in client 400.
Specifically, client 400 carries out caching query according to query key and judges whether delay corresponding with page request messageDeposit page data.As described above, the embodiment of the present application is carried out in client 400 based on query key to caching page dataStorage and read-write operation.Therefore client 400 to server 500 send page request before, it is necessary to be entered according to query keyRow inquiry, judges to whether there is the caching page data corresponding with current page request in client 500.
In one embodiment of the application, if it is determined that in the presence of caching page data corresponding with page request message, then addingCarry caching page data.Specifically, if client 400 inquires corresponding caching according to query key in the caching of itselfPage data, then client 400 is loaded directly into the caching page data, so as to avoid asking the page to server 500 againFace data, cause the waste of flow.
In one embodiment of the application, client 400 also needs to determine whether whether caching page data is expired.ItsIn, each caching page data read has timestamp during caching, can determine whether according to the timestamp expired.For someThe ageing higher page, such as news pages, if the time of caching page data is longer, should be asked to server 500The page data looked for novelty.Therefore in embodiments herein, this method is also wrapped after judging that caching page data is expiredInclude and page type is further obtained according to page request message, and loading caching page data is judged according to page type, orThe page data that please be look for novelty to server 500.
In one embodiment of the application, if it is determined that caching page data corresponding with page request message is not present, thenThe page request message is sent to server 500, and loads the corresponding page data obtained from server 500.Specifically,Client 400 is if it is determined that in the absence of the caching page data corresponding with current page solicited message, then show current pageAsk to ask first, or the former corresponding caching page data of the page request message is out of date, therefore to server500 transmission page request message load the corresponding page obtained from server 500 to obtain corresponding page dataData.
By the page loading system of the client of the embodiment of the present application, according to page request message generation query key, and according toQuery key carries out caching query to judge whether the caching page data corresponding with page request message, if there is thenLoad the caching page data, if there is no then to server send page request message, and load from server obtainCorresponding page data.The system can accurately determine corresponding caching page data by query key, so as to thisThe caching page data of ground storage is effectively managed, and is optimized the loading velocity of the page, is reduced the consumption of flow.
In one embodiment of the application, client 400 is additionally operable to generate looking into for page data according to page request messageKey is ask, and is cached page data as caching page data, while recording corresponding query key.
In one embodiment of the application, the page request message that client 400 is generated includes target interface and required parameter.Specifically, client 400 can be serialized first to the required parameter in page request message, and to asking after serializingAsk parameter to carry out signature processing to generate corresponding signature value, and query key is generated according to target interface and signature value.Also,The page data obtained from server 500 is cached with client 400, and as caching page data for inquiry.Wherein,When page data is cached as caching page data, corresponding query key is recorded, so as to each cache the pageAll there is unique query key, the query key is obtained by the page request message with obtaining the caching page data in data.
It is appreciated that generating the query key of the page data based on page request message, and update or create based on the query keyLocal cache page data is built, and then is easy to inquire about the caching page number whether possessed for the page request according to the query keyAccording to.
By the page loading system of the client of the embodiment of the present application, corresponding query key is generated according to page request, andWhen memory buffers page data, corresponding query key is recorded, it is convenient that corresponding caching is accurately determined by query keyPage data, and then effective management can be carried out to the caching page data being locally stored, the loading velocity of the page is optimized,Reduce the consumption of flow.
In order to realize above-described embodiment, the application also proposed a kind of client, and Fig. 5 is according to the application one embodimentStructural representation, as shown in figure 5, the client includes:First solicited message acquisition module 410, the first generation module 420,Judge module 430 and load-on module 440.
Wherein, the first solicited message acquisition module 410, for obtaining page request message.
In embodiments herein, the first solicited message acquisition module 410 generates page request message according to the instruction of user,The network address input instruction of such as user, or link clicks triggering command etc..Further, obtained in the first solicited messageAfter the generation page request message of module 410, intercept and obtain the page request message.
First generation module 420, for generating query key according to page request message.
In one embodiment of the application, Fig. 6 is the structural representation of the client according to one specific embodiment of the application,As shown in fig. 6, on the basis of as shown in Figure 5, the first generation module 420 is specifically included:Serializing submodule 421,Signature submodule 422 and generation submodule 423.
In one embodiment of the application, the page request message of client generation includes target interface and required parameter.TheOne generation module 420 can be easy to the caching page according to query key to caching according to the corresponding query key of page request message generationFace data are inquired about.Specifically, serializing submodule 421 first can carry out sequence to the required parameter in page request messageChange, the required parameter after the 422 pairs of serializings of signature submodule carries out signature processing to generate corresponding signature value, Jin ErshengQuery key is generated according to target interface and signature value into submodule 423.
In embodiments herein, signature submodule 422 can be using existing signature algorithm to the request after serializingParameter carries out signature processing, such as MD5.
Judge module 430, delay corresponding with page request message is judged whether for carrying out caching query according to query keyDeposit page data.
The page data obtained from server is cached with embodiments herein, in client, and is used as caching page numberAccording to for inquiry.Wherein, there is unique query key in each caching page data, the query key passes through with obtaining the cachingThe page request message of page data is obtained.Therefore, in embodiments herein, judge module 430 can be according to query keyInquiry whether there is corresponding caching page data in the client.
The embodiment of the present application is stored and read-write operation based on query key to caching page data in the client.Therefore clientEnd to server before page request is sent, and judge module 430 needs to be inquired about according to query key, judges in clientIn whether there is the caching page data corresponding with current page request.
Load-on module 440, for when judge module 430 judges to exist caching page data corresponding with page request messageLoading caching page data, and judge in judge module 430 in the absence of caching page data corresponding with page request messageWhen, page request message is sent to server, and load the corresponding page data obtained from server.
Specifically, if judge module 430 inquires corresponding caching page data according to query key in the caching of itself,Then load-on module 440 is loaded directly into the caching page data, so as to avoid asking the page data to server again, causesThe waste of flow.
In one embodiment of the application, judge module 430 is if it is determined that in the absence of corresponding with current page solicited messageCaching page data, then show current page request to ask first, or the former page request message is corresponding slowDeposit page data out of date, therefore load-on module 440 sends the page request message to obtain corresponding page number to serverAccording to, and load the corresponding page data obtained from server.
By the client of the embodiment of the present application, query key is generated according to page request message, and cached according to query keyInquiry is to judge whether the caching page data corresponding with page request message, if there is then loading the caching pageData, if there is no then to server send page request message, and load from server obtain corresponding page data.The client can accurately determine corresponding caching page data by query key, so as to the caching page being locally storedFace data are effectively managed, and optimize the loading velocity of the page, reduce the consumption of flow.
Fig. 7 is the structural representation of the client according to the application another specific embodiment, on the basis of as shown in Figure 5,As shown in fig. 7, the client also includes:Caching record module 450.
Specifically, caching record module 450 is used to generate page data according to page request message in the first generation module 420Query key after, and using page data as caching page data cached, while recording corresponding query key.
In one embodiment of the application, the page request message of client generation includes target interface and required parameter.Caching record module 450 using page data as caching page data cached when, record corresponding query key, fromAnd each caching in page data has unique query key, the query key passes through the page with obtaining the caching page dataSolicited message is obtained.
It is appreciated that the first generation module 420 generates the query key of the page data, caching record based on page request messageModule 450 is based on the query key and updates or create local cache page data, and then is easy to judge module 430 to be looked into according to thisAsk key and inquire about the caching page data whether possessed for the page request.
By the client of the embodiment of the present application, corresponding query key is generated according to page request, and in the memory buffers pageWhen data, corresponding query key is recorded, it is convenient that corresponding caching page data is accurately determined by query key, and thenEffective management can be carried out to the caching page data being locally stored, optimize the loading velocity of the page, reduce flowConsumption.
In the embodiment of the present application, a kind of caching method of page data is also provided, the embodiment of this method is concentrated on according to the pageRequest generation query key side is described.Independently opened it is appreciated that realizing that the function of generating query key according to page request can beOne generation module of hair, or the application program of an individualism is can be, the caching method of the page data is according to the pageRequest generation identifies the query key of its uniqueness, and when page data of the caching corresponding to page request, records simultaneouslyQuery key, for judge exactly either with or without corresponding to current page ask it is data cached.
Fig. 8 is the flow chart of the caching method of the page data according to the application one embodiment, as shown in figure 8, the pageThe caching method of data includes:
S810, obtains page request message.
In embodiments herein, client generates page request message according to the instruction of user, and the network address of such as user is defeatedEnter instruction, or link clicks triggering command etc..Further, after client generation page request message, interceptAnd obtain the page request message.In embodiments herein, client is webpage loading classes application program etc., such as clearLook at device.
S820, sends page request message, and obtain corresponding page data from server to server.
In one embodiment of the application, if current page request is to ask first, or former page request letterThe corresponding caching page data of breath is out of date, then sends the page request message to server to obtain corresponding page data,And the corresponding page data obtained from server.
S830, query key is generated according to page request message.
In one embodiment of the application, page request message includes target interface and required parameter.Client in this stepEnd can generate corresponding query key according to page request message and be easy to look into the caching page data of caching according to query keyAsk.Specifically, client can be serialized first to the required parameter in page request message, and to asking after serializingAsk parameter to carry out signature processing to generate corresponding signature value, and query key is generated according to target interface and signature value.At thisIn the embodiment of application, signature processing can be carried out to the required parameter after serializing using existing signature algorithm, for exampleMD5 etc..
S840, page data is cached, while recording corresponding query key.
The page data obtained from server is cached with embodiments herein, in client, and is used as caching page numberAccording to for inquiry.Wherein, there is unique query key in each caching page data, the query key passes through with obtaining the cachingThe page request message of page data is obtained.
The page data obtained from server is cached with one embodiment of the application, in client, and is used as caching pageFace data are for inquiry.Wherein, when page data is cached as caching page data, corresponding inquiry is recordedKey, so as to each have unique query key in caching page data, the query key passes through with obtaining the caching page dataPage request message obtain.
It is appreciated that client generates the query key of the page data based on page request message, and updated based on the query keyOr local cache page data is created, and then it is easy to whether client possesses for the page request according to query key inquiryCaching page data.
According to the caching method of the page data of the embodiment of the present application, send the page request message got to server and obtainPage data is taken, and query key is generated according to page request message, and then page data is cached, while recording correspondenceQuery key.This method is easy to accurately determine by query key by recording the query key corresponding with caching page dataCorresponding caching page data, and then be easy to effectively manage the caching page data being locally stored.
In order to realize above-described embodiment, the application also proposed a kind of caching system of page data, and Fig. 9 is according to the applicationThe structural representation of the caching system of the page data of one embodiment, as shown in figure 9, the caching system bag of the page dataInclude:Client 1000 and server 2000.
Wherein, client 1000 is used to obtain page request message, and sends page request message to server 2000, withAnd page data is received from server 2000, and query key is generated according to page request message, and page data is delayedDeposit, while recording corresponding query key.
In one embodiment of the application, the page request message that client 1000 is generated includes target interface and required parameter.Client 1000 can be easy to the caching page according to query key to caching according to the corresponding query key of page request message generationData are inquired about.Specifically, client 1000 can be serialized first to the required parameter in page request message, and rightRequired parameter after serializing carries out signature processing to generate corresponding signature value, and given birth to according to target interface and signature valueInto query key.
Server 2000 is used to send corresponding page data to client 1000 according to page request message.
It should be noted that the embodiment of the caching method of the application page data, Ke Yiyong is described in detail in above-mentioned combination Fig. 8In the embodiment of the caching system for execution the application page data.For the embodiment of the caching system of the application page dataIn the details that is not disclosed, refer to the embodiment of the caching method of the application page data, will not be repeated here.
A kind of caching system of the page data proposed by the application, the page request message got is sent to server simultaneouslyPage data is obtained, and query key is generated according to page request message, and then page data is cached, while record pairThe query key answered.The system is easy to true exactly by query key by recording the query key corresponding with caching page dataFixed corresponding caching page data, and then be easy to effectively manage the caching page data being locally stored.
In order to realize above-described embodiment, the application also proposed another client, and Figure 10 is another is specific according to the applicationThe structural representation of the client of embodiment.As shown in Figure 10, the client includes:Second acquisition module 1010, interactionModule 1020, the second generation module 1030 and cache module 1040.
Wherein, the second acquisition module 1010 is used to obtain page request message.
In embodiments herein, client generates page request message according to the instruction of user, and the network address of such as user is defeatedEnter instruction, or link clicks triggering command etc..Further, after client generation page request message, secondAcquisition module 1010 intercepts and obtains the page request message.In embodiments herein, client should for webpage loading classesWith program etc., such as browser.
Interactive module 1020, for sending page request message to server, and obtains corresponding page data from server.
In one embodiment of the application, if current page request is to ask first, or former page request letterThe corresponding caching page data of breath is out of date, and interactive module 1020 then sends the page request message to obtain correspondence to serverPage data, and from server obtain corresponding page data.
Second generation module 1030, for generating query key according to page request message.
In one embodiment of the application, Figure 11 is the structural representation of the client according to the application another specific embodimentFigure, as shown in figure 11, on the basis of as shown in Figure 10, the second generation module 1030 is specifically included:Serialize submodule1031st, signature submodule 1032 and generation submodule 1033.
Specifically, page request message includes target interface and required parameter.Second generation module 1030 can be asked according to the pageAsk information to generate corresponding query key to be easy to inquire about the caching page data of caching according to query key.Specifically, sequenceBeggar's module 1031 can be serialized first to the required parameter in page request message, the 1032 pairs of serializings of signature submoduleRequired parameter afterwards carries out signature processing to generate corresponding signature value, and generation submodule 1033 is according to target interface and signatureValue generation query key., can be using existing signature algorithm to the required parameter after serializing in embodiments hereinSignature processing is carried out, such as MD5.
Cache module 1040, for page data to be cached, while recording corresponding query key.
The page data obtained from server is cached with one embodiment of the application, in client, and is used as caching pageFace data are for inquiry.Wherein, when cache module 1040 is cached page data as caching page data, noteCorresponding query key is recorded, so as to each have unique query key in caching page data, the query key with obtaining by being somebody's turn to doThe page request message for caching page data is obtained.
It is appreciated that the second generation module 1030 generates the query key of the page data, cache module based on page request message1040 based on the query key update or create local cache page data, and then be easy to client according to the query key inquiry beThe no caching page data possessed for the page request.
According to the client of the embodiment of the present application, send the page request message got to server and obtain page data,And query key is generated according to page request message, and then page data is cached, while recording corresponding query key.ShouldClient is easy to accurately determine corresponding caching by query key by recording the query key corresponding with caching page dataPage data, and then be easy to effectively manage the caching page data being locally stored.
In the description of the present application, it is to be understood that term " first ", " second " are only used for describing purpose, and can not manageSolve to indicate or imply relative importance or the implicit quantity for indicating indicated technical characteristic.Thus, define " first ",At least one this feature can be expressed or be implicitly included to the feature of " second ".In the description of the present application, " multiples' " containsJustice is at least two, such as two, three etc., unless otherwise specifically defined.
In the description of this specification, reference term " one embodiment ", " some embodiments ", " example ", " specific example ",Or the description of " some examples " etc. means to combine specific features, structure, material or the feature bag that the embodiment or example are describedIt is contained at least one embodiment of the application or example.In this manual, to the schematic representation of above-mentioned term necessarilyIt is directed to identical embodiment or example.Moreover, specific features, structure, material or the feature of description can be anyCombined in an appropriate manner in individual or multiple embodiments or example.In addition, in the case of not conflicting, the skill of this areaNot be the same as Example or the feature of example and non-be the same as Example or example described in this specification can be combined by art personnelAnd combination.
Any process described otherwise above or method description are construed as in flow chart or herein, and expression includes oneOr more be used for executable instruction the step of realize specific logical function or process code module, fragment or part,And the scope of the preferred embodiment of the application includes other realization, wherein order that is shown or discussing can not be pressed,Including according to involved function by it is basic simultaneously in the way of or in the opposite order, carry out perform function, this should be by the application'sEmbodiment person of ordinary skill in the field is understood.
It should be appreciated that each several part of the application can be realized with hardware, software, firmware or combinations thereof.In above-mentioned realityApply in mode, software that multiple steps or method can be performed in memory and by suitable instruction execution system with storage orFirmware is realized.If, and in another embodiment, can be with well known in the art for example, realized with hardwareAny one of row technology or their combination are realized:With the logic gates for realizing logic function to data-signalDiscrete logic, the application specific integrated circuit with suitable combinational logic gate circuit, programmable gate array (PGA),Field programmable gate array (FPGA) etc..
Those skilled in the art be appreciated that to realize all or part of step that above-described embodiment method is carried is canTo instruct the hardware of correlation to complete by program, described program can be stored in a kind of computer-readable recording medium,The program upon execution, including one or a combination set of the step of embodiment of the method.
In addition, each functional unit in the application each embodiment can be integrated in a processing module or eachIndividual unit is individually physically present, can also two or more units be integrated in a module.Above-mentioned integrated module was bothIt can be realized in the form of hardware, it would however also be possible to employ the form of software function module is realized.If the integrated module withThe form of software function module realize and as independent production marketing or in use, can also be stored in one it is computer-readableTake in storage medium.
Storage medium mentioned above can be read-only storage, disk or CD etc..Although having been shown and described aboveEmbodiments herein, it is to be understood that above-described embodiment is exemplary, it is impossible to be interpreted as the limitation to the application,One of ordinary skill in the art can be changed to above-described embodiment, change, replacing and modification within the scope of application.

Claims (16)

CN201610127393.1A2016-03-072016-03-07The page loading of client and caching method, system and the client of the pagePendingCN107168963A (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201610127393.1ACN107168963A (en)2016-03-072016-03-07The page loading of client and caching method, system and the client of the page

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201610127393.1ACN107168963A (en)2016-03-072016-03-07The page loading of client and caching method, system and the client of the page

Publications (1)

Publication NumberPublication Date
CN107168963Atrue CN107168963A (en)2017-09-15

Family

ID=59849234

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201610127393.1APendingCN107168963A (en)2016-03-072016-03-07The page loading of client and caching method, system and the client of the page

Country Status (1)

CountryLink
CN (1)CN107168963A (en)

Cited By (14)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN108881493A (en)*2018-08-082018-11-23郑州云海信息技术有限公司A kind of Task Progress information-pushing method, device and equipment
CN109299414A (en)*2018-09-262019-02-01深圳壹账通智能科技有限公司 A method and terminal for loading a page
CN109842610A (en)*2018-12-132019-06-04平安科技(深圳)有限公司Interface requests processing method, device, computer equipment and storage medium
CN109885784A (en)*2019-01-172019-06-14平安城市建设科技(深圳)有限公司Screen content loading method, device, equipment and computer readable storage medium
CN110309456A (en)*2018-03-122019-10-08优视科技有限公司A kind of page display method and device
CN110347945A (en)*2018-01-152019-10-18北京京东金融科技控股有限公司The method and apparatus for obtaining the data of the page
CN110765377A (en)*2018-07-272020-02-07北京华通人商用信息有限公司Data loading method and device
CN111273947A (en)*2018-12-052020-06-12国基电子(上海)有限公司Method and electronic device for optimizing user interface waiting time
CN111355766A (en)*2018-12-202020-06-30福建福昕软件开发股份有限公司Method for rendering PDF (Portable document Format) file loaded on network as required
CN112100541A (en)*2020-08-242020-12-18浙江三维万易联科技有限公司Website page element loading method and device, electronic device and storage medium
CN112910973A (en)*2021-01-212021-06-04云账户技术(天津)有限公司Application page selection method and device
CN113486273A (en)*2021-07-092021-10-08上海淇馥信息技术有限公司Front-end information flow page loading method and device and electronic equipment
CN114237784A (en)*2021-11-162022-03-25建信金融科技有限责任公司User interface generation method and device, electronic equipment and storage medium
CN115270023A (en)*2022-07-192022-11-01深圳乐信软件技术有限公司Page data caching method and related equipment thereof

Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN103686684A (en)*2012-09-202014-03-26腾讯科技(深圳)有限公司Offline cache method and device
CN103973695A (en)*2014-05-162014-08-06浪潮电子信息产业股份有限公司Signature algorithm for server validation
CN104753966A (en)*2013-12-252015-07-01明博教育科技有限公司Resource file inquiry method and system based on server and client caches

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN103686684A (en)*2012-09-202014-03-26腾讯科技(深圳)有限公司Offline cache method and device
CN104753966A (en)*2013-12-252015-07-01明博教育科技有限公司Resource file inquiry method and system based on server and client caches
CN103973695A (en)*2014-05-162014-08-06浪潮电子信息产业股份有限公司Signature algorithm for server validation

Cited By (18)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN110347945A (en)*2018-01-152019-10-18北京京东金融科技控股有限公司The method and apparatus for obtaining the data of the page
CN110309456A (en)*2018-03-122019-10-08优视科技有限公司A kind of page display method and device
CN110765377A (en)*2018-07-272020-02-07北京华通人商用信息有限公司Data loading method and device
CN110765377B (en)*2018-07-272023-05-23北京华通人商用信息有限公司 A data loading method and device
CN108881493A (en)*2018-08-082018-11-23郑州云海信息技术有限公司A kind of Task Progress information-pushing method, device and equipment
CN109299414A (en)*2018-09-262019-02-01深圳壹账通智能科技有限公司 A method and terminal for loading a page
CN111273947B (en)*2018-12-052023-06-06富联国基(上海)电子有限公司Method for optimizing waiting time of user interface and electronic device
CN111273947A (en)*2018-12-052020-06-12国基电子(上海)有限公司Method and electronic device for optimizing user interface waiting time
CN109842610B (en)*2018-12-132022-07-26平安科技(深圳)有限公司Interface request processing method and device, computer equipment and storage medium
CN109842610A (en)*2018-12-132019-06-04平安科技(深圳)有限公司Interface requests processing method, device, computer equipment and storage medium
CN111355766A (en)*2018-12-202020-06-30福建福昕软件开发股份有限公司Method for rendering PDF (Portable document Format) file loaded on network as required
CN109885784A (en)*2019-01-172019-06-14平安城市建设科技(深圳)有限公司Screen content loading method, device, equipment and computer readable storage medium
CN112100541A (en)*2020-08-242020-12-18浙江三维万易联科技有限公司Website page element loading method and device, electronic device and storage medium
CN112100541B (en)*2020-08-242024-04-02三维通信股份有限公司Method and device for loading website page element, electronic device and storage medium
CN112910973A (en)*2021-01-212021-06-04云账户技术(天津)有限公司Application page selection method and device
CN113486273A (en)*2021-07-092021-10-08上海淇馥信息技术有限公司Front-end information flow page loading method and device and electronic equipment
CN114237784A (en)*2021-11-162022-03-25建信金融科技有限责任公司User interface generation method and device, electronic equipment and storage medium
CN115270023A (en)*2022-07-192022-11-01深圳乐信软件技术有限公司Page data caching method and related equipment thereof

Similar Documents

PublicationPublication DateTitle
CN107168963A (en)The page loading of client and caching method, system and the client of the page
US20210268389A1 (en)Determining Whether Object is Genuine or Fake in Metaverse
CN112800370B (en)Processing method and device of business document, computer equipment and storage medium
US9448932B2 (en)System for caching data
US9304808B2 (en)Updating a workflow when a user reaches an impasse in the workflow
US10970312B2 (en)Content resonance
US8631394B2 (en)Static resource processing
CN111860864A (en) Vertical federated modeling optimization method, device and readable storage medium
US20090319570A1 (en)Consolidating duplicate item images using an image identifier
CN111177499B (en)Label adding method and device and computer readable storage medium
CN105210352A (en)Fingerprint-based, intelligent, content pre-fetching
US20130086323A1 (en)Efficient cache management in a cluster
US20140122629A1 (en)Information Acquisition Method and Device
CN107197359A (en)Video file caching method and device
CN106817388A (en)The system that virtual machine, host obtain the method, device and access data of data
CN113641697A (en)Crowd generation method and device, electronic equipment and storage medium
CN104461929B (en)Distributed data cache method based on blocker
CN115858972B (en)Page display method and device of application program, storage medium and computer equipment
US20160255174A1 (en)Data file and rule driven synchronous or asynchronous document generation
CN104408178A (en)Device and method for WEB control loading
CN108200127A (en)Data transmission method for uplink, device, server, terminal and storage medium
CN116661657A (en)Message transmission method, apparatus, computer device, storage medium, and computer program product
Melnichuk et al.Web-service. restful architecture
JanneWeb Design and CSS Animation
CN115329864A (en)Method and device for training recommendation model and electronic equipment

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
REGReference to a national code

Ref country code:HK

Ref legal event code:DE

Ref document number:1244079

Country of ref document:HK

TA01Transfer of patent application right

Effective date of registration:20201013

Address after:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant after:Innovative advanced technology Co.,Ltd.

Address before:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant before:Advanced innovation technology Co.,Ltd.

Effective date of registration:20201013

Address after:Cayman Enterprise Centre, 27 Hospital Road, George Town, Grand Cayman Islands

Applicant after:Advanced innovation technology Co.,Ltd.

Address before:A four-storey 847 mailbox in Grand Cayman Capital Building, British Cayman Islands

Applicant before:Alibaba Group Holding Ltd.

TA01Transfer of patent application right
RJ01Rejection of invention patent application after publication

Application publication date:20170915

RJ01Rejection of invention patent application after publication
REGReference to a national code

Ref country code:HK

Ref legal event code:WD

Ref document number:1244079

Country of ref document:HK


[8]ページ先頭

©2009-2025 Movatter.jp