Method and device for writing data and acquiring data in a distributed storage system
Abstract:
The present application provides methods and devices for writing data and acquiring data in a distributed storage system. According to an exemplary method, in a process of writing data, a data file is not overwritten but is instead updated by making a copy in a newly allocated storage block and an updated description file is persisted by using an atomic operation. This way, in a process of appending data, it can be ensured that a data file is not damaged, and the readability and consistency of data are maintained, facilitating the use by a user. Further, writing data according to some embodiments of the present application supports a write in which a user specifies a write position of to-be-written data, and also supports a write in which the user does not specify a write position of to-be-written data, thereby improving the flexibility of writing data.
Information query
Patent Agency Ranking
0/0