WO2017167039A1 - 数据缓存的方法及装置 - Google Patents

数据缓存的方法及装置 Download PDF

Info

Publication number
WO2017167039A1
WO2017167039A1 PCT/CN2017/077241 CN2017077241W WO2017167039A1 WO 2017167039 A1 WO2017167039 A1 WO 2017167039A1 CN 2017077241 W CN2017077241 W CN 2017077241W WO 2017167039 A1 WO2017167039 A1 WO 2017167039A1
Authority
WO
WIPO (PCT)
Prior art keywords
data
page
cached
database
client
Prior art date
Application number
PCT/CN2017/077241
Other languages
English (en)
French (fr)
Inventor
王玲玉
李雅民
Original Assignee
阿里巴巴集团控股有限公司
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 阿里巴巴集团控股有限公司 filed Critical 阿里巴巴集团控股有限公司
Priority to SG11201808173RA priority Critical patent/SG11201808173RA/en
Priority to JP2018551171A priority patent/JP6748734B2/ja
Priority to EP17773069.4A priority patent/EP3418911A4/en
Priority to KR1020187031539A priority patent/KR102232813B1/ko
Priority to MYPI2018703568A priority patent/MY190884A/en
Publication of WO2017167039A1 publication Critical patent/WO2017167039A1/zh
Priority to PH12018502065A priority patent/PH12018502065A1/en
Priority to US16/145,660 priority patent/US11449570B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor

