主权项 |
1. A method comprising:
receiving, by a server, a pre-fetching request from a client; after receiving the pre-fetching request, determining, by the server, whether the client provided the expiration time of the pre-fetching request; in response to determining that the client did not provide the expiration time, setting, by the server, the expiration time of the pre-fetching request, such that the server specifies the expiration time; in response to determining that the client did provide the expiration time, setting, by the server, the expiration time of the pre-fetching request as provided by the client, such that the client specifies the expiration time; after setting the expiration time of the pre-fetching request, storing, by the server, the pre-fetching request within a pre-fetching request storage area of the server different from an actual request storage area of the server in which non-prefetching requests are stored; after storing the pre-fetching request within the pre-fetching request storage area, assigning, by the server, the pre-fetching request a dynamic priority that changes over time based on a length of time that the pre-fetching request remains in the pre-fetching request storage area; regardless of whether any non-prefetching requests are stored in the actual request storage area, at a point in time at which the dynamic priority of the prefetching request exceeds a priority threshold, removing, by the server, the pre-fetching request from the pre-fetching request storage area; after removing the pre-fetching request from the pre-fetching request storage area, determining, by the server, whether the pre-fetching request has expired based on an expiration time thereof; in response to determining that the pre-fetching request has expired, discarding, by the server, the pre-fetching request, such that the pre-fetching request is not executed; and in response to determining that the pre-fetching request has not expired, executing, by the server, the pre-fetching request, and storing, by the server, the data that has been received for subsequent fulfillment of an actual request for the data. |