Cloud storage space management method and device
The cloud storage space management method addresses the challenge of managing large data volumes by dynamically adjusting update frequencies based on user activity, enhancing data consistency and timeliness while optimizing storage resource utilization.
Patent Information
- Application Number
- CN202411077807.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-07
- Publication Date
- 2024-12-03
- Estimated Expiration
- 2044-08-07
AI Technical Summary
Existing cloud storage systems face challenges in achieving data consistency and timeliness while efficiently utilizing storage space and avoiding network congestion, especially when dealing with large volumes of data.
A cloud storage space management method that determines a time window based on user file requests, calculates upload and download data within that window, performs activity evaluation, and adjusts the frequency of space updates using a frequency adjustment coefficient to optimize storage resource utilization.
The method effectively manages cloud storage space by dynamically adjusting update frequencies based on user activity, reducing network congestion and optimizing resource use.
Smart Images

Figure CN119071311A_ABST
Abstract
Description
Technical Field
[0001] This document relates to the field of Internet technology, and in particular to a cloud storage space management method and device. Background Art
[0002] With the continuous development of Internet technology, cloud storage has become an important means for individuals and enterprises to store data. However, with the growth of data volume, efficient management and utilization of storage space has become increasingly important.
[0003] At present, cloud storage services usually update storage space regularly to achieve consistency and integrity of file storage. However, when the amount of data is small, updating the storage space with a fixed update frequency can ensure data consistency and timeliness. However, when the amount of data is huge, if all files are updated in real time, it may cause a waste of storage space computing power and cause congestion in the upload or download channels, reducing the user experience. Therefore, how to achieve data consistency and timeliness when the amount of data is huge while effectively utilizing storage space and avoiding network congestion has become a problem that needs to be solved urgently. Summary of the invention
[0004] An embodiment of the present specification aims to provide a cloud storage space management method and device to achieve reasonable utilization of cloud storage space resources.
[0005] To solve the above technical problems, an embodiment of this specification is implemented as follows:
[0006] In a first aspect, an embodiment of the present specification provides a cloud storage space management method, including:
[0007] Determine a time window based on the user's file request for the cloud storage space, and calculate the upload and download data according to the user's file processing record within the time window;
[0008] Inputting the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculating a frequency adjustment coefficient based on the obtained activity evaluation value;
[0009] Calculating a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping;
[0010] Based on the target space update frequency, files are updated on the remaining storage space of the user in the cloud storage space.
[0011] In a second aspect, another embodiment of the present specification provides a cloud storage space management device, including:
[0012] A data calculation module is configured to determine a time window based on a user's file request for a cloud storage space, and calculate upload and download data according to the user's file processing record within the time window;
[0013] A coefficient acquisition module is configured to input the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculate a frequency adjustment coefficient according to the obtained activity evaluation value;
[0014] A frequency calculation module, configured to calculate a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping;
[0015] The file update module is configured to update files on the remaining storage space of the user in the cloud storage space based on the target space update frequency.
[0016] In a third aspect, another embodiment of the present specification provides a cloud storage space management device, comprising: a memory, a processor, and computer executable instructions stored on the memory and executable on the processor, wherein the computer executable instructions, when executed by the processor, implement the steps of the cloud storage space management method as described in the first aspect above.
[0017] In a fourth aspect, another embodiment of the present specification provides a computer-readable storage medium, wherein the computer-readable storage medium is used to store computer-executable instructions, and when the computer-executable instructions are executed by a processor, the steps of the cloud storage space management method as described in the first aspect above are implemented.
[0018] In a fifth aspect, another embodiment of the present specification provides a computer program product, wherein the computer program product includes a cloud storage space management program, and the cloud storage space management program is executed by a processor to implement the steps of the cloud storage space management method as described in the first aspect above.
[0019] The cloud storage space management method provided in this embodiment first determines a time window based on the user's file request for the cloud storage space, calculates the upload and download data according to the user's file processing record within the time window, and then inputs the upload and download data into an activity evaluation algorithm for activity evaluation, and calculates a frequency adjustment coefficient according to the obtained activity evaluation value, and then calculates a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data, and finally based on the target space update frequency, performs file updates on the user's remaining storage space in the cloud storage space. The cloud storage space management is performed through the above method to achieve reasonable utilization of cloud storage space resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in one or more embodiments of the present specification, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present specification. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0021] Figure 1 A cloud storage space management process flow chart provided for one embodiment of this specification;
[0022] Figure 2 A schematic diagram of a time window provided for one embodiment of this specification;
[0023] Figure 3 A processing flow chart of a cloud storage space management method applied to a remaining storage space management scenario provided by an embodiment of this specification;
[0024] Figure 4 A schematic diagram of a cloud storage space management processing device provided in one embodiment of this specification;
[0025] Figure 5 A schematic diagram of the structure of a cloud storage space management processing device provided in one embodiment of the present specification. DETAILED DESCRIPTION
[0026] In order to enable those skilled in the art to better understand the technical solutions in one or more embodiments of this specification, the following will be combined with the drawings in one or more embodiments of this specification to clearly and completely describe the technical solutions in one or more embodiments of this specification. Obviously, the described embodiments are only part of the embodiments of this specification, not all of them. Based on one or more embodiments of this specification, all other embodiments obtained by ordinary technicians in this field without creative work should fall within the scope of protection of this document.
[0027] This specification provides a cloud storage space management method embodiment:
[0028] Reference Figure 1 , which shows a processing flow chart of a cloud storage space management method provided in this embodiment. The cloud storage space management method provided in this embodiment specifically includes the following steps S102 to S108.
[0029] Step S102: determining a time window based on the user's file request for the cloud storage space, and calculating upload and download data according to the user's file processing record within the time window.
[0030] The time window refers to a specific time period used to obtain and analyze the user's file request activities in the cloud storage space. This time period can be used to define which file upload or download requests will be included in the current data processing and analysis cycle, providing a start and end time for processing and analyzing the user's file processing records.
[0031] The upload and download data refers to the upload and download frequency and upload and download volume calculated by the user based on the corresponding file processing records within a specified time window.
[0032] In specific implementation, file requests from users for cloud storage space are received in real time, corresponding file operations are performed based on these file requests, and file processing records corresponding to the file operations are recorded, including data such as file size, operation time, and operation type. At the same time, a specified time window length is preset to define the time window, and the file processing records obtained in real time are filtered and cached based on the time window. When a file request from a user for cloud storage space arrives, the corresponding time window is determined based on the file request. In an optional implementation manner provided by this embodiment, the time window is determined based on the file request of the cloud storage space, including:
[0033] The time window is determined according to the timestamp and the time window length carried by the file request.
[0034] The time window length refers to the specific duration of each time window from the beginning to the end. For example, if the time window length is set to 5 minutes, each time window will cover file requests within 5 minutes from its start time. The time window length can be adjusted according to actual needs to adapt to data analysis and management requirements of different granularities.
[0035] During the specific execution process, the specified time window length is first preset. When the user initiates a file request, the specific time point when the file request occurs is recorded, which is the timestamp. Check whether the timestamp falls within the current time window. If so, the file request is included in the file request processing record set of the current time window; if not, check whether the current time window has ended. If so, close the current time window and open a new time window, and at the same time attribute the file request to the new time window.
[0036] Optionally, the time window can be processed using a sliding time window algorithm; that is, as time goes on, the status of the current time window will be checked periodically. If the current time exceeds the end time of the time window, the current time window will be closed and a new time window will be opened immediately. The start time of the new time window is the current time, and the end time is the start time plus the preset time window length. Based on this, the time window corresponding to each file request can be determined according to the timestamp and the time window length.
[0037] For example, the preset time window length is 5 minutes. If the current system time is 09:12:00, according to the time window length, the current time window starts from 09:07:00 and ends at 09:12:00. When user A initiates a file upload request at 09:10:30, the timestamp of the upload request is recorded as 09:10:30. Because 09:10:30 is within the time range of 09:07:00 to 09:12:00, the upload request belongs to the current Time window; when user B initiates a file download request at 09:13:05, the timestamp of the download request is recorded as 09:13:05. Since 09:13:05 is not within the current time window (09:07:00 to 09:12:00), the current time window is closed and a new time window is opened. The new time window starts from 09:12:00 and ends at 09:17:00. Therefore, the timestamp 09:13:05 belongs to the new time window.
[0038] In specific implementation, after determining the time window according to the timestamp carried by the file request and the preset time window length, the file processing record within the time window is determined based on the time window, and the corresponding upload and download data is calculated for these file processing records. In an optional implementation provided by this embodiment, the upload and download data is calculated according to the file processing record of the user within the time window, including:
[0039] Deleting the file processing records in the historical time window before the start of the time window;
[0040] Calculate the file upload and download frequency corresponding to the file processing record of the user within the time window, extract the file size in the file processing record within the time window, calculate the file upload and download amount, and use the upload and download frequency and the upload and download amount as the upload and download data.
[0041] During the specific execution process, when a user initiates a file request for the cloud storage space, such as uploading a file, downloading a file, etc., these file requests are recorded and form corresponding file processing records. Each file processing record contains an operation timestamp, user identifier, file size, operation type, etc. After the time window is determined based on the timestamp carried by the file request and the preset time window length, all valid file processing records in the time window are screened out, that is, the file processing records in the historical time window before the start time of the current time window are deleted, and for the remaining file processing records, the number of file requests executed by the user in the time window is counted, and the obtained number is the file upload and download frequency; at the same time, for the remaining file processing records, the file size information in each record is extracted, and the sizes of all files in the time window are accumulated, and the result is the file upload and download volume.
[0042] For example, Figure 2 As shown, when a user initiates a file request for a cloud storage space, these file requests are recorded and corresponding file processing records are formed. The time window 201 is determined based on the timestamp carried by the file request and the preset time window length. Since the time window can be processed using a sliding time window algorithm, when the time window 201 slides forward, if the data block in the time window 201 exceeds the time window 201, the data block will be determined to be "abandoned", that is, the file processing record corresponding to the data block is no longer calculated in the file processing record of the current time window, that is, the file processing record corresponding to the data block a is deleted, and the file processing records in the time window are retained, that is, the file processing records corresponding to the data blocks b, c, and d are retained. Based on the data blocks b, c, and d, the corresponding upload and download frequencies are obtained by statistics.
[0043] In actual applications, users can store files in cloud storage space and perform transfer operations on files, that is, users perform operations such as moving files in cloud storage space, transfer files from the original storage location to another location (such as an external hard disk) or send target files to other users. Since the files are sent to other users, they are not added to the remaining storage space of the user in the cloud storage space. Therefore, the transfer operation only generates corresponding file transfer records and does not involve changes to the remaining storage space size of the user in the cloud storage space. In order to obtain an accurate remaining storage space size for subsequent calculations, in an optional implementation manner provided by this embodiment, a time window is determined based on the user's file request for the cloud storage space, and before calculating the upload and download data according to the user's file processing record within the time window, the following is also included:
[0044] If a file transfer request is received from the user, the file transfer process is performed and a file transfer record is generated.
[0045] The file transfer refers to a file request by a user to perform operations such as moving a file in a cloud storage space. This operation can transfer a file from one location to another, such as sending a target file to other users.
[0046] During the specific execution process, the cloud storage space receives users' file requests in real time and identifies file transfer requests among these file requests. When a file transfer request is detected, the corresponding file operation is performed and the file is sent to the target user. For each completed file transfer operation, a corresponding file transfer record will be generated, including but not limited to information such as the time of the operation, the source file path, and the target file path.
[0047] Optionally, the file processing record of the user within the time window includes the file transfer record; and the file transfer request file is not stored in the remaining storage space.
[0048] Specifically, since the file is sent to other users and not added to the remaining storage space of the user, it is equivalent to not adding new data to the remaining storage space, that is, the transfer operation only generates a corresponding file transfer record, and does not involve changes to the size of the remaining storage space of the user in the cloud storage space; in addition, the transfer operation may also involve a file transfer operation, that is, transferring the file from the original location to the target location. Accordingly, for each completed file transfer operation, a corresponding file transfer record will also be generated. At this time, since the file is transferred to the user's private storage space (such as a mobile hard disk), the operation will not change the size of the remaining storage space of the user in the cloud storage space.
[0049] In this embodiment, the storage and management of files in the cloud storage space can also be performed in a key-value pair manner, that is, based on the user's file request, a unique key is allowed to directly implement fast access, operation or management of the file, thereby simplifying the file retrieval process. In an optional implementation manner provided by this embodiment, the cloud storage space uses a key-value pair manner to store data;
[0050] If it is detected that the key-value pair is expired, the storage space occupied by the key-value pair is released, and the size of the remaining storage space is updated.
[0051] The key-value pair refers to storing and retrieving related data in the cloud storage space by associating two related data items: key and value. When a user uploads a file, a unique key is generated for the file, and the content of the file is associated with the key as the value. Based on this, when the user wants to access or retrieve a file, he only needs to provide the key of the file to retrieve the corresponding file content, thereby improving the efficiency of retrieval.
[0052] During the specific execution process, the status of the key-value pairs in the cloud storage space is continuously monitored. When a key-value pair is found to be expired, that is, the validity period of the file or data represented by the key-value pair has expired, the storage space occupied by the key-value pair is released, and the user's remaining storage space size in the cloud storage space is updated. Through this process, the storage resources occupied by expired files are effectively managed and recovered, thereby optimizing the operating efficiency of the cloud storage space, and providing users with more accurate and real-time remaining storage space usage information.
[0053] For example, user A's storage quota in the cloud storage space is 10GB. After user A uploads some files, the current remaining storage space is 5GB. If there is a 2GB file whose validity period has expired but has not been deleted, the file will occupy 2GB of space. When this expired file is detected, the 2GB occupied will be removed from the remaining storage space first, and then user A's remaining storage space will be updated to 3GB (original remaining storage space 5GB-space occupied by expired files 2GB=3GB).
[0054] Step S104: input the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculate a frequency adjustment coefficient according to the obtained activity evaluation value.
[0055] The activity assessment refers to the process of quantitatively analyzing the user's upload and download frequency and upload and download volume within a specified time window. This process is based on the user's upload and download frequency, upload and download volume and other data obtained, and uses a preset activity assessment algorithm to calculate an activity assessment value. The activity assessment value can reflect the frequency of the user's use of the cloud storage space within a certain period of time.
[0056] During specific implementation, the user's upload and download frequency and upload and download volume within a specified time window are obtained, and according to a preset activity evaluation algorithm, the obtained upload and download frequency and upload and download volume are input into the activity evaluation algorithm to calculate the activity evaluation value corresponding to the user in the specified time window. The higher the activity evaluation value, the more frequent the user's activity within the specified time window, and the greater the demand for the use of cloud storage space.
[0057] In the specific execution process, firstly, the upload and download data of the user within the specified time window is obtained, and the obtained upload and download data is analyzed according to the preset activity evaluation algorithm to calculate a preliminary activity score, which reflects the activity level of the user within a certain period of time. In an optional implementation manner provided by this embodiment, the upload and download data is input into the activity evaluation algorithm for activity evaluation, including:
[0058] Calculate the ratio of the upload and download frequency to the preset critical frequency to obtain a frequency ratio;
[0059] Calculate the ratio of the upload and download volume to the average upload and download volume in multiple historical time windows to obtain a volume ratio;
[0060] Based on the timestamp carried by the file request, the remaining storage space size corresponding to the timestamp is obtained, and the space ratio is obtained by calculating the ratio of the remaining storage space corresponding to the timestamp to the maximum storage space;
[0061] An activity evaluation calculation is performed according to the frequency ratio, the quantity ratio, the space ratio and preset parameters to obtain the activity evaluation value.
[0062] For example, the activity evaluation value F(T i ), can be calculated using the following formula:
[0063]
[0064] Where, 1≤i≤n, c is a preset constant parameter, t is the timestamp of the specified request, W t is the remaining storage space at time t, W is the maximum storage space, T i is the i-th specified time window, K(T n ) is the upload and download volume in the nth specified time window, N(T i ) is the upload and download frequency in the i-th specified time window, and Ns is the critical frequency.
[0065] Specifically, when the remaining storage space W t Reduce, space ratio Reduce, Increase, thereby improving F(T i ) value; similarly, the quantitative ratio Reflects the ratio of the upload and download volume in the i-th specified time window to the average upload and download volume in the n historical specified time windows. The larger the ratio, the more active the uplink and downlink activities in the i-th specified time window. When the upload and download frequency increases suddenly, F(T i ) value.
[0066] In this embodiment, after the activity evaluation value is calculated by the activity evaluation algorithm based on the upload and download data of the user within the specified time window, the frequency adjustment coefficient can be calculated based on the obtained activity evaluation value, that is, the obtained activity evaluation value can be mapped to a fixed range (such as between 0 and 1), and the obtained activity evaluation value is normalized to ensure the comparability between different user activity levels, and the corresponding frequency adjustment coefficient is calculated based on the normalized activity evaluation value.
[0067] Among them, normalization means that since the file upload and download volumes of different users in the cloud storage space may vary greatly, it may be difficult to obtain relatively accurate results by directly comparing the activity evaluation values of each user. Therefore, the activity evaluation value of each user is normalized, that is, it is adjusted to the same standard (such as between 0 and 1) through mathematical transformation, so that the activity evaluation values of users with different upload and download volumes are comparable.
[0068] For example, based on all historical activity evaluation values, the activity evaluation value F(T i ) is normalized in direct proportion to obtain the corresponding normalized score Fc(T i ); According to the normalized score Fc(T i ) to calculate the frequency adjustment coefficient α; the frequency adjustment coefficient α can be calculated using the following formula:
[0069]
[0070] Where k is a preset constant, which can be set to 1, r is the amplification factor, Fc(T i )∈(0,1].
[0071] In actual applications, a cloud storage space service may have a membership authority system. The membership authority of a user may have a direct impact on his / her use of the cloud storage space. For example, a user with membership authority may enjoy a larger storage space in the cloud storage space. Therefore, in order to ensure the accuracy of the activity evaluation, it is necessary to first detect the user's membership authority status. In an optional implementation manner provided by this embodiment, before the upload and download data is input into the activity evaluation algorithm for activity evaluation, it also includes:
[0072] receiving a file request from the user for the cloud storage space, and detecting whether the membership privilege of the user has expired;
[0073] If yes, performing an accumulation operation on the remaining storage space of the user in the cloud storage space to obtain the remaining storage space size after the accumulation operation;
[0074] If not, a cumulative subtraction operation is performed on the remaining storage space of the user in the cloud storage space to obtain the remaining storage space size after the cumulative operation.
[0075] During the specific implementation process, after receiving a file request from a user for the cloud storage space, it is first detected whether the user is a member user. If so, it is further detected whether the term of the user's membership rights has expired. If not, the user's membership rights are valid. At this time, if the file request requires additional storage space (such as uploading large files), the user's remaining storage space will be accumulated, that is, the additional storage space corresponding to the value-added service of the membership rights will be increased, and after the file operation is completed, the remaining storage space size displayed on the user interface will be updated, that is, the actual remaining storage space of the cloud storage space after uploading the large file and performing the accumulation operation; if the term of the membership rights expires, the remaining storage space of the user in the cloud storage space will be subtracted, that is, the additional storage space corresponding to the value-added service of the membership rights will be removed from the remaining storage space of the user's cloud storage space. Through this process, a more accurate remaining storage space size of the user can be obtained, thereby improving the accuracy of subsequent activity evaluation.
[0076] Step S106, calculating a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping.
[0077] The above method determines the time window based on the user's file request for the cloud storage space, calculates the upload and download data according to the user's file processing record within the time window, and inputs the upload and download data into the activity evaluation algorithm for activity evaluation. After the obtained activity evaluation value is normalized to obtain the frequency adjustment coefficient, in this step, the target space update frequency is calculated according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data.
[0078] In specific implementation, in order to adapt to the usage habits of different users and provide a more flexible target space update frequency, an optional implementation provided by this embodiment includes, before calculating the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping, the following steps are also included:
[0079] A corresponding preset range is queried in a correspondence table according to the upload and download frequencies, and the initial space update frequency is determined based on the preset range.
[0080] During the specific execution process, the user's file requests for cloud storage space are obtained in real time, corresponding file operations are performed based on these file requests, and file processing records corresponding to the file operations are recorded within a specified time window. The number of file requests executed by the user within the time window is counted according to the file processing records to obtain the upload and download frequencies, and then the preset range of the corresponding initial space update frequency is searched in the preset correspondence table, and the initial space update frequency used by the user is determined based on the preset range in the correspondence table.
[0081] For example, when the file upload times range is [50, 100), the initial space update frequency can be updated to once every 5 minutes; when the file upload times range is [100, 200), the initial space update frequency can be updated to once every 3 minutes; when the file upload times range is [200, 500), the initial space update frequency can be updated to once every 1 minute.
[0082] It should be noted that the process of obtaining the initial space update frequency based on the upload and download frequency table lookup can be performed after determining the time window based on the user's file request for the cloud storage space and calculating the upload and download data according to the user's file processing record within the time window. It can also be performed after inputting the upload and download data into the activity evaluation algorithm for activity evaluation and normalizing the obtained activity evaluation value to obtain the frequency adjustment coefficient.
[0083] Specifically, the upload and download frequency of the user within the specified time window is obtained, and after the initial space update frequency used by the user is determined based on the preset range corresponding to the upload and download frequency in the correspondence table, an optional implementation manner provided by this embodiment calculates the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data, including:
[0084] The initial space update frequency is weighted by taking the frequency adjustment coefficient as a weight to obtain the target space update frequency.
[0085] For example, when the frequency adjustment coefficient is α and the initial space update frequency is P0, the target space update frequency P can be calculated as follows:
[0086] P=P0*α
[0087] Among them, P is the target space update frequency, P0 is the initial space update frequency, and α is the frequency adjustment coefficient; due to the normalized score Fc(T i ) and activity evaluation value F(T i ) is in direct proportion, F(T i ) is larger, Fc(T i ) is larger and closer to 1, the smaller α is obtained, so the initial space update frequency can be adjusted significantly.
[0088] Step S108: updating files in the remaining storage space of the user in the cloud storage space based on the target space update frequency.
[0089] The above method first determines the time window based on the user's file request for the cloud storage space, calculates the upload and download data according to the user's file processing record within the time window, and then inputs the upload and download data into the activity evaluation algorithm for activity evaluation, and normalizes the obtained activity evaluation value to obtain the frequency adjustment coefficient. Finally, according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data, the target space update frequency is calculated. In this step, based on the calculated target space update frequency, the file of the user's remaining storage space in the cloud storage space is updated.
[0090] In specific implementation, based on the user's upload and download data within a specified time window, the frequency adjustment coefficient for the user can be calculated, and then the target space update frequency suitable for the user can be obtained. According to the target space update frequency, the file update operation can be executed, thereby optimizing the use of storage space and improving overall performance. At the same time, this process can also realize dynamic adjustment of the target space update frequency, so that the frequency of file updates in the cloud storage space can be adjusted according to the user's activity and needs, so as to reduce network congestion and avoid waste of resources.
[0091] In actual applications, before updating files, a timer may be configured, and the files in the cloud storage space may be updated periodically based on the countdown set by the timer. In an optional implementation provided by this embodiment, after calculating the target space update frequency based on the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping, and before updating the files in the remaining storage space of the user in the cloud storage space based on the target space update frequency, the following is further included:
[0092] Configure a countdown of a timer based on the target space update frequency;
[0093] When it is detected that the countdown of the timer is 0, files are updated in the remaining storage space of the user in the cloud storage space.
[0094] During the specific execution process, based on the user's upload and download data within the specified time window, the frequency adjustment coefficient for the user can be calculated, and then the target space update frequency suitable for the user can be obtained. The corresponding timer with a countdown is set according to the target space update frequency. The higher the target space update frequency, the faster the file update speed. Correspondingly, the smaller the countdown value set by the timer is. When the countdown ends, that is, the countdown of the timer is 0, the file will be automatically updated, and the remaining storage space size of the user in the cloud storage space will be updated accordingly.
[0095] For example, in the correspondence table, when the file upload times range is [100, 200), the initial space update frequency can be updated to once every 3 minutes. If the frequency adjustment coefficient calculated based on the upload and download data of user A in the specified time window is 0.7, and the number of file uploads by user A in the specified time window is 150 times / minute, then the target space update frequency of user A can be calculated to be once every 2.1 minutes (3*0.7=2.1). Accordingly, a timer can be set with a countdown of 2.1 minutes. When the timer counts down (i.e., after 2.1 minutes), the file is updated, and the remaining storage space size of user A in the cloud storage space is updated accordingly.
[0096] To summarize, the cloud storage space management method provided in this embodiment first determines the time window based on the user's file request for the cloud storage space, calculates the upload and download data according to the user's file processing record within the time window, and then inputs the upload and download data into the activity evaluation algorithm for activity evaluation, and normalizes the obtained activity evaluation value to obtain the frequency adjustment coefficient, and then calculates the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data, and finally updates the file of the user's remaining storage space in the cloud storage space based on the target space update frequency, thereby realizing the rational use of cloud storage space resources.
[0097] The following combination Figure 3 , taking the application of the cloud storage space management method provided by this embodiment in the remaining storage space management scenario as an example, the cloud storage space management method provided by this embodiment is further explained. Figure 3 The cloud storage space management method applied to the remaining storage space management scenario specifically includes steps S302 to S332.
[0098] Step S302: receiving a file request from a user.
[0099] Step S304, check whether the user's membership privilege has expired, if so, execute step S306; if not, execute step S308.
[0100] Step S306, accumulating the remaining storage space of the user in the cloud storage space and obtaining the corresponding storage space size.
[0101] Step S308, the remaining storage space of the user in the cloud storage space is decremented and the corresponding storage space size is obtained.
[0102] Step S310: obtaining a file transfer request from a user.
[0103] Step S312, perform file transfer processing and generate a file transfer record.
[0104] Step S314: determine the time window according to the timestamp and time window length carried in the file request.
[0105] Step S316, deleting the file processing records in the historical time window before the start of the time window.
[0106] Step S318, calculating the file upload and download frequencies corresponding to the file processing records of the user within the time window.
[0107] Step S320, extracting the file sizes in the file processing records within the time window, and calculating the file upload and download amounts.
[0108] Step S322: Input the upload and download frequency and the upload and download volume into an activity evaluation algorithm to perform activity evaluation.
[0109] Step S324: normalize the obtained activity evaluation value to obtain a frequency adjustment coefficient.
[0110] Step S326, query the corresponding preset range in the correspondence table according to the upload and download frequencies to determine the initial space update frequency.
[0111] Step S328: weighting the initial spatial update frequency with the frequency adjustment coefficient as a weight to obtain a target spatial update frequency.
[0112] Step S330: configuring a countdown of a timer based on the target space update frequency.
[0113] Step S332, when it is detected that the countdown of the timer is 0, the file is updated on the remaining storage space of the user in the cloud storage space to achieve the management of the remaining storage space.
[0114] The cloud storage space management method provided in this embodiment first determines a time window based on the user's file request for the cloud storage space, calculates the upload and download data according to the user's file processing record within the time window, and then inputs the upload and download data into an activity evaluation algorithm for activity evaluation, and calculates a frequency adjustment coefficient according to the obtained activity evaluation value, and then calculates a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data, and finally updates the files of the user's remaining storage space in the cloud storage space based on the target space update frequency, thereby realizing the rational use of cloud storage space resources.
[0115] Figure 4 A schematic diagram of a cloud storage space management device provided by an embodiment of the present invention is shown in FIG. Figure 4 Said device comprises:
[0116] The data calculation module 402 is configured to determine a time window based on a user's file request for the cloud storage space, and calculate the upload and download data according to the user's file processing record within the time window;
[0117] The coefficient acquisition module 404 is configured to input the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculate a frequency adjustment coefficient according to the obtained activity evaluation value;
[0118] The frequency calculation module 406 is configured to calculate the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping;
[0119] The file update module 408 is configured to update files on the remaining storage space of the user in the cloud storage space based on the space update frequency.
[0120] The cloud storage space management device provided in this embodiment first determines the time window based on the user's file request for the cloud storage space by running the data calculation module 402, and calculates the upload and download data according to the file processing record of the user in the time window. Secondly, the coefficient acquisition module 404 is run to input the upload and download data into the activity evaluation algorithm for activity evaluation, and the frequency adjustment coefficient is calculated according to the obtained activity evaluation value. Subsequently, the frequency calculation module 406 is run to calculate the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data. Finally, the file update module 408 is run to update the file of the remaining storage space of the user in the cloud storage space based on the target space update frequency. The cloud storage space management is performed through the above method to realize the rational use of cloud storage space resources.
[0121] The cloud storage space management device provided in one embodiment of this specification can implement each process in the aforementioned method embodiment and achieve the same functions and effects, which will not be repeated here.
[0122] Furthermore, an embodiment of the present specification also provides a cloud storage space management device, Figure 5 A schematic diagram of a cloud storage space management device provided in one embodiment of this specification is shown in FIG. Figure 5 As shown, the device includes: a memory 501, a processor 502, a bus 503 and a communication interface 504. The memory 501, the processor 502 and the communication interface 504 communicate through the bus 503, and the communication interface 504 may include an input and output interface, which includes but is not limited to a keyboard, a mouse, a display, a microphone, a loudspeaker, etc.
[0123] Figure 5In the embodiment, the memory 501 stores computer executable instructions that can be run on the processor 502. When the computer executable instructions are executed by the processor 502, the following process is implemented:
[0124] Determine a time window based on the user's file request for the cloud storage space, and calculate the upload and download data according to the user's file processing record within the time window;
[0125] Inputting the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculating a frequency adjustment coefficient based on the obtained activity evaluation value;
[0126] Calculating a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping;
[0127] Based on the target space update frequency, files are updated on the remaining storage space of the user in the cloud storage space.
[0128] The cloud storage space management device provided in this embodiment, through the cooperation of the memory 501, the processor 502, the bus 503 and the communication interface 504, first determines the time window based on the user's file request for the cloud storage space, calculates the upload and download data according to the user's file processing record within the time window, and then inputs the upload and download data into the activity evaluation algorithm for activity evaluation, and calculates the frequency adjustment coefficient according to the obtained activity evaluation value, and then calculates the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data, and finally based on the space update frequency, updates the files of the user's remaining storage space in the cloud storage space.
[0129] The cloud storage space management device provided in one embodiment of this specification can implement each process in the aforementioned method embodiment and achieve the same functions and effects, which will not be repeated here.
[0130] Furthermore, another embodiment of the present specification provides a computer-readable storage medium, wherein the computer-readable storage medium is used to store computer-executable instructions, and when the computer-executable instructions are executed by a processor, the following process is implemented:
[0131] Determine a time window based on the user's file request for the cloud storage space, and calculate the upload and download data according to the user's file processing record within the time window;
[0132] Inputting the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculating a frequency adjustment coefficient based on the obtained activity evaluation value;
[0133] Calculating a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping;
[0134] Based on the target space update frequency, files are updated on the remaining storage space of the user in the cloud storage space.
[0135] The computer-readable storage medium provided in this embodiment first determines a time window based on a user's file request for a cloud storage space, calculates upload and download data based on the user's file processing record within the time window, then inputs the upload and download data into an activity evaluation algorithm for activity evaluation, and calculates a frequency adjustment coefficient based on the obtained activity evaluation value, then calculates a target space update frequency based on the frequency adjustment coefficient and an initial space update frequency mapped by the upload and download data, and finally updates files on the user's remaining storage space in the cloud storage space based on the target space update frequency.
[0136] The computer-readable storage medium includes a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk, etc.
[0137] The computer-readable storage medium provided in one embodiment of this specification can implement each process in the aforementioned method embodiment and achieve the same functions and effects, which will not be repeated here.
[0138] Furthermore, another embodiment of the present specification also provides a computer program product, which implements the following process when executed by a processor:
[0139] Determine a time window based on the user's file request for the cloud storage space, and calculate the upload and download data according to the user's file processing record within the time window;
[0140] Inputting the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculating a frequency adjustment coefficient based on the obtained activity evaluation value;
[0141] Calculating a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping;
[0142] Based on the target space update frequency, files are updated on the remaining storage space of the user in the cloud storage space.
[0143] The computer program product provided in this embodiment first determines a time window based on a user's file request for a cloud storage space, calculates upload and download data based on the user's file processing record within the time window, and then inputs the upload and download data into an activity evaluation algorithm to perform activity evaluation, and normalizes the obtained activity evaluation value to obtain a frequency adjustment coefficient, and then calculates a target space update frequency based on the frequency adjustment coefficient and an initial space update frequency mapped by the upload and download data, and finally performs file updates on the user's remaining storage space in the cloud storage space based on the target space update frequency.
[0144] The computer program product provided in one embodiment of this specification can implement each process in the aforementioned method embodiment and achieve the same functions and effects, which will not be repeated here.
[0145] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0146] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0147] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0148] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0149] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0150] Memory may include non-permanent storage in a computer-readable storage medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable storage medium.
[0151] Computer-readable storage media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer-readable instructions, data structures, program modules or other data. Examples of computer-readable storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable storage media does not include temporary computer-readable media (transitory media), such as modulated data signals and carrier waves.
[0152] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0153] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.
[0154] The above is only an embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.
Claims
1. A cloud storage space management method, characterized in that: The method comprises: Determine a time window based on the user's file request for the cloud storage space, and calculate the upload and download data according to the user's file processing record within the time window; Inputting the upload and download data into an activity evaluation algorithm to perform activity evaluation, and calculating a frequency adjustment coefficient based on the obtained activity evaluation value; Calculating a target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping; Based on the target space update frequency, files are updated on the remaining storage space of the user in the cloud storage space.
2. The cloud storage space management method according to claim 1, characterized in that: The calculating the upload and download data according to the file processing record of the user within the time window includes: Deleting the file processing records in the historical time window before the start of the time window; Calculate the file upload and download frequency corresponding to the file processing record of the user within the time window, extract the file size in the file processing record within the time window, calculate the file upload and download amount, and use the upload and download frequency and the upload and download amount as the upload and download data.
3. The cloud storage space management method according to claim 2, characterized in that: The step of inputting the upload and download data into an activity evaluation algorithm for activity evaluation includes: Calculate the ratio of the upload and download frequency to the preset critical frequency to obtain a frequency ratio; Calculate the ratio of the upload and download volume to the average upload and download volume in multiple historical time windows to obtain a volume ratio; Based on the timestamp carried by the file request, the size of the remaining storage space corresponding to the timestamp is obtained, and the ratio of the remaining storage space corresponding to the timestamp to the maximum storage space is calculated to obtain a space ratio; An activity evaluation calculation is performed according to the frequency ratio, the quantity ratio, the space ratio and preset parameters to obtain the activity evaluation value.
4. The cloud storage space management method according to claim 3, characterized in that: Before the upload and download data is input into the activity evaluation algorithm to perform the activity evaluation operation, the method further includes: receiving a file request from the user for the cloud storage space, and detecting whether the membership privilege of the user has expired; If yes, performing an accumulation operation on the remaining storage space of the user in the cloud storage space to obtain the remaining storage space size after the accumulation operation; If not, a cumulative subtraction operation is performed on the remaining storage space of the user in the cloud storage space to obtain the remaining storage space size after the cumulative operation.
5. The cloud storage space management method according to claim 1, characterized in that: The calculating the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping includes: The initial space update frequency is weighted by taking the frequency adjustment coefficient as a weight to obtain the target space update frequency.
6. The cloud storage space management method according to claim 1, characterized in that: The determining of the time window based on the user's file request for the cloud storage space, and calculating the upload and download data according to the user's file processing record within the time window, includes: If a file transfer request is received from the user, the file transfer process is performed and a file transfer record is generated; Determine a time window based on the user's file request for the cloud storage space, and calculate upload and download data based on the user's file processing record within the time window; The file processing record of the user within the time window includes the file transfer record; the file transfer request file is not stored in the remaining storage space.
7. The cloud storage space management method according to claim 1, characterized in that: After the step of calculating the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency of the upload and download data mapping is executed, and before the step of updating the file of the remaining storage space of the user in the cloud storage space based on the target space update frequency is executed, the method further includes: Configure a countdown of a timer based on the target space update frequency; When it is detected that the countdown of the timer is 0, files are updated in the remaining storage space of the user in the cloud storage space.
8. The cloud storage space management method according to claim 1, characterized in that: The cloud storage space uses key-value pairs to store data; If it is detected that the key-value pair is expired, the storage space occupied by the key-value pair is released, and the size of the remaining storage space is updated.
9. The cloud storage space management method according to claim 1, characterized in that: The determining of the time window based on the file request of the cloud storage space includes: The time window is determined according to the timestamp and the time window length carried in the file request of the user for the cloud storage space.
10. The cloud storage space management method according to claim 1, characterized in that: After the step of determining a time window based on the user's file request for the cloud storage space and calculating the upload and download data according to the user's file processing record within the time window is executed, and before the step of calculating the target space update frequency according to the frequency adjustment coefficient and the initial space update frequency mapped by the upload and download data is executed, the method further includes: A corresponding preset range is queried in a correspondence table according to the upload and download frequencies, and the initial space update frequency is determined based on the preset range.
Citation Information
Patent Citations
Information recommendation method and device and computer readable storage medium
CN114117221A
Data processing method and device, terminal equipment and storage medium
CN114880339A
Cloud storage management method and system based on big data
CN118075294A
Synchronizing file updates between two cloud controllers of a distributed filesystem
US20150370827A1