Definitions

  • the present invention relates to the field of Internet technologies, and in particular, to a data cache method and apparatus.
  • the data cached to the cache server is only temporarily cached and not cached.
  • the cached data of a certain page expires, if a large number of users access the page, the system needs to separately search for data from the database for each request, and therefore, there are a large number of requests for simultaneous access to the database.
  • the query data from the database is inefficient, and the number of connections in the database is also limited, so that some users' interfaces may have short-term system exceptions and cannot view the contents of the page.
  • the present invention provides a data cache method and apparatus, which can solve the following problem: when a cached data of a certain page expires, if a large number of users access the page, it is necessary to separately search for each request from the database. Data, which causes a large number of requests to access the database at the same time, which causes some users to have short-term system anomalies and unable to view the contents of the page.
  • a method of data caching comprising:
  • an apparatus for data caching comprising:
  • a determining unit configured to determine, after receiving the data request sent by the client, a remaining valid cache duration of the cached data corresponding to the data request;
  • a determining unit configured to determine whether the remaining valid cache duration obtained by the determining unit is greater than a preset update threshold
  • an updating unit configured to update the cached data by using a database when a result of the determining by the determining unit is that the remaining valid cache duration is less than or equal to the update threshold.
  • the method and device for data caching provided by the present invention can determine whether the remaining valid cache duration of the cached data corresponding to the data request is greater than a preset update threshold after receiving the data request sent by the client; When the remaining valid cache duration is greater than the update threshold, the cache data is directly returned to the client; when the remaining valid cache duration is a positive number and less than or equal to the update threshold, not only the cached data is returned to the client, but also through the database. Update the cached data.
  • the cache data when the cache data is expired, the cache data is updated before the cache data expires, so that the cache data is updated before the cache data expires, so that when a large number of clients subsequently request the cache data, the cache The data is still in a valid state, and the cached data can be directly returned to each client, thereby reducing the phenomenon that a large number of requests concurrently access the database due to cached data expiration.
  • FIG. 1 is a flowchart of a method for data caching provided by an embodiment of the present invention
  • FIG. 2 is a block diagram showing the structure of an apparatus for data caching provided by an embodiment of the present invention
  • FIG. 3 is a block diagram showing the composition of another data cache device according to an embodiment of the present invention.
  • the embodiment of the invention provides a method for data caching.
  • the method is mainly applied to the server side. As shown in FIG. 1 , the method mainly includes:
  • the server may search the cache for the cached data corresponding to the data request, and determine the remaining valid cache duration of the cached data, so as to determine whether the cached data needs to be updated according to the remaining valid cache duration. .
  • the cache start time and the total effective cache duration may be recorded.
  • the cache time reaches the total effective cache duration the cached data expires; or a countdown timer of the total effective cache duration may be set.
  • the timing is 0, the cached data expires. It can be seen that the server can determine the remaining effective cache duration of the cached data according to the time attribute of the cached data.
  • the remaining valid cache duration is a positive number, and the update threshold is less than the total effective cache duration of the cached data. If the remaining valid cache duration is a positive number, the cached data is valid data. In this case, step 102 may be performed to determine whether the cached data needs to be updated in advance; if the remaining valid cache duration is 0, the cache is indicated. The data has expired, in which case step 102 is cancelled, the data is queried directly to the database for each data request, and the found data is returned to the client, and the expired cached data is updated based on the found data.
  • the cached data is updated through the database.
  • the cached data is returned to the client, and the cached data is updated through the database; if the remaining valid cache duration is greater than the update threshold, the cached data is directly returned to the client. You can do this without having to update the cached data through the database.
  • the cache data is returned to the client and the cache data is updated by the database, or may be performed at different times, and is not limited herein.
  • the server needs to update the cached data through the database.
  • the update threshold is the average time required to query the data from the database to write the queried data into the cache
  • the cached data completes the update operation just after the expiration; if the update threshold is less than the average time , the update operation has not been completed at the moment when the cached data expires, so that when a large number of clients send data requests from the cache data expiration to the completion of the update operation,
  • To send a query request to the database for each data request which may cause a system abnormality; if the update threshold is greater than the average time, the update operation is completed before the cached data expires, so that the cache expires, and the The phenomenon that each data request sends a query request to the database. It can be seen that, in practical applications, when the update threshold is greater than or equal to the average time required to query the data from the database to write the que
  • the method for data caching can determine whether the remaining valid cache duration of the cached data corresponding to the data request is greater than a preset update threshold after receiving the data request sent by the client; when the remaining valid cache duration is greater than When the threshold is updated, the cache data is directly returned to the client; when the remaining valid cache duration is a positive number and is less than or equal to the update threshold, not only the cached data is returned to the client, but also the cached data is updated through the database.
  • the cache data when the cache data is expired, the cache data is updated before the cache data expires, so that the cache data is updated before the cache data expires, so that when a large number of clients subsequently request the cache data, the cache The data is still in a valid state, and the cached data can be directly returned to each client, thereby reducing the phenomenon that a large number of requests concurrently access the database due to cached data expiration.
  • the data request sent by the client may be received, and during this time, the cached data corresponding to the data request may not have expired, and the update condition is satisfied (ie, the remaining of the cached data)
  • the effective cache duration is less than or equal to the update threshold). Therefore, during the period in which the cached data has not expired and the cached data is updated through the database, the cached data always satisfies the update condition. Therefore, during this period, each time a data request corresponding to the cached data is received, a data query request needs to be sent to the database. In order to update the cached data, the phenomenon of frequently updating cached data and frequent access to the database occurs.
  • the embodiment of the present invention improves the foregoing embodiment.
  • the execution of the remaining valid cache is determined to be greater than a preset update threshold. That is, the cached data is updated only when the received data request satisfies the update condition for the first time.
  • the cached data is directly returned to the corresponding client, and the cached data does not need to be updated by accessing the database.
  • the embodiment of the present invention may be improved as follows on the basis of any of the above embodiments:
  • the query receives the data corresponding to the cached data sent by the client. If the data request corresponding to the cached data sent by the client is not received, the cached data is updated through the database; if the data request corresponding to the cached data sent by the client is received, the data corresponding to the data request is searched from the database. After that, the found data is returned to the client, and the cached data is updated based on the found data.
  • the embodiment of the present invention determines whether the stored cached data is expired in real time, and only if the cached data is expired, if the cached data is expired, if the cached data is expired, the client sends the cached data.
  • the data request corresponding to the cached data directly updates the cached data through the database, so that after the cached data is updated, if the data request sent by the client is received, the updated cached data can be directly returned to the client without Each data request accesses the database, further reducing the number of requests to access the database at the same time.
  • embodiment of the present invention may further improve on the basis of any of the foregoing embodiments:
  • the data contained in the data resource is divided into at least two data sets according to the resource type and the preset rule.
  • Each data set is independently cached, and a key corresponding to each data set is generated, so that the cached data is subsequently searched according to the key.
  • the expiration time of each data set is different, and the value of the key is the primary key value of the cached data.
  • the data resources include browser pages, pages on other application software, and files to be downloaded.
  • the specific implementation of the foregoing step 102 may be: determining whether the remaining effective cache duration of the data set corresponding to the data request is greater than the update threshold.
  • the embodiment of the present invention may divide the first page as follows: when the data resource is the first page for displaying the fixed data, according to the page layout of the first page, the data will be found from the database.
  • the data contained in the first page is divided into at least two data sets. After the first page is divided, each data set is independently cached, and a key corresponding to each data set is generated, so that the cached data is subsequently searched according to the key, wherein each data set has different expiration time points.
  • the first page is a page for displaying fixed data, that is, when the client accesses the first page, the service The device needs to return all the data contained in the first page to the client, so that the first page is completely displayed on the client.
  • the fixed data displayed on the first page includes text, links, images, and the like.
  • the data included in the first page may be divided into at least two data sets according to the page layout, and each data set corresponds to one area in the page layout, or each data set corresponds to a part of one area;
  • the division rule divides the first page and is not limited herein.
  • the data resource is the first page for displaying the fixed data
  • the data is cached based on the first case
  • the cache duration is greater than the update threshold, and the data set that satisfies the remaining valid cache duration is less than or equal to the update threshold is updated by the database.
  • the embodiment of the present invention only needs to update the data set that satisfies the remaining valid cache duration less than or equal to the update threshold, compared with the prior art that the page is completely cached (ie, all the data included in the page corresponds to one key). There is no need to update other data sets corresponding to the page, thereby reducing the amount of data for updating the page data, thereby improving the update efficiency.
  • the second case in the prior art, when the data contained in the second page with the conditional query function is cached, all the data is completely cached, that is, all the data contained in the second page corresponds to one key, therefore,
  • the data that satisfies the condition is searched from all the cached data corresponding to the second page, and the found data is returned to the client, so the response to the client request is less efficient.
  • the embodiment of the present invention may divide the second page as follows:
  • the data included in the second page found in the database is divided into at least two data sets; the second page includes Multiple sets of query conditions, the result data corresponding to a set of query conditions is a data set, and a set of query conditions consists of at least one query condition.
  • each data set is independently cached, and a key corresponding to each data set is generated, so that the cached data is subsequently searched according to the key.
  • the second page includes each query condition and result data corresponding to a certain set of query conditions.
  • the query condition is often unlimited, so all the data will be displayed on the page; when the user selects a certain set of query conditions based on the second page to query, the set of query conditions will be displayed on the page. Corresponding result data.
  • the query conditions on the second page are: "Term (including unlimited, within 3 months, within 3-6 months, 6-12) Within the month), "purchase amount (including unlimited, 100-1000, 1000-1 million, 10,000-50,000, 50,000 or more)", "product type (including unlimited, fund products, insurance products, Other products)”.
  • the time limit, purchase amount and product type are all unlimited, all data is displayed; when the user selects based on the second page, the period is 3 months, the purchase amount is When the product type is 10,000-50,000, the second page will display the data that meets the conditions.
  • the data resource is the second page with the conditional query function, and the data is cached based on the second case, when the user performs the conditional query based on the page, it is required to determine that the remaining data set corresponding to the requested query condition is valid. Whether the cache duration is greater than the update threshold, and updating the data set through the database when the remaining valid cache duration is less than or equal to the update threshold.
  • the data set corresponding to each group of query conditions is separately cached, when the user performs a conditional query based on the page, the data set under the query condition can be directly searched by the key, and the found data set is returned to the client without The query condition performs a second query from all the data contained in the page, thereby improving the efficiency of responding to client requests.
  • another embodiment of the present invention further provides a device for data buffering.
  • the device mainly includes: a determining unit 21, a determining unit 22, and an updating unit 23. among them,
  • a determining unit 21 configured to determine, after receiving the data request sent by the client, a remaining valid cache duration of the cached data corresponding to the data request;
  • the determining unit 22 is configured to determine whether the remaining valid cache duration obtained by the determining unit 21 is greater than a preset update threshold
  • the updating unit 23 is configured to update the cached data through the database when the judgment result of the determining unit 22 is that the remaining valid cache duration is less than or equal to the update threshold.
  • the device for data caching provided by the embodiment of the present invention can determine whether the remaining valid cache duration of the cached data corresponding to the data request is greater than a preset update threshold after receiving the data request sent by the client; when the remaining valid cache duration is greater than When the threshold is updated, the cache data is directly returned to the client; when the remaining valid cache duration is a positive number and is less than or equal to the update threshold, not only the cached data is returned to the client, but also the cached data is updated through the database.
  • the cache data when the cache data is expired, the cache data is updated before the cache data expires, so that the cache data is updated before the cache data expires, so that when a large number of clients subsequently request the cache data, the cache The data is still in a valid state, and the cached data can be directly returned to each client, thereby reducing the phenomenon that a large number of requests concurrently access the database due to cached data expiration.
  • the device further includes:
  • the canceling unit 24 is configured to: during the update of the cached data, if another data request is received, cancel the execution to determine whether the remaining valid cache duration is greater than a preset update threshold.
  • the device further includes:
  • the query unit 25 is configured to: when the stored cache data expires, query whether the data request corresponding to the cached data sent by the client is received;
  • the updating unit 23 is further configured to: when the data request corresponding to the cache data sent by the client is not received, update the cache data through the database;
  • the sending unit 26 is configured to: after receiving the data request corresponding to the cached data sent by the client, after searching the data corresponding to the data request from the database, returning the found data to the client;
  • the update unit 23 is also operative to update the cached data based on the found data.
  • the device further includes:
  • a dividing unit 27 configured to divide data included in the data resource into at least two data sets according to the resource type and the preset rule when the data resource is first accessed;
  • the buffer unit 28 is configured to cache the respective data sets obtained by the dividing unit 27, and generate keys corresponding to the respective data sets, so as to subsequently search the cached data according to the key, wherein the expiration time points of each data set are different.
  • the dividing unit 27 includes:
  • the first dividing module 271 is configured to: when the data resource is the first page for displaying the fixed data, divide the data included in the first page that is found from the database into at least two data according to the page layout of the first page. set;
  • the second dividing module 272 is configured to, when the data resource is the second page with the conditional query function, divide the data included in the second page found in the database into at least two according to the query condition combination involved in the second page.
  • the determining unit 22 is configured to determine whether the remaining valid cache duration of the data set corresponding to the data request is greater than an update threshold.
  • the device embodiment corresponds to the foregoing method embodiment.
  • the device embodiment does not describe the details in the foregoing method embodiments one by one, but it should be clear that the device in this embodiment can implement the foregoing method. All the contents of the example.
  • the device for buffering data includes a processor and a memory, and the determining unit, the determining unit, the updating unit, and the like Each is stored as a program unit in a memory, and the above-described program unit stored in the memory is executed by the processor to implement the corresponding function.
  • the processor contains a kernel, and the kernel removes the corresponding program unit from the memory.
  • the kernel can be set to one or more. By adjusting the kernel parameters to reduce the cache expiration, there are a large number of requests for concurrent access to the database.
  • the memory may include non-persistent memory, random access memory (RAM), and/or non-volatile memory in a computer readable medium, such as read only memory (ROM) or flash memory (flash RAM), the memory including at least one Memory chip.
  • RAM random access memory
  • ROM read only memory
  • flash RAM flash memory
  • the application also provides a computer program product, when executed on a data processing device, adapted to perform initialization of program code having the following method steps:
  • the cached data is updated by the database.
  • modules in the devices of the embodiments can be adaptively changed and placed in one or more devices different from the embodiment.
  • the modules or units or components of the embodiments may be combined into one module or unit or component, and further they may be divided into a plurality of sub-modules or sub-units or sub-components.
  • any combination of the features disclosed in the specification, including the accompanying claims, the abstract and the drawings, and any methods so disclosed, or All processes or units of the device are combined.
  • Each feature disclosed in this specification (including the accompanying claims, the abstract and the drawings) may be replaced by alternative features that provide the same, equivalent or similar purpose.
  • the various component embodiments of the present invention may be implemented in hardware, or in a software module running on one or more processors, or in a combination thereof.
  • a device or device program e.g., a computer program and a computer program product
  • Such a program implementing the invention may be stored on a computer readable medium or may be in the form of one or more signals.
  • signals may be downloaded from an Internet website, provided on a carrier signal, or provided in any other form.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本发明公开了一种数据缓存的方法及装置,涉及互联网技术领域,能够解决以下问题:当某一页面的缓存数据过期时,若存在大量用户访问该页面,则需要分别针对每一个请求从数据库中查找数据,从而造成大量请求同时访问数据库的现象。该方法主要包括:在接收到客户端发送的数据请求后,确定所述数据请求对应的缓存数据的剩余有效缓存时长;判断所述剩余有效缓存时长是否大于预设的更新阈值;若所述剩余有效缓存时长小于或等于所述更新阈值,则通过数据库更新所述缓存数据。本发明主要适用于基于数据缓存响应客户端请求的场景中。

