WO2019062572A1 - Data processing method, device and system - Google Patents

Data processing method, device and system Download PDF

Info

Publication number
WO2019062572A1
WO2019062572A1 PCT/CN2018/105965 CN2018105965W WO2019062572A1 WO 2019062572 A1 WO2019062572 A1 WO 2019062572A1 CN 2018105965 W CN2018105965 W CN 2018105965W WO 2019062572 A1 WO2019062572 A1 WO 2019062572A1
Authority
WO
WIPO (PCT)
Prior art keywords
target object
server
location information
container
target
Prior art date
Application number
PCT/CN2018/105965
Other languages
French (fr)
Chinese (zh)
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 华为技术有限公司
Publication of WO2019062572A1 publication Critical patent/WO2019062572A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • 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/953Querying, e.g. by the use of web search engines
    • G06F16/9537Spatial or temporal dependent retrieval, e.g. spatiotemporal queries
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/56Provisioning of proxy services
    • H04L67/568Storing data temporarily at an intermediate stage, e.g. caching
    • H04L67/5682Policies or rules for updating, deleting or replacing the stored data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources

Definitions

  • Embodiments of the present invention relate to the field of computer storage, and in particular, to a data processing method, apparatus, and system.
  • the object storage system quickly becomes the mainstream storage system for storing data in the computer storage field with its advantages of high-speed access characteristics, high reliability and scalability.
  • the terminal when a user uses a terminal (such as a browser on a terminal or other application), the terminal can use the terminal to write data to the object storage system (which can be called an object, the object includes metadata and the data itself), and deletes The object stores some data in the system or reads some data from the object storage system.
  • the object storage system may include a terminal 10, a proxy server 11, a container server 12, and an object server 13.
  • the proxy server 11 in the object storage system receives the object read request sent by the terminal 10, and the proxy server 11 sends the query to the container server 12 of the object storage system.
  • the location information message and then the container server 12 can query the location information of the object in the database in the container server 12. If the location information of the object is queried, the proxy server 11 sends the location information of the object to the object server 13, The object server 13 reads the object based on the position information of the object, and returns the read object to the terminal 10.
  • the proxy server 11 When the terminal 10 deletes a certain data (ie, an object) in the object storage system, the proxy server 11 receives the object deletion request sent by the terminal 10. Similarly, the proxy server 11 sends a message to the container server 12 to query the location information of the object. The container server 12 then queries the location information of the object in the database of the container server 12. If the location information of the object is queried, the location information of the object is sent to the proxy server 11, and the proxy server 11 sends the object to the object server 13. Location information, and then the object server 13 deletes the object in the object server 13 according to the location information of the object, and returns a delete response message to the proxy server 11, and the proxy server 11 sends the container server 12 to delete the container. A request message for the location information of the object in the server 12, whereby the container server 12 deletes the location information of the object in the database.
  • the object server when a request for reading an object (for example, the first object) and a request for deleting the object are concurrently present in the object storage system, since the object server needs to be in the process of deleting the first object, The object is marked as deleted. If the object server first receives the location information indicating the deletion of the first object of the first object, and then receives the location information indicating the first object that reads the first object, because the object server is according to the first The location information of the object may have been marked for deletion of the first object. As a result, the object server may not be able to read the first object according to the location information of the first target (ie, the object fails to be read), thus causing There is a conflict between reading the first object and deleting the first object.
  • the present application provides a data processing method, apparatus, and system, which can avoid conflicts between a read object and a deleted object to a certain extent.
  • the first aspect provides a data processing method, where the method includes: the container server receives a delete query message sent by the proxy server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier of the first target object.
  • the container server queries the location information of the first target object in the object list of the container server according to the identifier information of the container to which the first target object belongs and the identification information of the first target object; if the first target is queried in the object list
  • the location information of the object the container server deletes the location information of the first target object in the object list, and writes the location information of the first target object into the deletion log of the container server; and the container server sends a deletion response message to the proxy server.
  • the object list includes location information of the first type of object, the first type of object is an object stored in the object server that is not marked and deleted, and the location information of the first type of object is used to indicate that the object is in the object server.
  • the location, the deletion log contains location information of the second type of object, and the second type of object is the location information of the object stored in the object server that is marked and deleted.
  • the container server may delete the location information of the first target object from the object list, and The location of the first target object is newly written into the deletion log of the container server. It can be seen that the container server does not need to send the location information of the first target object to the proxy server, and the proxy server does not need to further locate the location information of the first target object.
  • the object server does not need to delete the first target object in the object server, so when deleting the first target object in the object storage system and the first in the read object storage system
  • the first target object in the object server is not marked as deleted during the process of deleting the first target object, so the first target object can be read in the object server, and Compared with the prior art, it can be avoided that the first target object in the object server is Record for deletion, reading problems caused by the failure of the first target object, that is, avoid reading the first target object and delete the conflict first target object.
  • the proxy server since the container server does not need to send the location information of the first target object to the proxy server, the proxy server does not need to send the location information of the first target object to the object server, so that the object server does not need to be in the object.
  • the first target object in the server is marked for deletion, so that the process of deleting the first target object can be simplified, and the communication resources between the servers can be saved.
  • the location information of the first target object may include a file identifier of the first target object, an offset of the first target object, and a size of the first target object.
  • the file identifier indicates that at least two objects are included in the file; or the location information of the first target object may include an ID of the first target object.
  • the stored method (which can be understood as the method of writing) is different, and the content information of the first target object may be different, and for different storage methods.
  • the above data processing method can implement the operation of deleting the first target object, and can simplify the process of deleting the first target object, and can save communication resources between servers.
  • the data processing method provided by the present application may further include: the container server receives a read query message sent by the proxy server, where the read query message includes the second target object The identifier information of the container and the identifier information of the second target object; the container server then queries the object list for the location information of the second target object according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object; If the location information of the second target object is queried in the object list, the container server sends the location information of the second target object to the proxy server, to instruct the proxy server to read the second target from the object server according to the location information of the second target object.
  • the object, the location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, and the file indicated by the file identifier includes at least two objects.
  • objects in the object storage system can be smoothly read by the above method.
  • the data processing method provided by the application may further include: the container server reads the number in the object list. The location information of a target object.
  • the container server reads the location information of the first target object from the object list after the container server writes the location information of the first target object to the delete log of the container server. Taking the location information of the first target object in the object list, in the process of reading the first target object and deleting the first target object, even if the location information of the first target object in the container server has been deleted, And the location information of the first target object has been written into the deletion log, and the first target object can also be read this time.
  • the location information of the first target object in the container server has been deleted, and the location information of the first target object has been written into the deletion log, and the first target object can also be read this time.
  • the reason is: in the process of deleting the first target object, the location information of the first target object may be written in the deletion log to indicate that the first target object is marked for deletion, and no need to be in the object server. The first target object is marked as deleted. Therefore, the first target object still exists in the object server and has not been reclaimed.
  • the object server may obtain the first target object according to the read query request message according to the container server. Location information, the first target object is read in the object server.
  • the data processing method provided by the embodiment of the present invention can avoid conflicts between the read object and the deleted object to a certain extent (refers to when the read object and the deleted object occur concurrently, the operation of deleting the object firstly causes the read object to be read. The operation could not read the object)
  • the data processing method provided by the application may further include: the container server sending a garbage collection request message to the object server, where the garbage collection request message includes deleting the target object in the log Location information; and the container server receives the garbage collection response message sent by the object server, and the container server deletes the location information of the target object in the deletion log, wherein the garbage collection response message indicates that the target server has deleted the target object.
  • the container server may also delete the target object according to the target object.
  • the location information requests the object server to delete (ie, recycle) the content of the target object in the object server, so that the container server deletes the location information of the target object in the deletion log, thereby completely deleting the target object in the object storage system.
  • the data processing method provided by the application may further include: the container server receives the location update message sent by the proxy server; and the container server updates the third target according to the location update message.
  • Location information of the object is used to update the location information of the third target object, where the location update message includes the identifier information of the container to which the third target object belongs, the identifier information of the third target object, and the third target object.
  • the method for updating the location information of the third target object by the container server according to the location update message may include: the container server according to the identifier information of the container to which the third target object belongs, The identification information of the third target object is used to query the location information of the third target object in the object list of the container server; if the location information of the third target object is not queried in the object list, the container server will be the third in the location update message.
  • the first location information of the target object is written to the object list; if the location information of the third target object is queried in the object list, the location information of the third target object is the second location information, and the second target object is the second location information.
  • the location information is different from the first location information of the third target object in the location update message, the container server replaces the second location information of the third target object with the first location information of the third target object, and the third target object The second location information is written to the delete log of the container server.
  • the container server may update location information of an object (eg, the third target object described above) in the object storage system (eg, update the location of the third target object after writing the third target object) Information), in this way, when the third target object is subsequently read or deleted, the location information of the accurate third target object can be queried from the container server to correctly read the third target object, or delete the third object. target.
  • an object eg, the third target object described above
  • the container server may update location information of an object (eg, the third target object described above) in the object storage system (eg, update the location of the third target object after writing the third target object) Information), in this way, when the third target object is subsequently read or deleted, the location information of the accurate third target object can be queried from the container server to correctly read the third target object, or delete the third object. target.
  • the second aspect provides a data processing method, the method may include: the object server receives a request message of the upload target object sent by the proxy server, where the request message of the upload target object includes a third target object; The third target object is written in the object server; and the object server sends the location information of the third target object to the proxy server, where the location information of the third target object includes the file identifier of the third target object and the offset of the third target object And the size of the third target object, the file identifier indicates that at least two objects are included in the file.
  • the data processing method provided by the present application in the process of uploading an object (for example, may be referred to as a third target object) to the object storage system, because the object server writes the third target object into the file system file of the object server,
  • the file may include at least two objects. It can be known that when multiple small objects are written in the object storage system, multiple small objects can be written into one file, thereby saving the storage resources of the file system of the object server. Improve the performance of the object server.
  • the data processing method provided by the present application may further include: the object server receives location information of the second target object sent by the proxy server; and the object server is configured according to the second target object.
  • the location information reads the second target object; and the object server sends a second target object to the proxy server.
  • the data processing method provided by the application may further include: receiving, by the object server, a garbage collection request message sent by the container server, where the garbage collection request message includes a deletion log of the container server Position information of the first target object; and the object server deletes the first target object according to the location information of the first target object; and the object server sends a garbage collection response message to the container server, the garbage collection response message indicating that the first target has been deleted target.
  • the present application provides a data processing method, the method may include: the proxy server sends a request message for uploading a target object to the object server, where the request message of the upload target object includes a target object; and then the proxy server receives the object server and sends the First location information of the target object, the first location information of the target object includes a file identifier of the target object, an offset of the target object, and a size of the target object, where at least two objects are stored in the file indicated by the file identifier; And the proxy server sends a location update message to the container server, to instruct the container server to update the location information of the target object in the object list of the container server according to the location update message, where the location update message includes the identifier information and the target of the container to which the target object belongs.
  • the identification information of the object and the first location information of the target object is a request message for uploading a target object to the object server, where the request message of the upload target object includes a target object; and then the proxy server receives the object
  • the data processing method provided by the present application may further include: receiving, by the proxy server, a delete response message sent by the container server, where the delete response message is a target of the container service deletion target list The location information of the object, and the location information of the target target object is sent after being written to the delete log of the container server.
  • the identification information of the container to which the first target object belongs and the identification information of the first target object and querying the location information of the first target object in the object list of the container server, where the object list includes location information of the first type of object,
  • the first type of object is an object stored in the object server that is not marked for deletion, and the location information of the first type object is used to indicate the location of the object in the object server; the update module can be used to query the object list in the query module.
  • transmitting module may be configured to send a message deletion response to the proxy server.
  • the location information of the first target object includes a file identifier of the first target object, an offset of the first target object, and a size of the first target object, where The file identifier indicates that at least two objects are included in the file; or the location information of the first target object includes the ID of the first target object.
  • the receiving module may be further configured to receive a read query message sent by the proxy server, where the read query message includes the identifier information of the container to which the second target object belongs and the first
  • the identifier information of the second target object may be used to query the location information of the second target object in the object list according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object received by the receiving module.
  • the location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, where the file indicated by the file identifier includes at least two objects; the sending module
  • the container server may further send the location information of the second target object to the proxy server, to indicate the location information of the second target object according to the location information of the second target object from the object server. Read the second target object in .
  • the container server provided by the present application may further include a reading module.
  • the reading module may be configured to: if the read query message received by the receiving module includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object, the first target object in the object list is deleted in the update module The location information, and the location information of the first target object in the object list is read before the location information of the first target object is written in the deletion log of the container server.
  • the sending module may be further configured to send a garbage collection request message to the object server, where the garbage collection request message includes deleting location information of the target object in the log;
  • the module may be further configured to receive a garbage collection response message sent by the object server, where the garbage collection response message indicates that the target server has deleted the target object; and the update module may further be configured to delete the location information of the target object in the deletion log.
  • the receiving module is further configured to receive a location update message sent by the proxy server, where the location update message is used to update location information of the third target object, where the location update message is The identifier information of the container to which the third target object belongs, the identification information of the third target object, and the first location information of the third target object are included; the update module may be further configured to update the third according to the location update message received by the receiving module. The location information of the target object.
  • the query module may be further configured to query the object list of the container server according to the identifier information of the container to which the third target object belongs and the identifier information of the third target object.
  • Position information of the third target object the update module is specifically configured to: when the query module does not query the location information of the third target object in the object list, write the first location information of the third target object in the location update message to the object a list, if the query module queries the location information of the third target object in the object list, the location information of the third target object is the second location information, and the second location information of the third target object and the third location information in the location update message
  • the first location information of the target object is different, the second location information of the third target object is replaced with the first location information of the third target object, and the second location information of the third target object is written into the deletion log of the container server.
  • an object server may include a receiving module, a write data module, and a sending module.
  • the receiving module may be configured to receive a request message of the upload target object sent by the proxy server, where the request message of the upload target object includes a third target object
  • the write data module may be configured to write the third target object received by the receiving module.
  • the sending module may be configured to send, to the proxy server, location information of the third target object, where the location information of the third target object includes a file identifier of the third target object, an offset of the third target object, and a third The size of the target object, the file identifier indicates that at least two objects are included in the file.
  • the object server provided by the application may further include a reading module.
  • the receiving module may be further configured to receive location information of the second target object sent by the proxy server; the reading module may be configured to read the second target object according to the location information of the second target object received by the receiving module; Used to send a second target object to the proxy server.
  • the object server provided by the application may further include a deletion module.
  • the receiving module may be further configured to receive a garbage collection request message sent by the container server, where the garbage collection request message includes location information of the first target object in the deletion log of the container server; the deletion module may be configured to receive according to the receiving module.
  • the location information of the first target object deletes the first target object;
  • the sending module may be further configured to send a garbage collection response message to the container server, where the garbage collection response message indicates that the first target object has been deleted.
  • a proxy server which can include a sending module and a receiving module.
  • the sending module may be configured to send a request message for uploading the target object to the object server, where the request message of the upload target object includes a target object
  • the receiving module may be configured to receive first location information of the target object sent by the object server, where the target The first location information of the object includes a file identifier of the target object, an offset of the target object, and a size of the target object, where at least two objects are stored in the file indicated by the file identifier; the sending module may be further configured to send to the container server.
  • a location update message to instruct the container server to update the location information of the target object in the object list of the container server according to the location update message, where the location update message includes the identification information of the container to which the target object belongs, the identification information of the target object, and the target object.
  • the receiving module is further configured to receive a deletion response message sent by the container server, where the deletion response message is a location information of the target object in the container service deletion object list, and The location information of the target target object is sent after being written to the delete log of the container server.
  • a container server in a seventh aspect, can include a processor and a memory coupled to the processor. This memory can be used to store computer instructions.
  • the processor executes the computer instructions stored by the memory to cause the container server to perform the data processing method of any of the above first aspects and various alternative implementations thereof.
  • a computer readable storage medium comprising computer instructions.
  • the container server is caused to perform the data processing method of any of the above first aspects and various alternative implementations thereof.
  • a computer program product comprising computer instructions for causing a container server to perform any of the first aspect described above and various alternative implementations thereof when the computer program product is run on a container server The data processing method described.
  • an object server can include a processor and a memory coupled to the processor.
  • This memory can be used to store computer instructions.
  • the processor executes the computer instructions stored by the memory to cause the object server to perform the data processing method of any of the above second aspects and various alternative implementations thereof.
  • a computer readable storage medium comprising computer instructions.
  • the object server is caused to perform the data processing method of any of the above second aspects and various alternative implementations thereof.
  • a computer program product comprising computer instructions, when the computer program product is run on an object server, causes the object server to perform any one of the second aspect described above and various alternative implementations thereof The data processing method described.
  • a proxy server in a thirteenth aspect, can include a processor and a memory coupled to the processor. This memory can be used to store computer instructions.
  • the processor executes the computer instructions stored by the memory to cause the proxy server to perform the data processing method of any of the above third aspects and various alternative implementations thereof.
  • a computer readable storage medium comprising computer instructions.
  • the proxy server is caused to perform the data processing method of any of the above third aspects and various alternative implementations thereof.
  • a computer program product comprising computer instructions, when executed on a proxy server, causes the proxy server to perform any one of the above third aspects and various alternative implementations thereof The data processing method described.
  • an object storage system may include the container server according to any one of the foregoing fourth aspects and various alternative implementations thereof, the fifth aspect and various The object server of any one of the selected implementations, and the proxy server of any of the sixth aspect and various alternative implementations thereof.
  • the object storage system system may include the container server in the seventh aspect, the object server in the tenth aspect, and the proxy server in the thirteenth aspect.
  • FIG. 1 is a schematic structural diagram of an object storage system according to an embodiment of the present invention.
  • FIG. 2 is a schematic diagram of hardware of various servers according to an embodiment of the present invention.
  • FIG. 3 is a schematic diagram 1 of a data processing method according to an embodiment of the present invention.
  • FIG. 4 is a second schematic diagram of a data processing method according to an embodiment of the present invention.
  • FIG. 5 is a schematic diagram 3 of a data processing method according to an embodiment of the present disclosure.
  • FIG. 6 is a schematic diagram 4 of a data processing method according to an embodiment of the present disclosure.
  • FIG. 8 is a schematic structural diagram 2 of a container server according to an embodiment of the present disclosure.
  • FIG. 9 is a schematic structural diagram 1 of an object server according to an embodiment of the present disclosure.
  • FIG. 10 is a schematic structural diagram 2 of an object server according to an embodiment of the present disclosure.
  • FIG. 11 is a schematic structural diagram 1 of a proxy server according to an embodiment of the present invention.
  • FIG. 12 is a schematic structural diagram 2 of a proxy server according to an embodiment of the present invention.
  • first and second in the specification and claims of the embodiments of the present invention are used to distinguish different objects, and are not intended to describe a specific order of the objects.
  • first target object and the second target object are used to distinguish different target objects, rather than to describe a specific order of the target objects.
  • the words “exemplary” or “such as” are used to mean an example, illustration, or illustration. Any embodiment or design described as “exemplary” or “for example” in the embodiments of the invention should not be construed as preferred or advantageous over other embodiments or designs. Rather, the use of the words “exemplary” or “such as” is intended to present the concepts in a particular manner.
  • a plurality means two or more unless otherwise stated.
  • a plurality of processing units refers to two or more processing units;
  • a plurality of systems refers to two or more systems.
  • Container In the field of object storage, it can also be called a bucket, in which information about an object is stored (for example, it can be called a list of objects, including location information of multiple objects, such as the ID of the object, and the offset of the object in a file) And the size of the object, etc.), the container is located in the container server.
  • information about an object for example, it can be called a list of objects, including location information of multiple objects, such as the ID of the object, and the offset of the object in a file) And the size of the object, etc.
  • the object In the object storage domain, the object is the storage unit, the object is stored in the object server in the object storage system, the object includes the object metadata and the object data, and the object metadata is used to describe the information of the object's attributes, such as the size of the object. Or the type of the object (such as pictures, audio, video, etc.), etc., the object data is the object itself.
  • the data processing method provided by the embodiment of the present invention can be applied to an object storage system.
  • a schematic diagram of the architecture of the object storage system refer to the schematic diagram of the object storage system shown in FIG. 1 , where the proxy server 11 is responsible for the object storage system. Inter-communication between the remaining components, for example, the proxy server 11 can receive hypertext transfer requests (e.g., read requests, delete requests, upload requests, etc.) of the client, and can forward requests from clients (e.g., terminal 10 in Figure 1). The message is to the container server 12 or the object server 13 in the object storage system.
  • hypertext transfer requests e.g., read requests, delete requests, upload requests, etc.
  • the information of the container and the information of the object are maintained (considered to be stored) in the database of the container server 12, and the metadata and data of the plurality of objects are stored in the file system of the object server 13.
  • an operation of uploading (ie, writing) an object, reading an object, and deleting an object may be implemented through interaction between the proxy server 11, the container server 12, and the object server 13.
  • the terminal 10 can be a mobile phone, a tablet computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (personal).
  • Digital assistant (PDA) smart car, sensing device, internet of thing (IOT) equipment, customer premise equipment (CPE), etc.
  • the proxy server 11, the container server 12, and the object server 13 shown in FIG. 1 may be a hardware server or a software server.
  • the proxy server 11, the container server 12, and the object server 13 are hardware. Server, introduces the hardware structure and software function modules of each server.
  • the proxy server 11 , the container server 12 , and the object server 13 may be servers of the same structure or servers of different configurations.
  • the components of the proxy server, the container server, and the object server are respectively described below in conjunction with the object storage system shown in FIG.
  • FIG. 2 is a schematic diagram of hardware of each server according to an embodiment of the present invention.
  • the proxy server 100 shown in FIG. 2 may include: a processor 101, a memory 102, and a communication interface 103.
  • the processor 101 is a core component of the proxy server and is used to run the server's operating system and applications on the server (including system applications and third-party applications).
  • the processor 101 may be a central processing unit (CPU), a general-purpose processor, a digital signal processor (DSP), or an application-specific integrated circuit (ASIC). a field programmable gate array (FPGA) or other programmable logic device, transistor logic device, hardware component, or any combination thereof, which may implement or perform various aspects described in the disclosure of the embodiments of the present invention.
  • exemplary logical blocks, modules and circuits; the processor may also be a combination of computing functions, for example, including one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like.
  • Memory 102 program code and data for storing a proxy server.
  • the memory 102 may specifically include a volatile memory, such as a random-access memory (RAM); the memory may also include a non-volatile memory.
  • a volatile memory such as a random-access memory (RAM)
  • the memory may also include a non-volatile memory.
  • ROM read-only memory
  • flash memory flash memory
  • HDD hard disk
  • SSD solid-state disk
  • the memory may further include the above-described type of memory. The combination.
  • the communication interface 103 is an interface circuit for the proxy server to communicate with other devices.
  • the communication interface may be a transceiver, a transceiver circuit, or the like having a transceiving function, and the communication interface includes a serial communication interface and a parallel communication interface.
  • the proxy server 100 can communicate with a client (e.g., terminal 10 in FIG. 2) via the communication interface 103, with the container server 200, or with the object server 300.
  • the container server 200 shown in FIG. 2 may include a processor 201, a memory 202, and a communication interface 203.
  • the processor 201 refer to the description of the processor 101 of the proxy server 100, and details are not described herein again.
  • the processor 101 of the container server may process the read query message or delete the query message.
  • the memory 202 of the container server 200 may include at least one container (for example, M containers shown). M ⁇ 1)), each container may include a list of objects and a delete log, where the object list stores location information of a plurality of objects (which may be referred to as first type objects), and the first type of objects are unmarked and deleted.
  • the object stored in the object server deletes the location information of a plurality of objects (which may be referred to as a second type of object), and the second type of object is the location information of the object stored in the object server that is marked and deleted.
  • the communication interface 203 For a description of the communication interface 203, reference may be made to the description of the communication structure 103 of the proxy server 100, in which the container server may communicate with the proxy server 100 via the communication interface 203 or with the object server 300.
  • the file 302 of the object server 300 may include a file system, and the file system includes at least one file (for example, The file system shown in FIG. 2 includes N files (N ⁇ 1), and each of the at least one file can store a plurality of objects (for example, each of the files shown in FIG. 2 can include P objects). (P ⁇ 2)).
  • the communication interface 303 For a description of the communication interface 303, reference may be made to the description of the communication structure 103 of the proxy server 100, in which the object server 300 may communicate with the proxy server 100 via the communication interface 303 or with the container server 200.
  • the object server needs to delete the object according to the location information of the object, and when the object storage system has both read an object (for example, the first object) Request, there is also a request to delete the object, because the object in the object server may have been marked as deleted when the object is read, so the failure to read the object may occur, which leads to the first reading
  • the object conflicts with deleting the first object.
  • the embodiment of the invention provides a data processing method, device and system, which can avoid conflicts between a read object and a deleted object to a certain extent.
  • the user equipment may delete an object stored in the object storage system, or may read an object stored in the object storage system, and may also upload the object to the object storage system, and firstly through the object storage.
  • the interaction process between the various servers in the system describes three different application scenarios of deleting objects, reading objects, and uploading objects.
  • the scene of the deleted object is recorded as the scene 1
  • the scene of the read object is recorded as the scene 2
  • the scene of the uploaded object is recorded as the scene 3.
  • the data processing method provided by the embodiment of the present invention may include S101-S105:
  • the proxy server sends a delete query message to the container server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object.
  • the terminal when the terminal needs to delete an object in the object storage system (hereinafter may be referred to as a first target object), the terminal may send a request message for deleting the first target object to the proxy server, and the proxy server receives the terminal.
  • the proxy server After the sent request message for deleting the first target object is sent, and the request message for deleting the first target object is parsed, and the identifier information of the container to which the first target object belongs and the identification information of the first target object are obtained, the proxy server may The identifier information of the container to which the target object belongs and the identifier information of the first target object are carried in the delete query message and sent to the container server, where the location information of the object is stored in the container, and the location information is used to indicate the target server.
  • the location of the object, the identifier information of the container to which the first target object belongs may identify in which container the location of the first target object to be deleted is stored, and the identifier information of the first target object may indicate that the target object to be deleted is in the container Which target object.
  • the identifier information of the first target object may be a name of the first target object or other information that may be specified by the user, which may be a predetermined target, which is not specifically limited.
  • the identifier information of the container to which the first target object belongs may also be the name of the container or other information defined by the user, which may be instructed by the user.
  • the container server receives a delete query message sent by the proxy server.
  • the container server queries the location information of the first target object in the object list of the container server according to the identifier information of the container to which the first target object belongs and the identifier information of the first target object in the delete query message.
  • the object list of the container server includes location information of the first type of object, and the first type of object is an object stored in the object server that is not marked and deleted, and the location information of each first type of object is used to indicate each The location of the object in the object server.
  • the location information of the object is also different.
  • the object is The location information is the ID of the object; if at least two objects are stored in one file, it can be understood that at least two objects are stored in each file, and the location information of the object is the file identifier of the object, the offset of the object, and The size of the object, the offset of the object is the position of the object in its stored file, and the size of the object identifies the size of the object, such as the number of bits occupied by the object.
  • the location information of the first target object may include an ID of the first target object, or the location information of the first target object may include a file identifier of the first target object, an offset of the first target object, and the first The size of the target object, which includes at least two objects in the file indicated by the file identifier.
  • the location information of the object may be jointly represented by the ID of the container and the ID of the object, and the object server
  • the range of objects that can be represented by the ID of the object may not satisfy the number of objects, that is, the actual number of objects exceeds the number of objects that can be represented by the ID of the object. Therefore, the ID of the container and the ID of the object can be used. Two fields identify the location information of the object to indicate the object.
  • the object information of the container server may store location information of multiple objects, that is, multiple pieces of location information may be stored, and each piece of location information corresponds to location information of one object, and each piece of location information may correspond to a location index, and the information tuple composed of the identification information of the container to which the object belongs and the identification information of the object also corresponds to a location index, and the container server according to the identification information of the container to which the first target object belongs and the identifier of the first target object
  • the method for querying the location information of the first target object in the object list of the container server is specifically: the container server determines the location index of the first target according to the identifier information of the container to which the first target object belongs and the identification information of the first target object, The location information of the first target object can then be determined based on the index of the location of the first target object.
  • the information binary consisting of the identification information of the container to which the object in the container server belongs and the identification information of the object (Table 1) An example of the correspondence between the positional index of the object and the positional index of the object and the positional index of the object.
  • object1 represents the identifier of the object 1
  • container1 represents the identifier of the container to which the object 1 belongs.
  • the container server deletes the location information of the first target object in the object list, and writes the location information of the first target object to the deletion of the container server. In the log.
  • the deletion log includes location information of the second type of object, and the second type of object is location information of the object stored in the object server that is marked and deleted.
  • the container server after the container server deletes the location information of the first target object from the object list, and after the location information of the first target object is written into the deletion log, the container server subsequently receives other information about the first target object.
  • the container server When querying a message (for example, reading a query message), the container server will not find the location information of the first target object in the object list, and thus cannot perform corresponding operations on the first target object.
  • the first target object is considered to be deleted successfully.
  • the content of the first target object that is, the metadata of the first target object and the data itself have not been deleted (ie, not recovered), and are also stored in the object server.
  • the location information of the object in the deletion log of the container server indicates the object to be reclaimed in the object server, and the location information of the first target object is written into the deletion log, which can be understood as the first target to be deleted.
  • the object is first marked, and at the appropriate time, the content of the first target object is recovered from the object server based on the location information of the first target object in the deletion log.
  • the container server sends a delete response message to the proxy server.
  • the deletion response message may include indication information indicating that the deletion of the first target object is successful, to indicate that the container server successfully deletes the first target object.
  • the container server may send, to the proxy server, indication information including location information indicating that the first target object is not queried, to indicate The container server does not query the location information of the first target object, that is, the deletion operation ends.
  • the container server may query the object list of the container server.
  • the location information of the first target object and in the case where the location information of the first target object is queried in the object list, the location information of the first target object is deleted from the object list, and the location of the first target object is Information is written to the delete log of the container server.
  • the container server queries the location information of the first target object in the object list
  • the location information of the first target object does not need to be sent to the proxy server
  • the proxy server does not need to be Sending the location information of the first target object to the object server, so that the object server does not need to delete the first target object in the object server, so when deleting the first target object and reading in the object storage system
  • the object can be read in the object server.
  • the proxy server since the container server does not need to send the location information of the first target object to the proxy server, the proxy server does not need to send the location information of the first target object to the object server, so that the object server does not need to be in the object.
  • the first target object in the server is marked for deletion, so that the process of deleting the first target object can be simplified, and the communication resources between the servers can be saved.
  • the data processing method provided by the embodiment of the present invention may include S201-S209:
  • the proxy server sends a read query message to the container server, where the read query message includes the identifier information of the container to which the second target object belongs and the identifier information of the second target object.
  • the terminal when the terminal needs to read an object in the object storage system (which may be referred to as a second target object), the terminal may send a request message for reading the second target object to the proxy server, and the proxy server receives the request message.
  • the proxy server may Carrying the identification information of the container to which the second target object belongs and the identification information of the second target object in the read query message, and sending the information to the container server to obtain the location information of the second target object, thereby reading the second target object.
  • the container service receives a read query message sent by the proxy server.
  • the container server queries the location information of the second target object in the object list of the container server according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object.
  • the location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, where the file identifier includes at least two files. Object.
  • the container server sends the location information of the second target object to the proxy server.
  • the container server sends the location information of the second target object to the proxy server, and may instruct the proxy server to read the second target object from the object server according to the location information of the second target object.
  • the proxy server receives location information of the second target object sent by the container server.
  • the proxy server sends the location information of the second target object to the object server.
  • the object server receives location information of the second target object sent by the container server.
  • the object server reads the second target object according to the location information of the second target object.
  • the object server sends a second target object to the proxy server.
  • the location information of the second target object that can be received by the proxy server is sent to the object server, so that the object server can read the second target object in the corresponding location in the object server according to the location information of the second target object. And sending the second target object to the proxy server, and then the proxy server sends the second target object to the terminal, so that the terminal can smoothly read the second target object.
  • the data processing method provided by the embodiment of the present invention may further include S301-S308:
  • the proxy server sends a request message for uploading a third target object to the object server, where the request message for uploading the third target object includes a third target object.
  • the terminal when the terminal needs to upload an object to the object storage system (for example, it may be referred to as a third target object), the terminal may send an upload request message to the proxy server, where the upload request message includes the third target object.
  • the identification information of the container and the identification information of the third target object, the identification information of the container to which the third target object belongs is used to indicate in which container the third target object is updated after the third target object is written to the object server Location information; the proxy server may send the third target to the object server in the request message for uploading the third target object.
  • the object server receives a request message that is sent by the container server and uploads the third target object.
  • the object server writes the third target object into a file of the object server.
  • the file written to the third target object can support writing multiple objects, and the multiple objects are small objects, and the small object can be understood as the space occupied by the object is relatively small, that is, the size of the object is relatively small ( For example, an image, a small text, etc. can be called a small object.
  • each file contains only one object, and multiple objects (here, will refer to multiple small objects). Writing to a large file can save the storage resources of the file system of the object server, thereby improving the performance of the object server.
  • each file contains only one object.
  • the object server reclaims multiple small objects, multiple space fragments are generated in the server (ie, small files after each small object are reclaimed).
  • multiple small objects are written into one large file, so that when small objects in the large file are recovered, space fragmentation in the server can be reduced, thereby writing a large object (occupied)
  • the storage space is relatively large, it is not necessary to divide the large object into multiple small files, and the entire contents of the large object can be written into a large file, thereby improving the performance of the object storage system.
  • the object server sends the first location information of the third target object to the proxy server.
  • the first location information of the third target object includes a file identifier of the third target object, an offset of the third target object, and a size of the third target object, where the file identifier of the third target object is in the file indicated by the file identifier Save at least two objects.
  • the object server writes the third target object to a certain location of the object server, and if the location is called the first location, the object server may generate the location information of the third target object, because the object server is in the current time.
  • the third target object may already be stored in the object server (possibly the third target object to be written this time is a modified version of the stored third target object), so in order to distinguish the present
  • the positional position information of the third target object that has been written in the second time and the positional information of the third target object that has been previously stored are recorded as the first positional information of the third target object.
  • the proxy server receives first location information of the third target object sent by the object server.
  • the proxy server sends the location update message to the container server.
  • the location update message is used to update location information of the target object in the object list of the container server.
  • the proxy server may carry the identifier information of the container to which the target object belongs, the identifier information of the target object, and the first location information of the target object in the location update message. Is sent to the container server to instruct the container server to update the location information of the target object in the object list of the container server according to the location update message.
  • the container server receives a location update message sent by the proxy server.
  • the container server updates the location information of the third target object in the object list of the container server according to the location update message.
  • S308a-S308b may be specifically implemented by using S308a-S308b:
  • the container server queries the location information of the third target object in the object list of the container server according to the identifier information of the container to which the third target object belongs and the identifier information of the third target object.
  • S308b The container server updates the location information of the third target object according to the query result.
  • the query result of the container server querying the location information of the third target object in the object list may include: the container server does not query the location information of the third target object in the object list, or the container server is in the object list.
  • Query the location information of the third target object may include the following 308b1 or S208b2:
  • the third target object is written in the object server in the object storage system, if the location information of the third target object does not exist in the container server, the first location information of the third target object is obtained.
  • the object list is written, so that in the subsequent process of reading or deleting the third target object, the third target object can be read or deleted by querying the location information of the third target object in the object list.
  • the container server replaces the second location information of the third target object with the first location information of the third target object, and writes the second location information of the third target object to the deletion log of the container server in.
  • the third target object is already stored in the object server when the third target object is written to the object server.
  • the third target object to be written is a modified version of the stored third target object. Therefore, the second location information of the third target object may be replaced with the first location information of the third target object, specifically,
  • the container server deletes the second location information of the third target object, and writes the first location information of the third target object into the object list, such that in subsequent operations (eg, reading the third target object or deleting the third During the target object, the information of the accurate third target object can be queried in the container server to correctly read the third target object or delete the third target object.
  • the second location information of the third target object may be written into the deletion log of the container server, and the object server recovers the second location information of the third target in the object server according to the second location information of the third target object in the deletion log.
  • the proxy server may send a request message for uploading the third target object to the object server, and the object Receiving, by the server, the request message for uploading the third target object, and writing the third target object in the request message to the object server, and sending the first location information of the third target object to the proxy server, the third target
  • the first location information of the object includes a file identifier of the third target object, an offset of the third target object, and a size of the third target object, where the file identifier indicated by the third target object stores at least two files.
  • the file may include at least two objects, and it is known that when the object storage system writes When multiple small objects are entered, multiple small objects can be written to one file. This saves the storage resources of the file system of the object server, thereby improving the performance of the object server.
  • the first target object in the scenario 1 , the second target object in the scenario 2, and the third target object in the scenario 3 may be the same target object, or may be different targets.
  • Object If the first target object, the second target object, and the third target object are the same target object, for example, each is referred to as the first target object, the first target object may be written by the description of the three scenarios in the above embodiment.
  • the object storage system is such that the first target object can be read from the object storage system or the first target object can be deleted.
  • the container server when the container server deletes the location information of an object from the object list, and writes the location information of the object to the deletion log, the container server may The interaction of the object server, which recycles the object in the object server.
  • the following takes the first target object as an example, and exemplifies the method of recycling the object.
  • the data processing method may also include S401-S406:
  • the container server sends a garbage collection request message to the object server.
  • the garbage collection request message includes location information of the first target object in the deletion log.
  • the spam request message is used to request the object server to reclaim the content of the first target object in the object server (ie, including the metadata and data of the first target object).
  • the container server after the container server deletes the location information of the first target object from the object list, and the location information of the first target object is written into the deletion log, the container server is in a preset time interval.
  • the object server sends a garbage collection request message, or the container server can send a garbage collection request to the object server to reclaim the object in the object server (also known as garbage) when the remaining storage space of the object server is relatively small.
  • the object server receives a garbage collection request message sent by the container server.
  • the object server deletes the first target object according to the location information of the first target object in the garbage collection request message.
  • the object server may reclaim the garbage object in the object server, where the garbage object is an object indicated by the location information of the object in the deletion log of the container server, and the method for the object server to collect the first target object is: The location information of the first target object in the garbage collection request message deletes the first target object, thereby releasing the storage space of the object server.
  • the object server sends a garbage collection response message to the container server, where the garbage collection response message indicates that the first target object has been deleted.
  • the container server receives the garbage collection response message sent by the object server.
  • the container server deletes the location information of the first target object in the deletion log of the container server.
  • the container server may delete the location information of the first target object in the deletion log, thereby completing the recovery of the first target object, and the object storage The first target object no longer exists in the system.
  • the object storage system when an object is read and the object is deleted concurrently (that is, it can be understood that the object storage system processes the event of reading an object, and also needs to be processed.
  • the location information of the first target object is received from the object in the container server according to the method of reading the object and deleting the object in the foregoing embodiment. After the list is deleted, and the location information of the first target object is written in the delete log of the container server, the container server has read the location information of the first target object in the object list, and then the first target object is read this time. In the process of deleting and deleting the first target object, even if the location information of the first target object in the container server has been deleted, and the location information of the first target object has been written into the deletion log, this time can be read. Go to the first target object.
  • the location information of the first target object in the container server has been deleted, and the location information of the first target object has been written into the deletion log, and the first target object can also be read this time.
  • the reason is: in the process of deleting the first target object, the location information of the first target object may be written in the deletion log to indicate that the first target object is marked for deletion, and no need to be in the object server. The first target object is marked as deleted. Therefore, the first target object still exists in the object server and has not been reclaimed.
  • the object server may obtain the first target object according to the read query request message according to the container server. Location information, the first target object is read in the object server.
  • the data processing method provided by the embodiment of the present invention can avoid conflicts between the read object and the deleted object to a certain extent (refer to when the read object and the deleted object occur concurrently, the operation of deleting the object firstly causes the read object to be read. The operation could not read the object).
  • the process of deleting the object, reading the object, uploading the object, and reclaiming the object may be completed in the user state, which can reduce the difficulty in developing and maintaining the object storage system.
  • the solution provided by the embodiment of the present invention is mainly introduced from the perspective of interaction between the network elements.
  • various network elements such as a container server, an object server, and a proxy server, etc.
  • a container server such as a container server, an object server, and a proxy server, etc.
  • the embodiments of the present invention can be implemented in a combination of hardware or hardware and computer software in combination with the elements and algorithm steps of the various examples described in the embodiments disclosed herein. Whether a function is implemented in hardware or computer software to drive hardware depends on the specific application and design constraints of the solution. A person skilled in the art can use different methods to implement the described functions for each particular application, but such implementation should not be considered to be beyond the scope of the present application.
  • the embodiments of the present invention may divide the function modules of the container server, the object server, the proxy server, and the like according to the foregoing method examples.
  • each function module may be divided according to each function, or two or more functions may be integrated into one.
  • Processing module can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of the module in the embodiment of the present invention is schematic, and is only a logical function division, and the actual implementation may have another division manner.
  • FIG. 7 is a schematic diagram of a possible structure of the container server involved in the foregoing embodiment.
  • the container server may include: a receiving module 30, The query module 31, the update module 32, and the sending module 33.
  • the receiving module 30 can be used to support the container server to execute S102, S202, S307, and S405 in the foregoing method embodiment;
  • the query module 31 can be used to support the container server to execute S103, S203 in the foregoing method embodiment;
  • the update module 32 can S104, S308 (including S308a-S308b) and S406 are used to support the container server in the foregoing method embodiment;
  • the sending module 33 can be used to support the container server to execute S105, S204 and S401 in the above method embodiment.
  • the container server may further include a reading module 34.
  • the reading module 34 can be used to support the container server to perform the above-mentioned embodiment: "If the read query message received by the receiving module 30 includes the identification information of the container to which the first target object belongs and the identification information of the first target object, the update is performed. The module deletes the location information of the first target object in the object list, and reads the location information of the first target object in the object list before writing the location information of the first target object to the deletion log of the container server. All the related content of the steps involved in the foregoing method embodiments may be referred to the functional descriptions of the corresponding functional modules, and details are not described herein again.
  • FIG. 8 shows a possible structural diagram of the container server involved in the above embodiment.
  • the container server may include a processing module 40 and a communication module 41.
  • the processing module 40 can be used to control and manage the actions of the container server.
  • the processing module 40 can be used to support the container server to execute S103, S104, S203, S308 (including S308a-S308b) and S406 in the foregoing method embodiment, and / or other processes for the techniques described herein.
  • the communication module 41 can be used to support communication between the container server and other network entities.
  • the communication module 41 can be used to support the container server to execute S102, S105, S202, S204, S307, S401, and S405 in the foregoing method embodiments.
  • the container server may further include a storage module 42 for storing program code and data of the container server.
  • the processing module 40 may be a processor or a controller (for example, the processor 201 shown in FIG. 2 above), and may be, for example, a central processing unit (CPU), a general-purpose processor, and a digital signal processor. (digital signal processor, DSP), application-specific integrated circuit (ASIC), field programmable gate array (FPGA) or other programmable logic device, transistor logic device, hardware component or any combination. It is possible to implement or carry out the various illustrative logical blocks, modules and circuits described in connection with the embodiments of the invention.
  • the above processors may also be a combination of computing functions, such as one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like.
  • the communication module 41 may be a transceiver, a transceiver circuit, or a communication interface or the like (for example, may be the communication interface 203 shown in FIG. 2 described above).
  • the storage module 42 can be a memory (which can be, for example, the memory 202 shown above in FIG. 2).
  • the processing module 40 is a processor
  • the communication module 41 is a transceiver
  • the storage module 42 is a memory
  • the processor, the transceiver, and the memory can be connected by a bus.
  • the bus can be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus.
  • PCI peripheral component interconnect
  • EISA extended industry standard architecture
  • the bus can be divided into an address bus, a data bus, a control bus, and the like.
  • FIG. 9 is a schematic diagram of a possible structure of the object server involved in the foregoing embodiment.
  • the object server may include: a receiving module 50, The data module 51 and the transmitting module 52 are written.
  • the receiving module 50 can be used to support the object server to execute S207, S302, and S402 in the foregoing method embodiment;
  • the write data module 51 can be used to support the object server to execute S303 in the foregoing method embodiment;
  • the sending module 52 can be used to support the object server.
  • S209, S304, and S404 in the above method embodiment are executed.
  • the object server may further include a reading module 53 and a deleting module 54.
  • the reading module 53 can be used to support the object server to execute S208 in the above method embodiment; the deleting module 54 can be used to support the object server to execute S403 in the above method embodiment. All the related content of the steps involved in the foregoing method embodiments may be referred to the functional descriptions of the corresponding functional modules, and details are not described herein again.
  • the processing module 60 may be a processor or a controller (for example, the processor 301 shown in FIG. 2 above), and may be, for example, a CPU, a general-purpose processor, a DSP, an ASIC, an FPGA, or other programmable logic device, a transistor. Logic device, hardware component, or any combination thereof. It is possible to implement or carry out the various illustrative logical blocks, modules and circuits described in connection with the embodiments of the invention.
  • the above processors may also be a combination of computing functions, such as one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like.
  • the communication module 61 may be a transceiver, a transceiver circuit or a communication interface or the like (for example, may be the communication interface 303 shown in FIG. 2 described above).
  • the storage module 62 can be a memory (which can be, for example, the memory 302 shown above in FIG. 2).
  • the processing module 60 is a processor
  • the communication module 61 is a transceiver
  • the storage module 62 is a memory
  • the processor, the transceiver, and the memory can be connected by a bus.
  • the bus can be a PCI bus or an EISA bus.
  • the bus can be divided into an address bus, a data bus, a control bus, and the like.
  • FIG. 11 is a schematic diagram showing a possible structure of the proxy server involved in the foregoing embodiment.
  • the proxy server may include: a sending module 70 and Receive module 71.
  • the sending module 70 can be used to support the proxy server to execute S101, S201, S206, S301, and S306 in the foregoing method embodiment;
  • the receiving module 50 can be used to support the proxy server to execute S205 and S305 in the foregoing method embodiment. All the related content of the steps involved in the foregoing method embodiments may be referred to the functional descriptions of the corresponding functional modules, and details are not described herein again.
  • FIG. 12 shows a possible structural diagram of the proxy server involved in the above embodiment.
  • the proxy server may include a processing module 80 and a communication module 81.
  • the processing module 80 can be used to control and manage the actions of the proxy server.
  • the communication module 81 can be used to support communication between the proxy server and other network entities.
  • the communication module 81 can be used to support the proxy server to execute S101, S201, S206, S205, S301, S305, and S306 in the foregoing method embodiments.
  • the proxy server may further include a storage module 82 for storing program code and data of the proxy server.
  • the processing module 80 may be a processor or a controller (for example, the processor 101 shown in FIG. 2 above), and may be, for example, a CPU, a general-purpose processor, a DSP, an ASIC, an FPGA, or other programmable logic device, a transistor. Logic device, hardware component, or any combination thereof. It is possible to implement or carry out the various illustrative logical blocks, modules and circuits described in connection with the embodiments of the invention.
  • the above processors may also be a combination of computing functions, such as one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like.
  • the communication module 81 may be a transceiver, a transceiver circuit or a communication interface or the like (for example, may be the communication interface 103 as shown in FIG. 2 described above).
  • the storage module 82 can be a memory (which can be, for example, the memory 102 shown above in FIG. 2).
  • the processing module 80 is a processor
  • the communication module 81 is a transceiver
  • the storage module 82 is a memory
  • the processor, the transceiver, and the memory can be connected by a bus.
  • the bus can be a PCI bus or an EISA bus.
  • the bus can be divided into an address bus, a data bus, a control bus, and the like.
  • the above embodiments it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof.
  • a software program it may be implemented in whole or in part in the form of a computer program product.
  • the computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the processes or functions in accordance with embodiments of the present invention are generated in whole or in part.
  • the computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable device.
  • the computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be wired from a website site, computer, server or data center (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (eg infrared, wireless, microwave, etc.) to another website, computer, server or data center.
  • the computer readable storage medium can be any available media that can be accessed by a computer or a data storage device such as a server, data center, or the like that includes one or more available media.
  • the usable medium may be a magnetic medium (for example, a floppy disk, a magnetic disk, a magnetic tape), an optical medium (for example, a digital video disc (DVD)), or a semiconductor medium (such as a solid state drives (SSD)).
  • a magnetic medium for example, a floppy disk, a magnetic disk, a magnetic tape
  • an optical medium for example, a digital video disc (DVD)
  • a semiconductor medium such as a solid state drives (SSD)
  • the disclosed system, apparatus, and method may be implemented in other manners.
  • the device embodiments described above are merely illustrative.
  • the division of the modules or units is only a logical function division.
  • there may be another division manner for example, multiple units or components may be used. Combinations can be integrated into another system, or some features can be ignored or not executed.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be in an electrical, mechanical or other form.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
  • the integrated unit if implemented in the form of a software functional unit and sold or used as a standalone product, may be stored in a computer readable storage medium.
  • a computer readable storage medium A number of instructions are included to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to perform all or part of the steps of the methods described in various embodiments of the present application.
  • the foregoing storage medium includes: a flash memory, a mobile hard disk, a read only memory, a random access memory, a magnetic disk, or an optical disk, and the like, which can store program codes.

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Theoretical Computer Science (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

The embodiments of the present invention relate to the field of computer storage, and provided thereby is a data processing method, which may avoid to a certain extent conflict occurring between a reading object and a deleting object. The method comprises: a container server in an object storage system receiving a deletion query message sent by a proxy server, the deletion query message comprising identification information of a container to which a first target object belongs and identification information of the first target object; the container server querying location information of the first target object in an object list of the container server according to the identification information of the container to which the first target object belongs and the identification information of the first target object; if the location information of the first target object is found in the object list, the container server deleting the location information of the first target object in the object list and writing the location information of the first target object into a deletion log of the container server; and the container server sending a deletion response message to the proxy server.

Description

一种数据处理方法、装置及系统Data processing method, device and system 技术领域Technical field
本发明实施例涉及计算机存储领域,尤其涉及一种数据处理方法、装置及系统。Embodiments of the present invention relate to the field of computer storage, and in particular, to a data processing method, apparatus, and system.
背景技术Background technique
随着计算机存储技术的快速发展,对象存储系统以其高速访问特性、高可靠性以及可扩展性等优势,快速地成为计算机存储领域用于存储数据为主流存储系统。With the rapid development of computer storage technology, the object storage system quickly becomes the mainstream storage system for storing data in the computer storage field with its advantages of high-speed access characteristics, high reliability and scalability.
在对象存储系统中,用户使用某一终端(例如终端上的浏览器或者其他应用)时,可以使用终端向对象存储系统写入数据(可以称为对象,对象包括元数据和数据本身)、删除对象存储系统中的某些数据或者读取对象存储系统中的某些数据。如图1所示,对象存储系统可以包括终端10,代理服务器11,容器服务器12和对象服务器13。终端10读取对象存储系统中的数据(即对象)时,对象存储系统中的代理服务器11接收到终端10发送的对象读取请求,代理服务器11向对象存储系统的容器服务器12发送查询该对象位置信息的消息,然后容器服务器12可以在该容器服务器12中的数据库中查询该对象的位置信息,若查询到该对象的位置信息,则代理服务器11向对象服务器13发送该对象的位置信息,对象服务器13根据该对象的位置信息,读取该对象,并将读取的对象返回给终端10。In an object storage system, when a user uses a terminal (such as a browser on a terminal or other application), the terminal can use the terminal to write data to the object storage system (which can be called an object, the object includes metadata and the data itself), and deletes The object stores some data in the system or reads some data from the object storage system. As shown in FIG. 1, the object storage system may include a terminal 10, a proxy server 11, a container server 12, and an object server 13. When the terminal 10 reads the data (ie, the object) in the object storage system, the proxy server 11 in the object storage system receives the object read request sent by the terminal 10, and the proxy server 11 sends the query to the container server 12 of the object storage system. The location information message, and then the container server 12 can query the location information of the object in the database in the container server 12. If the location information of the object is queried, the proxy server 11 sends the location information of the object to the object server 13, The object server 13 reads the object based on the position information of the object, and returns the read object to the terminal 10.
终端10删除对象存储系统中的某一数据(即对象)时,代理服务器11接收到终端10发送的对象删除请求,同理,代理服务器11向容器服务器12发送查询该对象的位置信息的消息,然后容器服务器12在该容器服务器12的数据库中查询该对象的位置信息,若查询到该对象的位置信息,将该对象的位置信息发送给代理服务器11,代理服务器11向对象服务器13发送该对象的位置信息,然后对象服务器13根据该对象的位置信息,对该对象服务器13中的该对象做删除标记,并返回删除响应消息给代理服务器11,代理服务器11再向容器服务器12发送删除该容器服务器12中的该对象的位置信息的请求消息,从而容器服务器12删除数据库中的该对象的位置信息。When the terminal 10 deletes a certain data (ie, an object) in the object storage system, the proxy server 11 receives the object deletion request sent by the terminal 10. Similarly, the proxy server 11 sends a message to the container server 12 to query the location information of the object. The container server 12 then queries the location information of the object in the database of the container server 12. If the location information of the object is queried, the location information of the object is sent to the proxy server 11, and the proxy server 11 sends the object to the object server 13. Location information, and then the object server 13 deletes the object in the object server 13 according to the location information of the object, and returns a delete response message to the proxy server 11, and the proxy server 11 sends the container server 12 to delete the container. A request message for the location information of the object in the server 12, whereby the container server 12 deletes the location information of the object in the database.
然而,在上述方法中,当对象存储系统中并发存在读取某一对象(例如第一对象)的请求和删除该对象的请求时,由于在删除该第一对象的过程中,对象服务器需对该对象做删除标记,如果对象服务器先接收到指示删除该第一对象的第一对象的位置信息,后接收到指示读取该第一对象的第一对象的位置信息,由于对象服务器根据第一对象的位置信息可能已经对该第一对象做了删除标记,如此,可能会导致对象服务器根据第一目标的位置信息无法再读取该第一对象(即读取该对象失败),因此,导致读取第一对象和删除第一对象发生冲突。However, in the above method, when a request for reading an object (for example, the first object) and a request for deleting the object are concurrently present in the object storage system, since the object server needs to be in the process of deleting the first object, The object is marked as deleted. If the object server first receives the location information indicating the deletion of the first object of the first object, and then receives the location information indicating the first object that reads the first object, because the object server is according to the first The location information of the object may have been marked for deletion of the first object. As a result, the object server may not be able to read the first object according to the location information of the first target (ie, the object fails to be read), thus causing There is a conflict between reading the first object and deleting the first object.
发明内容Summary of the invention
本申请提供一种数据处理方法、装置及系统,能够在一定程度上避免读取对象和删除对象发生冲突。The present application provides a data processing method, apparatus, and system, which can avoid conflicts between a read object and a deleted object to a certain extent.
为达到上述目的,本申请采用如下技术方案:To achieve the above objectives, the present application adopts the following technical solutions:
第一方面,提供一种数据处理方法,该方法可以包括:容器服务器接收代理服务器发送的删除查询消息,该删除查询消息中包括第一目标对象所属的容器的标识信息和第一目标对象的标识信息;然后容器服务器根据第一目标对象所属的容器的标识信息和第一目标对象的标识信息在容器服务器的对象列表中查询第一目标对象的位置信息;若在对象列表中查询到第一目标对象的位置信息,容器服务器删除对象列表中的第一目标对象的位置信息,并且将第一目标对象的位置信息写入容器服务器的删除日志中;以及容器服务器向代理服务器发送删除响应消息。其中,对象列表中包含第一类对象的位置信息,该第一类对象为未被标记删除的、对象服务器中存储的对象,一个第一类对象的位置信息用于指示对象在对象服务器中的位置,删除日志中包含第二类对象的位置信息,该第二类对象为被标记删除的、对象服务器中存储的对象的位置信息。The first aspect provides a data processing method, where the method includes: the container server receives a delete query message sent by the proxy server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier of the first target object. The container server then queries the location information of the first target object in the object list of the container server according to the identifier information of the container to which the first target object belongs and the identification information of the first target object; if the first target is queried in the object list The location information of the object, the container server deletes the location information of the first target object in the object list, and writes the location information of the first target object into the deletion log of the container server; and the container server sends a deletion response message to the proxy server. The object list includes location information of the first type of object, the first type of object is an object stored in the object server that is not marked and deleted, and the location information of the first type of object is used to indicate that the object is in the object server. The location, the deletion log contains location information of the second type of object, and the second type of object is the location information of the object stored in the object server that is marked and deleted.
本申请提供的数据处理方法,在删除对象存储系统中的对象(例如上述第一目标对象)的过程中,由于容器服务器可以将该第一目标对象的位置信息从对象列表中删除,并且将该第一目标对象的位置新写入容器服务器的删除日志中,可知,容器服务器无需再将该第一目标对象的位置信息发送给代理服务器,代理服务器也无需再将该第一目标对象的位置信息发送给对象服务器,从而对象服务器也无需在对该对象服务器中的第一目标对象做删除标记,如此,当删除对象存储系统中的该第一目标对象与读取对象存储系统中的该第一目标对象并发发生时,由于在删除该第一目标对象的过程中,对象服务器中的该第一目标对象并没有被标记为删除,因此可以在对象服务器中读取到该第一目标对象,与现有技术相比,可以避免由于对象服务器中的第一目标对象被标记为删除,而造成读取该第一目标对象失败的问题,即可以避免读取第一目标对象和删除第一目标对象的发生冲突。The data processing method provided by the present application, in deleting an object in the object storage system (for example, the first target object), the container server may delete the location information of the first target object from the object list, and The location of the first target object is newly written into the deletion log of the container server. It can be seen that the container server does not need to send the location information of the first target object to the proxy server, and the proxy server does not need to further locate the location information of the first target object. Is sent to the object server, so that the object server does not need to delete the first target object in the object server, so when deleting the first target object in the object storage system and the first in the read object storage system When the target object occurs concurrently, the first target object in the object server is not marked as deleted during the process of deleting the first target object, so the first target object can be read in the object server, and Compared with the prior art, it can be avoided that the first target object in the object server is Record for deletion, reading problems caused by the failure of the first target object, that is, avoid reading the first target object and delete the conflict first target object.
进一步地,由于容器服务器无需再将该第一目标对象的位置信息发送给代理服务器,代理服务器也无需再将该第一目标对象的位置信息发送给对象服务器,从而对象服务器也无需在对该对象服务器中的第一目标对象做删除标记,如此,可以简化删除第一目标对象的流程,而且可以节约服务器之间的通信资源。Further, since the container server does not need to send the location information of the first target object to the proxy server, the proxy server does not need to send the location information of the first target object to the object server, so that the object server does not need to be in the object. The first target object in the server is marked for deletion, so that the process of deleting the first target object can be simplified, and the communication resources between the servers can be saved.
在第一方面的第一种可选的实现方式中,上述第一目标对象的位置信息可以包括第一目标对象所在的文件标识、第一目标对象的偏移量以及第一目标对象的尺寸,文件标识指示的文件中包括至少两个对象;或者,第一目标对象的位置信息可以包括第一目标对象的ID(identity)。In a first optional implementation manner of the first aspect, the location information of the first target object may include a file identifier of the first target object, an offset of the first target object, and a size of the first target object. The file identifier indicates that at least two objects are included in the file; or the location information of the first target object may include an ID of the first target object.
本申请中,根据第一目标对象写入对象存储系统中,存储的方法(可以理解为写入的方法)的不同,第一目标对象的位置信息包含的内容可以不同,对于不同的存储方法,上述数据处理方法均可以实现删除第一目标对象的操作,并且可以简化删除第一目标对象的流程,而且可以节约服务器之间的通信资源。In the present application, according to the first target object written in the object storage system, the stored method (which can be understood as the method of writing) is different, and the content information of the first target object may be different, and for different storage methods, The above data processing method can implement the operation of deleting the first target object, and can simplify the process of deleting the first target object, and can save communication resources between servers.
在第一方面的第二种可选的实现方式中,本申请提供的数据处理方法还可以包括:容器服务器接收代理服务器发送的读取查询消息,该读取查询消息中包括第二目标对象所属的容器的标识信息和第二目标对象的标识信息;然后容器服务器根据第二目标对象所属的容器的标识信息和第二目标对象的标识信息,在对象列表中查询第二目标对象的位置信息;若在对象列表中查询到第二目标对象的位置信息,容器服务器向代理服务器发送第二目标对象的位置信息,以指示代理服务器根据第二目标对象的位置信息从对象服务器中读取第二目标对象,该第二目标对象的位置信息包括第二目标对象所在的文件 标识、第二目标对象的偏移量以及第二目标对象的尺寸,文件标识指示的文件中包括至少两个对象。In a second optional implementation manner of the first aspect, the data processing method provided by the present application may further include: the container server receives a read query message sent by the proxy server, where the read query message includes the second target object The identifier information of the container and the identifier information of the second target object; the container server then queries the object list for the location information of the second target object according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object; If the location information of the second target object is queried in the object list, the container server sends the location information of the second target object to the proxy server, to instruct the proxy server to read the second target from the object server according to the location information of the second target object. The object, the location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, and the file indicated by the file identifier includes at least two objects.
本申请中,可以通过上述方法顺利地读取对象存储系统中的对象。In the present application, objects in the object storage system can be smoothly read by the above method.
在第一方面的第三种可选的实现方式中,若容器服务器接收的读取查询消息中包括第一目标对象所属的容器的标识信息和第一目标对象的标识信息,在容器服务器删除对象列表中的第一目标对象的位置信息,并且将第一目标对象的位置信息写入容器服务器的删除日志中之前,本申请提供的数据处理方法还可以包括:容器服务器读取对象列表中的第一目标对象的位置信息。In a third optional implementation manner of the first aspect, if the read query message received by the container server includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object, deleting the object in the container server Before the location information of the first target object in the list, and the location information of the first target object is written in the deletion log of the container server, the data processing method provided by the application may further include: the container server reads the number in the object list. The location information of a target object.
本申请中,在对象存储系统中,当读取某一对象与删除该对象并发发生时(即可以理解为对象存储系统处理读取某一对象的事件的同时也需要处理删除该对象的事件),以第一目标对象为例说明,在容器服务器将第一目标对象的位置信息从对象列表中删除,并且将第一目标对象的位置信息写入容器服务器的删除日志中之前,容器服务器已读取对象列表中的第一目标对象的位置信息,那么本次读取第一目标对象的流程和删除第一目标对象的流程中,即使容器服务器中的第一目标对象的位置信息已被删除,并且该第一目标对象的位置信息已被写入删除日志中,本次还可以读取到第一目标对象。In the present application, in the object storage system, when an object is read and the object is deleted concurrently (that is, it can be understood that the object storage system processes the event of reading an object, and also needs to process the event of deleting the object) Taking the first target object as an example, the container server reads the location information of the first target object from the object list after the container server writes the location information of the first target object to the delete log of the container server. Taking the location information of the first target object in the object list, in the process of reading the first target object and deleting the first target object, even if the location information of the first target object in the container server has been deleted, And the location information of the first target object has been written into the deletion log, and the first target object can also be read this time.
与现有技术相比,上述容器服务器中的第一目标对象的位置信息已被删除,并且该第一目标对象的位置信息已被写入删除日志中,本次还可以读取第一目标对象的原因是:本次删除第一目标对象的过程中,可以在删除日志中写入第一目标对象的位置信息,以表示对该第一目标对象做了删除标记,无需再对对象服务器中的第一目标对象做删除标记,因此,在对象服务器中该第一目标对象依然存在,并且还未被回收,如此,对象服务器可以根据上述容器服务器根据读取查询请求消息获取的第一目标对象的位置信息,在该对象服务器中读取该第一目标对象。可见本发明实施例提供的数据处理方法,能够在一定程度上避免读取对象和删除对象的冲突(指的是读取对象和删除对象并发发生时,先删除对象的操作会造成读取对象的操作无法读取到该对象)Compared with the prior art, the location information of the first target object in the container server has been deleted, and the location information of the first target object has been written into the deletion log, and the first target object can also be read this time. The reason is: in the process of deleting the first target object, the location information of the first target object may be written in the deletion log to indicate that the first target object is marked for deletion, and no need to be in the object server. The first target object is marked as deleted. Therefore, the first target object still exists in the object server and has not been reclaimed. Thus, the object server may obtain the first target object according to the read query request message according to the container server. Location information, the first target object is read in the object server. It can be seen that the data processing method provided by the embodiment of the present invention can avoid conflicts between the read object and the deleted object to a certain extent (refers to when the read object and the deleted object occur concurrently, the operation of deleting the object firstly causes the read object to be read. The operation could not read the object)
在第一方面的第四种可选的实现方式中,本申请提供的数据处理方法还可以包括:容器服务器向对象服务器发送垃圾回收请求消息,该垃圾回收请求消息中包括删除日志中的目标对象的位置信息;并且容器服务器接收对象服务器发送的垃圾回收响应消息,以及容器服务器删除删除日志中目标对象的位置信息,其中,垃圾回收响应消息指示对象服务器已删除目标对象。In a fourth optional implementation manner of the first aspect, the data processing method provided by the application may further include: the container server sending a garbage collection request message to the object server, where the garbage collection request message includes deleting the target object in the log Location information; and the container server receives the garbage collection response message sent by the object server, and the container server deletes the location information of the target object in the deletion log, wherein the garbage collection response message indicates that the target server has deleted the target object.
本申请中,容器服务器删除目标对象之后(即将目标对象的位置信息从对象列表中删除,并且将该目标对象的位置信息写入删除日志之后),容器服务器还可以根据删除日志中的目标对象的位置信息,请求对象服务器删除(即回收)该对象服务器中的目标对象的内容,从而容器服务器删除删除日志中的目标对象的位置信息,从而彻底删除对象存储系统中的该目标对象。In the present application, after the container server deletes the target object (ie, the location information of the target object is deleted from the object list, and the location information of the target object is written to the deletion log), the container server may also delete the target object according to the target object. The location information requests the object server to delete (ie, recycle) the content of the target object in the object server, so that the container server deletes the location information of the target object in the deletion log, thereby completely deleting the target object in the object storage system.
在第一方面的第五种可选的是实现方式中,本申请提供的数据处理方法还可以包括:容器服务器接收代理服务器发送的位置更新消息;并且容器服务器根据位置更新消息,更新第三目标对象的位置信息,该位置更新消息用于更新第三目标对象的位置信息,该位置更新消息中包括第三目标对象所属的容器的标识信息、第三目标对象的标识信息以及第三目标对象的第一位置信息。In a fifth optional implementation manner of the first aspect, the data processing method provided by the application may further include: the container server receives the location update message sent by the proxy server; and the container server updates the third target according to the location update message. Location information of the object, the location update message is used to update the location information of the third target object, where the location update message includes the identifier information of the container to which the third target object belongs, the identifier information of the third target object, and the third target object. First location information.
在第一方面的第六种可选的实现方式中,上述容器服务器根据位置更新消息,更新 第三目标对象的位置信息的方法可以包括:容器服务器根据第三目标对象所属的容器的标识信息、第三目标对象的标识信息,在容器服务器的对象列表中查询第三目标对象的位置信息;若在对象列表中未查询到第三目标对象的位置信息,容器服务器将位置更新消息中的第三目标对象的第一位置信息写入对象列表;若在对象列表中查询到第三目标对象的位置信息,该第三目标对象的位置信息为第二位置信息,并且该第三目标对象的第二位置信息与位置更新消息中的第三目标对象的第一位置信息不同,容器服务器将第三目标对象的第二位置信息替换为第三目标对象的第一位置信息,并且将第三目标对象的第二位置信息写入容器服务器的删除日志中。In a sixth optional implementation manner of the first aspect, the method for updating the location information of the third target object by the container server according to the location update message may include: the container server according to the identifier information of the container to which the third target object belongs, The identification information of the third target object is used to query the location information of the third target object in the object list of the container server; if the location information of the third target object is not queried in the object list, the container server will be the third in the location update message. The first location information of the target object is written to the object list; if the location information of the third target object is queried in the object list, the location information of the third target object is the second location information, and the second target object is the second location information. The location information is different from the first location information of the third target object in the location update message, the container server replaces the second location information of the third target object with the first location information of the third target object, and the third target object The second location information is written to the delete log of the container server.
本申请中,在对象存储系统中,容器服务器可以更新对象存储系统中的对象(例如上述第三目标对象)的位置信息(例如,在写入第三目标对象之后,更新第三目标对象的位置信息),如此,在后续的读取或者删除该第三目标对象时,可以从容器服务器中查询到准确的第三目标对象的位置信息,以正确读取该第三目标对象,或者删除第三目标对象。In the present application, in the object storage system, the container server may update location information of an object (eg, the third target object described above) in the object storage system (eg, update the location of the third target object after writing the third target object) Information), in this way, when the third target object is subsequently read or deleted, the location information of the accurate third target object can be queried from the container server to correctly read the third target object, or delete the third object. target.
第二方面,提供一种数据处理方法,该方法可以包括:对象服务器接收代理服务器发送的上传目标对象的请求消息,该上传目标对象的请求消息中包括第三目标对象;然后对象服务器将该第三目标对象写入对象服务器中;以及对象服务器向代理服务器发送第三目标对象的位置信息,该第三目标对象的位置信息包括第三目标对象所在的文件标识、第三目标对象的偏移量以及第三目标对象的尺寸,文件标识指示的文件中包括有至少两个对象。The second aspect provides a data processing method, the method may include: the object server receives a request message of the upload target object sent by the proxy server, where the request message of the upload target object includes a third target object; The third target object is written in the object server; and the object server sends the location information of the third target object to the proxy server, where the location information of the third target object includes the file identifier of the third target object and the offset of the third target object And the size of the third target object, the file identifier indicates that at least two objects are included in the file.
本申请提供的数据处理方法,在向对象存储系统中上传对象(例如可以称为第三目标对象)的过程中,由于对象服务器将第三目标对象写入对象服务器的文件系统的文件中,该文件中可以包括至少两个对象,可知,当对象存储系统中写入多个小对象时,可以将多个小对象写入一个文件中,如此,可以节省对象服务器的文件系统的存储资源,从而提高对象服务器的性能。The data processing method provided by the present application, in the process of uploading an object (for example, may be referred to as a third target object) to the object storage system, because the object server writes the third target object into the file system file of the object server, The file may include at least two objects. It can be known that when multiple small objects are written in the object storage system, multiple small objects can be written into one file, thereby saving the storage resources of the file system of the object server. Improve the performance of the object server.
在第二方面的第一种可选的实现方式中,本申请提供的数据处理方法还可以包括:对象服务器接收代理服务器发送的第二目标对象的位置信息;并且对象服务器根据第二目标对象的位置信息读取第二目标对象;以及对象服务器向代理服务器发送发送第二目标对象。In a first optional implementation manner of the second aspect, the data processing method provided by the present application may further include: the object server receives location information of the second target object sent by the proxy server; and the object server is configured according to the second target object. The location information reads the second target object; and the object server sends a second target object to the proxy server.
在第二方面的第二种可选的实现方式中,本申请提供的数据处理方法还可以包括:对象服务器接收容器服务器发送的垃圾回收请求消息,该垃圾回收请求消息中包括容器服务器的删除日志中的第一目标对象的位置信息;并且对象服务器根据第一目标对象的位置信息,删除第一目标对象;以及对象服务器向容器服务器发送垃圾回收响应消息,该垃圾回收响应消息指示已删除第一目标对象。In a second optional implementation manner of the second aspect, the data processing method provided by the application may further include: receiving, by the object server, a garbage collection request message sent by the container server, where the garbage collection request message includes a deletion log of the container server Position information of the first target object; and the object server deletes the first target object according to the location information of the first target object; and the object server sends a garbage collection response message to the container server, the garbage collection response message indicating that the first target has been deleted target.
对于第二方面的第二种可选的实现方式的技术效果的描述,可以参见上述第一方面的第四种可选的实现方式的技术效果的描述,此处不再赘述。For a description of the technical effects of the second optional implementation of the second aspect, refer to the description of the technical effects of the fourth optional implementation of the foregoing first aspect, and details are not described herein again.
第三方面,本申请提供一种数据处理方法,该方法可以包括:代理服务器向对象服务器发送上传目标对象的请求消息,该上传目标对象的请求消息中包括目标对象;然后代理服务器接收对象服务器发送的目标对象的第一位置信息,该目标对象的第一位置信息包括目标对象所在的文件标识、目标对象的偏移量以及目标对象的尺寸,文件标识指示的文件中保存有至少两个对象;以及代理服务器向容器服务器发送位置更新消息,以 指示容器服务器根据位置更新消息,更新容器服务器的对象列表中的目标对象的位置信息,该位置更新消息中包括目标对象所属的容器的标识信息、目标对象的标识信息以及上述目标对象的第一位置信息。In a third aspect, the present application provides a data processing method, the method may include: the proxy server sends a request message for uploading a target object to the object server, where the request message of the upload target object includes a target object; and then the proxy server receives the object server and sends the First location information of the target object, the first location information of the target object includes a file identifier of the target object, an offset of the target object, and a size of the target object, where at least two objects are stored in the file indicated by the file identifier; And the proxy server sends a location update message to the container server, to instruct the container server to update the location information of the target object in the object list of the container server according to the location update message, where the location update message includes the identifier information and the target of the container to which the target object belongs. The identification information of the object and the first location information of the target object.
在第三方面的第一种可选的实现方式中,本申请提供的数据处理方法还可以包括:代理服务器接收容器服务器发送的删除响应消息,该删除响应消息为容器服务删除对象列表中的目标对象的位置信息,并将目标目标对象的位置信息写入容器服务器的删除日志之后发送的。In a first optional implementation manner of the third aspect, the data processing method provided by the present application may further include: receiving, by the proxy server, a delete response message sent by the container server, where the delete response message is a target of the container service deletion target list The location information of the object, and the location information of the target target object is sent after being written to the delete log of the container server.
第三方面及其可选的实现方式的技术效果可以参见第一方面及其各种可选的实现方式,第二方面及其各种可选的实现方式的技术效果的相关描述,此处不再赘述。For the technical effects of the third aspect and its optional implementation, reference may be made to the first aspect and various optional implementation manners thereof, and related descriptions of the technical effects of the second aspect and various optional implementation manners thereof, Let me repeat.
第四方面,提供一种容器服务器,该容器服务器可以包括:接收模块、查询模块、更新模块以及发送模块。其中,接收模块可以用于接收代理服务器发送的删除查询消息,该删除查询消息中包括第一目标对象所属的容器的标识信息和第一目标对象的标识信息;查询模块可以用于根据接收模块接收的第一目标对象所属的容器的标识信息和第一目标对象的标识信息,在容器服务器的对象列表中查询第一目标对象的位置信息,该对象列表中包含第一类对象的位置信息,该第一类对象为未被标记删除的、对象服务器中存储的对象,一个第一类对象的位置信息用于指示对象在对象服务器中的位置;更新模块可以用于若查询模块在对象列表中查询到第一目标对象的位置信息,删除对象列表中的第一目标对象的位置信息,并且将第一目标对象的位置信息写入容器服务器的删除日志中,该删除日志中包含第二类对象的位置信息,该第二类对象为被标记删除的、对象服务器中存储的对象的位置信息;发送模块可以用于向代理服务器发送删除响应消息。In a fourth aspect, a container server is provided, and the container server can include: a receiving module, a query module, an update module, and a sending module. The receiving module may be configured to receive the delete query message sent by the proxy server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object; the query module may be configured to receive according to the receiving module. The identification information of the container to which the first target object belongs and the identification information of the first target object, and querying the location information of the first target object in the object list of the container server, where the object list includes location information of the first type of object, The first type of object is an object stored in the object server that is not marked for deletion, and the location information of the first type object is used to indicate the location of the object in the object server; the update module can be used to query the object list in the query module. Go to the location information of the first target object, delete the location information of the first target object in the object list, and write the location information of the first target object into the deletion log of the container server, where the deletion log includes the second type of object Location information, the second type of object is marked, deleted, object service Position information stored in the object; transmitting module may be configured to send a message deletion response to the proxy server.
在第四方面的第一种可选的实现方式中,上述第一目标对象的位置信息包括第一目标对象所在的文件标识、第一目标对象的偏移量以及第一目标对象的尺寸,该文件标识指示的文件中包括至少两个对象;或者,第一目标对象的位置信息包括第一目标对象的ID。In a first optional implementation manner of the fourth aspect, the location information of the first target object includes a file identifier of the first target object, an offset of the first target object, and a size of the first target object, where The file identifier indicates that at least two objects are included in the file; or the location information of the first target object includes the ID of the first target object.
在第四方面的第二种可选的实现方式中,上述接收模块还可以用于接收代理服务器发送的读取查询消息,读取查询消息中包括第二目标对象所属的容器的标识信息和第二目标对象的标识信息;上述查询模块还可以用于根据接收模块接收的第二目标对象所属的容器的标识信息和第二目标对象的标识信息,在对象列表中查询第二目标对象的位置信息,该第二目标对象的位置信息包括第二目标对象所在的文件标识、第二目标对象的偏移量以及第二目标对象的尺寸,文件标识指示的文件中包括至少两个对象;上述发送模块还可以用于若查询模块在对象列表中查询到第二目标对象的位置信息,容器服务器向代理服务器发送第二目标对象的位置信息,以指示代理服务器根据第二目标对象的位置信息从对象服务器中读取第二目标对象。In a second optional implementation manner of the fourth aspect, the receiving module may be further configured to receive a read query message sent by the proxy server, where the read query message includes the identifier information of the container to which the second target object belongs and the first The identifier information of the second target object may be used to query the location information of the second target object in the object list according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object received by the receiving module. The location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, where the file indicated by the file identifier includes at least two objects; the sending module The container server may further send the location information of the second target object to the proxy server, to indicate the location information of the second target object according to the location information of the second target object from the object server. Read the second target object in .
在第四方面的第三种可选的实现方式中,本申请提供的容器服务器还可以包括读取模块。该读取模块可以用于若接收模块接收的读取查询消息中包括第一目标对象所属的容器的标识信息和第一目标对象的标识信息,在更新模块删除对象列表中的第一目标对象的位置信息,并且将第一目标对象的位置信息写入容器服务器的删除日志中之前,读取对象列表中的第一目标对象的位置信息。In a third optional implementation manner of the fourth aspect, the container server provided by the present application may further include a reading module. The reading module may be configured to: if the read query message received by the receiving module includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object, the first target object in the object list is deleted in the update module The location information, and the location information of the first target object in the object list is read before the location information of the first target object is written in the deletion log of the container server.
在第四方面的第四种可选的实现方式中,上述发送模块还可以用于向对象服务器发送垃圾回收请求消息,该垃圾回收请求消息中包括删除日志中的目标对象的位置信息; 上述接收模块还可以用于接收对象服务器发送的垃圾回收响应消息,该垃圾回收响应消息指示对象服务器已删除目标对象;更新模块还可以用于删除删除日志中目标对象的位置信息。In a fourth optional implementation manner of the fourth aspect, the sending module may be further configured to send a garbage collection request message to the object server, where the garbage collection request message includes deleting location information of the target object in the log; The module may be further configured to receive a garbage collection response message sent by the object server, where the garbage collection response message indicates that the target server has deleted the target object; and the update module may further be configured to delete the location information of the target object in the deletion log.
在第四方面的第五种可选的实现方式中,上述接收模块还可以用于接收代理服务器发送的位置更新消息,该位置更新消息用于更新第三目标对象的位置信息,该位置更新消息中包括第三目标对象所属的容器的标识信息、第三目标对象的标识信息以及第三目标对象的第一位置信息;上述更新模块还可以用于根据接收模块接收的位置更新消息,更新第三目标对象的位置信息。In a fifth optional implementation manner of the fourth aspect, the receiving module is further configured to receive a location update message sent by the proxy server, where the location update message is used to update location information of the third target object, where the location update message is The identifier information of the container to which the third target object belongs, the identification information of the third target object, and the first location information of the third target object are included; the update module may be further configured to update the third according to the location update message received by the receiving module. The location information of the target object.
在第四方面的第六种可选的实现方式中,上述查询模块还可以用于根据第三目标对象所属的容器的标识信息、第三目标对象的标识信息,在容器服务器的对象列表中查询第三目标对象的位置信息;上述更新模块具体用于若查询模块在对象列表中未查询到第三目标对象的位置信息,将位置更新消息中的第三目标对象的第一位置信息写入对象列表,若查询模块在对象列表中查询到第三目标对象的位置信息,第三目标对象的位置信息为第二位置信息,并且第三目标对象的第二位置信息与位置更新消息中的第三目标对象的第一位置信息不同,将第三目标对象的第二位置信息替换为第三目标对象的第一位置信息,并且将第三目标对象的第二位置信息写入容器服务器的删除日志中。In a sixth optional implementation manner of the fourth aspect, the query module may be further configured to query the object list of the container server according to the identifier information of the container to which the third target object belongs and the identifier information of the third target object. Position information of the third target object; the update module is specifically configured to: when the query module does not query the location information of the third target object in the object list, write the first location information of the third target object in the location update message to the object a list, if the query module queries the location information of the third target object in the object list, the location information of the third target object is the second location information, and the second location information of the third target object and the third location information in the location update message The first location information of the target object is different, the second location information of the third target object is replaced with the first location information of the third target object, and the second location information of the third target object is written into the deletion log of the container server. .
第五方面,提供一种对象服务器,该对象服务器可以包括接收模块、写数据模块以及发送模块。其中,接收模块可以用于接收代理服务器发送的上传目标对象的请求消息,该上传目标对象的请求消息中包括第三目标对象;写数据模块可以用于将接收模块接收的第三目标对象写入对象服务器中;发送模块可以用于向代理服务器发送第三目标对象的位置信息,该第三目标对象的位置信息包括第三目标对象所在的文件标识、第三目标对象的偏移量以及第三目标对象的尺寸,文件标识指示的文件中包括有至少两个对象。In a fifth aspect, an object server is provided, which may include a receiving module, a write data module, and a sending module. The receiving module may be configured to receive a request message of the upload target object sent by the proxy server, where the request message of the upload target object includes a third target object, and the write data module may be configured to write the third target object received by the receiving module. In the object server, the sending module may be configured to send, to the proxy server, location information of the third target object, where the location information of the third target object includes a file identifier of the third target object, an offset of the third target object, and a third The size of the target object, the file identifier indicates that at least two objects are included in the file.
在第五方面的第一种可选的实现方式中,本申请提供的对象服务器还可以包括读取模块。上述接收模块还可以用于接收代理服务器发送的第二目标对象的位置信息;读取模块可以用于根据接收模块接收的第二目标对象的位置信息读取第二目标对象;上述发送模块还可以用于向代理服务器发送发送第二目标对象。In a first optional implementation manner of the fifth aspect, the object server provided by the application may further include a reading module. The receiving module may be further configured to receive location information of the second target object sent by the proxy server; the reading module may be configured to read the second target object according to the location information of the second target object received by the receiving module; Used to send a second target object to the proxy server.
在第五方面的第二种可选的实现方式中,本申请提供的对象服务器还可以包括删除模块。上述接收模块还可以用于接收容器服务器发送的垃圾回收请求消息,该垃圾回收请求消息中包括容器服务器的删除日志中的第一目标对象的位置信息;该删除模块可以用于根据接收模块接收的第一目标对象的位置信息,删除第一目标对象;上述发送模块还可以用于向容器服务器发送垃圾回收响应消息,该垃圾回收响应消息指示已删除第一目标对象。In a second optional implementation manner of the fifth aspect, the object server provided by the application may further include a deletion module. The receiving module may be further configured to receive a garbage collection request message sent by the container server, where the garbage collection request message includes location information of the first target object in the deletion log of the container server; the deletion module may be configured to receive according to the receiving module. The location information of the first target object deletes the first target object; the sending module may be further configured to send a garbage collection response message to the container server, where the garbage collection response message indicates that the first target object has been deleted.
第六方面,提供一种代理服务器,该代理服务器可以包括发送模块和接收模块。其中,发送模块可以用于向对象服务器发送上传目标对象的请求消息,该上传目标对象的请求消息中包括目标对象;接收模块可以用于接收对象服务器发送的目标对象的第一位置信息,该目标对象的第一位置信息包括目标对象所在的文件标识、目标对象的偏移量以及目标对象的尺寸,文件标识指示的文件中保存有至少两个对象;上述发送模块还可以用于向容器服务器发送位置更新消息,以指示容器服务器根据位置更新消息,更新容器服务器的对象列表中的目标对象的位置信息,该位置更新消息中包括目标对象所属的容器的标识信息、目标对象的标识信息以及目标对象的第一位置信息。In a sixth aspect, a proxy server is provided, which can include a sending module and a receiving module. The sending module may be configured to send a request message for uploading the target object to the object server, where the request message of the upload target object includes a target object, and the receiving module may be configured to receive first location information of the target object sent by the object server, where the target The first location information of the object includes a file identifier of the target object, an offset of the target object, and a size of the target object, where at least two objects are stored in the file indicated by the file identifier; the sending module may be further configured to send to the container server. a location update message to instruct the container server to update the location information of the target object in the object list of the container server according to the location update message, where the location update message includes the identification information of the container to which the target object belongs, the identification information of the target object, and the target object. First location information.
在第六方面的第一种可选的实现方式中,上述接收模块还可以用于接收容器服务器发送的删除响应消息,该删除响应消息为容器服务删除对象列表中的目标对象的位置信息,并将目标目标对象的位置信息写入容器服务器的删除日志之后发送的。In a first optional implementation manner of the sixth aspect, the receiving module is further configured to receive a deletion response message sent by the container server, where the deletion response message is a location information of the target object in the container service deletion object list, and The location information of the target target object is sent after being written to the delete log of the container server.
第七方面,提供一种容器服务器,该容器服务器可以包括处理器和与该处理器耦合连接的存储器。该存储器可以用于存储计算机指令。当该容器服务器运行时,该处理器执行该存储器存储的该计算机指令,以使得该容器服务器执行上述第一方面及其各种可选的实现方式中任意之一所述的数据处理方法。In a seventh aspect, a container server is provided, the container server can include a processor and a memory coupled to the processor. This memory can be used to store computer instructions. When the container server is running, the processor executes the computer instructions stored by the memory to cause the container server to perform the data processing method of any of the above first aspects and various alternative implementations thereof.
第八方面,提供一种计算机可读存储介质,该计算机可读存储介质可以包括计算机指令。当该计算机指令在容器服务器上运行时,使得该容器服务器执行上述第一方面及其各种可选的实现方式中任意之一所述的数据处理方法。In an eighth aspect, a computer readable storage medium is provided, the computer readable storage medium comprising computer instructions. When the computer instruction is run on the container server, the container server is caused to perform the data processing method of any of the above first aspects and various alternative implementations thereof.
第九方面,提供一种包括计算机指令的计算机程序产品,当该计算机程序产品在容器服务器上运行时,使得该容器服务器执行上述第一方面及其各种可选的实现方式中任意之一所述的数据处理方法。In a ninth aspect, a computer program product comprising computer instructions for causing a container server to perform any of the first aspect described above and various alternative implementations thereof when the computer program product is run on a container server The data processing method described.
第七方面至第九方面的技术效果的描述,可以参见上述对第一方面的技术效果的相关描述,此处不再赘述。For the description of the technical effects of the seventh aspect to the ninth aspect, reference may be made to the related description of the technical effects of the first aspect, and details are not described herein again.
第十方面,提供一种对象服务器,该对象服务器可以包括处理器和与该处理器耦合连接的存储器。该存储器可以用于存储计算机指令。当该对象服务器运行时,该处理器执行该存储器存储的该计算机指令,以使得该对象服务器执行上述第二方面及其各种可选的实现方式中任意之一所述的数据处理方法。In a tenth aspect, an object server is provided, the object server can include a processor and a memory coupled to the processor. This memory can be used to store computer instructions. When the object server is running, the processor executes the computer instructions stored by the memory to cause the object server to perform the data processing method of any of the above second aspects and various alternative implementations thereof.
第十一方面,提供一种计算机可读存储介质,该计算机可读存储介质可以包括计算机指令。当该计算机指令在对象服务器上运行时,使得该对象服务器执行上述第二方面及其各种可选的实现方式中任意之一所述的数据处理方法。In an eleventh aspect, a computer readable storage medium is provided, the computer readable storage medium comprising computer instructions. When the computer instruction is run on the object server, the object server is caused to perform the data processing method of any of the above second aspects and various alternative implementations thereof.
第十二方面,提供一种包括计算机指令的计算机程序产品,当该计算机程序产品在对象服务器上运行时,使得该对象服务器执行上述第二方面及其各种可选的实现方式中任意之一所述的数据处理方法。According to a twelfth aspect, a computer program product comprising computer instructions, when the computer program product is run on an object server, causes the object server to perform any one of the second aspect described above and various alternative implementations thereof The data processing method described.
第十方面至第十二方面的技术效果的描述,可以参见上述对第二方面的技术效果的相关描述,此处不再赘述。For a description of the technical effects of the tenth to twelfth aspects, reference may be made to the related description of the technical effects of the second aspect, and details are not described herein again.
第十三方面,提供一种代理服务器,该代理服务器可以包括处理器和与该处理器耦合连接的存储器。该存储器可以用于存储计算机指令。当该代理服务器运行时,该处理器执行该存储器存储的该计算机指令,以使得该代理服务器执行上述第三方面及其各种可选的实现方式中任意之一所述的数据处理方法。In a thirteenth aspect, a proxy server is provided, the proxy server can include a processor and a memory coupled to the processor. This memory can be used to store computer instructions. When the proxy server is running, the processor executes the computer instructions stored by the memory to cause the proxy server to perform the data processing method of any of the above third aspects and various alternative implementations thereof.
第十四方面,提供一种计算机可读存储介质,该计算机可读存储介质可以包括计算机指令。当该计算机指令在代理服务器上运行时,使得该代理服务器执行上述第三方面及其各种可选的实现方式中任意之一所述的数据处理方法。In a fourteenth aspect, a computer readable storage medium is provided, the computer readable storage medium comprising computer instructions. When the computer instruction is run on a proxy server, the proxy server is caused to perform the data processing method of any of the above third aspects and various alternative implementations thereof.
第十五方面,提供一种包括计算机指令的计算机程序产品,当该计算机程序产品在代理服务器上运行时,使得该代理服务器执行上述第三方面及其各种可选的实现方式中任意之一所述的数据处理方法。According to a fifteenth aspect, a computer program product comprising computer instructions, when executed on a proxy server, causes the proxy server to perform any one of the above third aspects and various alternative implementations thereof The data processing method described.
第十三方面至第十五方面的技术效果的描述,可以参见上述对第三方面的技术效果的相关描述,此处不再赘述。For a description of the technical effects of the thirteenth aspect to the fifteenth aspect, reference may be made to the related description of the technical effects of the third aspect, and details are not described herein again.
第十六方面,提供一种对象存储系统,该对象存储系统可以包括上述第四方面及其 各种可选的实现方式中任意之一所述的容器服务器,上述第五方面及其各种可选的实现方式中任意之一所述的对象服务器,以及上述第六方面及其各种可选的实现方式中任意之一所述的代理服务器。According to a sixteenth aspect, an object storage system is provided, which may include the container server according to any one of the foregoing fourth aspects and various alternative implementations thereof, the fifth aspect and various The object server of any one of the selected implementations, and the proxy server of any of the sixth aspect and various alternative implementations thereof.
或者,该对象存储系统系统可以包括上述第七方面中的容器服务器,第十方面中的对象服务器,以及上述第十三方面中的代理服务器。Alternatively, the object storage system system may include the container server in the seventh aspect, the object server in the tenth aspect, and the proxy server in the thirteenth aspect.
第十六方面的相关内容和技术效果的描述可以参见上述对第一方面或任意一种可能的实现方式,第二方面或任意一种可能的实现方式以及第三方面或任意一种可能的实现方式的相关内容和技术效果的相关描述,此处不再赘述。For a description of the related content and technical effects of the sixteenth aspect, reference may be made to the foregoing first aspect or any possible implementation manner, the second aspect or any possible implementation manner, and the third aspect or any possible implementation. The related content of the method and the related description of the technical effect will not be described here.
附图说明DRAWINGS
图1为本发明实施例提供的一种对象存储系统的架构示意图;1 is a schematic structural diagram of an object storage system according to an embodiment of the present invention;
图2为本发明实施例提供的各种服务器的硬件示意图;2 is a schematic diagram of hardware of various servers according to an embodiment of the present invention;
图3为本发明实施例提供的一种数据处理方法示意图一;3 is a schematic diagram 1 of a data processing method according to an embodiment of the present invention;
图4为本发明实施例提供的一种数据处理方法示意图二;4 is a second schematic diagram of a data processing method according to an embodiment of the present invention;
图5为本发明实施例提供的一种数据处理方法示意图三;FIG. 5 is a schematic diagram 3 of a data processing method according to an embodiment of the present disclosure;
图6为本发明实施例提供的一种数据处理方法示意图四;FIG. 6 is a schematic diagram 4 of a data processing method according to an embodiment of the present disclosure;
图7为本发明实施例提供的容器服务器的结构示意图一;FIG. 7 is a schematic structural diagram 1 of a container server according to an embodiment of the present invention;
图8为本发明实施例提供的容器服务器的结构示意图二;FIG. 8 is a schematic structural diagram 2 of a container server according to an embodiment of the present disclosure;
图9为本发明实施例提供的对象服务器的结构示意图一;FIG. 9 is a schematic structural diagram 1 of an object server according to an embodiment of the present disclosure;
图10为本发明实施例提供的对象服务器的结构示意图二;FIG. 10 is a schematic structural diagram 2 of an object server according to an embodiment of the present disclosure;
图11为本发明实施例提供的代理服务器的结构示意图一;FIG. 11 is a schematic structural diagram 1 of a proxy server according to an embodiment of the present invention;
图12为本发明实施例提供的代理服务器的结构示意图二。FIG. 12 is a schematic structural diagram 2 of a proxy server according to an embodiment of the present invention.
具体实施方式Detailed ways
本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。The term "and/or" in this context is merely an association describing the associated object, indicating that there may be three relationships, for example, A and/or B, which may indicate that A exists separately, and both A and B exist, respectively. B these three situations.
本发明实施例的说明书和权利要求书中的术语“第一”和“第二”等是用于区别不同的对象,而不是用于描述对象的特定顺序。例如,第一目标对象和第二目标对象等是用于区别不同的目标对象,而不是用于描述目标对象的特定顺序。The terms "first" and "second" and the like in the specification and claims of the embodiments of the present invention are used to distinguish different objects, and are not intended to describe a specific order of the objects. For example, the first target object and the second target object are used to distinguish different target objects, rather than to describe a specific order of the target objects.
在本发明实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本发明实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of the present invention, the words "exemplary" or "such as" are used to mean an example, illustration, or illustration. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the invention should not be construed as preferred or advantageous over other embodiments or designs. Rather, the use of the words "exemplary" or "such as" is intended to present the concepts in a particular manner.
在本发明实施例的描述中,除非另有说明,“多个”的含义是指两个或两个以上。例如,多个处理单元是指两个或两个以上的处理单元;多个系统是指两个或两个以上的系统。In the description of the embodiments of the present invention, the meaning of "a plurality" means two or more unless otherwise stated. For example, a plurality of processing units refers to two or more processing units; a plurality of systems refers to two or more systems.
首先对本发明实施例提供的一种数据处理方法、装置及系统中涉及的一些概念做解释说明。First, some concepts involved in the data processing method, apparatus, and system provided by the embodiments of the present invention are explained.
容器:在对象存储领域,也可以称为桶,其中存储有对象的信息(例如可以称为对 象列表,包括多个对象的位置信息,例如对象的ID,对象在某一文件中的偏移量以及对象的大小等信息),容器位于容器服务器中。Container: In the field of object storage, it can also be called a bucket, in which information about an object is stored (for example, it can be called a list of objects, including location information of multiple objects, such as the ID of the object, and the offset of the object in a file) And the size of the object, etc.), the container is located in the container server.
对象:在对象存储领域,对象为存储的单位,对象存储在对象存储系统中的对象服务器中,对象包括对象元数据和对象数据,对象元数据用于描述对象的属性的信息,例如对象的大小或者对象的类型(例如图片、音频和视频等)等,对象数据为对象本身。Object: In the object storage domain, the object is the storage unit, the object is stored in the object server in the object storage system, the object includes the object metadata and the object data, and the object metadata is used to describe the information of the object's attributes, such as the size of the object. Or the type of the object (such as pictures, audio, video, etc.), etc., the object data is the object itself.
本发明实施例提供的数据处理方法可以应用于对象存储系统中,该对象存储系统的架构示意图可以参见上述图1所示的对象存储系统的架构示意图,其中,代理服务器11负责对象存储系统中的其余组件间的相互通信,例如,代理服务器11可以接收客户端的超文本传输请求(例如读取请求、删除请求和上传请求等),并且可以转发客户端(例如图1中的终端10)的请求消息至对象存储系统中的容器服务器12或对象服务器13。容器服务器12的数据库中维护(可理解为存储)容器的信息和对象的信息(例如对象的位置信息),对象服务器13的文件系统中存储多个对象的元数据和数据。在本发明实施例提供的对象存储系统中,可以通过代理服务器11、容器服务器12和对象服务器13的交互实现上传(即写入)对象、读取对象和删除对象的操作。The data processing method provided by the embodiment of the present invention can be applied to an object storage system. For a schematic diagram of the architecture of the object storage system, refer to the schematic diagram of the object storage system shown in FIG. 1 , where the proxy server 11 is responsible for the object storage system. Inter-communication between the remaining components, for example, the proxy server 11 can receive hypertext transfer requests (e.g., read requests, delete requests, upload requests, etc.) of the client, and can forward requests from clients (e.g., terminal 10 in Figure 1). The message is to the container server 12 or the object server 13 in the object storage system. The information of the container and the information of the object (for example, the location information of the object) are maintained (considered to be stored) in the database of the container server 12, and the metadata and data of the plurality of objects are stored in the file system of the object server 13. In the object storage system provided by the embodiment of the present invention, an operation of uploading (ie, writing) an object, reading an object, and deleting an object may be implemented through interaction between the proxy server 11, the container server 12, and the object server 13.
可以理解的是,在如图1所示的对象存储系统中,终端10可以为手机、平板电脑、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本或者个人数字助理(personal digital assistant,PDA)、智能汽车、传感设备、物联网(internet of thing,IOT)设备、客户终端设备(customer premise equipment,CPE)等。It can be understood that in the object storage system shown in FIG. 1, the terminal 10 can be a mobile phone, a tablet computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (personal). Digital assistant (PDA), smart car, sensing device, internet of thing (IOT) equipment, customer premise equipment (CPE), etc.
上述如图1所示的代理服务器11、容器服务器12和对象服务器13,可以为硬件服务器,也可以为软件服务器,本发明实施例中,以代理服务器11、容器服务器12和对象服务器13为硬件服务器,介绍各个服务器的硬件结构和软件功能模块。The proxy server 11, the container server 12, and the object server 13 shown in FIG. 1 may be a hardware server or a software server. In the embodiment of the present invention, the proxy server 11, the container server 12, and the object server 13 are hardware. Server, introduces the hardware structure and software function modules of each server.
需要说明的是,本发明实施例中,上述如图1所示的对象存储系统中,代理服务器11、容器服务器12和对象服务器13可以为同一种结构的服务器,也可以为不同结构的服务器。下面结合图1所示的对象存储系统,分别介绍代理服务器、容器服务器和对象服务器的组成部件。It should be noted that, in the embodiment of the present invention, in the object storage system shown in FIG. 1 , the proxy server 11 , the container server 12 , and the object server 13 may be servers of the same structure or servers of different configurations. The components of the proxy server, the container server, and the object server are respectively described below in conjunction with the object storage system shown in FIG.
图2为本发明实施例提供的各个服务器的硬件示意图,如图2所示的代理服务器100可以包括:处理器101、存储器102以及通信接口103。FIG. 2 is a schematic diagram of hardware of each server according to an embodiment of the present invention. The proxy server 100 shown in FIG. 2 may include: a processor 101, a memory 102, and a communication interface 103.
处理器101:是代理服务器的核心部件,用于运行服务器的操作系统与服务器上的应用程序(包括系统应用程序和第三方应用程序)。The processor 101 is a core component of the proxy server and is used to run the server's operating system and applications on the server (including system applications and third-party applications).
本发明实施例中,处理器101具体可以为中央处理器(central processing unit,CPU),通用处理器,数字信号处理器(digital signal processor,DSP),专用集成电路(application-specific integrated circuit,ASIC),现场可编程门阵列(field programmable gate array,FPGA)或者其他可编程逻辑器件、晶体管逻辑器件、硬件部件或者其任意组合,其可以实现或执行本发明实施例公开的内容所描述的各种示例性的逻辑方框,模块和电路;处理器也可以是实现计算功能的组合,例如包含一个或多个微处理器组合,DSP和微处理器的组合等。In the embodiment of the present invention, the processor 101 may be a central processing unit (CPU), a general-purpose processor, a digital signal processor (DSP), or an application-specific integrated circuit (ASIC). a field programmable gate array (FPGA) or other programmable logic device, transistor logic device, hardware component, or any combination thereof, which may implement or perform various aspects described in the disclosure of the embodiments of the present invention. Exemplary logical blocks, modules and circuits; the processor may also be a combination of computing functions, for example, including one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like.
存储器102:用于存储代理服务器的程序代码和数据。Memory 102: program code and data for storing a proxy server.
本发明实施例中,存储器102具体可以包括易失性存储器(volatile memory),例如随机存取存储器(random-access memory,RAM);该存储器也可以包括非易失性存储器(non-volatile memory),例如只读存储器(read-only memory,ROM),快闪存储器 (flash memory),硬盘(hard disk,HDD)或固态硬盘(solid-state disk,SSD);该存储器还可以包括上述种类的存储器的组合。In the embodiment of the present invention, the memory 102 may specifically include a volatile memory, such as a random-access memory (RAM); the memory may also include a non-volatile memory. For example, a read-only memory (ROM), a flash memory, a hard disk (HDD), or a solid-state disk (SSD); the memory may further include the above-described type of memory. The combination.
通信接口103:用于代理服务器与其他设备进行通信的接口电路,通信接口可以为收发器、收发电路等具有收发功能的结构,通信接口包括串行通信接口和并行通信接口。例如,本发明实施例中,代理服务器100可以通过通信接口103与客户端(例如图2中的终端10)通信,与容器服务器200通信,或者与对象服务器300通信。The communication interface 103 is an interface circuit for the proxy server to communicate with other devices. The communication interface may be a transceiver, a transceiver circuit, or the like having a transceiving function, and the communication interface includes a serial communication interface and a parallel communication interface. For example, in an embodiment of the present invention, the proxy server 100 can communicate with a client (e.g., terminal 10 in FIG. 2) via the communication interface 103, with the container server 200, or with the object server 300.
图2所示的容器服务器200可以包括处理器201、存储器202以及通信接口203。其中,对于处理器201的描述可以参见对于代理服务器100的处理器101的描述,此处不再赘述。本发明实施例中,在对象存储系统中,容器服务器200接收到代理服务器100发送的读取查询消息或者删除查询消息之后,容器服务器的处理器101可以处理读取查询消息或者删除查询消息。The container server 200 shown in FIG. 2 may include a processor 201, a memory 202, and a communication interface 203. For a description of the processor 201, refer to the description of the processor 101 of the proxy server 100, and details are not described herein again. In the embodiment of the present invention, in the object storage system, after the container server 200 receives the read query message sent by the proxy server 100 or deletes the query message, the processor 101 of the container server may process the read query message or delete the query message.
对于存储器202的描述可以参见对于代理服务器100的存储器102的描述,本发明实施例中,如图2所示,容器服务器200的存储器202中可以包括至少一个容器(例如所示的M个容器(M≥1)),每一个容器中可以包括对象列表和删除日志,对象列表中存储有多个对象(可以称为第一类对象)的位置信息,第一类对象为未被标记删除的、对象服务器中存储的对象,删除日志中存储有多个对象(可以称为第二类对象)的位置信息,第二类对象为被标记删除的、对象服务器中存储的对象的位置信息。For a description of the memory 202, reference may be made to the description of the memory 102 of the proxy server 100. In the embodiment of the present invention, as shown in FIG. 2, the memory 202 of the container server 200 may include at least one container (for example, M containers shown). M≥1)), each container may include a list of objects and a delete log, where the object list stores location information of a plurality of objects (which may be referred to as first type objects), and the first type of objects are unmarked and deleted. The object stored in the object server deletes the location information of a plurality of objects (which may be referred to as a second type of object), and the second type of object is the location information of the object stored in the object server that is marked and deleted.
对于通信接口203的描述可以参见对于代理服务器100的通信结构103的描述,本发明实施例中,容器服务器可以通过通信接口203与代理服务器100通信,或者与对象服务器300通信。For a description of the communication interface 203, reference may be made to the description of the communication structure 103 of the proxy server 100, in which the container server may communicate with the proxy server 100 via the communication interface 203 or with the object server 300.
图2所示的对象服务器300可以包括处理器301、存储器302以及通信接口303。其中,对于处理器301的描述可以参见对于代理服务器100的处理器101的描述,此处不再赘述。本发明实施例中,在对象存储系统中,对象服务器200接收到代理服务器100发送的上传对象的请求消息或接收到容器服务器200发送的垃圾回收请求消息之后,对象服务器300的处理器301可以处理处理该上传对象的请求消息或处理该垃圾回收请求消息。The object server 300 shown in FIG. 2 may include a processor 301, a memory 302, and a communication interface 303. For a description of the processor 301, reference may be made to the description of the processor 101 of the proxy server 100, and details are not described herein again. In the embodiment of the present invention, in the object storage system, after the object server 200 receives the request message of the upload object sent by the proxy server 100 or receives the garbage collection request message sent by the container server 200, the processor 301 of the object server 300 can process Process the request message of the upload object or process the garbage collection request message.
对于存储器302的描述可以参见对于代理服务器100的存储器102的描述,本发明实施例中,如图2所示,对象服务器300的存储器302中可以包括文件系统,文件系统中包括至少一个文件(例如如图2所示的文件系统包括N个文件(N≥1)),该至少一个文件中每一个文件中可以存储多个对象(例如如图2所示的每个文件中可以包括P个对象(P≥2))。For a description of the memory 302, reference may be made to the description of the memory 102 of the proxy server 100. In the embodiment of the present invention, as shown in FIG. 2, the file 302 of the object server 300 may include a file system, and the file system includes at least one file (for example, The file system shown in FIG. 2 includes N files (N≥1), and each of the at least one file can store a plurality of objects (for example, each of the files shown in FIG. 2 can include P objects). (P ≥ 2)).
对于通信接口303的描述可以参见对于代理服务器100的通信结构103的描述,本发明实施例中,对象服务器300可以通过通信接口303与代理服务器100通信,或者与容器服务器200通信。For a description of the communication interface 303, reference may be made to the description of the communication structure 103 of the proxy server 100, in which the object server 300 may communicate with the proxy server 100 via the communication interface 303 or with the container server 200.
在现有技术中,由于在删除某一对象的过程中,对象服务器需根据该对象的位置信息对该对象做删除标记,当对象存储系统中既有读取某一对象(例如第一对象)的请求,也有删除该对象的请求时,由于在读取该对象时,对象服务器中的该对象可能已被标记为删除,因此可能会出现读取该对象失败的情况,即导致读取第一对象和删除第一对象发生冲突。本发明实施例提供了一种数据处理方法、装置及系统,能够在一定程度上避免读取对象和删除对象发生冲突。In the prior art, in the process of deleting an object, the object server needs to delete the object according to the location information of the object, and when the object storage system has both read an object (for example, the first object) Request, there is also a request to delete the object, because the object in the object server may have been marked as deleted when the object is read, so the failure to read the object may occur, which leads to the first reading The object conflicts with deleting the first object. The embodiment of the invention provides a data processing method, device and system, which can avoid conflicts between a read object and a deleted object to a certain extent.
结合上述如图1所示的对象存储系统,用户设备可以删除对象存储系统中存储的对象,也可以读取对象存储系统中存储的对象,还可以上传对象至对象存储系统,下面首先通过对象存储系统中的各个服务器之间的交互过程对删除对象、读取对象和上传对象三个不同的应用场景做详细介绍。In combination with the object storage system shown in FIG. 1 above, the user equipment may delete an object stored in the object storage system, or may read an object stored in the object storage system, and may also upload the object to the object storage system, and firstly through the object storage. The interaction process between the various servers in the system describes three different application scenarios of deleting objects, reading objects, and uploading objects.
本发明实施例中,将删除对象的场景记为场景一,将读取对象的场景记为场景二,将上传对象的场景记为场景三。In the embodiment of the present invention, the scene of the deleted object is recorded as the scene 1, the scene of the read object is recorded as the scene 2, and the scene of the uploaded object is recorded as the scene 3.
场景一scene one
结合图1和图2,如图3所示,删除对象存储系统中的对象的场景下,本发明实施例提供的数据处理方法可以包括S101-S105:With reference to FIG. 1 and FIG. 2, as shown in FIG. 3, in the scenario of deleting an object in the object storage system, the data processing method provided by the embodiment of the present invention may include S101-S105:
S101、代理服务器向容器服务器发送删除查询消息,该删除查询消息中包括第一目标对象所属的容器的标识信息和第一目标对象的标识信息。S101. The proxy server sends a delete query message to the container server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object.
本发明实施例中,终端需删除对象存储系统中的某一对象(以下均可以称为第一目标对象)时,终端可以向代理服务器发送删除第一目标对象的请求消息,代理服务器接收到终端发送的删除第一目标对象的请求消息,并且解析该删除第一目标对象的请求消息,获取第一目标对象所属的容器的标识信息和第一目标对象的标识信息之后,代理服务器可以将该第一目标对象所属的容器的标识信息和第一目标对象的标识信息携带在删除查询消息中发送给容器服务器,其中,容器中存储有对象的位置信息,该位置信息用于指示对象服务器中的该对象的位置,第一目标对象所属的容器的标识信息可以标识需删除的第一目标对象的位置存储在哪一个容器中,第一目标对象的标识信息可以指示需删除的目标对象为该容器中的哪一个目标对象。In the embodiment of the present invention, when the terminal needs to delete an object in the object storage system (hereinafter may be referred to as a first target object), the terminal may send a request message for deleting the first target object to the proxy server, and the proxy server receives the terminal. After the sent request message for deleting the first target object is sent, and the request message for deleting the first target object is parsed, and the identifier information of the container to which the first target object belongs and the identification information of the first target object are obtained, the proxy server may The identifier information of the container to which the target object belongs and the identifier information of the first target object are carried in the delete query message and sent to the container server, where the location information of the object is stored in the container, and the location information is used to indicate the target server. The location of the object, the identifier information of the container to which the first target object belongs may identify in which container the location of the first target object to be deleted is stored, and the identifier information of the first target object may indicate that the target object to be deleted is in the container Which target object.
可选的,本发明实施例中,第一目标对象的标识信息可以为第一目标对象的名称或者预先预定好的用户定义的可以指示目标对象的其他信息,本发明实施例不作具体限定。Optionally, in the embodiment of the present invention, the identifier information of the first target object may be a name of the first target object or other information that may be specified by the user, which may be a predetermined target, which is not specifically limited.
同理,第一目标对象所属的容器的标识信息也可以为该容器的名称或者预先预定好的用户定义的可以指示该容器的其他信息,本发明实施例不作具体限定。For the same reason, the identifier information of the container to which the first target object belongs may also be the name of the container or other information defined by the user, which may be instructed by the user.
S102、容器服务器接收代理服务器发送的删除查询消息。S102. The container server receives a delete query message sent by the proxy server.
S103、容器服务器根据删除查询消息中的第一目标对象所属的容器的标识信息和第一目标对象的标识信息,在容器服务器的对象列表中查询第一目标对象的位置信息。S103. The container server queries the location information of the first target object in the object list of the container server according to the identifier information of the container to which the first target object belongs and the identifier information of the first target object in the delete query message.
其中,容器服务器的对象列表中包含第一类对象的位置信息,该第一类对象为未被标记删除的、对象服务器中存储的对象,每一个第一类对象的位置信息用于指示每一对象在对象服务器中的位置。The object list of the container server includes location information of the first type of object, and the first type of object is an object stored in the object server that is not marked and deleted, and the location information of each first type of object is used to indicate each The location of the object in the object server.
本发明实施例中,根据对象的存储的方式的不用,对象的位置信息也不同,示例性的,如果将一个对象存储在一个文件中,可以理解为每一个文件仅存储一个对象,那么对象的位置信息为对象的ID;如果将至少两个对象存储在一个文件中,可以理解为每一个文件中存储至少两个对象,那么对象的位置信息为对象所在的文件标识、对象的偏移量以及对象的尺寸,对象的偏移量为该对象在其存储的文件中的位置,对象的尺寸标识对象的大小,例如对象所占的比特数的数量。In the embodiment of the present invention, according to the manner of storing the object, the location information of the object is also different. For example, if an object is stored in a file, it can be understood that only one object is stored in each file, then the object is The location information is the ID of the object; if at least two objects are stored in one file, it can be understood that at least two objects are stored in each file, and the location information of the object is the file identifier of the object, the offset of the object, and The size of the object, the offset of the object is the position of the object in its stored file, and the size of the object identifies the size of the object, such as the number of bits occupied by the object.
可知,上述第一目标对象的位置信息可以包括该第一目标对象的ID,或者第一目标对象的位置信息可以包括第一目标对象所在的文件标识、第一目标对象的偏移量以及第一目标对象的尺寸,该文件标识指示的文件中包括至少两个对象。It can be seen that the location information of the first target object may include an ID of the first target object, or the location information of the first target object may include a file identifier of the first target object, an offset of the first target object, and the first The size of the target object, which includes at least two objects in the file indicated by the file identifier.
可选的,本发明实施例中,在实际的实现过程中,对于上述每一个文件仅存储一个 对象的情况,那么对象的位置信息还可以使用容器的ID和对象的ID共同表示,在对象服务器中的对象较多时,由于对象的ID可以表示的对象的范围可能无法满足对象的数量,即对象的实际数量超出对象的ID可表示的对象的数量,因此,可以使用容器的ID和对象的ID两种字段标识对象的位置信息,以指示该对象。Optionally, in the embodiment of the present invention, in an actual implementation process, if only one object is stored for each file, the location information of the object may be jointly represented by the ID of the container and the ID of the object, and the object server When there are many objects in the object, the range of objects that can be represented by the ID of the object may not satisfy the number of objects, that is, the actual number of objects exceeds the number of objects that can be represented by the ID of the object. Therefore, the ID of the container and the ID of the object can be used. Two fields identify the location information of the object to indicate the object.
可选的,本发明实施例中,容器服务器的对象列表中可以存储多个对象的位置信息,即可以存储多条位置信息,每一条位置信息对应一个对象的位置信息,每一条位置信息可以对应一个位置索引,并且对象所属的容器的标识信息和对象的标识信息组成的信息二元组也对应一个位置索引,上述容器服务器根据第一目标对象所属的容器的标识信息和第一目标对象的标识信息在容器服务器的对象列表中查询第一目标对象的位置信息的方法具体为:容器服务器根据第一目标对象所属的容器的标识信息和第一目标对象的标识信息确定第一目标的位置索引,然后根据第一目标对象的位置的索引可以确定第一目标对象的位置信息。Optionally, in the embodiment of the present invention, the object information of the container server may store location information of multiple objects, that is, multiple pieces of location information may be stored, and each piece of location information corresponds to location information of one object, and each piece of location information may correspond to a location index, and the information tuple composed of the identification information of the container to which the object belongs and the identification information of the object also corresponds to a location index, and the container server according to the identification information of the container to which the first target object belongs and the identifier of the first target object The method for querying the location information of the first target object in the object list of the container server is specifically: the container server determines the location index of the first target according to the identifier information of the container to which the first target object belongs and the identification information of the first target object, The location information of the first target object can then be determined based on the index of the location of the first target object.
示例性的,以容器服务器中包括5个对象的位置信息为例,如表1所示,为容器服务器中的对象所属的容器的标识信息和对象的标识信息组成的信息二元组(表1中简称为对象的信息二元组)与对象的位置索引,以及对象的位置信息与对象的位置索引之间的对应关系示例。Illustratively, taking the location information of the five objects in the container server as an example, as shown in Table 1, the information binary consisting of the identification information of the container to which the object in the container server belongs and the identification information of the object (Table 1) An example of the correspondence between the positional index of the object and the positional index of the object and the positional index of the object.
表1Table 1
对象的信息二元组Object information binary 位置索引Location index 位置信息location information
(container1,object1)(container1, object1) 11 位置信息1Location information 1
(container2,object3)(container2, object3) 22 位置信息2Location information 2
(container1,object4)(container1, object4) 33 位置信息3Location information 3
(container3,object1)(container3, object1) 44 位置信息4Location information 4
(container4,object2)(container4, object2) 55 位置信息5Location information 5
在表1中,object1表示对象1的标识,container1表示对象1所属的容器的标识。In Table 1, object1 represents the identifier of the object 1, and container1 represents the identifier of the container to which the object 1 belongs.
S104、若在上述对象列表中查询到第一目标对象的位置信息,该容器服务器删除对象列表中的第一目标对象的位置信息,并且将该第一目标对象的位置信息写入容器服务器的删除日志中。S104. If the location information of the first target object is queried in the object list, the container server deletes the location information of the first target object in the object list, and writes the location information of the first target object to the deletion of the container server. In the log.
其中,删除日志中包含第二类对象的位置信息,该第二类对象为被标记删除的、对象服务器中存储的对象的位置信息。The deletion log includes location information of the second type of object, and the second type of object is location information of the object stored in the object server that is marked and deleted.
本发明实施例中,容器服务器将第一目标对象的位置信息从对象列表中删除,并且将该第一目标对象的位置信息写入删除日志之后,容器服务器后续接收到关于第一目标对象的其他查询消息(例如读取查询消息)时,容器服务器在对象列表将查询不到该第一目标目标对象的位置信息,从而也不能对该第一目标对象实施相应的操作。In the embodiment of the present invention, after the container server deletes the location information of the first target object from the object list, and after the location information of the first target object is written into the deletion log, the container server subsequently receives other information about the first target object. When querying a message (for example, reading a query message), the container server will not find the location information of the first target object in the object list, and thus cannot perform corresponding operations on the first target object.
需要说明的是,本发明实施例中,将第一目标对象的位置信息从对象列表中删除,并且将该第一目标对象的位置信息写入删除日志完成之后,即认为删除第一目标对象成功,实际上第一目标对象的内容,即第一目标对象的元数据和数据本身还未被删除(即未被回收),还存储在对象服务器中。It should be noted that, in the embodiment of the present invention, after the location information of the first target object is deleted from the object list, and the location information of the first target object is written into the deletion log, the first target object is considered to be deleted successfully. In fact, the content of the first target object, that is, the metadata of the first target object and the data itself have not been deleted (ie, not recovered), and are also stored in the object server.
本发明实施例中,容器服务器的删除日志中的对象的位置信息指示对象服务器中待回收的对象,上述将第一目标对象的位置信息写入删除日志中,可以理解为待删除的第 一目标对象先在标记出来,在适当的时间,在根据该删除日志中的第一目标对象的位置信息,从对象服务器中回收第一目标对象的内容。In the embodiment of the present invention, the location information of the object in the deletion log of the container server indicates the object to be reclaimed in the object server, and the location information of the first target object is written into the deletion log, which can be understood as the first target to be deleted. The object is first marked, and at the appropriate time, the content of the first target object is recovered from the object server based on the location information of the first target object in the deletion log.
关于回收对象服务器中的对象的方法将在下述实施例中详细说明,此处不予描述。The method of reclaiming objects in the object server will be described in detail in the following embodiments and will not be described here.
S105、容器服务器向代理服务器发送删除响应消息。S105. The container server sends a delete response message to the proxy server.
本发明实施例中,该删除响应消息中可以包括指示删除第一目标对象成功的指示信息,以指示容器服务器删除该第一目标对象成功。In the embodiment of the present invention, the deletion response message may include indication information indicating that the deletion of the first target object is successful, to indicate that the container server successfully deletes the first target object.
可以理解的是,本发明实施例中,若对象存储系统中不存在第一目标对象,即容器服务器中不存在该第一目标对象的位置信息,对象服务器中也不存在该第一目标对象,在这种情况下,若上述容器服务器在对象列表中未查询到第一目标对象的位置信息,容器服务器可以向代理服务器发送包括指示未查询到第一目标对象的位置信息的指示信息,以指示容器服务器未查询到该第一目标对象的位置信息,即本次删除操作结束。It can be understood that, in the embodiment of the present invention, if the first target object does not exist in the object storage system, that is, the location information of the first target object does not exist in the container server, the first target object does not exist in the object server. In this case, if the container server does not query the location information of the first target object in the object list, the container server may send, to the proxy server, indication information including location information indicating that the first target object is not queried, to indicate The container server does not query the location information of the first target object, that is, the deletion operation ends.
本发明实施例提供的数据处理方法,在删除对象存储系统中的对象(例如第一目标对象)的过程中,容器服务器接收到删除查询消息之后,容器服务器可以在容器服务器的对象列表中查询该第一目标对象的位置信息,并且在对象列表中查询到第一目标对象的位置信息的情况下,将该第一目标对象的位置信息从对象列表中删除,并且将该第一目标对象的位置信息写入容器服务器的删除日志中。现有技术相比,本发明实施例中,容器服务器在对象列表中查询到第一目标对象的位置信息时,无需再将该第一目标对象的位置信息发送给代理服务器,代理服务器也无需再将该第一目标对象的位置信息发送给对象服务器,从而对象服务器也无需在对该对象服务器中的第一目标对象做删除标记,如此,当删除对象存储系统中的该第一目标对象与读取对象存储系统中的该第一目标对象并发发生时,由于在删除该第一目标对象的过程中,对象服务器中的该第一目标对象并没有被标记为删除,因此可以在对象服务器中读取到该第一目标对象,与现有技术相比,可以避免由于对象服务器中的第一目标对象被标记为删除,而造成读取该第一目标对象失败的问题,即可以避免读取第一目标对象和删除第一目标对象的发生冲突。In the data processing method provided by the embodiment of the present invention, in the process of deleting an object (for example, a first target object) in the object storage system, after the container server receives the delete query message, the container server may query the object list of the container server. The location information of the first target object, and in the case where the location information of the first target object is queried in the object list, the location information of the first target object is deleted from the object list, and the location of the first target object is Information is written to the delete log of the container server. Compared with the prior art, in the embodiment of the present invention, when the container server queries the location information of the first target object in the object list, the location information of the first target object does not need to be sent to the proxy server, and the proxy server does not need to be Sending the location information of the first target object to the object server, so that the object server does not need to delete the first target object in the object server, so when deleting the first target object and reading in the object storage system When the first target object in the object storage system is concurrently generated, since the first target object in the object server is not marked as deleted during the process of deleting the first target object, the object can be read in the object server. Obtaining the first target object, compared with the prior art, avoiding the problem that the first target object in the object server is marked as deleted, causing the first target object to fail to be read, thereby avoiding reading A target object conflicts with deleting the first target object.
进一步地,由于容器服务器无需再将该第一目标对象的位置信息发送给代理服务器,代理服务器也无需再将该第一目标对象的位置信息发送给对象服务器,从而对象服务器也无需在对该对象服务器中的第一目标对象做删除标记,如此,可以简化删除第一目标对象的流程,而且可以节约服务器之间的通信资源。Further, since the container server does not need to send the location information of the first target object to the proxy server, the proxy server does not need to send the location information of the first target object to the object server, so that the object server does not need to be in the object. The first target object in the server is marked for deletion, so that the process of deleting the first target object can be simplified, and the communication resources between the servers can be saved.
场景二Scene two
结合图1和图2,如图4所示,读取对象存储系统中的对象的场景下,本发明实施例提供的数据处理方法可以包括S201-S209:With reference to FIG. 1 and FIG. 2, as shown in FIG. 4, in a scenario of reading an object in an object storage system, the data processing method provided by the embodiment of the present invention may include S201-S209:
S201、代理服务器向容器服务器发送读取查询消息,该读取查询消息中包括第二目标对象所属的容器的标识信息和第二目标对象的标识信息。S201. The proxy server sends a read query message to the container server, where the read query message includes the identifier information of the container to which the second target object belongs and the identifier information of the second target object.
本发明实施例中,终端需读取对象存储系统中的某一对象(均可以称为第二目标对象)时,终端可以向代理服务器发送读取第二目标对象的请求消息,代理服务器接收到终端发送的读取第二目标对象的请求消息,并且解析该读取第一目标对象的请求消息,获取第二目标对象所属的容器的标识信息和第二目标对象的标识信息之后,代理服务器可以将该第二目标对象所属的容器的标识信息和第二目标对象的标识信息携带在读取查询消息中发送给容器服务器,以获取第二目标对象的位置信息,从而读取该第二目标对象。In the embodiment of the present invention, when the terminal needs to read an object in the object storage system (which may be referred to as a second target object), the terminal may send a request message for reading the second target object to the proxy server, and the proxy server receives the request message. After the request message of the second target object is read by the terminal, and the request message for reading the first target object is parsed, and the identifier information of the container to which the second target object belongs and the identification information of the second target object are obtained, the proxy server may Carrying the identification information of the container to which the second target object belongs and the identification information of the second target object in the read query message, and sending the information to the container server to obtain the location information of the second target object, thereby reading the second target object. .
S202、容器服务接收代理服务器发送的读取查询消息。S202. The container service receives a read query message sent by the proxy server.
S203、容器服务器根据第二目标对象所属的容器的标识信息和第二目标对象的标识信息,在该容器服务器的对象列表中查询第二目标对象的位置信息。S203. The container server queries the location information of the second target object in the object list of the container server according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object.
本发明实施例中,第二目标对象的位置信息包括第二目标对象所在的文件标识、第二目标对象的偏移量以及第二目标对象的尺寸,该文件标识指示的文件中包括至少两个对象。In the embodiment of the present invention, the location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, where the file identifier includes at least two files. Object.
对于S202的其他描述可以具体参见上述场景一的实施例中,对于S103的相关描述,此处不再赘述For other descriptions of S202, refer to the embodiment of scenario 1 above. For the related description of S103, details are not described herein again.
S204、若在对象列表中查询到第二目标对象的位置信息,容器服务器向代理服务器发送第二目标对象的位置信息。S204. If the location information of the second target object is queried in the object list, the container server sends the location information of the second target object to the proxy server.
本发明实施例中,容器服务器向代理服务器发送第二目标对象的位置信息,可以指示代理服务器根据第二目标对象的位置信息从对象服务器中读取第二目标对象。In the embodiment of the present invention, the container server sends the location information of the second target object to the proxy server, and may instruct the proxy server to read the second target object from the object server according to the location information of the second target object.
S205、代理服务器接收容器服务器发送的第二目标对象的位置信息。S205. The proxy server receives location information of the second target object sent by the container server.
S206、代理服务器向对象服务器发送第二目标对象的位置信息。S206. The proxy server sends the location information of the second target object to the object server.
S207、对象服务器接收容器服务器发送的第二目标对象的位置信息。S207. The object server receives location information of the second target object sent by the container server.
S208、对象服务器根据第二目标对象的位置信息读取第二目标对象。S208. The object server reads the second target object according to the location information of the second target object.
S209、对象服务器向代理服务器发送第二目标对象。S209. The object server sends a second target object to the proxy server.
本发明实施例中,代理服务器可以接收的第二目标对象的位置信息发送给对象服务器,从而对象服务器可以根据第二目标对象的位置信息,在对象服务器中的对应位置读取该第二目标对象,并将该第二目标对象发送给代理服务器,然后代理服务器将该第二目标对象发送给终端,如此终端可以顺利读取到第二目标对象。In the embodiment of the present invention, the location information of the second target object that can be received by the proxy server is sent to the object server, so that the object server can read the second target object in the corresponding location in the object server according to the location information of the second target object. And sending the second target object to the proxy server, and then the proxy server sends the second target object to the terminal, so that the terminal can smoothly read the second target object.
场景三Scene three
结合图1和图2,如图5所示,向对象服务器上传对象的场景下,本发明实施例提供的数据处理方法还可以包括S301-S308:With reference to FIG. 1 and FIG. 2, as shown in FIG. 5, in the scenario of uploading an object to the object server, the data processing method provided by the embodiment of the present invention may further include S301-S308:
S301、代理服务器向对象服务器发送上传第三目标对象的请求消息,该上传第三目标对象的请求消息中包括第三目标对象。S301. The proxy server sends a request message for uploading a third target object to the object server, where the request message for uploading the third target object includes a third target object.
本发明实施例中,终端需向对象存储系统中上传某一对象(例如可以称为第三目标对象)时,终端可以向代理服务器发送上传请求消息,该上传请求消息中包括第三目标对象所属的容器的标识信息和第三目标对象的标识信息,该第三目标对象所属的容器的标识信息用于指示将第三目标对象写入对象服务器之后,在哪一个容器中更新第三目标对象的位置信息;代理服务器可以将该第三目标携带在上传第三目标对象的请求消息中发送给对象服务器。In the embodiment of the present invention, when the terminal needs to upload an object to the object storage system (for example, it may be referred to as a third target object), the terminal may send an upload request message to the proxy server, where the upload request message includes the third target object. The identification information of the container and the identification information of the third target object, the identification information of the container to which the third target object belongs is used to indicate in which container the third target object is updated after the third target object is written to the object server Location information; the proxy server may send the third target to the object server in the request message for uploading the third target object.
S302、对象服务器接收容器服务器发送的上传第三目标对象的请求消息。S302. The object server receives a request message that is sent by the container server and uploads the third target object.
S303、对象服务器将第三目标对象写入对象服务器的某一文件中。S303. The object server writes the third target object into a file of the object server.
本发明实施例中,写入第三目标对象的文件可支持写入多个对象,该多个对象为小对象,小对象可以理解为该对象占用的空间比较小,即对象的尺寸比较小(例如一幅图像、一个小文本等都可以称为小对象),与现有技术中,每一个文件中仅包含一个对象相比,将多个对象(这里指的是将对多个小对象)写入一个大文件中,可以节省对象服务器的文件系统的存储资源,从而可以提高对象服务器的性能。In the embodiment of the present invention, the file written to the third target object can support writing multiple objects, and the multiple objects are small objects, and the small object can be understood as the space occupied by the object is relatively small, that is, the size of the object is relatively small ( For example, an image, a small text, etc. can be called a small object. Compared with the prior art, each file contains only one object, and multiple objects (here, will refer to multiple small objects). Writing to a large file can save the storage resources of the file system of the object server, thereby improving the performance of the object server.
进一步的,在现有技术中,每一个文件中仅包含一个对象相比,当对象服务器回收 多个小对象之后,服务器中会产生多个空间碎片(即回收每一个小对象之后的小文件),本发明实施例中,将多个小对象写入一个大文件中,如此,回收该大文件中的小对象时,可以减少服务器中的空间碎片,从而,在写入某一个大对象(占用的存储空间比较大)时,无需再将该大对象分成多个部分写入多个小文件中,可以将该大对象的全部内容写入大文件中,能够提高对象存储系统的性能。Further, in the prior art, each file contains only one object. When the object server reclaims multiple small objects, multiple space fragments are generated in the server (ie, small files after each small object are reclaimed). In the embodiment of the present invention, multiple small objects are written into one large file, so that when small objects in the large file are recovered, space fragmentation in the server can be reduced, thereby writing a large object (occupied) When the storage space is relatively large, it is not necessary to divide the large object into multiple small files, and the entire contents of the large object can be written into a large file, thereby improving the performance of the object storage system.
S304、对象服务器向代理服务器发送第三目标对象的第一位置信息。S304. The object server sends the first location information of the third target object to the proxy server.
其中,第三目标对象的第一位置信息包括第三目标对象所在的文件标识、第三目标对象的偏移量以及第三目标对象的尺寸,该第三目标对象所在的文件标识指示的文件中保存有至少两个对象。The first location information of the third target object includes a file identifier of the third target object, an offset of the third target object, and a size of the third target object, where the file identifier of the third target object is in the file indicated by the file identifier Save at least two objects.
本发明实施例中,对象服务器将第三目标对象写入对象服务器的某一位置,假设该位置称为第一位置,对象服务器可以生成第三目标对象的位置信息,由于在本次向对象服务器写入第三目标对象之前,对象服务器中可能已存储有该第三目标对象(可能本次待写入的第三目标对象为对已存储的第三目标对象的修改版本),因此为了区分本次写入的第三目标对象的位置位置信息与之前已存储的第三目标对象的位置信息,将本次写入的第三目标对象的位置信息记为第三目标对象的第一位置信息。In the embodiment of the present invention, the object server writes the third target object to a certain location of the object server, and if the location is called the first location, the object server may generate the location information of the third target object, because the object server is in the current time. Before the third target object is written, the third target object may already be stored in the object server (possibly the third target object to be written this time is a modified version of the stored third target object), so in order to distinguish the present The positional position information of the third target object that has been written in the second time and the positional information of the third target object that has been previously stored are recorded as the first positional information of the third target object.
S305、代理服务器接收对象服务器发送的第三目标对象的第一位置信息。S305. The proxy server receives first location information of the third target object sent by the object server.
S306、代理服务器向容器服务器发送上述位置更新消息。S306. The proxy server sends the location update message to the container server.
本发明实施例中,上述位置更新消息用于更新容器服务器的对象列表中的目标对象的位置信息。代理服务器接收到对象服务器发送的第三目标对象的第一位置信息之后,代理服务器可以将目标对象所属的容器的标识信息、目标对象的标识信息以及目标对象的第一位置信息携带在位置更新消息中发送给容器服务器,以指示容器服务器根据位置更新消息,更新容器服务器的对象列表中的目标对象的位置信息。In the embodiment of the present invention, the location update message is used to update location information of the target object in the object list of the container server. After the proxy server receives the first location information of the third target object sent by the object server, the proxy server may carry the identifier information of the container to which the target object belongs, the identifier information of the target object, and the first location information of the target object in the location update message. Is sent to the container server to instruct the container server to update the location information of the target object in the object list of the container server according to the location update message.
S307、容器服务器接收代理服务器发送的位置更新消息。S307. The container server receives a location update message sent by the proxy server.
S308、容器服务器根据位置更新消息,更新容器服务器的对象列表中的第三目标对象的位置信息。S308. The container server updates the location information of the third target object in the object list of the container server according to the location update message.
可选的,本发明实施例中,上述S308具体可以通过S308a-S308b实现:Optionally, in the embodiment of the present invention, the foregoing S308 may be specifically implemented by using S308a-S308b:
S308a、容器服务器根据第三目标对象所属的容器的标识信息、第三目标对象的标识信息,在容器服务器的对象列表中查询第三目标对象的位置信息。S308a. The container server queries the location information of the third target object in the object list of the container server according to the identifier information of the container to which the third target object belongs and the identifier information of the third target object.
本发明实施例中,容器服务器根据其接收的位置更新消息中的第三目标对象所属的容器的标识信息和第三目标对象的标识信息,在对象列表中查询对象列表中是否存在第三目标对象的位置信息。In the embodiment of the present invention, the container server queries the object list for the presence of the third target object in the object list according to the identification information of the container to which the third target object belongs and the identification information of the third target object in the location update message received by the container server. Location information.
对于S308a的具体描述可以参见上述场景一的实施例中,对于S103的相关描述,此处不再赘述。For a detailed description of the S308a, refer to the embodiment of the foregoing scenario 1. For the related description of S103, details are not described herein again.
S308b、容器服务器根据查询结果,更新第三目标对象的位置信息。S308b: The container server updates the location information of the third target object according to the query result.
本发明实施例中,容器服务器在对象列表中查询第三目标对象的位置信息的查询结果可以包括:容器服务器在对象列表中未查询到第三目标对象的位置信息,或者容器服务器在对象列表中查询到第三目标对象的位置信息。根据查询结果的不同,上述S307b可以包括下述308b1或S208b2:In the embodiment of the present invention, the query result of the container server querying the location information of the third target object in the object list may include: the container server does not query the location information of the third target object in the object list, or the container server is in the object list. Query the location information of the third target object. Depending on the result of the query, the above S307b may include the following 308b1 or S208b2:
S308b1、若在对象列表中未查询到第三目标对象的位置信息,容器服务器将其接收的位置更新消息中的第三目标对象的第一位置信息写入对象列表。S308b1: If the location information of the third target object is not queried in the object list, the container server writes the first location information of the third target object in the location update message received by the container server to the object list.
本发明实施例中,在对象存储系统中,将第三目标对象写入对象服务器中之后,若容器服务器不存在该第三目标对象的位置信息,则将该第三目标对象的第一位置信息写入对象列表中,从而在后续的读取或者删除第三目标对象过程中,可以通过在对象列表中查询该第三目标对象的位置信息,从而完成该第三目标对象的读取或者删除。In the embodiment of the present invention, after the third target object is written in the object server in the object storage system, if the location information of the third target object does not exist in the container server, the first location information of the third target object is obtained. The object list is written, so that in the subsequent process of reading or deleting the third target object, the third target object can be read or deleted by querying the location information of the third target object in the object list.
S308b2、若在对象列表中查询到第三目标对象的位置信息,该第三目标对象的位置信息为第二位置信息,并且第三目标对象的第二位置信息与位置更新消息中的第三目标对象的第一位置信息不同,容器服务器将第三目标对象的第二位置信息替换为第三目标对象的第一位置信息,并且将第三目标对象的第二位置信息写入容器服务器的删除日志中。S308b2, if the location information of the third target object is queried in the object list, the location information of the third target object is the second location information, and the second location information of the third target object and the third target in the location update message The first location information of the object is different, the container server replaces the second location information of the third target object with the first location information of the third target object, and writes the second location information of the third target object to the deletion log of the container server in.
本发明实施例中,若在对象列表中查询到第三目标对象的位置信息,说明本次向对象服务器中写入第三目标对象时,对象服务器中已存储有第三目标对象(可能本次待写入的第三目标对象为对已存储的第三目标对象的修改版本),因此,可以将第三目标对象的第二位置信息替换为第三目标对象的第一位置信息,具体的,容器服务器将第三目标对象的第二位置信息删除,将第三目标对象的第一位置信息写入对象列表中,如此,在后续的操作(例如读取该第三目标对象或删除该第三目标对象)过程中,可以在容器服务器中查询到准确的第三目标对象的信息,从而正确读取该第三目标对象,或者删除第三目标对象。并且可以将第三目标对象的第二位置信息写入容器服务器的删除日志中,对象服务器根据删除日志中的第三目标对象的第二位置信息,回收对象服务器中第三目标的第二位置信息指示的第三目标对象。In the embodiment of the present invention, if the location information of the third target object is queried in the object list, the third target object is already stored in the object server when the third target object is written to the object server. The third target object to be written is a modified version of the stored third target object. Therefore, the second location information of the third target object may be replaced with the first location information of the third target object, specifically, The container server deletes the second location information of the third target object, and writes the first location information of the third target object into the object list, such that in subsequent operations (eg, reading the third target object or deleting the third During the target object, the information of the accurate third target object can be queried in the container server to correctly read the third target object or delete the third target object. And the second location information of the third target object may be written into the deletion log of the container server, and the object server recovers the second location information of the third target in the object server according to the second location information of the third target object in the deletion log. The third target object indicated.
本发明实施例提供的数据处理方法,在向对象存储系统中上传对象(例如可以称为第三目标对象)的过程中,代理服务器可以将上传第三目标对象的请求消息发送给对象服务器,对象服务器接收该上传第三目标对象的请求消息,并将该请求消息中的第三目标对象写入该对象服务器中,以及向代理服务器发送该第三目标对象的第一位置信息,该第三目标对象的第一位置信息包括第三目标对象所在的文件标识、第三目标对象的偏移量以及第三目标对象的尺寸,该第三目标对象所在的文件标识指示的文件中保存有至少两个对象。与现有技术相比,本发明实施例中,由于对象服务器将第三目标对象写入对象服务器的文件系统的文件中,该文件中可以包括至少两个对象,可知,当对象存储系统中写入多个小对象时,可以将多个小对象写入一个文件中,如此,可以节省对象服务器的文件系统的存储资源,从而提高对象服务器的性能。In the data processing method provided by the embodiment of the present invention, in the process of uploading an object (for example, may be referred to as a third target object) to the object storage system, the proxy server may send a request message for uploading the third target object to the object server, and the object Receiving, by the server, the request message for uploading the third target object, and writing the third target object in the request message to the object server, and sending the first location information of the third target object to the proxy server, the third target The first location information of the object includes a file identifier of the third target object, an offset of the third target object, and a size of the third target object, where the file identifier indicated by the third target object stores at least two files. Object. Compared with the prior art, in the embodiment of the present invention, since the object server writes the third target object into the file system file of the object server, the file may include at least two objects, and it is known that when the object storage system writes When multiple small objects are entered, multiple small objects can be written to one file. This saves the storage resources of the file system of the object server, thereby improving the performance of the object server.
可选的,本发明实施例中,上述场景一中的第一目标对象,场景二中的第二目标对象以及场景三中的第三目标对象可以为相同的目标对象,也可以为不同的目标对象。若第一目标对象、第二目标对象以及第三目标对象为相同的目标对象,例如均称为第一目标对象,则通过上述实施例中三种场景的描述,可以将第一目标对象写入对象存储系统,从而可以从该对象存储系统中读取该第一目标对象,或者删除该第一目标对象。Optionally, in the embodiment of the present invention, the first target object in the scenario 1 , the second target object in the scenario 2, and the third target object in the scenario 3 may be the same target object, or may be different targets. Object. If the first target object, the second target object, and the third target object are the same target object, for example, each is referred to as the first target object, the first target object may be written by the description of the three scenarios in the above embodiment. The object storage system is such that the first target object can be read from the object storage system or the first target object can be deleted.
可选的,本发明实施例中,根据上述实施例的相关描述,当容器服务器从对象列表中删除一个对象的位置信息,并且将该对象的位置信息写入删除日志之后,可以通过容器服务器和对象服务器的交互,回收对象服务器中的该对象。下面以第一目标对象为例,对回收对象的方法做示例性的说明。Optionally, in the embodiment of the present invention, according to the related description of the foregoing embodiment, when the container server deletes the location information of an object from the object list, and writes the location information of the object to the deletion log, the container server may The interaction of the object server, which recycles the object in the object server. The following takes the first target object as an example, and exemplifies the method of recycling the object.
结合图1和图2,如图6所示,容器服务器从对象列表中删除第一目标对象的位置信息,并且将该第一目标对象的位置信息写入删除日志之后,本发明实施例提供的数据处 理方法还可以包括S401-S406:With reference to FIG. 1 and FIG. 2, as shown in FIG. 6, after the container server deletes the location information of the first target object from the object list, and the location information of the first target object is written into the deletion log, the embodiment of the present invention provides The data processing method may also include S401-S406:
S401、容器服务器向对象服务器发送垃圾回收请求消息。S401. The container server sends a garbage collection request message to the object server.
其中,垃圾回收请求消息中包括删除日志中的第一目标对象的位置信息。该垃圾请求消息用于请求对象服务器回收对象服务器中的第一目标对象的内容(即包括第一目标对象的元数据和数据)。The garbage collection request message includes location information of the first target object in the deletion log. The spam request message is used to request the object server to reclaim the content of the first target object in the object server (ie, including the metadata and data of the first target object).
可选的,本发明实施例中,容器服务器从对象列表中删除第一目标对象的位置信息,并且将该第一目标对象的位置信息写入删除日志之后,容器服务器在预设的时间间隔内向对象服务器发送垃圾回收请求消息,或者容器服务器可以在对象服务器的剩余存储空间比较小时,向对象服务器发送垃圾回收请求,以回收对象服务器中的对象(也可理解为垃圾)。Optionally, in the embodiment of the present invention, after the container server deletes the location information of the first target object from the object list, and the location information of the first target object is written into the deletion log, the container server is in a preset time interval. The object server sends a garbage collection request message, or the container server can send a garbage collection request to the object server to reclaim the object in the object server (also known as garbage) when the remaining storage space of the object server is relatively small.
S402、对象服务器接收容器服务器发送的垃圾回收请求消息。S402. The object server receives a garbage collection request message sent by the container server.
S403、对象服务器根据垃圾回收请求消息中的第一目标对象的位置信息,删除第一目标对象。S403. The object server deletes the first target object according to the location information of the first target object in the garbage collection request message.
本发明实施例中,对象服务器可以回收对象服务器中的垃圾对象,该垃圾对象即为容器服务器的删除日志中的对象的位置信息指示的对象,上述对象服务器回收第一目标对象的方法为:根据垃圾回收请求消息中的第一目标对象的位置信息,删除第一目标对象,从而释放了对象服务器的存储空间。In the embodiment of the present invention, the object server may reclaim the garbage object in the object server, where the garbage object is an object indicated by the location information of the object in the deletion log of the container server, and the method for the object server to collect the first target object is: The location information of the first target object in the garbage collection request message deletes the first target object, thereby releasing the storage space of the object server.
S404、对象服务器向容器服务器发送垃圾回收响应消息,该垃圾回收响应消息指示已删除第一目标对象。S404. The object server sends a garbage collection response message to the container server, where the garbage collection response message indicates that the first target object has been deleted.
S405、容器服务器接收对象服务器发送的垃圾回收响应消息。S405. The container server receives the garbage collection response message sent by the object server.
S406、容器服务器删除容器服务器的删除日志中的第一目标对象的位置信息。S406. The container server deletes the location information of the first target object in the deletion log of the container server.
本发明实施例中,容器服务器接收到对象服务器发送的垃圾回收响应消息之后,容器服务器可以将其删除日志中的该第一目标对象的位置信息删除,至此完成回收该第一目标对象,对象存储系统中不再存在该第一目标对象。In the embodiment of the present invention, after the container server receives the garbage collection response message sent by the object server, the container server may delete the location information of the first target object in the deletion log, thereby completing the recovery of the first target object, and the object storage The first target object no longer exists in the system.
可选的,本发明实施例中,在对象存储系统中,当读取某一对象与删除该对象并发发生时(即可以理解为对象存储系统处理读取某一对象的事件的同时也需要处理删除该对象的事件),以第一目标对象为例说明,根据上述实施例中的读取对象和删除对象的方法,本发明实施例中,在容器服务器将第一目标对象的位置信息从对象列表中删除,并且将第一目标对象的位置信息写入容器服务器的删除日志中之前,容器服务器已读取对象列表中的第一目标对象的位置信息,那么本次读取第一目标对象的流程和删除第一目标对象的流程中,即使容器服务器中的第一目标对象的位置信息已被删除,并且该第一目标对象的位置信息已被写入删除日志中,本次还可以读取到第一目标对象。Optionally, in the embodiment of the present invention, in the object storage system, when an object is read and the object is deleted concurrently (that is, it can be understood that the object storage system processes the event of reading an object, and also needs to be processed. In the embodiment of the present invention, the location information of the first target object is received from the object in the container server according to the method of reading the object and deleting the object in the foregoing embodiment. After the list is deleted, and the location information of the first target object is written in the delete log of the container server, the container server has read the location information of the first target object in the object list, and then the first target object is read this time. In the process of deleting and deleting the first target object, even if the location information of the first target object in the container server has been deleted, and the location information of the first target object has been written into the deletion log, this time can be read. Go to the first target object.
与现有技术相比,上述容器服务器中的第一目标对象的位置信息已被删除,并且该第一目标对象的位置信息已被写入删除日志中,本次还可以读取第一目标对象的原因是:本次删除第一目标对象的过程中,可以在删除日志中写入第一目标对象的位置信息,以表示对该第一目标对象做了删除标记,无需再对对象服务器中的第一目标对象做删除标记,因此,在对象服务器中该第一目标对象依然存在,并且还未被回收,如此,对象服务器可以根据上述容器服务器根据读取查询请求消息获取的第一目标对象的位置信息,在该对象服务器中读取该第一目标对象。可见本发明实施例提供的数据处理方法,能够在一定程度上避免读取对象和删除对象的冲突(指的是读取对象和删除对象并发发生时, 先删除对象的操作会造成读取对象的操作无法读取到该对象)。Compared with the prior art, the location information of the first target object in the container server has been deleted, and the location information of the first target object has been written into the deletion log, and the first target object can also be read this time. The reason is: in the process of deleting the first target object, the location information of the first target object may be written in the deletion log to indicate that the first target object is marked for deletion, and no need to be in the object server. The first target object is marked as deleted. Therefore, the first target object still exists in the object server and has not been reclaimed. Thus, the object server may obtain the first target object according to the read query request message according to the container server. Location information, the first target object is read in the object server. It can be seen that the data processing method provided by the embodiment of the present invention can avoid conflicts between the read object and the deleted object to a certain extent (refer to when the read object and the deleted object occur concurrently, the operation of deleting the object firstly causes the read object to be read. The operation could not read the object).
综上所述,本发明实施例提供的数据处理方法,上述删除对象、读取对象、上传对象以及回收对象的过程可以在用户态完成,能够降低开发和维护对象存储系统的难度。In summary, in the data processing method provided by the embodiment of the present invention, the process of deleting the object, reading the object, uploading the object, and reclaiming the object may be completed in the user state, which can reduce the difficulty in developing and maintaining the object storage system.
上述主要从各个网元之间交互的角度对本发明实施例提供的方案进行了介绍。可以理解的是,各个网元,例如容器服务器、对象服务器以及代理服务器等为了实现上述功能,其包含了执行各个功能相应的硬件结构和/或软件模块。本领域技术人员应该很容易意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,本发明实施例能够以硬件或硬件和计算机软件的结合形式来实现。某个功能究竟以硬件还是计算机软件驱动硬件的方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。The solution provided by the embodiment of the present invention is mainly introduced from the perspective of interaction between the network elements. It can be understood that various network elements, such as a container server, an object server, and a proxy server, etc., in order to implement the above functions, include hardware structures and/or software modules corresponding to each function. Those skilled in the art will readily appreciate that the embodiments of the present invention can be implemented in a combination of hardware or hardware and computer software in combination with the elements and algorithm steps of the various examples described in the embodiments disclosed herein. Whether a function is implemented in hardware or computer software to drive hardware depends on the specific application and design constraints of the solution. A person skilled in the art can use different methods to implement the described functions for each particular application, but such implementation should not be considered to be beyond the scope of the present application.
本发明实施例可以根据上述方法示例对容器服务器、对象服务器以及代理服务器等进行功能模块的划分,例如,可以对应各个功能划分各个功能模块,也可以将两个或两个以上的功能集成在一个处理模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。需要说明的是,本发明实施例中对模块的划分是示意性的,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式。The embodiments of the present invention may divide the function modules of the container server, the object server, the proxy server, and the like according to the foregoing method examples. For example, each function module may be divided according to each function, or two or more functions may be integrated into one. Processing module. The above integrated modules can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of the module in the embodiment of the present invention is schematic, and is only a logical function division, and the actual implementation may have another division manner.
在采用对应各个功能划分各个功能模块的情况下,图7示出了上述实施例中所涉及的容器服务器的一种可能的结构示意图,如图7所示,容器服务器可以包括:接收模块30、查询模块31、更新模块32以及发送模块33。其中,接收模块30可以用于支持容器服务器执行上述方法实施例中的S102、S202、S307和S405;查询模块31可以用于支持容器服务器执行上述方法实施例中的S103、S203;更新模块32可以用于支持容器服务器执行上述方法实施例中的S104、S308(包括S308a-S308b)和S406;发送模块33可以用于支持容器服务器执行上述方法实施例中的S105、S204和S401。可选的,如图7所示,该容器服务器还可以包括读取模块34。读取模块34可以用于支持容器服务器执行上述实施例中的“若接收模块30接收的读取查询消息中包括第一目标对象所属的容器的标识信息和第一目标对象的标识信息,在更新模块删除对象列表中的第一目标对象的位置信息,并且将第一目标对象的位置信息写入所述容器服务器的删除日志中之前,读取对象列表中的第一目标对象的位置信息”。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。FIG. 7 is a schematic diagram of a possible structure of the container server involved in the foregoing embodiment. As shown in FIG. 7, the container server may include: a receiving module 30, The query module 31, the update module 32, and the sending module 33. The receiving module 30 can be used to support the container server to execute S102, S202, S307, and S405 in the foregoing method embodiment; the query module 31 can be used to support the container server to execute S103, S203 in the foregoing method embodiment; the update module 32 can S104, S308 (including S308a-S308b) and S406 are used to support the container server in the foregoing method embodiment; the sending module 33 can be used to support the container server to execute S105, S204 and S401 in the above method embodiment. Optionally, as shown in FIG. 7, the container server may further include a reading module 34. The reading module 34 can be used to support the container server to perform the above-mentioned embodiment: "If the read query message received by the receiving module 30 includes the identification information of the container to which the first target object belongs and the identification information of the first target object, the update is performed. The module deletes the location information of the first target object in the object list, and reads the location information of the first target object in the object list before writing the location information of the first target object to the deletion log of the container server. All the related content of the steps involved in the foregoing method embodiments may be referred to the functional descriptions of the corresponding functional modules, and details are not described herein again.
在采用集成的单元的情况下,图8示出了上述实施例中所涉及的容器服务器的一种可能的结构示意图。如图8所示,容器服务器可以包括:处理模块40和通信模块41。处理模块40可以用于对容器服务器的动作进行控制管理,例如,处理模块40可以用于支持容器服务器执行上述方法实施例中的S103、S104、S203、S308(包括S308a-S308b)和S406,和/或用于本文所描述的技术的其它过程。通信模块41可以用于支持容器服务器与其他网络实体的通信,例如通信模块41可以用于支持容器服务器执行上述方法实施例中的S102、S105、S202、S204、S307、S401和S405。可选的,如图8所示,该容器服务器还可以包括存储模块42,用于存储容器服务器的程序代码和数据。In the case of employing an integrated unit, FIG. 8 shows a possible structural diagram of the container server involved in the above embodiment. As shown in FIG. 8, the container server may include a processing module 40 and a communication module 41. The processing module 40 can be used to control and manage the actions of the container server. For example, the processing module 40 can be used to support the container server to execute S103, S104, S203, S308 (including S308a-S308b) and S406 in the foregoing method embodiment, and / or other processes for the techniques described herein. The communication module 41 can be used to support communication between the container server and other network entities. For example, the communication module 41 can be used to support the container server to execute S102, S105, S202, S204, S307, S401, and S405 in the foregoing method embodiments. Optionally, as shown in FIG. 8, the container server may further include a storage module 42 for storing program code and data of the container server.
其中,处理模块40可以是处理器或控制器(例如可以是上述如图2所示的处理器201),例如可以是中央处理器(central processing unit,CPU)、通用处理器、数字信号 处理器(digital signal processor,DSP)、专用集成电路(application-specific integrated circuit,ASIC)、现场可编程门阵列(field programmable gate array,FPGA)或者其他可编程逻辑器件、晶体管逻辑器件、硬件部件或者其任意组合。其可以实现或执行结合本发明实施例公开内容所描述的各种示例性的逻辑方框、模块和电路。上述处理器也可以是实现计算功能的组合,例如包含一个或多个微处理器组合,DSP和微处理器的组合等等。通信模块41可以是收发器、收发电路或通信接口等(例如可以是上述如图2所示的通信接口203)。存储模块42可以是存储器(例如可以是上述如图2所示的存储器202)。The processing module 40 may be a processor or a controller (for example, the processor 201 shown in FIG. 2 above), and may be, for example, a central processing unit (CPU), a general-purpose processor, and a digital signal processor. (digital signal processor, DSP), application-specific integrated circuit (ASIC), field programmable gate array (FPGA) or other programmable logic device, transistor logic device, hardware component or any combination. It is possible to implement or carry out the various illustrative logical blocks, modules and circuits described in connection with the embodiments of the invention. The above processors may also be a combination of computing functions, such as one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like. The communication module 41 may be a transceiver, a transceiver circuit, or a communication interface or the like (for example, may be the communication interface 203 shown in FIG. 2 described above). The storage module 42 can be a memory (which can be, for example, the memory 202 shown above in FIG. 2).
当处理模块40为处理器,通信模块41为收发器,存储模块42为存储器时,处理器、收发器和存储器可以通过总线连接。总线可以是外设部件互连标准(peripheral component interconnect,PCI)总线或扩展工业标准结构(extended Industry standard architecture,EISA)总线等。总线可以分为地址总线、数据总线、控制总线等。When the processing module 40 is a processor, the communication module 41 is a transceiver, and the storage module 42 is a memory, the processor, the transceiver, and the memory can be connected by a bus. The bus can be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The bus can be divided into an address bus, a data bus, a control bus, and the like.
在采用对应各个功能划分各个功能模块的情况下,图9示出了上述实施例中所涉及的对象服务器的一种可能的结构示意图,如图9所示,对象服务器可以包括:接收模块50、写数据模块51以及发送模块52。接收模块50可以用于支持对象服务器执行上述方法实施例中的S207、S302和S402;写数据模块51可以用于支持对象服务器执行上述方法实施例中的S303;发送模块52可以用于支持对象服务器执行上述方法实施例中的S209、S304和S404。可选的,如图9所示,该对象服务器还可以包括读取模块53和删除模块54。读取模块53可以用于支持对象服务器执行上述方法实施例中的S208;删除模块54可以用于支持对象服务器执行上述方法实施例中的S403。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。FIG. 9 is a schematic diagram of a possible structure of the object server involved in the foregoing embodiment. As shown in FIG. 9, the object server may include: a receiving module 50, The data module 51 and the transmitting module 52 are written. The receiving module 50 can be used to support the object server to execute S207, S302, and S402 in the foregoing method embodiment; the write data module 51 can be used to support the object server to execute S303 in the foregoing method embodiment; and the sending module 52 can be used to support the object server. S209, S304, and S404 in the above method embodiment are executed. Optionally, as shown in FIG. 9, the object server may further include a reading module 53 and a deleting module 54. The reading module 53 can be used to support the object server to execute S208 in the above method embodiment; the deleting module 54 can be used to support the object server to execute S403 in the above method embodiment. All the related content of the steps involved in the foregoing method embodiments may be referred to the functional descriptions of the corresponding functional modules, and details are not described herein again.
在采用集成的单元的情况下,图10示出了上述实施例中所涉及的对象服务器的一种可能的结构示意图。如图10所示,对象服务器可以包括:处理模块60和通信模块61。处理模块60可以用于对对象服务器的动作进行控制管理,例如,处理模块60可以用于支持对象服务器执行上述方法实施例中的S208、S303和S403,和/或用于本文所描述的技术的其它过程。通信模块61可以用于支持对象服务器与其他网络实体的通信,例如通信模块61可以用于支持对象服务器执行上述方法实施例中的S207、S209、S302、S304、S402和S404。可选的,如图10所示,该对象服务器还可以包括存储模块62,用于存储对象服务器的程序代码和数据。In the case of employing an integrated unit, FIG. 10 shows a possible structural diagram of the object server involved in the above embodiment. As shown in FIG. 10, the object server may include a processing module 60 and a communication module 61. The processing module 60 can be used to control and manage the actions of the object server. For example, the processing module 60 can be used to support the object server to execute S208, S303, and S403 in the foregoing method embodiments, and/or for the techniques described herein. Other processes. The communication module 61 can be used to support communication between the object server and other network entities. For example, the communication module 61 can be used to support the object server to execute S207, S209, S302, S304, S402, and S404 in the foregoing method embodiments. Optionally, as shown in FIG. 10, the object server may further include a storage module 62 for storing program code and data of the object server.
其中,处理模块60可以是处理器或控制器(例如可以是上述如图2所示的处理器301),例如可以是CPU、通用处理器、DSP、ASIC、FPGA或者其他可编程逻辑器件、晶体管逻辑器件、硬件部件或者其任意组合。其可以实现或执行结合本发明实施例公开内容所描述的各种示例性的逻辑方框、模块和电路。上述处理器也可以是实现计算功能的组合,例如包含一个或多个微处理器组合,DSP和微处理器的组合等等。通信模块61可以是收发器、收发电路或通信接口等(例如可以是上述如图2所示的通信接口303)。存储模块62可以是存储器(例如可以是上述如图2所示的存储器302)。The processing module 60 may be a processor or a controller (for example, the processor 301 shown in FIG. 2 above), and may be, for example, a CPU, a general-purpose processor, a DSP, an ASIC, an FPGA, or other programmable logic device, a transistor. Logic device, hardware component, or any combination thereof. It is possible to implement or carry out the various illustrative logical blocks, modules and circuits described in connection with the embodiments of the invention. The above processors may also be a combination of computing functions, such as one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like. The communication module 61 may be a transceiver, a transceiver circuit or a communication interface or the like (for example, may be the communication interface 303 shown in FIG. 2 described above). The storage module 62 can be a memory (which can be, for example, the memory 302 shown above in FIG. 2).
当处理模块60为处理器,通信模块61为收发器,存储模块62为存储器时,处理器、收发器和存储器可以通过总线连接。总线可以是PCI总线或EISA总线等。总线可以分为地址总线、数据总线、控制总线等。When the processing module 60 is a processor, the communication module 61 is a transceiver, and the storage module 62 is a memory, the processor, the transceiver, and the memory can be connected by a bus. The bus can be a PCI bus or an EISA bus. The bus can be divided into an address bus, a data bus, a control bus, and the like.
在采用对应各个功能划分各个功能模块的情况下,图11示出了上述实施例中所涉及的代理服务器的一种可能的结构示意图,如图11所示,代理服务器可以包括:发送模块 70和接收模块71。发送模块70可以用于支持代理服务器执行上述方法实施例中的S101、S201、S206、S301和S306;接收模块50可以用于支持代理服务器执行上述方法实施例中的S205和S305。其中,上述方法实施例涉及的各步骤的所有相关内容均可以援引到对应功能模块的功能描述,在此不再赘述。FIG. 11 is a schematic diagram showing a possible structure of the proxy server involved in the foregoing embodiment. As shown in FIG. 11, the proxy server may include: a sending module 70 and Receive module 71. The sending module 70 can be used to support the proxy server to execute S101, S201, S206, S301, and S306 in the foregoing method embodiment; the receiving module 50 can be used to support the proxy server to execute S205 and S305 in the foregoing method embodiment. All the related content of the steps involved in the foregoing method embodiments may be referred to the functional descriptions of the corresponding functional modules, and details are not described herein again.
在采用集成的单元的情况下,图12示出了上述实施例中所涉及的代理服务器的一种可能的结构示意图。如图12所示,代理服务器可以包括:处理模块80和通信模块81。处理模块80可以用于对代理服务器的动作进行控制管理。通信模块81可以用于支持代理服务器与其他网络实体的通信,例如通信模块81可以用于支持代理服务器执行上述方法实施例中的S101、S201、S206、S205、S301、S305和S306。可选的,如图12所示,该代理服务器还可以包括存储模块82,用于存储代理服务器的程序代码和数据。In the case of employing an integrated unit, FIG. 12 shows a possible structural diagram of the proxy server involved in the above embodiment. As shown in FIG. 12, the proxy server may include a processing module 80 and a communication module 81. The processing module 80 can be used to control and manage the actions of the proxy server. The communication module 81 can be used to support communication between the proxy server and other network entities. For example, the communication module 81 can be used to support the proxy server to execute S101, S201, S206, S205, S301, S305, and S306 in the foregoing method embodiments. Optionally, as shown in FIG. 12, the proxy server may further include a storage module 82 for storing program code and data of the proxy server.
其中,处理模块80可以是处理器或控制器(例如可以是上述如图2所示的处理器101),例如可以是CPU、通用处理器、DSP、ASIC、FPGA或者其他可编程逻辑器件、晶体管逻辑器件、硬件部件或者其任意组合。其可以实现或执行结合本发明实施例公开内容所描述的各种示例性的逻辑方框、模块和电路。上述处理器也可以是实现计算功能的组合,例如包含一个或多个微处理器组合,DSP和微处理器的组合等等。通信模块81可以是收发器、收发电路或通信接口等(例如可以是上述如图2所示的通信接口103)。存储模块82可以是存储器(例如可以是上述如图2所示的存储器102)。The processing module 80 may be a processor or a controller (for example, the processor 101 shown in FIG. 2 above), and may be, for example, a CPU, a general-purpose processor, a DSP, an ASIC, an FPGA, or other programmable logic device, a transistor. Logic device, hardware component, or any combination thereof. It is possible to implement or carry out the various illustrative logical blocks, modules and circuits described in connection with the embodiments of the invention. The above processors may also be a combination of computing functions, such as one or more microprocessor combinations, a combination of a DSP and a microprocessor, and the like. The communication module 81 may be a transceiver, a transceiver circuit or a communication interface or the like (for example, may be the communication interface 103 as shown in FIG. 2 described above). The storage module 82 can be a memory (which can be, for example, the memory 102 shown above in FIG. 2).
当处理模块80为处理器,通信模块81为收发器,存储模块82为存储器时,处理器、收发器和存储器可以通过总线连接。总线可以是PCI总线或EISA总线等。总线可以分为地址总线、数据总线、控制总线等。When the processing module 80 is a processor, the communication module 81 is a transceiver, and the storage module 82 is a memory, the processor, the transceiver, and the memory can be connected by a bus. The bus can be a PCI bus or an EISA bus. The bus can be divided into an address bus, a data bus, a control bus, and the like.
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件程序实现时,可以全部或部分地以计算机程序产品的形式实现。该计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行该计算机指令时,全部或部分地产生按照本发明实施例中的流程或功能。该计算机可以是通用计算机、专用计算机、计算机网络或者其他可编程装置。该计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,该计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(digital subscriber line,DSL))方式或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心传输。该计算机可读存储介质可以是计算机能够存取的任何可用介质或者是包括一个或多个可用介质集成的服务器、数据中心等数据存储设备。该可用介质可以是磁性介质(例如,软盘、磁盘、磁带)、光介质(例如,数字视频光盘(digital video disc,DVD))、或者半导体介质(例如固态硬盘(solid state drives,SSD))等。In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented using a software program, it may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the processes or functions in accordance with embodiments of the present invention are generated in whole or in part. The computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be wired from a website site, computer, server or data center (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (eg infrared, wireless, microwave, etc.) to another website, computer, server or data center. The computer readable storage medium can be any available media that can be accessed by a computer or a data storage device such as a server, data center, or the like that includes one or more available media. The usable medium may be a magnetic medium (for example, a floppy disk, a magnetic disk, a magnetic tape), an optical medium (for example, a digital video disc (DVD)), or a semiconductor medium (such as a solid state drives (SSD)). .
通过以上的实施方式的描述,所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Through the description of the above embodiments, those skilled in the art can clearly understand that for the convenience and brevity of the description, only the division of the above functional modules is illustrated. In practical applications, the above functions can be allocated according to needs. It is completed by different functional modules, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. For the specific working process of the system, the device and the unit described above, reference may be made to the corresponding process in the foregoing method embodiments, and details are not described herein again.
在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述模 块或单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided by the present application, it should be understood that the disclosed system, apparatus, and method may be implemented in other manners. For example, the device embodiments described above are merely illustrative. For example, the division of the modules or units is only a logical function division. In actual implementation, there may be another division manner, for example, multiple units or components may be used. Combinations can be integrated into another system, or some features can be ignored or not executed. In addition, the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, device or unit, and may be in an electrical, mechanical or other form.
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
所述集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读取存储介质中。基于这样的理解,本申请的技术方案本质上或者说对现有技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质中,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)或处理器执行本申请各个实施例所述方法的全部或部分步骤。而前述的存储介质包括:快闪存储器、移动硬盘、只读存储器、随机存取存储器、磁碟或者光盘等各种可以存储程序代码的介质。The integrated unit, if implemented in the form of a software functional unit and sold or used as a standalone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application, in essence or the contribution to the prior art, or all or part of the technical solution may be embodied in the form of a software product stored in a storage medium. A number of instructions are included to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to perform all or part of the steps of the methods described in various embodiments of the present application. The foregoing storage medium includes: a flash memory, a mobile hard disk, a read only memory, a random access memory, a magnetic disk, or an optical disk, and the like, which can store program codes.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何在本申请揭露的技术范围内的变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。The foregoing is only a specific embodiment of the present application, but the scope of protection of the present application is not limited thereto, and any changes or substitutions within the technical scope of the present application should be covered by the scope of the present application. . Therefore, the scope of protection of the present application should be determined by the scope of the claims.

Claims (31)

  1. 一种数据处理方法,其特征在于,包括:A data processing method, comprising:
    容器服务器接收代理服务器发送的删除查询消息,所述删除查询消息中包括第一目标对象所属的容器的标识信息和所述第一目标对象的标识信息;The container server receives the delete query message sent by the proxy server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object;
    所述容器服务器根据所述第一目标对象所属的容器的标识信息和所述第一目标对象的标识信息,在所述容器服务器的对象列表中查询所述第一目标对象的位置信息,所述对象列表中包含第一类对象的位置信息,所述第一类对象为未被标记删除的、对象服务器中存储的对象,一个第一类对象的位置信息用于指示所述对象在所述对象服务器中的位置;The container server queries the location information of the first target object in the object list of the container server according to the identifier information of the container to which the first target object belongs and the identifier information of the first target object, The object list includes location information of the first type of object, the first type of object is an object stored in the object server that is not marked and deleted, and the location information of the first type of object is used to indicate that the object is in the object. The location in the server;
    若在所述对象列表中查询到所述第一目标对象的位置信息,所述容器服务器删除所述对象列表中的所述第一目标对象的位置信息,并且将所述第一目标对象的位置信息写入所述容器服务器的删除日志中,所述删除日志中包含第二类对象的位置信息,所述第二类对象为被标记删除的、对象服务器中存储的对象的位置信息;If the location information of the first target object is queried in the object list, the container server deletes location information of the first target object in the object list, and positions the first target object The information is written in the deletion log of the container server, where the deletion log includes location information of the second type of object, and the second type of object is location information of the object stored in the object server that is marked and deleted;
    所述容器服务器向所述代理服务器发送删除响应消息。The container server sends a delete response message to the proxy server.
  2. 根据权利要求1所述的方法,其特征在于,The method of claim 1 wherein
    所述第一目标对象的位置信息包括所述第一目标对象所在的文件标识、所述第一目标对象的偏移量以及所述第一目标对象的尺寸,所述文件标识指示的文件中包括至少两个对象;或者,The location information of the first target object includes a file identifier of the first target object, an offset of the first target object, and a size of the first target object, where the file identifier indicates that the file includes At least two objects; or,
    所述第一目标对象的位置信息包括所述第一目标对象的ID。The location information of the first target object includes an ID of the first target object.
  3. 根据权利要求1或2所述的方法,其特征在于,所述方法还包括:The method according to claim 1 or 2, wherein the method further comprises:
    所述容器服务器接收所述代理服务器发送的读取查询消息,所述读取查询消息中包括第二目标对象所属的容器的标识信息和所述第二目标对象的标识信息;The container server receives the read query message sent by the proxy server, where the read query message includes the identifier information of the container to which the second target object belongs and the identifier information of the second target object;
    所述容器服务器根据所述第二目标对象所属的容器的标识信息和所述第二目标对象的标识信息,在所述对象列表中查询所述第二目标对象的位置信息,所述第二目标对象的位置信息包括所述第二目标对象所在的文件标识、所述第二目标对象的偏移量以及所述第二目标对象的尺寸,所述文件标识指示的文件中包括至少两个对象;The container server queries location information of the second target object in the object list according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object, and the second target The location information of the object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, where the file identifier indicates that at least two objects are included in the file;
    若在所述对象列表中查询到所述第二目标对象的位置信息,所述容器服务器向所述代理服务器发送所述第二目标对象的位置信息,以指示所述代理服务器根据所述第二目标对象的位置信息从所述对象服务器中读取所述第二目标对象。If the location information of the second target object is queried in the object list, the container server sends location information of the second target object to the proxy server to indicate that the proxy server is according to the second The location information of the target object reads the second target object from the object server.
  4. 根据权利要求1至3任意一项所述的方法,其特征在于,若所述容器服务器接收的读取查询消息中包括所述第一目标对象所属的容器的标识信息和所述第一目标对象的标识信息,在所述容器服务器删除所述对象列表中的所述第一目标对象的位置信息,并且将所述第一目标对象的位置信息写入所述容器服务器的删除日志中之前,所述方法还包括:The method according to any one of claims 1 to 3, wherein the read query message received by the container server includes identification information of the container to which the first target object belongs and the first target object. Identification information, where the container server deletes location information of the first target object in the object list, and writes location information of the first target object into a deletion log of the container server, The method also includes:
    所述容器服务器读取所述对象列表中的所述第一目标对象的位置信息。The container server reads location information of the first target object in the object list.
  5. 根据权利要求1至4任意一项所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1 to 4, further comprising:
    所述容器服务器向所述对象服务器发送垃圾回收请求消息,所述垃圾回收请求消息中包括所述删除日志中的目标对象的位置信息;The container server sends a garbage collection request message to the object server, where the garbage collection request message includes location information of the target object in the deletion log;
    所述容器服务器接收所述对象服务器发送的垃圾回收响应消息,所述垃圾回收响应消息指示所述对象服务器已删除所述目标对象;Receiving, by the container server, a garbage collection response message sent by the object server, where the garbage collection response message indicates that the target server has deleted the target object;
    所述容器服务器删除所述删除日志中所述目标对象的位置信息。The container server deletes location information of the target object in the deletion log.
  6. 根据权利要求1至5任意一项所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1 to 5, further comprising:
    所述容器服务器接收所述代理服务器发送的位置更新消息,所述位置更新消息用于更新第三目标对象的位置信息,所述位置更新消息中包括所述第三目标对象所属的容器的标识信息、所述第三目标对象的标识信息以及所述第三目标对象的第一位置信息;Receiving, by the container server, a location update message sent by the proxy server, where the location update message is used to update location information of a third target object, where the location update message includes identifier information of a container to which the third target object belongs The identification information of the third target object and the first location information of the third target object;
    所述容器服务器根据所述位置更新消息,更新所述第三目标对象的位置信息。The container server updates the location information of the third target object according to the location update message.
  7. 根据权利要求6所述的方法,其特征在于,所述容器服务器根据所述位置更新消息,更新所述第三目标对象的位置信息,包括:The method according to claim 6, wherein the container server updates the location information of the third target object according to the location update message, including:
    所述容器服务器根据所述第三目标对象所属的容器的标识信息、所述第三目标对象的标识信息,在所述容器服务器的对象列表中查询所述第三目标对象的位置信息;The container server queries the location information of the third target object in the object list of the container server according to the identifier information of the container to which the third target object belongs and the identifier information of the third target object;
    若在所述对象列表中未查询到所述第三目标对象的位置信息,所述容器服务器将所述位置更新消息中的第三目标对象的第一位置信息写入所述对象列表;If the location information of the third target object is not queried in the object list, the container server writes the first location information of the third target object in the location update message into the object list;
    若在所述对象列表中查询到所述第三目标对象的位置信息,所述第三目标对象的位置信息为第二位置信息,并且所述第三目标对象的第二位置信息与所述位置更新消息中的所述第三目标对象的第一位置信息不同,所述容器服务器将所述第三目标对象的第二位置信息替换为所述第三目标对象的第一位置信息,并且将所述第三目标对象的第二位置信息写入所述容器服务器的删除日志中。If the location information of the third target object is queried in the object list, the location information of the third target object is second location information, and the second location information of the third target object is related to the location The first location information of the third target object in the update message is different, the container server replaces the second location information of the third target object with the first location information of the third target object, and The second location information of the third target object is written in the delete log of the container server.
  8. 一种数据处理方法,其特征在于,包括:A data processing method, comprising:
    对象服务器接收代理服务器发送的上传目标对象的请求消息,所述上传目标对象的请求消息中包括第三目标对象;The object server receives a request message of the upload target object sent by the proxy server, where the request message of the upload target object includes a third target object;
    所述对象服务器将所述第三目标对象写入所述对象服务器中;Writing, by the object server, the third target object into the object server;
    所述对象服务器向所述代理服务器发送所述第三目标对象的位置信息,所述第三目标对象的位置信息包括所述第三目标对象所在的文件标识、所述第三目标对象的偏移量以及所述第三目标对象的尺寸,所述文件标识指示的文件中包括有至少两个对象。The object server sends the location information of the third target object to the proxy server, where the location information of the third target object includes a file identifier of the third target object, and an offset of the third target object. And the size of the third target object, wherein the file identifier indicates that at least two objects are included in the file.
  9. 根据权利要求8所述的方法,其特征在于,所述方法还包括:The method of claim 8 further comprising:
    所述对象服务器接收所述代理服务器发送的第二目标对象的位置信息;Receiving, by the object server, location information of the second target object sent by the proxy server;
    所述对象服务器根据所述第二目标对象的位置信息读取所述第二目标对象;The object server reads the second target object according to location information of the second target object;
    所述对象服务器向所述代理服务器发送发送所述第二目标对象。The object server sends the second target object to the proxy server.
  10. 根据权利要求8或9所述的方法,其特征在于,所述方法还包括:The method according to claim 8 or 9, wherein the method further comprises:
    所述对象服务器接收所述容器服务器发送的垃圾回收请求消息,所述垃圾回收请求消息中包括所述容器服务器的删除日志中的第一目标对象的位置信息;Receiving, by the object server, a garbage collection request message sent by the container server, where the garbage collection request message includes location information of a first target object in a deletion log of the container server;
    所述对象服务器根据所述第一目标对象的位置信息,删除所述第一目标对象;The object server deletes the first target object according to location information of the first target object;
    所述对象服务器向所述容器服务器发送垃圾回收响应消息,所述垃圾回收响应消息指示已删除所述第一目标对象。The object server sends a garbage collection response message to the container server, the garbage collection response message indicating that the first target object has been deleted.
  11. 一种数据处理方法,其特征在于,包括:A data processing method, comprising:
    代理服务器向对象服务器发送上传目标对象的请求消息,所述上传目标对象的请求消息中包括所述目标对象;The proxy server sends a request message for uploading the target object to the object server, where the request message of the upload target object includes the target object;
    所述代理服务器接收所述对象服务器发送的所述目标对象的第一位置信息,所述目标对象的第一位置信息包括所述目标对象所在的文件标识、所述目标对象的偏移量以及所述目标对象的尺寸,所述文件标识指示的文件中保存有至少两个对象;Receiving, by the proxy server, first location information of the target object sent by the object server, where the first location information of the target object includes a file identifier of the target object, an offset of the target object, and a location a size of the target object, where the file identifier indicates that at least two objects are stored in the file;
    所述代理服务器向容器服务器发送所述位置更新消息,以指示所述容器服务器根据所述位置更新消息,更新所述容器服务器的对象列表中的所述目标对象的位置信息,所述位置更新消息中包括所述目标对象所属的容器的标识信息、所述目标对象的标识信息以及所述目标对象的第一位置信息。Sending, by the proxy server, the location update message to the container server, to instruct the container server to update location information of the target object in the object list of the container server according to the location update message, the location update message The identification information of the container to which the target object belongs, the identification information of the target object, and the first location information of the target object are included.
  12. 根据权利要求11所述的方法,其特征在于,所述方法还包括:The method of claim 11 wherein the method further comprises:
    所述代理服务器接收所述容器服务器发送的删除响应消息,所述删除响应消息为所述容器服务删除所述对象列表中的所述目标对象的位置信息,并将所述目标所述目标对象的位置信息写入所述容器服务器的删除日志之后发送的。Receiving, by the proxy server, a delete response message sent by the container server, where the delete response message is used by the container service to delete location information of the target object in the object list, and the target target object is The location information is sent after being written to the delete log of the container server.
  13. 一种容器服务器,其特征在于,包括接收模块、查询模块、更新模块以及发送模块;A container server, comprising: a receiving module, a query module, an update module, and a sending module;
    所述接收模块,用于接收代理服务器发送的删除查询消息,所述删除查询消息中包括第一目标对象所属的容器的标识信息和所述第一目标对象的标识信息;The receiving module is configured to receive a delete query message sent by the proxy server, where the delete query message includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object;
    所述查询模块,用于根据所述接收模块接收的所述第一目标对象所属的容器的标识信息和所述第一目标对象的标识信息,在所述容器服务器的对象列表中查询所述第一目标对象的位置信息,所述对象列表中包含第一类对象的位置信息,所述第一类对象为未被标记删除的、对象服务器中存储的对象,一个第一类对象的位置信息用于指示所述对象在所述对象服务器中的位置;The querying module is configured to query the object list in the container server according to the identifier information of the container to which the first target object belongs and the identifier information of the first target object received by the receiving module Position information of a target object, the object list includes location information of the first type of object, the first type of object is an object stored in the object server that is not marked and deleted, and the location information of the first type of object is used. Instructing the location of the object in the object server;
    所述更新模块,用于若所述查询模块在所述对象列表中查询到所述第一目标对象的位置信息,删除所述对象列表中的所述第一目标对象的位置信息,并且将所述第一目标对象的位置信息写入所述容器服务器的删除日志中,所述删除日志中包含第二类对象的位置信息,所述第二类对象为被标记删除的、对象服务器中存储的对象的位置信息;The update module is configured to: if the query module queries location information of the first target object in the object list, delete location information of the first target object in the object list, and The location information of the first target object is written in a deletion log of the container server, where the deletion log includes location information of a second type of object, and the second type of object is deleted by the object server stored in the object server Location information of the object;
    所述发送模块,用于向所述代理服务器发送删除响应消息。The sending module is configured to send a delete response message to the proxy server.
  14. 根据权利要求13所述的容器服务器,其特征在于,A container server according to claim 13 wherein:
    所述第一目标对象的位置信息包括所述第一目标对象所在的文件标识、所述第一目标对象的偏移量以及所述第一目标对象的尺寸,所述文件标识指示的文件中包括至少两个对象;或者,The location information of the first target object includes a file identifier of the first target object, an offset of the first target object, and a size of the first target object, where the file identifier indicates that the file includes At least two objects; or,
    所述第一目标对象的位置信息包括所述第一目标对象的ID。The location information of the first target object includes an ID of the first target object.
  15. 根据权利要求13或14所述的容器服务器,其特征在于,A container server according to claim 13 or 14, wherein
    所述接收模块,还用于接收所述代理服务器发送的读取查询消息,所述读取查询消息中包括第二目标对象所属的容器的标识信息和所述第二目标对象的标识信息;The receiving module is further configured to receive a read query message sent by the proxy server, where the read query message includes identifier information of a container to which the second target object belongs and identifier information of the second target object;
    所述查询模块,还用于根据所述接收模块接收的所述第二目标对象所属的容器的标识信息和所述第二目标对象的标识信息,在所述对象列表中查询所述第二目标对象的位置信息,所述第二目标对象的位置信息包括所述第二目标对象所在的文件标识、所述第二目标对象的偏移量以及所述第二目标对象的尺寸,所述文件标识指示的文件中包括至少两个对象;The querying module is further configured to query the second target in the object list according to the identifier information of the container to which the second target object belongs and the identifier information of the second target object received by the receiving module Location information of the object, the location information of the second target object includes a file identifier of the second target object, an offset of the second target object, and a size of the second target object, the file identifier The indicated file includes at least two objects;
    所述发送模块,还用于若所述查询模块在所述对象列表中查询到所述第二目标对象的位置信息,所述容器服务器向所述代理服务器发送所述第二目标对象的位置信息,以指示所述代理服务器根据所述第二目标对象的位置信息从所述对象服务器中读取所述第二目标对象。The sending module is further configured to: if the query module queries location information of the second target object in the object list, the container server sends location information of the second target object to the proxy server Instructing the proxy server to read the second target object from the object server according to location information of the second target object.
  16. 根据权利要求13至15任意一项所述的容器服务器,其特征在于,所述容器服 务器还包括读取模块;A container server according to any one of claims 13 to 15, wherein the container server further comprises a reading module;
    所述读取模块,用于若所述接收模块接收的读取查询消息中包括所述第一目标对象所属的容器的标识信息和所述第一目标对象的标识信息,在所述更新模块删除所述对象列表中的所述第一目标对象的位置信息,并且将所述第一目标对象的位置信息写入所述容器服务器的删除日志中之前,读取所述对象列表中的所述第一目标对象的位置信息。The reading module is configured to: if the read query message received by the receiving module includes the identifier information of the container to which the first target object belongs and the identifier information of the first target object, the update module deletes Reading the location information of the first target object in the object list, and reading the location information of the first target object into the deletion log of the container server, reading the number in the object list The location information of a target object.
  17. 根据权利要求13至16任意一项所述的容器服务器,其特征在于,A container server according to any one of claims 13 to 16, wherein
    所述发送模块,还用于向所述对象服务器发送垃圾回收请求消息,所述垃圾回收请求消息中包括所述删除日志中的目标对象的位置信息;The sending module is further configured to send a garbage collection request message to the object server, where the garbage collection request message includes location information of the target object in the deletion log;
    所述接收模块,还用于接收所述对象服务器发送的垃圾回收响应消息,所述垃圾回收响应消息指示所述对象服务器已删除所述目标对象;The receiving module is further configured to receive a garbage collection response message sent by the object server, where the garbage collection response message indicates that the target server has deleted the target object;
    所述更新模块,还用于删除所述删除日志中所述目标对象的位置信息。The update module is further configured to delete location information of the target object in the deletion log.
  18. 根据权利要要求13至17任意一项所述的容器服务器,其特征在于,A container server according to any one of claims 13 to 17, wherein
    所述接收模块,还用于接收所述代理服务器发送的位置更新消息,所述位置更新消息用于更新第三目标对象的位置信息,所述位置更新消息中包括所述第三目标对象所属的容器的标识信息、所述第三目标对象的标识信息以及所述第三目标对象的第一位置信息;The receiving module is further configured to receive a location update message sent by the proxy server, where the location update message is used to update location information of a third target object, where the location update message includes a third target object that belongs to Identification information of the container, identification information of the third target object, and first location information of the third target object;
    所述更新模块,还用于根据所述接收模块接收的所述位置更新消息,更新所述第三目标对象的位置信息。The update module is further configured to update location information of the third target object according to the location update message received by the receiving module.
  19. 根据权利要求18所述的容器服务器,其特征在于,A container server according to claim 18, wherein
    所述查询模块,还用于根据所述第三目标对象所属的容器的标识信息、所述第三目标对象的标识信息,在所述容器服务器的对象列表中查询所述第三目标对象的位置信息;The querying module is further configured to query, according to the identifier information of the container to which the third target object belongs, and the identifier information of the third target object, the location of the third target object in the object list of the container server information;
    所述更新模块,具体用于若所述查询模块在所述对象列表中未查询到所述第三目标对象的位置信息,将所述位置更新消息中的第三目标对象的第一位置信息写入所述对象列表,若所述查询模块在所述对象列表中查询到所述第三目标对象的位置信息,所述第三目标对象的位置信息为第二位置信息,并且所述第三目标对象的第二位置信息与所述位置更新消息中的所述第三目标对象的第一位置信息不同,将所述第三目标对象的第二位置信息替换为所述第三目标对象的第一位置信息,并且将所述第三目标对象的第二位置信息写入所述容器服务器的删除日志中。The update module is specifically configured to: if the query module does not query the location information of the third target object in the object list, write the first location information of the third target object in the location update message Entering the object list, if the query module queries the location information of the third target object in the object list, the location information of the third target object is second location information, and the third target The second location information of the object is different from the first location information of the third target object in the location update message, and the second location information of the third target object is replaced with the first location of the third target object. Location information, and the second location information of the third target object is written into the deletion log of the container server.
  20. 一种对象服务器,其特征在于,包括接收模块、写数据模块以及发送模块;An object server, comprising: a receiving module, a write data module, and a sending module;
    所述接收模块,用于接收代理服务器发送的上传目标对象的请求消息,所述上传目标对象的请求消息中包括第三目标对象;The receiving module is configured to receive a request message of an upload target object sent by the proxy server, where the request message of the upload target object includes a third target object;
    所述写数据模块,用于将所述接收模块接收的所述第三目标对象写入所述对象服务器中;The write data module is configured to write the third target object received by the receiving module into the object server;
    所述发送模块,用于向所述代理服务器发送所述第三目标对象的位置信息,所述第三目标对象的位置信息包括所述第三目标对象所在的文件标识、所述第三目标对象的偏移量以及所述第三目标对象的尺寸,所述文件标识指示的文件中包括有至少两个对象。The sending module is configured to send location information of the third target object to the proxy server, where the location information of the third target object includes a file identifier of the third target object, and the third target object And an offset of the third target object, wherein the file identifier indicates that at least two objects are included in the file.
  21. 根据权利要求20所述的对象服务器,其特征在于,所述对象服务器还包括读取模块;The object server according to claim 20, wherein the object server further comprises a reading module;
    所述接收模块,还用于接收所述代理服务器发送的第二目标对象的位置信息;The receiving module is further configured to receive location information of the second target object sent by the proxy server;
    所述读取模块,用于根据所述接收模块接收的所述第二目标对象的位置信息读取所 述第二目标对象;The reading module is configured to read the second target object according to location information of the second target object received by the receiving module;
    所述发送模块,还用于向所述代理服务器发送发送所述第二目标对象。The sending module is further configured to send, send, to the proxy server, the second target object.
  22. 根据权利要求20或21所述的对象服务器,其特征在于,所述对象服务器还包括删除模块;The object server according to claim 20 or 21, wherein the object server further comprises a deletion module;
    所述接收模块,还用于接收所述容器服务器发送的垃圾回收请求消息,所述垃圾回收请求消息中包括所述容器服务器的删除日志中的第一目标对象的位置信息;The receiving module is further configured to receive a garbage collection request message sent by the container server, where the garbage collection request message includes location information of a first target object in a deletion log of the container server;
    所述删除模块,用于根据所述接收模块接收的所述第一目标对象的位置信息,删除所述第一目标对象;The deleting module is configured to delete the first target object according to location information of the first target object received by the receiving module;
    所述发送模块,还用于向所述容器服务器发送垃圾回收响应消息,所述垃圾回收响应消息指示已删除所述第一目标对象。The sending module is further configured to send a garbage collection response message to the container server, where the garbage collection response message indicates that the first target object has been deleted.
  23. 一种代理服务器,其特征在于,包括发送模块和接收模块;A proxy server, comprising: a sending module and a receiving module;
    所述发送模块,用于向对象服务器发送上传目标对象的请求消息,所述上传目标对象的请求消息中包括所述目标对象;The sending module is configured to send a request message for uploading a target object to the object server, where the request message of the upload target object includes the target object;
    所述接收模块,用于接收所述对象服务器发送的所述目标对象的第一位置信息,所述目标对象的第一位置信息包括所述目标对象所在的文件标识、所述目标对象的偏移量以及所述目标对象的尺寸,所述文件标识指示的文件中保存有至少两个对象;The receiving module is configured to receive first location information of the target object that is sent by the object server, where the first location information of the target object includes a file identifier of the target object, and an offset of the target object And a size of the target object, where at least two objects are stored in the file indicated by the file identifier;
    所述发送模块,还用于向容器服务器发送位置更新消息,以指示所述容器服务器根据所述位置更新消息,更新所述容器服务器的对象列表中的所述目标对象的位置信息,所述位置更新消息中包括所述目标对象所属的容器的标识信息、所述目标对象的标识信息以及所述目标对象的第一位置信息。The sending module is further configured to send a location update message to the container server, to instruct the container server to update location information of the target object in the object list of the container server according to the location update message, where the location The update message includes identification information of the container to which the target object belongs, identification information of the target object, and first location information of the target object.
  24. 根据权利要求23所述的代理服务器,其特征在于,A proxy server according to claim 23, wherein
    所述接收模块,还用于接收所述容器服务器发送的删除响应消息,所述删除响应消息为所述容器服务删除所述对象列表中的所述目标对象的位置信息,并将所述目标所述目标对象的位置信息写入所述容器服务器的删除日志之后发送的。The receiving module is further configured to receive a deletion response message sent by the container server, where the deletion response message is used by the container service to delete location information of the target object in the object list, and the target location The location information of the target object is sent after being written to the delete log of the container server.
  25. 一种容器服务器,其特征在于,包括处理器和与所述处理器耦合连接的存储器;A container server, comprising: a processor and a memory coupled to the processor;
    所述存储器用于存储计算机指令,当所述容器服务器运行时,所述处理器执行所述存储器存储的所述计算机指令,以使得所述容器服务器执行如权利要求1至7任意一项所述的数据处理方法。The memory is for storing computer instructions that, when the container server is running, execute the computer instructions stored by the memory to cause the container server to perform the method of any one of claims 1 to Data processing method.
  26. 一种对象服务器,其特征在于,包括处理器和与所述处理器耦合连接的存储器;An object server, comprising: a processor and a memory coupled to the processor;
    所述存储器用于存储计算机指令,当所述对象服务器运行时,所述处理器执行所述存储器存储的所述计算机指令,以使得所述对象服务器执行如权利要求8至10任意一项所述的数据处理方法。The memory is configured to store computer instructions that, when the object server is running, execute the computer instructions stored by the memory to cause the object server to perform the method of any one of claims 8 to 10. Data processing method.
  27. 一种代理服务器,其特征在于,包括处理器和与所述处理器耦合连接的存储器;A proxy server, comprising: a processor and a memory coupled to the processor;
    所述存储器用于存储计算机指令,当所述代理服务器运行时,所述处理器执行所述存储器存储的所述计算机指令,以使得所述代理服务器执行如权利要求11或12所述的数据处理方法。The memory is configured to store computer instructions that, when the proxy server is running, execute the computer instructions stored by the memory to cause the proxy server to perform data processing as claimed in claim 11 or method.
  28. 一种计算机可读存储介质,其特征在于,包括计算机指令,当所述计算 机指令在容器服务器上运行时,使得所述容器服务器执行如权利要求1至7任意一项所述的数据处理方法。A computer readable storage medium, comprising computer instructions that, when executed on a container server, cause the container server to perform the data processing method of any one of claims 1 to 7.
  29. 一种计算机可读存储介质,其特征在于,包括计算机指令,当所述计算机指令在对象服务器上运行时,使得所述对象服务器执行如权利要求8至10任意一项所述的数据处理方法。A computer readable storage medium comprising computer instructions that, when executed on an object server, cause the object server to perform the data processing method of any one of claims 8 to 10.
  30. 一种计算机可读存储介质,其特征在于,包括计算机指令,当所述计算机指令在代理服务器上运行时,使得所述代理服务器执行如权利要求11或12所述的数据处理方法。A computer readable storage medium, comprising computer instructions that, when executed on a proxy server, cause the proxy server to perform the data processing method of claim 11 or 12.
  31. 一种对象存储系统,其特征在于,包括如权利要求13至19任意一项或者权利要求25所述的容器服务器,如权利要求20至22任意一项或者权利要求26所述的对象服务器,以及如权利要求23或24或者权利要求27所述的代理服务器。An object storage system, comprising: the container server according to any one of claims 13 to 19 or claim 25, the object server according to any one of claims 20 to 22 or claim 26, A proxy server as claimed in claim 23 or 24 or claim 27.
PCT/CN2018/105965 2017-09-27 2018-09-17 Data processing method, device and system WO2019062572A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201710890580.X 2017-09-27
CN201710890580.XA CN107786638B (en) 2017-09-27 2017-09-27 Data processing method, device and system

Publications (1)

Publication Number Publication Date
WO2019062572A1 true WO2019062572A1 (en) 2019-04-04

Family

ID=61434093

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/105965 WO2019062572A1 (en) 2017-09-27 2018-09-17 Data processing method, device and system

Country Status (2)

Country Link
CN (1) CN107786638B (en)
WO (1) WO2019062572A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112948694A (en) * 2021-03-31 2021-06-11 北京奇艺世纪科技有限公司 Data processing method and device, electronic equipment and readable storage medium
CN113342274A (en) * 2021-06-10 2021-09-03 北京字节跳动网络技术有限公司 Data processing method and device

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107786638B (en) * 2017-09-27 2020-04-14 华为技术有限公司 Data processing method, device and system
CN108628664A (en) * 2018-05-11 2018-10-09 北京辰森世纪科技股份有限公司 A kind of method and device of container processing
CN109088913B (en) * 2018-06-29 2021-05-11 华为技术有限公司 Method for requesting data and load balancing server
CN110896408B (en) * 2018-09-13 2021-08-13 华为技术有限公司 Data processing method and server cluster
CN110543325A (en) * 2019-08-15 2019-12-06 中国银行股份有限公司 data processing method and device
CN113950145B (en) * 2021-12-20 2022-03-08 支付宝(杭州)信息技术有限公司 Data processing method and device
CN117194298A (en) * 2023-09-18 2023-12-08 上海鸿翼软件技术股份有限公司 Control method, device, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130013780A1 (en) * 2007-09-03 2013-01-10 Sony Corporation Content receiving device and method
CN105100149A (en) * 2014-05-13 2015-11-25 中国电信股份有限公司 Method and system for file management
CN105338113A (en) * 2015-11-25 2016-02-17 北京航空航天大学 Multi-platform data interconnected system for sharing urban data resources
CN105677250A (en) * 2016-01-04 2016-06-15 北京百度网讯科技有限公司 Method and device for updating object data in object storage system
CN107105050A (en) * 2017-05-11 2017-08-29 北京奇艺世纪科技有限公司 A kind of storage of business object, method for down loading and system
CN107786638A (en) * 2017-09-27 2018-03-09 华为技术有限公司 A kind of data processing method, apparatus and system

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP3327606A1 (en) * 2012-10-19 2018-05-30 McAfee, LLC Data loss prevention for mobile computing devices
US9419953B2 (en) * 2012-12-23 2016-08-16 Mcafee, Inc. Trusted container
EP3304285A1 (en) * 2015-06-03 2018-04-11 Telefonaktiebolaget LM Ericsson (publ) Implanted agent within a first service container for enabling a reverse proxy on a second container

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130013780A1 (en) * 2007-09-03 2013-01-10 Sony Corporation Content receiving device and method
CN105100149A (en) * 2014-05-13 2015-11-25 中国电信股份有限公司 Method and system for file management
CN105338113A (en) * 2015-11-25 2016-02-17 北京航空航天大学 Multi-platform data interconnected system for sharing urban data resources
CN105677250A (en) * 2016-01-04 2016-06-15 北京百度网讯科技有限公司 Method and device for updating object data in object storage system
CN107105050A (en) * 2017-05-11 2017-08-29 北京奇艺世纪科技有限公司 A kind of storage of business object, method for down loading and system
CN107786638A (en) * 2017-09-27 2018-03-09 华为技术有限公司 A kind of data processing method, apparatus and system

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112948694A (en) * 2021-03-31 2021-06-11 北京奇艺世纪科技有限公司 Data processing method and device, electronic equipment and readable storage medium
CN112948694B (en) * 2021-03-31 2023-06-27 北京奇艺世纪科技有限公司 Data processing method, device, electronic equipment and readable storage medium
CN113342274A (en) * 2021-06-10 2021-09-03 北京字节跳动网络技术有限公司 Data processing method and device
CN113342274B (en) * 2021-06-10 2024-01-30 北京火山引擎科技有限公司 Data processing method and device

Also Published As

Publication number Publication date
CN107786638B (en) 2020-04-14
CN107786638A (en) 2018-03-09

Similar Documents

Publication Publication Date Title
WO2019062572A1 (en) Data processing method, device and system
US9792306B1 (en) Data transfer between dissimilar deduplication systems
US8650159B1 (en) Systems and methods for managing data in cloud storage using deduplication techniques
US10303363B2 (en) System and method for data storage using log-structured merge trees
US20170206353A1 (en) Method and system for preventing malicious alteration of data in computer system
US10715622B2 (en) Systems and methods for accelerating object stores with distributed caching
US10983867B1 (en) Fingerprint change during data operations
US20120072763A1 (en) System and method of file locking in a network file system federated namespace
CN105205082A (en) Method and system for processing file storage in HDFS
CN108415986B (en) Data processing method, device, system, medium and computing equipment
US10901643B2 (en) Using log objects in object storage for durability of file objects in volatile memory
US8392437B2 (en) Method and system for providing deduplication information to applications
US11392545B1 (en) Tracking access pattern of inodes and pre-fetching inodes
US20180364915A1 (en) Method and system for distributed storage using client-side global persistent cache
US11455117B2 (en) Data reading method, apparatus, and system, avoiding version rollback issues in distributed system
CN113568566A (en) Method, host device and storage server for seamless migration of simple storage service by using index object
JP2020506444A (en) Expired backup processing method and backup server
CN113900972A (en) Data transmission method, chip and equipment
US11550913B2 (en) System and method for performing an antivirus scan using file level deduplication
US10846301B1 (en) Container reclamation using probabilistic data structures
WO2018064319A9 (en) Tracking access pattern of inodes and pre-fetching inodes
US11562067B2 (en) System and method of inspecting archive slices for malware using empty sparse files
EP3964996A1 (en) Database access method and device
CN109542860B (en) Service data management method based on HDFS and terminal equipment
JP2018526740A (en) Data storage method and apparatus for mobile terminal

Legal Events

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

Ref document number: 18861027

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18861027

Country of ref document: EP

Kind code of ref document: A1