Method, apparatus, electronic device and storage medium for data processing
AssigneeBeijing Zitiao Network Technology Co., Ltd.
InventorsWei Zhang, Qingfeng Liu
Life of this patent
Estimating the term…
Abstract
The disclosure provides a method, apparatus, electronic device and storage medium for data processing. The method includes: obtaining a storage request for target data; obtaining first dimension information and second dimension information of the target data based on the storage request, the first dimension information representing information of a user to which the target data belongs, and the second dimension information representing information of a business to which the target data belongs; and storing the target data into the first storage region.
Claims16
A method for data processing, comprising:
- obtaining, at an electronic device, a storage request for target data;
- obtaining, by the electronic device, first dimension information and second dimension information of the target data based on the storage request, the first dimension information representing information of a user to which the target data belongs, and the second dimension information representing information of a business to which the target data belongs;
- determining, by the electronic device, a first storage region in a storage space based on the first dimension information and second dimension information;
- storing, by the electronic device, the target data into the first storage region;
- and
- constructing, by the electronic device, index information for the first storage region based on the first dimension information and second dimension information, wherein obtaining the target data from the first storage region is based on the index information,
- wherein before constructing index information for the first storage region based on the first dimension information and second dimension information, the method further comprises:
- obtaining a storage service that matches a storage type of the target data, wherein the storage type comprises at least one of:
- a file storage, a key-value storage or a keychain storage;
- and
- constructing a storage service instance corresponding to the first dimension information and second dimension information based on the first dimension information, the second dimension information and the storage service,
- wherein the storage type comprises a file storage, and the storage service instance comprises a file storage service instance, and
- wherein constructing index information for the first storage region based on the first dimension information and second dimension information comprises:
- calling the file storage service instance to parse a generated path based on the first dimension information and second dimension information;
- and
- adding a relative path for the first storage region as the index information of the first storage region based on the generated path.
An electronic device, comprising a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the program when executed by the processor, implements a method comprising:
- obtaining a storage request for target data;
- obtaining first dimension information and second dimension information of the target data based on the storage request, the first dimension information representing information of a user to which the target data belongs, and the second dimension information representing information of a business to which the target data belongs;
- determining a first storage region in a storage space based on the first dimension information and second dimension information;
- storing the target data into the first storage region;
- and
- constructing index information for the first storage region based on the first dimension information and second dimension information, wherein obtaining the target data from the first storage region is based on the index information,
- wherein before constructing index information for the first storage region based on the first dimension information and second dimension information, the method further comprises:
- obtaining a storage service that matches a storage type of the target data, wherein the storage type comprises at least one of:
- a file storage, a key-value storage or a keychain storage;
- and
- constructing a storage service instance corresponding to the first dimension information and second dimension information based on the first dimension information, the second dimension information and the storage service,
- wherein the storage type comprises a file storage, and the storage service instance comprises a file storage service instance, and
- wherein constructing index information for the first storage region based on the first dimension information and second dimension information comprises:
- calling the file storage service instance to parse a generated path based on the first dimension information and second dimension information;
- and
- adding a relative path for the first storage region as the index information of the first storage region based on the generated path.
A non-transitory computer-readable storage medium storing computer instructions, wherein the computer instructions are used to cause the computer to execute a method comprising:
- obtaining a storage request for target data;
- obtaining first dimension information and second dimension information of the target data based on the storage request, the first dimension information representing information of a user to which the target data belongs, and the second dimension information representing information of a business to which the target data belongs;
- determining a first storage region in a storage space based on the first dimension information and second dimension information;
- and
- storing the target data into the first storage region;
- and
- constructing index information for the first storage region based on the first dimension information and second dimension information, wherein obtaining the target data from the first storage region is based on the index information,
- wherein before constructing index information for the first storage region based on the first dimension information and second dimension information, the method further comprises:
- obtaining a storage service that matches a storage type of the target data, wherein the storage type comprises at least one of:
- a file storage, a key-value storage or a keychain storage;
- and
- constructing a storage service instance corresponding to the first dimension information and second dimension information based on the first dimension information, the second dimension information and the storage service,
- wherein the storage type comprises a file storage, and the storage service instance comprises a file storage service instance, and
- wherein constructing index information for the first storage region based on the first dimension information and second dimension information comprises:
- calling the file storage service instance to parse a generated path based on the first dimension information and second dimension information;
- and
- adding a relative path for the first storage region as the index information of the first storage region based on the generated path.
Dependencies are inferred from the claim text.