Description

数据缓存的方法及装置
本申请要求2016年04月01日递交的申请号为201610204539.8、发明名称为“数据缓存的方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本发明涉及互联网技术领域,特别是涉及一种数据缓存的方法及装置。
背景技术
在实际应用中,对于大型的网站或应用,几乎每时每刻存在着数万级用户在访问同一个页面。因此,为了快速响应用户请求,引入了缓存技术。在现有技术中,当某页面首次被访问时,系统先从数据库中查找该页面对应的数据,然后将查找到的数据返回给客户端,同时将查找到的数据缓存至缓存服务器中,以便后续该页面再次被访问时,可直接从缓存服务器侧获取数据,而无需从包含大量数据的数据库中花费大量时间进行查询,从而提高了响应用户请求的效率。
由于数据库中的数据会不断更新,所以缓存至缓存服务器的数据只会暂时缓存,而不会持久缓存。在这种情况下,当某一页面的缓存数据过期时,若存在大量用户访问该页面,则系统需要分别针对每一个请求从数据库中查找数据,因此,会存在大量请求同时访问数据库的现象,且从数据库中查询数据效率较低,数据库的连接数也有限,从而部分用户的界面可能会出现短暂的系统异常、无法查看到页面内容的现象。
发明内容
有鉴于此,本发明提供一种数据缓存的方法及装置,能够解决以下问题:当某一页面的缓存数据过期时,若存在大量用户访问该页面,则需要分别针对每一个请求从数据库中查找数据,从而造成大量请求同时访问数据库的现象,进而使得部分用户的界面出现短暂的系统异常、无法查看页面内容的现象。
依据本发明一个方面,提供了一种数据缓存的方法,所述方法包括:
在接收到客户端发送的数据请求后,确定所述数据请求对应的缓存数据的剩余有效缓存时长;
判断所述剩余有效缓存时长是否大于预设的更新阈值;
若所述剩余有效缓存时长小于或等于所述更新阈值,则通过数据库更新所述缓存数 据。
依据本发明另一个方面,提供了一种数据缓存的装置,所述装置包括:
确定单元,用于在接收到客户端发送的数据请求后,确定所述数据请求对应的缓存数据的剩余有效缓存时长;
判断单元,用于判断所述确定单元获得的所述剩余有效缓存时长是否大于预设的更新阈值;
更新单元,用于当所述判断单元的判断结果为所述剩余有效缓存时长小于或等于所述更新阈值时,通过数据库更新所述缓存数据。
借由上述技术方案,本发明提供的数据缓存的方法及装置,能够在接收到客户端发送的数据请求后,判断该数据请求对应的缓存数据的剩余有效缓存时长是否大于预设的更新阈值;当剩余有效缓存时长大于该更新阈值时,直接向客户端返回该缓存数据;当剩余有效缓存时长为正数,且小于或者等于该更新阈值时,不仅向客户端返回该缓存数据,还通过数据库更新该缓存数据。由此可知,与现有技术中当缓存数据过期时,才更新缓存数据相比,本发明能够在缓存数据过期前就更新缓存数据,从而当后续存在大量客户端请求该缓存数据时,该缓存数据仍然处于有效状态,并可以直接将该缓存数据返回给各个客户端,进而减少因缓存数据过期,存在大量请求并发访问数据库的现象。
上述说明仅是本发明技术方案的概述,为了能够更清楚了解本发明的技术手段,而可依照说明书的内容予以实施,并且为了让本发明的上述和其它目的、特征和优点能够更明显易懂,以下特举本发明的具体实施方式。
附图说明
通过阅读下文优选实施方式的详细描述,各种其他的优点和益处对于本领域普通技术人员将变得清楚明了。附图仅用于示出优选实施方式的目的,而并不认为是对本发明的限制。而且在整个附图中,用相同的参考符号表示相同的部件。在附图中:
图1示出了本发明实施例提供的一种数据缓存的方法的流程图;
图2示出了本发明实施例提供的一种数据缓存的装置的组成框图;
图3示出了本发明实施例提供的另一种数据缓存的装置的组成框图。
具体实施方式
下面将参照附图更详细地描述本公开的示例性实施例。虽然附图中显示了本公开的 示例性实施例,然而应当理解,可以以各种形式实现本公开而不应被这里阐述的实施例所限制。相反,提供这些实施例是为了能够更透彻地理解本公开,并且能够将本公开的范围完整的传达给本领域的技术人员。
本发明实施例提供了一种数据缓存的方法,该方法主要应用于服务器侧,如图1所示,该方法主要包括:
101、在接收到客户端发送的数据请求后,确定数据请求对应的缓存数据的剩余有效缓存时长。
当服务器接收到客户端发送的数据请求后,可以从缓存中查找该数据请求对应的缓存数据,并确定缓存数据的剩余有效缓存时长,以便后续根据该剩余有效缓存时长判断是否需要更新该缓存数据。其中,在缓存各个缓存数据时,可以记录其缓存起始时间和总体有效缓存时长,在缓存时间到总体有效缓存时长时,缓存数据过期;也可以设置一个时间为总体有效缓存时长的倒计时器,当计时为0时,缓存数据过期。由此可知,服务器可以根据缓存数据的时间属性,确定缓存数据的剩余有效缓存时长。
102、判断剩余有效缓存时长是否大于预设的更新阈值。
其中,剩余有效缓存时长为正数,更新阈值小于缓存数据的总体有效缓存时长。若剩余有效缓存时长为正数,则说明该缓存数据为有效数据,在这种情况下,可以执行步骤102,以便确定是否需要提前更新缓存数据;若剩余有效缓存时长为0,则说明该缓存数据已过期,在这种情况下,取消执行步骤102,直接针对每一个数据请求,向数据库查询数据,并将查找到的数据返回给客户端,以及根据查找到的数据更新过期的缓存数据。
103、若剩余有效缓存时长小于或等于更新阈值,则通过数据库更新缓存数据。
具体的,若剩余有效缓存时长小于或等于更新阈值,则将该缓存数据返回给客户端,并通过数据库更新缓存数据;若剩余有效缓存时长大于更新阈值,则直接将该缓存数据返回给客户端即可,而无需通过数据库更新缓存数据。其中,将缓存数据返回给客户端以及通过数据库更新缓存数据可以同时进行,也可以不同时进行,在此不作限定。
若在缓存数据的剩余有效缓存时长等于更新阈值时接收到客户端发送的数据请求,则服务器需要通过数据库更新该缓存数据。在这种情况下,若更新阈值为从数据库中查询数据到将查询的数据写入缓存中所需的平均时间,则该缓存数据正好在过期的瞬间完成更新操作;若更新阈值小于该平均时间,则在该缓存数据过期的瞬间还未完成更新操作,从而从缓存数据过期到完成更新操作期间,若存在大量客户端发送数据请求,则需 要针对每个数据请求向数据库发送查询请求,进而可能造成系统异常的现象;若更新阈值大于该平均时间,则在该缓存数据过期前就完成更新操作,从而不会出现因缓存过期,需要针对每个数据请求向数据库发送查询请求的现象。由此可知,在实际应用中,当更新阈值大于或者等于从数据库中查询数据到将查询的数据写入缓存中所需的平均时间时,可以进一步减少大量请求访问数据库的现象。
本发明实施例提供的数据缓存的方法,能够在接收到客户端发送的数据请求后,判断该数据请求对应的缓存数据的剩余有效缓存时长是否大于预设的更新阈值;当剩余有效缓存时长大于该更新阈值时,直接向客户端返回该缓存数据;当剩余有效缓存时长为正数,且小于或者等于该更新阈值时,不仅向客户端返回该缓存数据,还通过数据库更新该缓存数据。由此可知,与现有技术中当缓存数据过期时,才更新缓存数据相比,本发明能够在缓存数据过期前就更新缓存数据,从而当后续存在大量客户端请求该缓存数据时,该缓存数据仍然处于有效状态,并可以直接将该缓存数据返回给各个客户端,进而减少因缓存数据过期,存在大量请求并发访问数据库的现象。
进一步的,在通过数据库更新缓存数据期间,可能会接收到客户端发送的数据请求,并且在这段时间内,数据请求对应的缓存数据可能还未过期,且满足更新条件(即缓存数据的剩余有效缓存时长小于或等于更新阈值)。由此可知,在缓存数据未过期且通过数据库更新缓存数据期间,缓存数据一直满足更新条件,因此,在此期间,每接收一个该缓存数据对应的数据请求,就需要向数据库发送一次数据查询请求,以便更新缓存数据,从而出现频繁更新缓存数据、频繁访问数据库的现象。
为解决上述技术问题,本发明实施例对上述实施例作了如下改进:在缓存数据的更新期间,若再接收到其他数据请求,则取消执行判断剩余有效缓存时长是否大于预设的更新阈值,即只在接收到的数据请求首次满足更新条件时才更新缓存数据,在更新完成之前,接收到其他请求后,直接向对应的客户端返回缓存数据,无需再通过访问数据库更新缓存数据。
进一步的,对于上述实施例涉及的方案,由于在缓存数据的剩余有效缓存时长由更新阈值逐渐变为0(不包括0)的过程中,若没有接收到任何一个该缓存数据对应的数据请求,则不会触发对该缓存数据更新的操作,所以缓存数据仍然存在过期的现象,从而可能存在大量请求同时访问数据库的现象。为了进一步减少大量请求同时访问数据库的现象,本发明实施例可以在上述任一实施例的基础上作如下改进:
当存储的缓存数据过期时,查询是否接收到客户端发送的缓存数据对应的数据请 求;若没有接收到客户端发送的缓存数据对应的数据请求,则通过数据库更新缓存数据;若接收到客户端发送的缓存数据对应的数据请求,则在从数据库中查找到数据请求对应的数据后,将查找到的数据返回给客户端,并基于查找到的数据更新缓存数据。
与只有在接收到客户端发送的数据请求后,才判断是否需要更新缓存数据相比,本发明实施例通过实时判断存储的缓存数据是否过期,当缓存数据过期时,若没有接收到客户端发送的缓存数据对应的数据请求,则直接通过数据库更新缓存数据,从而在缓存数据更新后,若接收到客户端发送的数据请求,则可以直接将更新后的缓存数据返回给客户端,而无需针对每个数据请求访问数据库,进而进一步减少了大量请求同时访问数据库的现象。
进一步的,本发明实施例还可以在上述任一实施例的基础上作如下改进:
当数据资源首次被访问时,根据资源类型和预置规则将数据资源包含的数据划分为至少两个数据集合。将各个数据集合独立进行缓存,并生成各个数据集合对应的key,以便后续根据key查找缓存数据,其中,每个数据集合的过期时间点不同,key的取值为缓存数据的主键值。其中,数据资源包括浏览器页面、其他应用软件上的页面以及待下载的文件等。
此外,在数据资源包含的数据划分成至少两个数据集合进行缓存后,上述步骤102的具体实现方式可以为:判断数据请求对应的数据集合的剩余有效缓存时长是否大于更新阈值。
在实际应用中,当数据资源为页面时,不同类型的页面可以有不同的页面数据划分方法,下面以以下两种情况为例进行介绍:
第一种情况:在现有技术中,在对用于展示固定数据的第一页面包含的数据进行缓存时,会将所有数据进行完整缓存,即第一页面包含的所有数据对应一个key,因此,在对该第一页面对应的缓存数据进行更新时,需要从数据库中查找该第一页面包含的所有数据,查询的数据量较大,从而查询效率较低。因此为解决上述技术问题,本发明实施例可以对第一页面进行如下划分:当数据资源为用于展示固定数据的第一页面时,根据第一页面的页面布局,将从数据库中查找到的第一页面包含的数据划分为至少两个数据集合。并且在对第一页面划分后,将各个数据集合独立进行缓存,并生成各个数据集合对应的key,以便后续根据key查找缓存数据,其中,每个数据集合的过期时间点不同。
具体的,第一页面为用于展示固定数据的页面,即当客户端访问第一页面时,服务 器需要将第一页面包含的所有数据返回给客户端,以便在客户端完整展示第一页面。其中,第一页面所展示的固定数据包括文字、链接、图像等。
在实际应用中,一个页面往往被划分为至少两个区域进行显示,且每个区域显示的数据的格式往往相同。因此,可以根据页面布局将第一页面包含的数据划分为至少两个数据集合,且每个数据集合对应页面布局中的一个区域,或者每个数据集合对应一个区域中的一部分;还可以根据其他划分规则划分第一页面,在此不作限定。
若数据资源为用于展示固定数据的第一页面,且基于上述第一种情况进行数据缓存,则当客户端请求该页面的数据时,需要分别判断该数据请求对应的各个数据集合的剩余有效缓存时长是否大于更新阈值,并通过数据库对满足剩余有效缓存时长小于或等于更新阈值的数据集合进行更新。
由于各个数据集合的过期时间点不同,所以在同一时刻,可能只存在部分数据集合的剩余有效缓存时长小于或等于更新阈值。因此,与现有技术中对页面进行完整缓存(即页面包含的所有数据对应一个key)相比,本发明实施例只需对满足剩余有效缓存时长小于或等于更新阈值的数据集合进行更新,而无需对该页面对应的其他数据集合进行更新,从而减少了更新页面数据的数据量,进而提高了更新效率。
第二种情况:在现有技术中,在对具有条件查询功能的第二页面包含的数据进行缓存时,会将所有数据进行完整缓存,即第二页面包含的所有数据对应一个key,因此,当用户基于第二页面进行条件查询时,需要从第二页面对应的所有缓存数据中查询满足条件的数据,并将查找到的数据返回给客户端,因此响应客户端请求的效率较低。为解决上述技术问题,本发明实施例可以对第二页面进行如下划分:
当数据资源为具有条件查询功能的第二页面时,根据第二页面涉及的查询条件组合,将从数据库中查找到的第二页面包含的数据划分为至少两个数据集合;第二页面中包括多组查询条件,一组查询条件对应的结果数据为一个数据集合,一组查询条件由至少一个查询条件组成。并且在对第二页面划分后,将各个数据集合独立进行缓存,并生成各个数据集合对应的key,以便后续根据key查找缓存数据。
其中,第二页面包括各个查询条件以及某组查询条件对应的结果数据。当用户首次进入第二页面时,查询条件往往为不限,因此会在该页面上显示所有数据;当用户基于第二页面选择某组查询条件进行查询时,会在该页面显示该组查询条件对应的结果数据。
例如,第二页面上的查询条件有:“期限(包括不限、3个月内、3-6个月内、6-12 个月内)”、“起购金额(包括不限、100-1000、1000-1万、1万-5万、5万以上)”、“产品类型(包括不限、基金产品、保险产品、其他产品)”。当用户首次进入第二页面时,期限、起购金额以及产品类型均为不限,显示所有数据;当用户基于第二页面选择“期限为3个月内,起购金额为1万-5万,产品类型为基金产品”时,第二页面会显示满足该条件的数据。
若数据资源为具有条件查询功能的第二页面,且基于上述第二种情况进行数据缓存,则当用户基于该页面进行条件查询时,需要判断请求的这组查询条件对应的数据集合的剩余有效缓存时长是否大于更新阈值,并在剩余有效缓存时长小于或者等于更新阈值时,通过数据库更新该数据集合。
由于每组查询条件对应的数据集合分开缓存,所以当用户基于该页面进行条件查询时,可直接通过key查找查询条件下的数据集合,并将查找到的数据集合返回给客户端,而无需根据查询条件从该页面包含的所有数据中进行二次查询,从而提高了响应客户端请求的效率。
进一步的,依据上述方法实施例,本发明的另一个实施例还提供了一种数据缓存的装置,如图2所示,该装置主要包括:确定单元21、判断单元22和更新单元23。其中,
确定单元21,用于在接收到客户端发送的数据请求后,确定数据请求对应的缓存数据的剩余有效缓存时长;
判断单元22,用于判断确定单元21获得的剩余有效缓存时长是否大于预设的更新阈值;
更新单元23,用于当判断单元22的判断结果为剩余有效缓存时长小于或等于更新阈值时,通过数据库更新缓存数据。
本发明实施例提供的数据缓存的装置,能够在接收到客户端发送的数据请求后,判断该数据请求对应的缓存数据的剩余有效缓存时长是否大于预设的更新阈值;当剩余有效缓存时长大于该更新阈值时,直接向客户端返回该缓存数据;当剩余有效缓存时长为正数,且小于或者等于该更新阈值时,不仅向客户端返回该缓存数据,还通过数据库更新该缓存数据。由此可知,与现有技术中当缓存数据过期时,才更新缓存数据相比,本发明能够在缓存数据过期前就更新缓存数据,从而当后续存在大量客户端请求该缓存数据时,该缓存数据仍然处于有效状态,并可以直接将该缓存数据返回给各个客户端,进而减少因缓存数据过期,存在大量请求并发访问数据库的现象。
进一步的,如图3所示,该装置还包括:
取消单元24,用于在缓存数据的更新期间,若再接收到其他数据请求,则取消执行判断剩余有效缓存时长是否大于预设的更新阈值
进一步的,如图3所示,该装置还包括:
查询单元25,用于当存储的缓存数据过期时,查询是否接收到客户端发送的缓存数据对应的数据请求;
更新单元23还用于当没有接收到客户端发送的缓存数据对应的数据请求时,通过数据库更新缓存数据;
发送单元26,用于当接收到客户端发送的缓存数据对应的数据请求时,在从数据库中查找到数据请求对应的数据后,将查找到的数据返回给客户端;
更新单元23还用于基于查找到的数据更新缓存数据。
进一步的,如图3所示,该装置还包括:
划分单元27,用于当数据资源首次被访问时,根据资源类型和预置规则将数据资源包含的数据划分为至少两个数据集合;
缓存单元28,用于将划分单元27获得的各个数据集合独立进行缓存,并生成各个数据集合对应的key,以便后续根据key查找缓存数据,其中,每个数据集合的过期时间点不同。
进一步的,如图3所示,划分单元27,包括:
第一划分模块271,用于当数据资源为用于展示固定数据的第一页面时,根据第一页面的页面布局,将从数据库中查找到的第一页面包含的数据划分为至少两个数据集合;
第二划分模块272,用于当数据资源为具有条件查询功能的第二页面时,根据第二页面涉及的查询条件组合,将从数据库中查找到的第二页面包含的数据划分为至少两个数据集合;第二页面中包括多组查询条件,一组查询条件对应的结果数据为一个数据集合,一组查询条件由至少一个查询条件组成。
进一步的,判断单元22用于判断数据请求对应的数据集合的剩余有效缓存时长是否大于更新阈值。
该装置实施例与前述方法实施例对应,为便于阅读,本装置实施例不再对前述方法实施例中的细节内容进行逐一赘述,但应当明确,本实施例中的装置能够对应实现前述方法实施例中的全部内容。
所述数据缓存的装置包括处理器和存储器,上述确定单元、判断单元和更新单元等 均作为程序单元存储在存储器中,由处理器执行存储在存储器中的上述程序单元来实现相应的功能。
处理器中包含内核,由内核去存储器中调取相应的程序单元。内核可以设置一个或以上,通过调整内核参数来减少因缓存过期,而存在大量请求并发访问数据库的现象。
存储器可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM),存储器包括至少一个存储芯片。
本申请还提供了一种计算机程序产品,当在数据处理设备上执行时,适于执行初始化有如下方法步骤的程序代码:
在接收到客户端发送的数据请求后,确定所述数据请求对应的缓存数据的剩余有效缓存时长;
判断所述剩余有效缓存时长是否大于预设的更新阈值,所述剩余有效缓存时长为正数,所述更新阈值小于所述缓存数据的总体有效缓存时长;
若所述剩余有效缓存时长小于或等于所述更新阈值,则通过数据库更新所述缓存数据。
在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
可以理解的是,上述实施例中的“第一”、“第二”等是用于区分各实施例,而并不代表各实施例的优劣。
在此提供的算法和显示不与任何特定计算机、虚拟系统或者其它设备固有相关。各种通用系统也可以与基于在此的示教一起使用。根据上面的描述,构造这类系统所要求的结构是显而易见的。此外,本发明也不针对任何特定编程语言。应当明白,可以利用各种编程语言实现在此描述的本发明的内容,并且上面对特定语言所做的描述是为了披露本发明的最佳实施方式。
在此处所提供的说明书中,说明了大量具体细节。然而,能够理解,本发明的实施例可以在没有这些具体细节的情况下实践。在一些实例中,并未详细示出公知的方法、结构和技术,以便不模糊对本说明书的理解。
类似地,应当理解,为了精简本公开并帮助理解各个发明方面中的一个或多个,在上面对本发明的示例性实施例的描述中,本发明的各个特征有时被一起分组到单个实施例、图、或者对其的描述中。然而,并不应将该公开的方法解释成反映如下意图:即所 要求保护的本发明要求比在每个权利要求中所明确记载的特征更多的特征。更确切地说,如下面的权利要求书所反映的那样,发明方面在于少于前面公开的单个实施例的所有特征。因此,遵循具体实施方式的权利要求书由此明确地并入该具体实施方式,其中每个权利要求本身都作为本发明的单独实施例。
本领域那些技术人员可以理解,可以对实施例中的设备中的模块进行自适应性地改变并且把它们设置在与该实施例不同的一个或多个设备中。可以把实施例中的模块或单元或组件组合成一个模块或单元或组件,以及此外可以把它们分成多个子模块或子单元或子组件。除了这样的特征和/或过程或者单元中的至少一些是相互排斥之外,可以采用任何组合对本说明书(包括伴随的权利要求、摘要和附图)中公开的所有特征以及如此公开的任何方法或者设备的所有过程或单元进行组合。除非另外明确陈述,本说明书(包括伴随的权利要求、摘要和附图)中公开的每个特征可以由提供相同、等同或相似目的的替代特征来代替。
此外,本领域的技术人员能够理解,尽管在此所述的一些实施例包括其它实施例中所包括的某些特征而不是其它特征,但是不同实施例的特征的组合意味着处于本发明的范围之内并且形成不同的实施例。例如,在下面的权利要求书中,所要求保护的实施例的任意之一都可以以任意的组合方式来使用。
本发明的各个部件实施例可以以硬件实现,或者以在一个或者多个处理器上运行的软件模块实现,或者以它们的组合实现。本领域的技术人员应当理解,本发明可以实现为用于执行这里所描述的方法的一部分或者全部的设备或者装置程序(例如,计算机程序和计算机程序产品)。这样的实现本发明的程序可以存储在计算机可读介质上,或者可以具有一个或者多个信号的形式。这样的信号可以从因特网网站上下载得到,或者在载体信号上提供,或者以任何其他形式提供。
应该注意的是上述实施例对本发明进行说明而不是对本发明进行限制,并且本领域技术人员在不脱离所附权利要求的范围的情况下可设计出替换实施例。在权利要求中,不应将位于括号之间的任何参考符号构造成对权利要求的限制。单词“包含”不排除存在未列在权利要求中的元件或步骤。位于元件之前的单词“一”或“一个”不排除存在多个这样的元件。本发明可以借助于包括有若干不同元件的硬件以及借助于适当编程的计算机来实现。在列举了若干装置的单元权利要求中,这些装置中的若干个可以是通过同一个硬件项来具体体现。单词第一、第二、以及第三等的使用不表示任何顺序。可将这些单词解释为名称。

