Method and system for storing data items to a storage device
First Claim
1. In a computer system, a method for storing data generated by a data source to a hardware device by a data writer operating in a separate thread than a data collector, the method comprising the steps of:
- the data source generating a plurality of data items to be stored to the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are generated in an order other than one corresponding to the ordering for the contiguous area;
the data collector accumulating and producing an ordered set of data items according to their position to be stored on the hardware device and consolidating at least two data items that are to be written to contiguous portions of the hardware device into a larger data item within the set; and
the data writer acquiring the ordered set of data items from the data collector and storing the set of data items to the hardware device, and wherein the data source and the data collector are in the same execution thread.
2 Assignments
0 Petitions
Accused Products
Abstract
A system and method for efficiently storing data items to a storage device, such as hard disk, uses a data collector and a data writer running in different threads. A data source produces a stream of write requests to write data items to the storage device. The write requests are passed to the data collector, which accumulates, orders, and consolidates the write requests in a data structure. The data writer handles the operation of writing data to the storage device. The ordered and consolidated data items are then given to the data writer, which writes them to the storage device.
-
Citations
69 Claims
-
1. In a computer system, a method for storing data generated by a data source to a hardware device by a data writer operating in a separate thread than a data collector, the method comprising the steps of:
- the data source generating a plurality of data items to be stored to the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are generated in an order other than one corresponding to the ordering for the contiguous area;
the data collector accumulating and producing an ordered set of data items according to their position to be stored on the hardware device and consolidating at least two data items that are to be written to contiguous portions of the hardware device into a larger data item within the set; and
the data writer acquiring the ordered set of data items from the data collector and storing the set of data items to the hardware device, and wherein the data source and the data collector are in the same execution thread. - View Dependent Claims (2, 3, 4, 5, 6, 7)
- the data source generating a plurality of data items to be stored to the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are generated in an order other than one corresponding to the ordering for the contiguous area;
-
8. In a computer system, a method for storing data produced by a data source to a hardware device using a data writer operating in a separate thread than a data collector, the method comprising the steps of:
- the data source producing a plurality of data items to be stored on the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are produced in an order other than one corresponding to the ordering for the contiguous area;
the data source producing an additional data item to be stored on the hardware device;
the data collector adding the additional data item to a collector data structure of items or consolidating the item with an another item in the data structure if the additional item and the another item are to be written to contiguous portions of storage space in the hardware device;
the data writer copying the data items from the collector data structure into a writer data structure when the data writer has no previously copied items remaining to be stored to the hardware device; and
the data writer storing the data items in the writer data structure to the hardware device, and wherein the data source and the data collector are in the same execution thread. - View Dependent Claims (9, 10, 11, 12, 13)
- the data source producing a plurality of data items to be stored on the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are produced in an order other than one corresponding to the ordering for the contiguous area;
-
14. In a computer system, a method for storing data produced by a data source to a hardware device using a data writer operating in a separate thread than a data collector, the method comprising the steps of:
- the data source producing a plurality of data items to be stored on the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are produced in an order other than one corresponding to the ordering for the contiguous area;
the data collector acquiring a first data structure;
the data collector adding one of the data items to the first data structure or consolidating the item with another item in the first data structure if the item and the another item are to be written to contiguous portions of storage space in the hardware device;
the data writer acquiring the first data structure containing one or more items when there are no more data items in a second data structure remaining to be stored to the hardware device;
the data writer storing the one or more items in the first data structure to the hardware device;
the data collector acquiring the second data structure;
the data collector adding a second item to the second data structure or consolidating the second item with a second another item in the second data structure if the second item and the second another item are to be written to contiguous portions of storage space in the hardware device;
the data writer acquiring the second data structure containing one or more second items when the hardware device is available for writing and there are no more items in the first data structure remaining to be stored to the hardware device; and
the data writer storing the one or more second items in the second data structure to the hardware device, and wherein the data source and the data collector are in the same execution thread. - View Dependent Claims (15, 16, 17, 18, 19)
- the data source producing a plurality of data items to be stored on the hardware device wherein at least a portion of the data items produced are to be stored contiguously on an area of the hardware device and are produced in an order other than one corresponding to the ordering for the contiguous area;
-
20. In a computer system, a method for storing a plurality of data items received from a data source on a hardware device at discrete locations using a data writer and a data collector operating in separate threads, the method comprising the steps of:
- the data collector receiving and adding one of the plurality of data items to a data structure of items;
the data collector or the data writer consolidating one or more of the data items stored in the data structure of items into a new data item;
the data writer acquiring one or more items currently in the data structure when the data writer has no previously acquired items remaining to be stored to the hardware device; and
the data writer storing the one or more items to the hardware device and wherein the data source and the collector are in the same execution thread. - View Dependent Claims (21, 22, 23, 24, 25)
- the data collector receiving and adding one of the plurality of data items to a data structure of items;
-
26. In a computer system, a method for efficiently flushing portions of a memory-mapped file to a hardware device, the memory-mapped file comprising a portion of memory within the computer system and a portion of a storage area of the hardware device, the method comprising the steps of:
- a data collector receiving from a data source a plurality of write requests;
the data collector adding the plurality of write requests to a data structure and consolidating two or more data items in the data structure if the two or more data items are to be written to contiguous portions of storage space in the hardware device;
a data writer acquiring one or more write requests currently in the data structure when the data writer has no previously acquired items remaining to be stored to the hardware device; and
the data writer storing the one or more items to the hardware device, and wherein the data source and the data collector are in the same execution thread. - View Dependent Claims (27, 28, 29, 30, 31, 32, 33, 34, 35)
- a data collector receiving from a data source a plurality of write requests;
-
36. In a message queuing computer system, a method for maintaining a plurality of messages within a message queue comprising a memory-mapped file and using a data collector and a data writer operating in separate threads, the memory-mapped file including a portion of memory within the computer system and a portion of a storage area of a hardware device, the method comprising the steps of:
- a message queuing server receiving a plurality of messages, storing the plurality of messages within the portion of memory, and generating a plurality of write requests to flush memory locations corresponding to the stored messages;
the data collector receiving the plurality of write requests, each write request including a memory location;
the data collector processing each one of the plurality of write requests and either adding the one write request to a data structure or consolidating the one write request with another write request in the data structure;
the data writer acquiring one or more write requests currently in the data structure when the data writer has no previously acquired write requests remaining to be stored to the hardware device; and
the data writer storing a data value corresponding to the one or more write requests to the hardware device wherein the message queuing server and the data collector are in the same execution thread. - View Dependent Claims (37, 38, 39, 40, 41, 42, 43, 44)
- a message queuing server receiving a plurality of messages, storing the plurality of messages within the portion of memory, and generating a plurality of write requests to flush memory locations corresponding to the stored messages;
-
45. A computer-readable medium having computer-executable instructions for performing steps for storing a plurality of data items received from a data source on a hardware device at discrete locations using a data writer and a data collector operating in separate threads, the steps comprising:
- the data collector receiving and adding one of the plurality of data items to a data structure of items;
the data collector or the data writer consolidating one or more of the data items stored in the data structure of items into a new data item;
the data writer acquiring one or more items currently in the data structure when the data writer has no previously acquired items remaining to be stored to the hardware device; and
the data writer storing the one or more items to the hardware device, wherein the data source and the data collector are in the same execution thread. - View Dependent Claims (46, 47, 48, 49, 50)
- the data collector receiving and adding one of the plurality of data items to a data structure of items;
-
51. A computer-readable medium having computer-executable instructions for performing steps for efficiently flushing portions of a memory-mapped file to a hardware device, the memory-mapped file comprising a portion of memory within a computer system and a portion of a storage area of the hardware device, the steps comprising:
- a data collector receiving from a data source a plurality of write requests;
the data collector adding the plurality of write requests to a data structure and consolidating two or more data items in the data structure if the two or more data items are to be written to contiguous portions of storage space in the hardware device;
a data writer acquiring one or more write requests currently in the data structure when the data writer has no previously acquired items remaining to be stored to the hardware device; and
the data writer storing the one or more items to the hardware device, wherein the data source and the data collector are in the same execution thread. - View Dependent Claims (52, 53, 54, 55, 56, 57, 58, 59, 60)
- a data collector receiving from a data source a plurality of write requests;
-
61. A computer-readable medium having computer-executable instructions for performing steps for maintaining a plurality of messages within a message queuing computer system in a message queue comprising a memory-mapped file and using a data collector and a data writer operating in separate threads, the memory-mapped file including a portion of memory within the computer system and a portion of the storage area of a hardware device, the steps comprising:
- a message queuing server receiving a plurality of messages, storing the plurality of messages within the portion of memory, and generating a plurality of write requests to flush memory locations corresponding to the stored messages;
the data collector receiving the plurality of write requests, each write request including a memory location;
the data collector processing each one of the plurality of write requests and either adding the one write request to a data structure or consolidating the one write request with another write request in the data structure;
the data writer acquiring one or more write requests currently in the data structure when the data writer has no previously acquired write requests remaining to be stored to the hardware device; and
the data writer storing a data value corresponding to the one or more write requests to the hardware device wherein the message queuing server and the data collector are in the same execution thread. - View Dependent Claims (62, 63, 64, 65, 66, 67, 68, 69)
- a message queuing server receiving a plurality of messages, storing the plurality of messages within the portion of memory, and generating a plurality of write requests to flush memory locations corresponding to the stored messages;
Specification