CN-121996144-A - Data processing method, computing device, storage medium, and computer program product
Abstract
The embodiment of the specification relates to the technical field of computers, in particular to a data processing method, a computing device, a storage medium and a computer program product, wherein the data processing method comprises the steps of receiving a data reading request aiming at target written data in a target data writing unit, wherein the target data writing unit belongs to a data writing area, the data writing area is used for data writing, the target written data synchronously writes into the data writing area and a data reading and writing area, the data reading and writing area is used for data reading and data writing, and reading the target written data from the data reading and writing area under the condition that the target data writing unit does not meet preset storage conditions.
Inventors
- LI SHU
- ZHU FENG
Assignees
- 云智能资产控股(新加坡)私人股份有限公司
Dates
- Publication Date
- 20260508
- Application Date
- 20241104
Claims (17)
- 1.A data processing method, applied to a data storage device, comprising: Receiving a data reading request aiming at target written data in a target data writing unit, wherein the target data writing unit belongs to a data writing area, the data writing area is used for data writing, the target written data is synchronously written into the data writing area and a data reading area, and the data reading area is used for data reading and data writing; and under the condition that the target data writing unit does not meet the preset storage condition, reading the target written data from the data reading and writing area.
- 2. The method of claim 1, wherein the data writing area comprises a plurality of data writing units, each data writing unit comprises a plurality of data writing blocks, the target data writing unit is any one of the plurality of data writing units, the data reading and writing area comprises a plurality of data reading and writing blocks, and the number of the data writing blocks and the number of the data reading and writing blocks are determined according to a preset number proportion.
- 3. The method of claim 2, further comprising, prior to receiving a data read request for target written data in a target data write unit: And responding to a data writing request, and writing the data to be written carried in the data writing request into the data reading and writing area and the target data writing unit of the data writing area.
- 4. The method of claim 3, wherein writing the data to be written carried in the data writing request into the data reading and writing area includes: Under the condition that the data read-write area is determined to be in the data read process, after the data read is determined to be completed, writing the data to be written carried in the data write request into the data read-write area; reading the target written data from the data read-write area, comprising: and under the condition that the data read-write area is determined to be in the process of data writing, reading the target written data from the data read-write area after the data writing is completed.
- 5. A method according to claim 3, the method further comprising: And under the condition that the data read-write area meets the preset erasing condition, erasing the written data in the data read-write area to obtain a blank data read-write area so as to write the data to be written into the blank data read-write area.
- 6. The method according to claim 5, wherein the erasing process of the written data in the data read-write area further comprises: Responding to a data writing request, writing the data to be written carried in the data writing request into the data writing area, and caching the data to be written into a writing cache of the data storage device; after the blank data read-write area is obtained, the method further comprises the following steps: And writing the data cached in the write cache into the blank data read-write area.
- 7. The method of claim 6, wherein the erasing process of the written data in the data read-write area further comprises: And reading the cached data from the write cache in response to a data read request for the cached data in the write cache.
- 8. A method according to claim 3, further comprising: acquiring target data from the target data writing unit under the condition that the target data writing unit meets the preset storage condition and meets the preset recovery condition; Determining a blank data writing unit from the plurality of data writing units, and writing the target data into the blank data writing unit; And performing erasure processing on the written data in the target data writing unit, and determining the target data writing unit obtained after erasure as a blank data writing unit.
- 9. The method of claim 3, the data storage device further comprising a data cache region comprising a plurality of data cache blocks therein; The method further comprises the steps of: And under the condition that the target data writing unit meets the preset storage condition, accumulating the written data in the target data writing unit to obtain first accumulated data, and caching the first accumulated data into a first data cache block, wherein the first data cache block is any one data cache block in the plurality of data cache blocks.
- 10. The method of claim 9, after said buffering the first accumulated data into a first data buffering block, further comprising: Under the condition that the next target data writing unit meets the preset storage condition, accumulating the written data in the next target data writing unit to obtain second accumulated data; the first accumulated data is obtained from the first data cache block, the first accumulated data and the second accumulated data are accumulated to obtain target accumulated data, and the target accumulated data is cached to a second data cache block, wherein the second data cache block is any one data cache block except the first data cache block in the plurality of data cache blocks.
- 11. The method of claim 10, further comprising, after the obtaining the first accumulated data from the first data cache block: and erasing the first accumulated data cached in the first data cache block to obtain a blank data cache block.
- 12. The method of claim 9, further comprising: Acquiring written data in the target data writing unit under the condition that the target data writing unit meets the preset storage condition and meets the preset recovery condition; determining a target data cache block corresponding to the target data writing unit, and acquiring target accumulated data from the target data cache block; And updating the target accumulated data according to the data position information of the written data, the data position information of the target accumulated data and the data position information of a target data writing unit writing blank data writing unit in the target data writing unit to obtain updated accumulated data, and writing the updated accumulated data into a next data cache block of the target data cache block.
- 13. The method of claim 1, wherein, in a case where it is determined that the target data writing unit does not satisfy a preset storage condition, reading the target written data from the data reading-writing area, comprising: Determining the data amount of the written data in the target data writing unit; under the condition that the data quantity is determined to not meet a preset data threshold value, determining that the target data writing unit does not meet a preset storage condition; And reading the target written data from the data read-write area.
- 14. The method of claim 1, further comprising, after receiving a data read request for target written data in a target data write unit: And reading the target written data from the target data writing unit under the condition that the target data writing unit meets the preset storage condition.
- 15. A computing device, comprising: A memory and a processor; the memory is adapted to store a computer program/instruction, the processor being adapted to execute the computer program/instruction, which when executed by the processor performs the steps of the method of any of claims 1 to 14.
- 16. A computer readable storage medium storing a computer program/instruction which, when executed by a processor, implements the steps of the method of any one of claims 1 to 14.
- 17. A computer program product comprising computer programs/instructions which, when executed by a processor, implement the steps of the method of any of claims 1 to 14.
Description
Data processing method, computing device, storage medium, and computer program product Technical Field Embodiments of the present disclosure relate to the field of computer technology, and in particular, to a data processing method, a computing device, a storage medium, and a computer program product. Background In today's data-intensive applications, such as high-performance computing, big data analysis, real-time transaction systems, and cloud services, rapid access to data is a critical requirement. The random read-write operation refers to the operation that the system performs reading or writing of data according to any position on the random access storage device. Such operations place higher demands on the performance of the storage system than sequential reads and writes. However, in the current random read-write operation process of the data storage device, data is continuously written and simultaneously read randomly, because the data storage unit in the data storage device can only execute one of the write operation and the read operation at the same time, when the read operation and the write operation need to be performed simultaneously, waiting is generated due to conflict, thereby causing delay increase and affecting the data read-write performance of the data storage device. Disclosure of Invention In view of this, the present embodiments provide a data processing method. One or more embodiments of the present specification are also directed to a data processing apparatus, a computing device, a computer-readable storage medium, and a computer program product that address the deficiencies of the prior art. According to a first aspect of embodiments of the present specification, there is provided a data processing method, applied to a data storage device, including: Receiving a data reading request aiming at target written data in a target data writing unit, wherein the target data writing unit belongs to a data writing area, the data writing area is used for data writing, the target written data is synchronously written into the data writing area and a data reading area, and the data reading area is used for data reading and data writing; and under the condition that the target data writing unit does not meet the preset storage condition, reading the target written data from the data reading and writing area. According to a second aspect of embodiments of the present specification, there is provided a data processing apparatus for application to a data storage device, comprising: A receiving module configured to receive a data reading request for target written data in a target data writing unit, wherein the target data writing unit belongs to a data writing area, the data writing area is used for data writing, the target written data is synchronously written into the data writing area and a data reading area, and the data reading area is used for data reading and data writing; And the reading module is configured to read the target written data from the data reading and writing area under the condition that the target data writing unit is determined not to meet the preset storage condition. According to a third aspect of embodiments of the present specification, there is provided a computing device comprising: A memory and a processor; the memory is used for storing computer programs/instructions, and the processor is used for executing the computer programs/instructions, and the computer programs/instructions realize the steps of the data processing method when being executed by the processor. According to a fourth aspect of embodiments of the present specification, there is provided a computer readable storage medium storing a computer program/instruction which, when executed by a processor, implements the steps of the data processing method described above. According to a fifth aspect of embodiments of the present specification, there is provided a computer program product comprising computer programs/instructions which, when executed by a processor, implement the steps of the data processing method described above. One embodiment of the specification provides a data processing method applied to a data storage device, which comprises the steps of receiving a data reading request aiming at target written data in a target data writing unit, wherein the target data writing unit belongs to a data writing area, the data writing area is used for data writing, the target written data is synchronously written into the data writing area and a data reading and writing area, the data reading and writing area is used for data reading and data writing, and reading the target written data from the data reading and writing area under the condition that the target data writing unit does not meet a preset storage condition. According to the method, the data storage device is divided into the data reading and writing area and the data writing area, the data reading and writing area can be used for data rea