Claims (12)

  1. 一种数据缓存的方法,其特征在于,所述方法包括:
    在接收到客户端发送的数据请求后,确定所述数据请求对应的缓存数据的剩余有效缓存时长;
    判断所述剩余有效缓存时长是否大于预设的更新阈值;
    若所述剩余有效缓存时长小于或等于所述更新阈值,则通过数据库更新所述缓存数据。
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    在所述缓存数据的更新期间,若再接收到其他数据请求,则取消执行所述判断所述剩余有效缓存时长是否大于预设的更新阈值。
  3. 根据权利要求2所述的方法,其特征在于,所述方法还包括:
    当存储的缓存数据过期时,查询是否接收到客户端发送的所述缓存数据对应的数据请求;
    若没有接收到客户端发送的所述缓存数据对应的数据请求,则通过所述数据库更新所述缓存数据;
    若接收到客户端发送的所述缓存数据对应的数据请求,则在从所述数据库中查找到所述数据请求对应的数据后,将查找到的数据返回给客户端,并基于所述查找到的数据更新所述缓存数据。
  4. 根据权利要求1至3任一项所述的方法,其特征在于,所述方法还包括:
    当数据资源首次被访问时,根据资源类型和预置规则将所述数据资源包含的数据划分为至少两个数据集合;
    将各个数据集合独立进行缓存,并生成各个数据集合对应的key,以便后续根据所述key查找缓存数据,其中,每个数据集合的过期时间点不同。
  5. 根据权利要求4所述的方法,其特征在于,根据资源类型和预置规则将所述数据资源包含的数据划分为至少两个数据集合,包括:
    当所述数据资源为用于展示固定数据的第一页面时,根据所述第一页面的页面布局,将从所述数据库中查找到的所述第一页面包含的数据划分为至少两个数据集合;
    当所述数据资源为具有条件查询功能的第二页面时,根据所述第二页面涉及的查询条件组合,将从所述数据库中查找到的所述第二页面包含的数据划分为至少两个数据集 合;所述第二页面中包括多组查询条件,一组查询条件对应的结果数据为一个数据集合,一组查询条件由至少一个查询条件组成。
  6. 根据权利要求4所述的方法,其特征在于,判断所述剩余有效缓存时长是否大于预设的更新阈值,包括:
    判断所述数据请求对应的数据集合的剩余有效缓存时长是否大于所述更新阈值。
  7. 一种数据缓存的装置,其特征在于,所述装置包括:
    确定单元,用于在接收到客户端发送的数据请求后,确定所述数据请求对应的缓存数据的剩余有效缓存时长;
    判断单元,用于判断所述确定单元获得的所述剩余有效缓存时长是否大于预设的更新阈值;
    更新单元,用于当所述判断单元的判断结果为所述剩余有效缓存时长小于或等于所述更新阈值时,通过数据库更新所述缓存数据。
  8. 根据权利要求7所述的装置,其特征在于,所述装置还包括:
    取消单元,用于在所述缓存数据的更新期间,若再接收到其他数据请求,则取消执行所述判断所述剩余有效缓存时长是否大于预设的更新阈值。
  9. 根据权利要求8所述的装置,其特征在于,所述装置还包括:
    查询单元,用于当存储的缓存数据过期时,查询是否接收到客户端发送的所述缓存数据对应的数据请求;
    所述更新单元还用于当没有接收到客户端发送的所述缓存数据对应的数据请求时,通过所述数据库更新所述缓存数据;
    发送单元,用于当接收到客户端发送的所述缓存数据对应的数据请求时,在从所述数据库中查找到所述数据请求对应的数据后,将查找到的数据返回给客户端;
    所述更新单元还用于基于所述查找到的数据更新所述缓存数据。
  10. 根据权利要求7至9任一项所述的装置,其特征在于,所述装置还包括:
    划分单元,用于当数据资源首次被访问时,根据资源类型和预置规则将所述数据资源包含的数据划分为至少两个数据集合;
    缓存单元,用于将所述划分单元获得的各个数据集合独立进行缓存,并生成各个数据集合对应的key,以便后续根据所述key查找缓存数据,其中,每个数据集合的过期时间点不同。
  11. 根据权利要求10所述的装置,其特征在于,所述划分单元,包括:
    第一划分模块,用于当所述数据资源为用于展示固定数据的第一页面时,根据所述第一页面的页面布局,将从所述数据库中查找到的所述第一页面包含的数据划分为至少两个数据集合;
    第二划分模块,用于当所述数据资源为具有条件查询功能的第二页面时,根据所述第二页面涉及的查询条件组合,将从所述数据库中查找到的所述第二页面包含的数据划分为至少两个数据集合;所述第二页面中包括多组查询条件,一组查询条件对应的结果数据为一个数据集合,一组查询条件由至少一个查询条件组成。
  12. 根据权利要求11所述的装置,其特征在于,所述判断单元用于判断所述数据请求对应的数据集合的剩余有效缓存时长是否大于所述更新阈值。
