Some aspects of this disclosure may relate to “big data” processing systems, and more specifically, to efficient storage techniques that may be used in implementations of such systems.
Data parallel application frameworks for large scale applications, such as Hadoop, Storm, and Spark, process a large volume of data by partitioning the data among the nodes in a compute cluster. These frameworks expose a functional model to the application developer and manage state information of the partitions internally. By exposing a functional model, the system can account for node failures while executing an application by moving partitions to a live node.
General programming models may generally account for two very broad but interrelated categories: data structures and algorithms. Data structures represent the model used to store and retrieve data, while algorithms represent the procedures that operate on data. In each of the previously-mentioned frameworks, the programming model exposes a rich interface for developing algorithms, but a very limited interface for exposing data structures.
Hadoop, for example, allows any general algorithm that operates on a key value pair, called a “map,” or on a key and a list of values, called a “reduce.” The implicit data structure in this model is commonly referred to as a “multimap.” Spark limits the capabilities to transformations that take a list of key-value pairs and produce another list of key value pairs. Storm has no data storage capabilities at all.
What is lacking in each of these models is a general data structure, or set of data structures, that may be used for operations like random access, array lookup, list iteration, search, etc., but may expose an interface that hides partition state information so that the system can manage failures.
Various aspects of the present application may include a shared-memory key/value pair data structure and storage system, referred to herein as “Key-Value Store (KVS)” and a method that may enable a KVS to be shared and parallel-processed efficiently and reliably in a large distributed processing environment.
A KVS or a system including a KVS, along with KVS-oriented methods, may be implemented in hardware and/or software and/or firmware. In a software embodiment, executable instructions may be contained on a machine-readable storage medium, such as, but not limited to, read-only memory (ROM), random-access memory (RAM), flash memory, magnetic or optical-based memory, etc.
Various aspects of this disclosure will now be presented in detail, in conjunction with the attached drawings, in which:
To put various aspects of this disclosure into perspective, consider, for example, a naïve implementation of the Pagerank algorithm, e.g., as shown in
Next, an iteration phase may be executed. In the example shown in
A KVS is a type of data structure that may exist across multiple compute nodes, but may be treated as a single data structure.
Read and write access to the KVS may be based on key/value pairs, where the key represents an index, and the value represents an object to store or retrieve. Each KVS may fall under one of three categories:
Within these three categories there are several KVSs that may be implemented. Examples include, but are not limited to, hash tables, distributed arrays, multimap, and trees.
The concept of KVSs may be used in combination with flowlet-based processing, described in U.S. patent application Ser. No. 14/054,112, filed on Oct. 15, 2013, published as U.S. Patent Application Publication No. 2014/0108489, and incorporated by reference herein. Flowlets are data flow actors. Flowlets and KVSs may be connected in a directed graph, which may be a directed acyclic graph. Connections may indicate whether a particular flowlet can read from or read from and write to a KVS. Based on this graph, dependencies can be inferred, and barriers can be implicitly defined. These implicit barriers may allow the developer to access the KVSs from within the flowlet code without concern for the typical problems associated with parallel access to data structures.
The KVS may also supports reliability across nodes by use of a buddy system, as shown in
KVSs may generally have a limited amount of system memory allocated to them. If the KVS grows too large, the system may have several options for decreasing the memory utilization. Each option may trade memory usage for delay. In order of least delay/most memory usage first:
In each of these cases, the system may optimize access to the KVS by grouping access into large bins. A portion of the KVS can be read from disk, decompressed, and deserialized. This portion of the KVS may then be operated on by the system. Then this portion may be serialized, compressed, and written back to disk. Then, the next portion of the KVS may be operated on in the same manner.
Each KVS may also support versioning of its contents. Versioning of a KVS may be useful for cases where different parts of the system may operate on the KVS in different states. Parts of the system that are later in the computation might access a newer version of the KVS. This may be especially useful, for example, in algorithms that iterate over the data structure and where each iteration can overlap, that is, the second iteration may be executing in parallel with the first, etc.
Various embodiments of the invention have been presented above. However, the invention is not intended to be limited to the specific embodiments presented, which have been presented for purposes of illustration. Rather, the invention extends to functional equivalents as would be within the scope of the appended claims. Those skilled in the art, having the benefit of the teachings of this specification, may make numerous modifications without departing from the scope and spirit of the invention in its various aspects.
This application is a non-provisional application claiming priority to U.S. Provisional Patent Application No. 62/147,384, filed on Apr. 14, 2015, and incorporated herein by reference.
Number | Name | Date | Kind |
---|---|---|---|
9497039 | Greenberg | Nov 2016 | B2 |
9633051 | Maccanti | Apr 2017 | B1 |
20080270350 | Bojanic | Oct 2008 | A1 |
20080270424 | Lee | Oct 2008 | A1 |
20130103729 | Cooney | Apr 2013 | A1 |
20130138646 | Sirer | May 2013 | A1 |
20130226955 | Fang | Aug 2013 | A1 |
20130275656 | Talagala | Oct 2013 | A1 |
20140108489 | Glines et al. | Apr 2014 | A1 |
20140149355 | Gupta | May 2014 | A1 |
20150149870 | Kozat | May 2015 | A1 |
Number | Date | Country |
---|---|---|
103166785 | Jun 2013 | CN |
104156380 | Nov 2014 | CN |
Entry |
---|
Hamr, “K-Cliques,” published on Nov. 10, 2014 at http://www.hamrtech.com/assets/downloads/K-Cliques.pdf, pp. 1-4. |
Int'l Search Report and Written Opinion dated Jul. 19, 2016 in Int'l Application No. PCT/CN2016/07912. |
Number | Date | Country | |
---|---|---|---|
20160306817 A1 | Oct 2016 | US |
Number | Date | Country | |
---|---|---|---|
62147384 | Apr 2015 | US |