PCT/CN2017/077241 2016-04-01 2017-03-20 数据缓存的方法及装置 WO2017167039A1 (zh)

Priority Applications (7)

Application Number Priority Date Filing Date Title
SG11201808173RA SG11201808173RA (en) 2016-04-01 2017-03-20 Data caching method and apparatus
JP2018551171A JP6748734B2 (ja) 2016-04-01 2017-03-20 データキャッシング方法及び装置
EP17773069.4A EP3418911A4 (en) 2016-04-01 2017-03-20 METHOD AND APPARATUS FOR CACHING DATA
KR1020187031539A KR102232813B1 (ko) 2016-04-01 2017-03-20 데이터 캐싱 방법 및 장치
MYPI2018703568A MY190884A (en) 2016-04-01 2017-03-20 Data caching method and apparatus
PH12018502065A PH12018502065A1 (en) 2016-04-01 2018-09-26 Data caching method and apparatus
US16/145,660 US11449570B2 (en) 2016-04-01 2018-09-28 Data caching method and apparatus

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610204539.8 2016-04-01
CN201610204539.8A CN107291756A (zh) 2016-04-01 2016-04-01 数据缓存的方法及装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US16/145,660 Continuation US11449570B2 (en) 2016-04-01 2018-09-28 Data caching method and apparatus

Publications (1)

Publication Number Publication Date
WO2017167039A1 true WO2017167039A1 (zh) 2017-10-05

Family

ID=59963476

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/077241 WO2017167039A1 (zh) 2016-04-01 2017-03-20 数据缓存的方法及装置

Country Status (10)

Country Link
US (1) US11449570B2 (zh)
EP (1) EP3418911A4 (zh)
JP (1) JP6748734B2 (zh)
KR (1) KR102232813B1 (zh)
CN (1) CN107291756A (zh)
MY (1) MY190884A (zh)
PH (1) PH12018502065A1 (zh)
SG (1) SG11201808173RA (zh)
TW (1) TWI665569B (zh)
WO (1) WO2017167039A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110209968A (zh) * 2019-04-24 2019-09-06 北京奇艺世纪科技有限公司 一种数据存储系统、方法、装置及计算机可读存储介质

Families Citing this family (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102590347B1 (ko) * 2016-12-15 2023-10-18 삼성전자주식회사 서버, 전자 장치 및 데이터 관리 방법
CN109828749A (zh) * 2018-12-29 2019-05-31 北京航天云路有限公司 兼顾快速响应和数据更新的数据缓存方法及系统
CN111259034A (zh) * 2020-02-17 2020-06-09 腾讯科技(深圳)有限公司 一种缓存数据管理方法和相关装置
CN111506606A (zh) * 2020-04-14 2020-08-07 深圳市金蝶天燕云计算股份有限公司 一种报表查询方法及相关设备
US11636035B2 (en) * 2020-07-31 2023-04-25 Microsoft Technology Licensing, Llc Persisted data cache service
CN112307387A (zh) * 2020-10-30 2021-02-02 上海二三四五网络科技有限公司 一种动态时间段信息缓存的控制方法以及控制装置
CN113515530B (zh) * 2021-03-30 2023-06-13 贵州白山云科技股份有限公司 一种缓存对象更新方法、装置、设备及存储介质
CN113645309B (zh) * 2021-08-18 2024-08-06 浙江苍南仪表集团股份有限公司 多客户端数据差异化二次缓存及同步的处理方法及系统
KR20240003313A (ko) * 2022-06-30 2024-01-08 쿠팡 주식회사 데이터 제공 방법 및 그 장치
CN115438279B (zh) * 2022-08-10 2023-06-27 珠海金智维信息科技有限公司 数据可视化方法、装置、电子设备及介质
CN116701800A (zh) * 2023-08-07 2023-09-05 广州市千钧网络科技有限公司 页面内容处理方法、装置、计算机设备及介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110125901A1 (en) * 2009-11-23 2011-05-26 International Business Machines Corporation Dynamic property volatility assignment and assessment for distributed manageable resources
US20110173395A1 (en) * 2010-01-12 2011-07-14 International Business Machines Corporation Temperature-aware buffered caching for solid state storage
US20130024421A1 (en) * 2011-07-22 2013-01-24 Hitachi, Ltd. File storage system for transferring file to remote archive system
CN103853671A (zh) * 2012-12-07 2014-06-11 北京百度网讯科技有限公司 一种数据写入控制方法及装置
CN105138587A (zh) * 2015-07-31 2015-12-09 小米科技有限责任公司 数据访问方法、装置和系统

Family Cites Families (30)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6182122B1 (en) 1997-03-26 2001-01-30 International Business Machines Corporation Precaching data at an intermediate server based on historical data requests by users of the intermediate server
US5897634A (en) 1997-05-09 1999-04-27 International Business Machines Corporation Optimized caching of SQL data in an object server system
US7801913B2 (en) 1998-12-07 2010-09-21 Oracle International Corporation System and method for querying data for implicit hierarchies
US6587856B1 (en) 1998-12-07 2003-07-01 Oracle International Corporation Method and system for representing and accessing object-oriented data in a relational database system
US6934699B1 (en) 1999-09-01 2005-08-23 International Business Machines Corporation System and method for loading a cache with query results
US20030188021A1 (en) * 2001-12-19 2003-10-02 International Business Machines Corporation Method and system for processing multiple fragment requests in a single message
US20030221068A1 (en) * 2002-05-23 2003-11-27 Michael Tsuji Method and system for data cache
ES2348260T3 (es) 2003-01-31 2010-12-02 Visto Corporation Recuperacion asincrona de datos en tiempo real.
CA2425046C (en) 2003-04-08 2009-10-06 Ibm Canada Limited - Ibm Canada Limitee Method and system for caching database query statements
US8019735B2 (en) 2004-05-21 2011-09-13 Oracle International Corporation Systems and methods for query caching
US7461206B2 (en) * 2006-08-21 2008-12-02 Amazon Technologies, Inc. Probabilistic technique for consistency checking cache entries
US20080098093A1 (en) 2006-10-16 2008-04-24 Palm, Inc. Offline automated proxy cache for web applications
US8296394B1 (en) 2007-04-10 2012-10-23 AT & T Intellectual Property II, LP Method and system for caching real-time data
US8060486B2 (en) 2007-05-07 2011-11-15 Hewlett-Packard Development Company, L.P. Automatic conversion schema for cached web requests
US8032714B2 (en) 2007-09-28 2011-10-04 Aggregate Knowledge Inc. Methods and systems for caching data using behavioral event correlations
US7865573B2 (en) 2008-05-29 2011-01-04 Research In Motion Limited Method, system and devices for communicating between an internet browser and an electronic device
US8108587B2 (en) 2009-05-26 2012-01-31 Microsoft Corporation Free-space reduction in cached database pages
US8539160B2 (en) * 2009-09-10 2013-09-17 Red Hat, Inc. Asynchronous cache refresh for systems with a heavy load
US9235531B2 (en) 2010-03-04 2016-01-12 Microsoft Technology Licensing, Llc Multi-level buffer pool extensions
JP5387457B2 (ja) 2010-03-10 2014-01-15 富士電機株式会社 遠隔監視装置および該装置におけるデータアクセス方法
TW201145044A (en) * 2010-06-10 2011-12-16 Acer Inc Method for offline browse web pages and system thereof
EP2609517B1 (en) 2010-08-24 2020-04-01 BlackBerry Limited Constant access gateway and de-duplicated data cache server
JP5567967B2 (ja) * 2010-09-30 2014-08-06 インターナショナル・ビジネス・マシーンズ・コーポレーション データベースにおけるキャッシュ制御方法、システム及びプログラム
US9703706B2 (en) 2011-02-28 2017-07-11 Oracle International Corporation Universal cache management system
US9015269B2 (en) * 2012-06-19 2015-04-21 Canon Kabushiki Kaisha Methods and systems for notifying a server with cache information and for serving resources based on it
US9747288B1 (en) 2012-12-10 2017-08-29 Amazon Technologies, Inc. Scalable transaction-based data repository service
US9582604B2 (en) * 2013-03-27 2017-02-28 Thomson Licensing Caching mechanism to improve user interface responsiveness
US8886671B1 (en) 2013-08-14 2014-11-11 Advent Software, Inc. Multi-tenant in-memory database (MUTED) system and method
US9876873B1 (en) 2015-10-21 2018-01-23 Perfect Sense, Inc. Caching techniques
CN105335512B (zh) * 2015-10-30 2019-09-17 小米科技有限责任公司 数据查询方法及装置

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20110125901A1 (en) * 2009-11-23 2011-05-26 International Business Machines Corporation Dynamic property volatility assignment and assessment for distributed manageable resources
US20110173395A1 (en) * 2010-01-12 2011-07-14 International Business Machines Corporation Temperature-aware buffered caching for solid state storage
US20130024421A1 (en) * 2011-07-22 2013-01-24 Hitachi, Ltd. File storage system for transferring file to remote archive system
CN103853671A (zh) * 2012-12-07 2014-06-11 北京百度网讯科技有限公司 一种数据写入控制方法及装置
CN105138587A (zh) * 2015-07-31 2015-12-09 小米科技有限责任公司 数据访问方法、装置和系统

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP3418911A4 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110209968A (zh) * 2019-04-24 2019-09-06 北京奇艺世纪科技有限公司 一种数据存储系统、方法、装置及计算机可读存储介质

Also Published As

Publication number Publication date
US20190034550A1 (en) 2019-01-31
TWI665569B (zh) 2019-07-11
US11449570B2 (en) 2022-09-20
JP6748734B2 (ja) 2020-09-02
EP3418911A1 (en) 2018-12-26
CN107291756A (zh) 2017-10-24
KR20180125009A (ko) 2018-11-21
EP3418911A4 (en) 2019-11-06
SG11201808173RA (en) 2018-10-30
PH12018502065A1 (en) 2019-06-24
MY190884A (en) 2022-05-17
KR102232813B1 (ko) 2021-03-29
JP2019512819A (ja) 2019-05-16
TW201738783A (zh) 2017-11-01

Similar Documents

Publication Publication Date Title
WO2017167039A1 (zh) 数据缓存的方法及装置
JP6122199B2 (ja) 検索結果へのアクセスを改良するシステム、方法及び記憶媒体
US7974970B2 (en) Detection of undesirable web pages
EP3146698B1 (en) Method and system for acquiring web pages
US9721015B2 (en) Providing a query results page
US9021087B1 (en) Method to improve caching accuracy by using snapshot technology
JP6995211B2 (ja) 強化されたオンラインプライバシ
US10120849B2 (en) Document generation based on referral
CN109376318A (zh) 一种页面加载方法、计算机可读存储介质及终端设备
US11775518B2 (en) Asynchronous predictive caching of content listed in search results
US9195944B1 (en) Scoring site quality
CN110889073B (zh) 页面请求的响应方法、服务器及计算机存储介质
US11055223B2 (en) Efficient cache warm up based on user requests
CN109214884B (zh) 需求撮合方法及装置、电子设备
US11893138B2 (en) Dynamic trigger of web beacons
US9692633B2 (en) Role-based resource navigation
US20240211962A1 (en) System and method for augmentation of inclusive knolwedge recall outcomes

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 2017773069

Country of ref document: EP

WWE Wipo information: entry into national phase

Ref document number: 11201808173R

Country of ref document: SG

ENP Entry into the national phase

Ref document number: 2018551171

Country of ref document: JP

Kind code of ref document: A

Ref document number: 2017773069

Country of ref document: EP

Effective date: 20180917

NENP Non-entry into the national phase

Ref country code: DE

ENP Entry into the national phase

Ref document number: 20187031539

Country of ref document: KR

Kind code of ref document: A

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17773069

Country of ref document: EP

Kind code of ref document: A1