JP2018159987A - Data node management apparatus, storage system, data node management method and program - Google Patents

Data node management apparatus, storage system, data node management method and program Download PDF

Info

Publication number
JP2018159987A
JP2018159987A JP2017055492A JP2017055492A JP2018159987A JP 2018159987 A JP2018159987 A JP 2018159987A JP 2017055492 A JP2017055492 A JP 2017055492A JP 2017055492 A JP2017055492 A JP 2017055492A JP 2018159987 A JP2018159987 A JP 2018159987A
Authority
JP
Japan
Prior art keywords
data
pair
child
pair data
node
Prior art date
Legal status (The legal status 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 status listed.)
Pending
Application number
JP2017055492A
Other languages
Japanese (ja)
Inventor
昇平 湯村
Shohei Yumura
昇平 湯村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP2017055492A priority Critical patent/JP2018159987A/en
Publication of JP2018159987A publication Critical patent/JP2018159987A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

PROBLEM TO BE SOLVED: To suppress unbalance of data amount and distribute load without rearranging a partition even when a data size of KV pair is unbalanced.SOLUTION: A data node management apparatus 10 includes: an instruction reception unit 11 that receives an instruction to a data node 20; a pair data conversion processing unit 12 that adds a subscript to a key value of target pair data when the instruction is a writing instruction; a pair data division unit 13 that divides data included in pair data being parent pair data by a set number, generates child pair data with each of the divided data and the key value of the parent pair data, and writes the subscription of the key value of each of the child pair data into an identification number; a data node access unit 14 that stores the child pair data in the order of the identification number in the data node 20; and a data combination unit 15 that acquires the child pair data on the basis of a list when the instruction is a reading instruction and combines them.SELECTED DRAWING: Figure 1

Description

本発明は、データノードで構成されたストレージシステム、データノードの管理を行なう、データノード管理装置、及びデータノード管理方法に関し、更には、これらを実現するためのプログラムに関する。   The present invention relates to a storage system composed of data nodes, a data node management apparatus and a data node management method for managing the data nodes, and further to a program for realizing them.

KVSは、保存対象となるデータ(Value)に対して、対応する一意の標識(Key)を設定し、これらをペア(KVペア)で保存するデータストアである。また、KVSのうち、特に、複数のサーバ装置又は記憶装置に分散してデータを保存できる機能をもったものは、「分散KVS」と呼ばれている。   KVS is a data store that sets a corresponding unique indicator (Key) for data (Value) to be stored, and stores them as a pair (KV pair). Further, among KVS, in particular, one having a function capable of storing data in a distributed manner in a plurality of server devices or storage devices is called “distributed KVS”.

分散KVSは、近年、極めて大量のデータを保管する分野において注目されている。例えば、Voldemort(非特許文献1参照)は、分散KVSが実装されたシステムのひとつである。一般に、分散KVSは、スケーラビリティに優れており、ノードの数だけ膨大なデータを格納することが可能となる。   Distributed KVS has recently attracted attention in the field of storing extremely large amounts of data. For example, Voldemort (see Non-Patent Document 1) is one of systems in which distributed KVS is implemented. In general, the distributed KVS is excellent in scalability and can store a huge amount of data as many as the number of nodes.

また、分散KVSでは、キー値を基にハッシュ関数によって算出されたハッシュ値によって、格納先のノードが決定される。特に、Consistent Hashing(例えば、特許文献1参照)は、分散KVSシステムにおいて、データの格納先を決めるための手法として、利用されている。Consistent Hashingでは、ハッシュ空間は、均等なQ個のパーティションに分割される。また、Q/N個のパーティションが、各ノードに割り当てられる。Nは全体ノードの数である。   In the distributed KVS, the storage destination node is determined based on the hash value calculated by the hash function based on the key value. In particular, consistent hashing (see, for example, Patent Document 1) is used as a method for determining a data storage destination in a distributed KVS system. In Consistent Hashing, the hash space is divided into equal Q partitions. Further, Q / N partitions are allocated to each node. N is the number of all nodes.

但し、Valueのデータサイズに偏りがある論理データ構造の場合、ノード毎に格納しているデータ量が異なり、ノード間に偏りが生じてしまう。この結果、データサイズの大きなValueを持つキー値の格納先となっている特定のノードに、大きな負荷がかかってしまう。また、このようなノードにおいては、KVペアの取得時のTAT(Turn Around Time)が増加してしまう。   However, in the case of a logical data structure in which the data size of Value is biased, the amount of data stored differs from node to node, resulting in bias between nodes. As a result, a large load is applied to the specific node that stores the key value having Value having a large data size. In such a node, TAT (Turn Around Time) at the time of acquiring a KV pair increases.

特に、分散KVSをRDB(Relational Database)に適用する場合は、検索性を高めるために、特定の値及び属性によってレコードがまとめられるので、1つのKeyに複数のデータが格納される。このため、Valueが大きくなってしまうケースが多くなってしまう。   In particular, when distributed KVS is applied to an RDB (Relational Database), records are collected by specific values and attributes in order to improve searchability, so a plurality of data is stored in one key. For this reason, there are many cases where Value becomes large.

特開2011−95976号公報JP 2011-95976 A

“Project Voldemort”,[online],[平成29年3月1日検索],インターネット<URL:http://www.project-voldemort.com/>“Project Voldemort”, [online], [March 1, 2017 search], Internet <URL: http://www.project-voldemort.com/>

上述のノード間におけるデータ量の偏りを解消するための手法として、割り当てたパーティションを再配置して、各ノードのデータ量を均一にする手法が提案されている。しかしながら、パーティションの再配置に伴って、データの再配置も発生するため、既存ノード間のデータ移動が大量に起こる可能性がある。この結果、上記手法を実行する場合には、大きなコストがかかってしまう。   As a method for eliminating the above-described uneven data amount between nodes, a method has been proposed in which the allocated partitions are rearranged to make the data amount of each node uniform. However, since data rearrangement also occurs with partition rearrangement, a large amount of data movement between existing nodes may occur. As a result, when the above method is executed, a large cost is required.

本発明の目的の一例は、KVペアのデータサイズに偏りがあっても、パーティションの再配置を行なうことなく、データ量の偏りの抑制と負荷の分散化とを図り得る、ストレージシステム、データノード管理装置、データノード管理方法、及びプログラムを提供することにある。   An example of an object of the present invention is to provide a storage system and a data node capable of suppressing the uneven data amount and distributing the load without performing the rearrangement of partitions even when the data size of the KV pair is uneven. A management device, a data node management method, and a program are provided.

上記目的を達成するため、本発明の一側面におけるデータノード管理装置は、
データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、指示受付部と、
受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ペアデータ変換処理部と、
書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ペアデータ分割部と、
分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかの前記データノードに格納する、データノードアクセス部と、
受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、データ結合部と、
を備えている、ことを特徴とする。
In order to achieve the above object, a data node management device according to one aspect of the present invention provides:
An instruction receiving unit that receives an instruction to a data node that stores data and a corresponding key value as pair data;
A pair data conversion processing unit that assigns a preset subscript to a key value in the pair data to be written when the received instruction is a write instruction;
The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and each divided data and the key value of the parent pair data are combined to generate child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number different for each child pair data, and further, a list of key values of each child pair data is added to the data of the parent pair data. A pair data dividing unit for storing
A data node access unit that stores child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of each child pair data;
When the received instruction is a read instruction, based on the list, obtain a child pair node of the pair data to be read, and combine the acquired child pair node;
It is characterized by having.

上記目的を達成するため、本発明の一側面におけるストレージシステムは、データとそれに対応するキー値とをペアデータとして格納するデータノードと、データノード管理装置とを備え、
前記データノード管理装置は、
前記データノードに対する命令を受け付ける、指示受付部と、
受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ペアデータ変換処理部と、
書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ペアデータ分割部と、
分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかの前記データノードに格納する、データノードアクセス部と、
受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、データ結合部と、
を備えていることを特徴とする。
To achieve the above object, a storage system according to an aspect of the present invention includes a data node that stores data and a corresponding key value as pair data, and a data node management device,
The data node management device includes:
An instruction receiving unit for receiving an instruction for the data node;
A pair data conversion processing unit that assigns a preset subscript to a key value in the pair data to be written when the received instruction is a write instruction;
The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and each divided data and the key value of the parent pair data are combined to generate child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number different for each child pair data, and further, a list of key values of each child pair data is added to the data of the parent pair data. A pair data dividing unit for storing
A data node access unit that stores child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of each child pair data;
When the received instruction is a read instruction, based on the list, obtain a child pair node of the pair data to be read, and combine the acquired child pair node;
It is characterized by having.

また、上記目的を達成するため、本発明の一側面におけるデータノード管理方法は、
(a)データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、ステップと、
(b)受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ステップと、
(c)書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ステップと、
(d)分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかのデータノードに格納する、ステップと、
(e)受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、ステップと、
を有する、ことを特徴とする。
In order to achieve the above object, a data node management method according to one aspect of the present invention includes:
(A) receiving a command for a data node that stores data and a corresponding key value as pair data; and
(B) when the received command is a write command, a preset subscript is added to the key value in the pair data to be written; and
(C) The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and the divided paired data and the key value of the parent pair data are combined to obtain the child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number that differs for each child pair data, and further, the key of each child pair data is added to the data of the parent pair data. Storing a list of values, steps;
(D) storing the child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of the respective child pair data;
(E) when the received instruction is a read instruction, acquiring a child pair node of the pair data to be read based on the list, and combining the acquired child pair nodes;
It is characterized by having.

更に、上記目的を達成するため、本発明の一側面におけるプログラムは、
コンピュータに、
(a)データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、ステップと、
(b)受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ステップと、
(c)書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ステップと、
(d)分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかのデータノードに格納する、ステップと、
(e)受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、ステップと、
を有する、ことを特徴とする。
Furthermore, in order to achieve the above object, a program according to one aspect of the present invention is provided.
On the computer,
(A) receiving a command for a data node that stores data and a corresponding key value as pair data; and
(B) when the received command is a write command, a preset subscript is added to the key value in the pair data to be written; and
(C) The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and the divided paired data and the key value of the parent pair data are combined to obtain the child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number that differs for each child pair data, and further, the key of each child pair data is added to the data of the parent pair data. Storing a list of values, steps;
(D) storing the child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of the respective child pair data;
(E) when the received instruction is a read instruction, acquiring a child pair node of the pair data to be read based on the list, and combining the acquired child pair nodes;
It is characterized by having.

以上のように、本発明によれば、KVペアのデータサイズに偏りがあっても、パーティションの再配置を行なうことなく、データ量の偏りの抑制と負荷の分散化とを図ることができる。   As described above, according to the present invention, even if the data size of the KV pair is uneven, it is possible to suppress the uneven amount of data and to distribute the load without rearranging the partitions.

図1は、本発明の実施の形態におけるデータノード管理装置の概略構成を示すブロック図である。FIG. 1 is a block diagram showing a schematic configuration of a data node management apparatus according to an embodiment of the present invention. 図2は、本発明の実施の形態におけるデータノード管理装置の具体的構成を示すブロック図である。FIG. 2 is a block diagram showing a specific configuration of the data node management apparatus according to the embodiment of the present invention. 図3(a)〜(c)は、それぞれ、本実施の形態におけるペアデータに付加される添え字とフラグとの具体例を示す図である。FIGS. 3A to 3C are diagrams showing specific examples of subscripts and flags added to the pair data in the present embodiment, respectively. 図4は、ペアデータの分割を模式的に示す図である。FIG. 4 is a diagram schematically showing division of pair data. 図5は、本発明の実施の形態におけるデータノード管理装置の書き込み命令発行時の動作を示すフロー図である。FIG. 5 is a flowchart showing an operation when the data node management device according to the embodiment of the present invention issues a write command. 図6は、本発明の実施の形態における子KVペアの格納先の決定手法の一例を説明する説明図である。FIG. 6 is an explanatory diagram for explaining an example of a method for determining the storage destination of the child KV pair in the embodiment of the present invention. 図7は、本発明の実施の形態における子KVペアの格納先の決定手法の他の例を説明する説明図である。FIG. 7 is an explanatory diagram for explaining another example of the method for determining the storage destination of the child KV pair in the embodiment of the present invention. 図8は、本発明の実施の形態におけるデータノード管理装置の読み込み命令発行時の動作を示すフロー図である。FIG. 8 is a flowchart showing an operation when the read instruction is issued by the data node management device according to the embodiment of the present invention. 図9は、本発明の実施の形態におけるデータノードの他の例を示すブロック図である。FIG. 9 is a block diagram showing another example of the data node in the embodiment of the present invention. 図10は、本発明の実施の形態におけるデータノード管理装置10を実現するコンピュータの一例を示すブロック図である。FIG. 10 is a block diagram illustrating an example of a computer that implements the data node management apparatus 10 according to the embodiment of the present invention.

(本発明の概要)
本発明では、Valueサイズの大きなKVペアは、格納先となるKVSデータノードの数に応じて、自動的に複数のKVペアに分割されてから格納される。また、読み出し時においては、分割されたKVペアがすべて読み出され、読み出されたKVペアが結合された後、結合後のKVペアが返却される。
(Outline of the present invention)
In the present invention, a KV pair having a large value size is automatically divided into a plurality of KV pairs and stored in accordance with the number of KVS data nodes as storage destinations. Further, at the time of reading, all the divided KV pairs are read, and after the read KV pairs are combined, the combined KV pairs are returned.

更に、本発明では、分割後のKVペアは、格納される段階で、格納対象となるKVSデータノードの数に応じて、最大数で分割されるので、ノード間でのデータの偏りを未然に防ぐことが可能となる。また、分割後のKVペアに対して、並列に読み込み及び書き込みを実行することで、サイズの大きなKVペアの操作に伴うレイテンシも改善することができる。   Furthermore, in the present invention, the divided KV pairs are divided by the maximum number in accordance with the number of KVS data nodes to be stored at the stage of being stored, so that the bias of data between the nodes is obviated. It becomes possible to prevent. Further, by performing reading and writing in parallel on the divided KV pairs, it is possible to improve the latency associated with the operation of the large KV pair.

(実施の形態)
以下、本実施の形態における、データノード管理装置、ストレージシステム、データノード管理方法、及びプログラムについて、図1〜図10を参照しながら説明する。
(Embodiment)
Hereinafter, a data node management device, a storage system, a data node management method, and a program according to the present embodiment will be described with reference to FIGS.

[装置構成]
最初に、図1を用いて、本実施の形態におけるデータノード管理装置の構成について説明する。図1は、本発明の実施の形態におけるデータノード管理装置の概略構成を示すブロック図である。
[Device configuration]
First, the configuration of the data node management apparatus according to the present embodiment will be described with reference to FIG. FIG. 1 is a block diagram showing a schematic configuration of a data node management apparatus according to an embodiment of the present invention.

図1に示す本実施の形態におけるデータノード管理装置10は、データとそれに対応するキー値とをペアデータとして格納するデータノード20を管理するための装置である。データノード管理装置10は、各データノード20に、ネットワーク30を介して接続されており、データノード20と共に、ストレージシステム100を構築している。   A data node management device 10 in the present embodiment shown in FIG. 1 is a device for managing a data node 20 that stores data and key values corresponding to the data as pair data. The data node management apparatus 10 is connected to each data node 20 via a network 30 and constructs a storage system 100 together with the data node 20.

図1に示すように、データノード管理装置10は、指示受付部11と、ペアデータ変換処理部12と、ペアデータ分割部13と、データノードアクセス部14と、データ統合部15とを備えている。   As shown in FIG. 1, the data node management device 10 includes an instruction receiving unit 11, a pair data conversion processing unit 12, a pair data dividing unit 13, a data node access unit 14, and a data integration unit 15. Yes.

指示受付部11は、外部から、データノード20に対する命令、即ち、書き込み命令(put)又は読み込み命令(get)を受け付ける。   The instruction receiving unit 11 receives a command for the data node 20, that is, a write command (put) or a read command (get) from the outside.

ペアデータ変換処理部12は、受け付けられた命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する。   When the received command is a write command, the pair data conversion processing unit 12 gives a preset subscript to the key value in the pair data to be written.

ペアデータ分割部13は、まず、書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成する。また、ペアデータ分割部13は、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換える。更に、ペアデータ分割部13は、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する。   First, the pair data dividing unit 13 divides the data included in the parent pair data into a set number using the pair data to be written as the parent pair data, and combines the divided data and the key value of the parent pair data. To generate child pair data. Further, at this time, the pair data dividing unit 13 rewrites the subscript attached to the key value of each child pair data with a continuous identification number that is different for each child pair data. Further, the pair data dividing unit 13 stores a list of key values of each child pair data in the data of the parent pair data.

データノードアクセス部14は、分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている識別番号の順に、いずれかのデータノード20に格納する。   The data node access unit 14 stores the child pair data generated by the division in any of the data nodes 20 in the order of the identification numbers given to the key values of the respective child pair data.

データ結合部15は、受け付けられた命令が読み込み命令である場合に、親ペアデータが格納しているリストに基づいて、読み込み対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する。   When the received instruction is a read instruction, the data combining unit 15 acquires a child pair node of the pair data to be read based on the list stored in the parent pair data, and combines the acquired child pair nodes To do.

このように、本実施の形態では、書き込み対象となるデータは、設定数、例えば、データノード20の数に応じて分割され、分割された子ノードは、キー値に付与された識別番号によって管理される。また、読み込みの際には、キー値に付与された識別番号を元に、各データノード20から子ペアデータが取得され、これらが結合される。このため、本実施の形態によれば、KVペアのデータサイズに偏りがあっても、パーティションの再配置を行なうことなくノード間のデータの偏りが抑制され、負荷が分散される。   Thus, in the present embodiment, the data to be written is divided according to the set number, for example, the number of data nodes 20, and the divided child nodes are managed by the identification number assigned to the key value. Is done. Further, at the time of reading, child pair data is acquired from each data node 20 based on the identification number given to the key value, and these are combined. For this reason, according to the present embodiment, even if the data size of the KV pair is uneven, the uneven data distribution between the nodes is suppressed without rearranging the partitions, and the load is distributed.

続いて、図2を用いて、本実施の形態におけるデータノード管理装置10の構成についてより具体的に説明する。図2は、本発明の実施の形態におけるデータノード管理装置の具体的構成を示すブロック図である。   Next, the configuration of the data node management device 10 in the present embodiment will be described more specifically with reference to FIG. FIG. 2 is a block diagram showing a specific configuration of the data node management apparatus according to the embodiment of the present invention.

図2に示すように、本実施の形態では、複数のデータノード20は、分散KVSシステムを構築している。本実施の形態におけるペアデータは、KVペアである。よって、以降の説明においては、ペアデータはKVペアとも表記する。また、これに合わせて、親ペアデータは、親KVペア、子ペアデータは子KVペアとも表記する。また、データノード20は、計算機であり、それが備えるストレージに、KVペアを格納している。   As shown in FIG. 2, in the present embodiment, a plurality of data nodes 20 constructs a distributed KVS system. The pair data in the present embodiment is a KV pair. Therefore, in the following description, the pair data is also expressed as a KV pair. In accordance with this, the parent pair data is also referred to as a parent KV pair, and the child pair data is also referred to as a child KV pair. Further, the data node 20 is a computer and stores a KV pair in a storage provided therein.

また、図2に示すように、本実施の形態では、データノード管理装置10には、クライアント端末40が接続されている。クライアント端末40は、ユーザの操作に応じて、データノード20に対して、書き込み命令(put)及び読み込み命令(get)を発行し、これをデータノード管理装置10に入力する。   Further, as shown in FIG. 2, in the present embodiment, a client terminal 40 is connected to the data node management device 10. The client terminal 40 issues a write command (put) and a read command (get) to the data node 20 in accordance with a user operation, and inputs them to the data node management device 10.

また、本実施の形態において、データノード20の数は特に限定されるものではない。更に、図2の例では、図示されているクライアント端末40は1つであるが、実際には、クライアント端末40の数も複数である。そして、一般的な分散KVSシステムでは、複数のデータノード20は、不特定多数のクライアント端末40と通信し、その要求に応じて処理を実行する。本実施の形態では、クライアント端末40とデータノード20との間に、データノード管理装置10が配置される。   In the present embodiment, the number of data nodes 20 is not particularly limited. Furthermore, in the example of FIG. 2, the number of client terminals 40 shown in the figure is one, but actually, the number of client terminals 40 is also plural. In a general distributed KVS system, the plurality of data nodes 20 communicate with an unspecified number of client terminals 40 and execute processing in response to the request. In the present embodiment, the data node management device 10 is arranged between the client terminal 40 and the data node 20.

更に、本実施の形態においては、1つの分散KVSシステムにおいて、データノード管理装置10は、複数存在していても良い。加えて、一つのデータノード管理装置10が、複数のクライアント端末40からの命令を並列に受け付けることもできる。   Furthermore, in this embodiment, a plurality of data node management devices 10 may exist in one distributed KVS system. In addition, one data node management apparatus 10 can receive commands from a plurality of client terminals 40 in parallel.

また、図2に示すように、本実施の形態では、データノード管理装置10は、上述した指示受付部11、ペアデータ変換処理部12、ペアデータ分割部13、データノードアクセス部14、及びデータ統合部15に加えて、タイムスタンプ判定部16も備えている。   As shown in FIG. 2, in the present embodiment, the data node management device 10 includes the above-described instruction receiving unit 11, pair data conversion processing unit 12, pair data dividing unit 13, data node access unit 14, and data In addition to the integration unit 15, a time stamp determination unit 16 is also provided.

指示受付部11は、本実施の形態では、クライアント端末40から、データノード20に対する、書き込み命令(put)及び読み込み命令(get)を受け付ける。また、指示受付部11は、受け付けた命令に対する結果を、クライアント端末40に返却する。   In this embodiment, the instruction receiving unit 11 receives a write command (put) and a read command (get) for the data node 20 from the client terminal 40. In addition, the instruction receiving unit 11 returns the result for the received command to the client terminal 40.

ペアデータ変換処理部12は、本実施の形態では、指示受付部11で書き込み命令が受け付けられると書き込み対象となるKVペアにおいて、そのデータに、分割の有無及び状態を示すフラグを付与する。また、ペアデータ変換処理部12は、分割後の子KVペアのデータノード20への格納が終了すると、親KVペアのフラグを「分割あり」に設定する。   In this embodiment, when the instruction receiving unit 11 receives a write command, the pair data conversion processing unit 12 gives a flag indicating the presence / absence of division and a state to the data in the KV pair to be written. When the storage of the divided child KV pair in the data node 20 is completed, the pair data conversion processing unit 12 sets the flag of the parent KV pair to “with division”.

データノードアクセス部14は、本実施の形態では、各子KVペアをデータノード20に格納する場合は、各データノードに対して、書き込み命令(put)を発行する。また、データノードアクセス部14は、各データノード20から、各子KVペアを取得する場合は、各データノード20に対して、読み込み命令(get)を発行する。   In this embodiment, when storing each child KV pair in the data node 20, the data node access unit 14 issues a write command (put) to each data node. Further, when acquiring each child KV pair from each data node 20, the data node access unit 14 issues a read command (get) to each data node 20.

タイムスタンプ判定部16は、まず、指示受付部11で書き込み命令が受け付けられると、書き込み対象となるKVペアのデータに、データノード管理装置10の識別子とタイムスタンプとを付与する。具体的には、タイムスタンプ判定部16は、図3に示した分割フラグ:L(ロック中)のKVペアが生成される際に、識別子とタイムスタンプとを付与する。   First, when the instruction receiving unit 11 receives a write command, the time stamp determination unit 16 adds the identifier and time stamp of the data node management device 10 to the data of the KV pair to be written. Specifically, the time stamp determination unit 16 assigns an identifier and a time stamp when the split flag: L (locked) KV pair shown in FIG. 3 is generated.

また、タイムスタンプ判定部16は、子KVペアのデータノード20への格納が終了した場合は、親KVペアのデータに付与されている、識別子とタイムスタンプとを取得する。そして、タイムスタンプ判定部16は、取得した識別子とタイムスタンプとが、自身を備えているデータノード管理装置10によって付与されたものかどうかを判定する。判定の結果、付与されたものでない場合は、タイムスタンプ判定部16は、書き込み命令はタイムアウトしているとする。   In addition, when the storage of the child KV pair in the data node 20 is completed, the time stamp determination unit 16 acquires the identifier and the time stamp given to the data of the parent KV pair. Then, the time stamp determination unit 16 determines whether or not the acquired identifier and time stamp are given by the data node management apparatus 10 provided with the time stamp determination unit 16. As a result of the determination, if not given, the time stamp determination unit 16 assumes that the write command has timed out.

ここで、図3及び図4を用いて、ペアデータ変換処理部12、ペアデータ分割部13、及びデータ結合部15の処理について具体的に説明する。図3(a)〜(c)は、それぞれ、本実施の形態におけるペアデータに付加される添え字とフラグとの具体例を示す図である。図4は、ペアデータの分割を模式的に示す図である。   Here, the processing of the pair data conversion processing unit 12, the pair data dividing unit 13, and the data combining unit 15 will be specifically described with reference to FIGS. FIGS. 3A to 3C are diagrams showing specific examples of subscripts and flags added to the pair data in the present embodiment, respectively. FIG. 4 is a diagram schematically showing division of pair data.

本実施の形態では、ペアデータ変換処理部12は、KVペアにおけるキー値とValue部のデータとを、図3(a)〜(c)のいずれかに示す形式に書き換える。   In the present embodiment, the pair data conversion processing unit 12 rewrites the key value in the KV pair and the data in the Value portion into the format shown in any of FIGS.

具体的には、ペアデータ変換処理部12は、キー値に、添え字として、「−0000」〜「−9999」の形式の4ケタの数字(識別番号)を付与する。また、本実施の形態では、添え字が「−0000」であるものは「親KVペア」とされる。更に、添え字が「−0001」以降のものは「子KVペア」とされ、分割されたKVペアであることが表される。また、ペアデータ変換処理部12は、データが格納されているValue部の先頭に、「flag:N」、「flag:D」、「flag:L」といった形式で分割フラグを付与する。   Specifically, the pair data conversion processing unit 12 assigns a 4-digit number (identification number) in the form of “−0000” to “−9999” as a subscript to the key value. Further, in the present embodiment, those with the subscript “−0000” are regarded as “parent KV pairs”. Further, the subscripts after “−0001” are “child KV pairs”, which indicate that they are divided KV pairs. In addition, the pair data conversion processing unit 12 assigns a division flag in the form of “flag: N”, “flag: D”, and “flag: L” to the head of the Value unit in which data is stored.

また、ペアデータ変換処理部12は、読み込み命令(get)の結果を、クライアント端末40に返却する時は、キー値の4ケタの添え字「−0000」と、Value部の分割フラグとを取り除いた元の形式で、KVペアを返却する。   Further, when returning the result of the read command (get) to the client terminal 40, the pair data conversion processing unit 12 removes the 4-digit subscript “−0000” of the key value and the division flag of the Value portion. Return the KV pair in the original format.

また、本実施の形態では、ペアデータ分割部13は、図4に示すように、元のKVペアを複数の子KVペアに分割し、更に、親KVペアを生成する。また、このとき、ペアデータ分割部13は、元のKVペアのValue部のデータを設定された分割数に応じて分割し、子KVペアに格納する。   In the present embodiment, as shown in FIG. 4, the pair data dividing unit 13 divides the original KV pair into a plurality of child KV pairs, and further generates a parent KV pair. At this time, the pair data dividing unit 13 divides the data of the Value part of the original KV pair according to the set number of divisions and stores it in the child KV pair.

更に、本実施の形態では、データ結合部15は、親KVペアのValue部に格納されているキー値のリスト(図4参照)に基づいて、図4に示す形式に分割されたKVペアを取得し、これらのデータを結合する。   Furthermore, in the present embodiment, the data combining unit 15 selects the KV pair divided into the format shown in FIG. 4 based on the list of key values (see FIG. 4) stored in the Value part of the parent KV pair. Get and combine these data.

[装置動作]
次に、本発明の実施の形態におけるデータノード管理装置10の動作について図5〜図8を用いて説明する。以下の説明においては、適宜図1〜図4を参酌する。また、本実施の形態では、データノード管理装置10を動作させることによって、データノード管理方法が実施される。よって、本実施の形態におけるデータノード管理方法の説明は、以下のデータノード管理装置の動作説明に代える。
[Device operation]
Next, the operation of the data node management apparatus 10 according to the embodiment of the present invention will be described with reference to FIGS. In the following description, FIGS. In the present embodiment, the data node management method is implemented by operating the data node management apparatus 10. Therefore, the description of the data node management method in the present embodiment is replaced with the following description of the operation of the data node management device.

最初に、図5〜図7を用いて、クライアント端末40から書き込み命令が発行されて、データ格納処理が指示された場合について説明する。図5は、本発明の実施の形態におけるデータノード管理装置の書き込み命令発行時の動作を示すフロー図である。   First, a case where a write command is issued from the client terminal 40 and a data storage process is instructed will be described with reference to FIGS. FIG. 5 is a flowchart showing an operation when the data node management device according to the embodiment of the present invention issues a write command.

まず、前提として、クライアント端末40がデータ格納処理を実施する場合、クライアント端末40は、put要求とputするKVペアとを、データノード管理装置10に発行する。これにより、図5に示す処理が実行される。   First, as a premise, when the client terminal 40 performs a data storage process, the client terminal 40 issues a put request and a KV pair to be put to the data node management apparatus 10. Thereby, the process shown in FIG. 5 is executed.

図5に示すように、最初に、指示受付部11は、クライアント端末40から、データノード20に対する、データ格納処理を受け付ける(ステップA1)。   As shown in FIG. 5, first, the instruction receiving unit 11 receives a data storage process for the data node 20 from the client terminal 40 (step A1).

次に、ペアデータ変換処理部12は、「元のキー値-0000」を用いて、データノード10に対して、読み込み処理(get処理)を行い(ステップA2)、「親KVペア」の存在有無を確認する(ステップA3)。   Next, the pair data conversion processing unit 12 performs a read process (get process) on the data node 10 using “original key value −0000” (step A2), and the presence of the “parent KV pair”. The presence or absence is confirmed (step A3).

ステップA3の判定の結果、既に親KVペアが存在している場合は、ペアデータ変換処理部12は、図3に示した分割フラグを確認し、取得した親KVペアの分割フラグが「L」であるかどうかを判定する(ステップA13)。   If the parent KV pair already exists as a result of the determination in step A3, the pair data conversion processing unit 12 confirms the division flag shown in FIG. 3, and the division flag of the acquired parent KV pair is “L”. Is determined (step A13).

ステップA13の判定の結果、分割フラグが「flag:L」でない場合は、ペアデータ変換処理部12は、書き込み処理を継続し、ステップA4を実行する。   As a result of the determination in step A13, when the division flag is not “flag: L”, the pair data conversion processing unit 12 continues the writing process and executes step A4.

一方、ステップA13の判定の結果、分割フラグが「flag:L」である場合は、ロック中であり、他のデータノード管理装置が該当するキー値のKVペアを分割して書き込み中であることを表す。その場合は、ペアデータ変換処理部12は、Value部にタイムスタンプが格納されているので、タイムスタンプと現在の時刻との差分が予め設定されているタイムアウト値を超えているかどうかを判定する(ステップA14)。   On the other hand, if the result of the determination in step A13 is that the split flag is “flag: L”, the lock is being performed, and the other data node management device is writing the KV pair of the corresponding key value. Represents. In that case, since the time stamp is stored in the Value portion, the pair data conversion processing portion 12 determines whether or not the difference between the time stamp and the current time exceeds a preset time-out value ( Step A14).

ステップA14の判定の結果、タイムスタンプと現在時刻との差分値が予め設定されているタイムアウト値を超えていない場合は、ペアデータ変換処理部12は、該当するキー値のデータは『書き込み中』であると判断し、書き込み処理は失敗であることを、クライアント端末40に返却し、一連のデータ格納処理を終了とする(ステップA15)。   If the difference value between the time stamp and the current time does not exceed the preset timeout value as a result of the determination in step A14, the pair data conversion processing unit 12 sets the data of the corresponding key value to “being written”. The write process is unsuccessful, and it is returned to the client terminal 40 to end the series of data storage processes (step A15).

一方、ステップA14の判定の結果、タイムスタンプと現在時刻との差分値が予め設定されているタイムアウト値を超えている場合は、他のデータノード管理装置が実施していた書き込みは失敗したものとして、ペアデータ変換処理部12は、書き込み処理を継続し、後述するステップA4を実行する。   On the other hand, as a result of the determination in step A14, if the difference value between the time stamp and the current time exceeds a preset timeout value, it is assumed that the writing performed by another data node management device has failed. The pair data conversion processing unit 12 continues the writing process and executes Step A4 described later.

ステップA3の判定の結果、既に親KVペアが存在していない場合は、ペアデータ変換処理部12は、クライアント端末40から受けとったKVペアのデータサイズが閾値を超えていないかどうかを判定する(ステップA4)。ステップA4の判定の結果、閾値を超えていればステップA5以降の分割処理が実行される。   As a result of the determination in step A3, when the parent KV pair does not already exist, the pair data conversion processing unit 12 determines whether the data size of the KV pair received from the client terminal 40 exceeds the threshold ( Step A4). If the result of determination in step A4 is that the threshold value has been exceeded, the division processing after step A5 is executed.

一方、ステップA4の判定の結果、閾値を超えていなければ分割処理が実行されずに、ペアデータ変換処理部12は、格納先となるデータノード20に、KVペアを格納する(ステップA12)。   On the other hand, as a result of the determination in step A4, if the threshold is not exceeded, the pair data conversion processing unit 12 stores the KV pair in the data node 20 that is the storage destination without executing the division process (step A12).

具体的には、ステップA12では、ペアデータ変換処理部12は、図3に示した分割フラグの形式に沿って、キー値に「−0000」を付与し、Value部の先頭には分割フラグを「flag:N」を付与して、KVペアを書換え、データノード20に格納(put)処理を実施させる。データノード20による格納処理の完了後、ペアデータ変換処理部12は、クライアント端末40にデータ格納処理の完了を返却し、一連のデータ格納処理を終了とする。   Specifically, in step A12, the pair data conversion processing unit 12 assigns “−0000” to the key value according to the format of the split flag shown in FIG. 3, and sets the split flag at the head of the Value portion. “Flag: N” is assigned, the KV pair is rewritten, and the data node 20 performs a storage (put) process. After the storage process by the data node 20 is completed, the pair data conversion processing unit 12 returns the completion of the data storage process to the client terminal 40 and ends the series of data storage processes.

ステップA5では、分割処理が実行されるので、ペアデータ変換処理部12は、格納先となるデータノード20の総数を最大分割数として、格納されるデータ量が閾値を超えないサイズになるように、分割数を決定する。   In step A5, since the division process is executed, the pair data conversion processing unit 12 sets the total number of data nodes 20 as storage destinations as the maximum division number so that the amount of stored data does not exceed the threshold value. Determine the number of divisions.

次に、ペアデータ変換処理部12は、データノードアクセス部14を介して、キー値に「−0000」を付与した親KVペアの書き込みを実施する(ステップA6)。   Next, the pair data conversion processing unit 12 writes the parent KV pair with “−0000” added to the key value via the data node access unit 14 (step A6).

具体的には、ペアデータ変換処理部12は、図3に示した分割フラグの形式に沿って、親KVペアにおいて、キー値に「−0000」を付与し、Value部には、分割フラグ「flag:L」と、データノード管理装置10の識別子(装置ID)とを付与する。また、ペアデータ変換処理部12は、親KVペアのValue部には、実行時のタイムスタンプも付与する。その後、ペアデータ変換処理部12は、形式を変更した親KVペアのデータ格納処理をデータノード20に行なわせる。なお、ここで付与される識別子としては、ホスト名とプロセスIDとを合わせたもの等、データノード管理装置10を一位に特定できるものが挙げられる。   Specifically, the pair data conversion processing unit 12 assigns “−0000” to the key value in the parent KV pair in accordance with the format of the split flag shown in FIG. flag: L "and an identifier (device ID) of the data node management device 10 are given. The pair data conversion processing unit 12 also assigns a time stamp at the time of execution to the Value portion of the parent KV pair. Thereafter, the pair data conversion processing unit 12 causes the data node 20 to perform data storage processing of the parent KV pair whose format has been changed. Examples of the identifier assigned here include an identifier that can identify the data node management device 10 first, such as a combination of a host name and a process ID.

ステップA6で、親KVペアが「ロック中」で書き込まれると、ペアデータ分割部13は、分割数に応じて元のKVペアを、図4に示した子KVペアに分割し、データノードアクセス部14を介して、各データノード20に対して分割後の子KVペアの書き込みを指示する(ステップA7)。   When the parent KV pair is written as “locked” in step A6, the pair data dividing unit 13 divides the original KV pair into the child KV pairs shown in FIG. Via the unit 14, each data node 20 is instructed to write the divided child KV pair (step A7).

具体的には、ステップA7では、ペアデータ分割部13は、各子KVペアの分割フラグを「flag:N」とし、キー値の添え字として、分割した順番に「−0001」から分割数までの識別番号を付与する。   Specifically, in step A7, the pair data dividing unit 13 sets the division flag of each child KV pair to “flag: N”, and adds “−0001” to the number of divisions in the division order as a subscript of the key value. An identification number is assigned.

また、ステップA7では、ペアデータ分割部13は、子KVペアの格納先を、図6に示すようにConsistent Hashingの手法を用いて決定することができる。図6は、本発明の実施の形態における子KVペアの格納先の決定手法の一例を説明する説明図である。図6の例では、キー値の添え字が「−0000」である親KVペアのキー値でハッシュされた数字を起点として、子KVペアは順に格納され、分散されていく。   Further, in step A7, the pair data dividing unit 13 can determine the storage destination of the child KV pair using the consistent hashing method as shown in FIG. FIG. 6 is an explanatory diagram for explaining an example of a method for determining the storage destination of the child KV pair in the embodiment of the present invention. In the example of FIG. 6, the child KV pairs are sequentially stored and distributed starting from the number hashed with the key value of the parent KV pair whose key value subscript is “−0000”.

更に、ステップA7では、ペアデータ分割部13は、図7に示すように、子KVペアの書込み時に分散KVSのQuarum判定の仕様に沿ってレプリケーションすることもできる。図7は、本発明の実施の形態における子KVペアの格納先の決定手法の他の例を説明する説明図である。図7の例では、子KVペアは、レプリケーションされるものも含めて、「親KVペア」のキー値でハッシュされた数字を起点として、順番に格納される。   Further, in step A7, as shown in FIG. 7, the pair data dividing unit 13 can perform replication according to the specification of the distributed KVS Quarum determination when writing the child KV pair. FIG. 7 is an explanatory diagram for explaining another example of the method for determining the storage destination of the child KV pair in the embodiment of the present invention. In the example of FIG. 7, the child KV pairs, including those to be replicated, are stored in order starting from the number hashed with the key value of the “parent KV pair”.

次に、ステップA7の終了後、タイプスタンプ判定部16は、データノード20に対して読み込みを指示して、親KVペアを再度取得し、更に、親KVペアのデータに付与されている、識別子とタイムスタンプとを取得する。そして、タイムスタンプ判定部16は、取得した識別子とタイムスタンプとが、自身を備えているデータノード管理装置10によって付与したものと一致するかどうかを判定する(ステップA9)。   Next, after the end of step A7, the type stamp determination unit 16 instructs the data node 20 to read, acquires the parent KV pair again, and further adds the identifier assigned to the data of the parent KV pair. And timestamp. Then, the time stamp determination unit 16 determines whether or not the acquired identifier and time stamp match those provided by the data node management device 10 provided with the time stamp determination unit 16 (step A9).

ステップA9の判定の結果、一致していない場合は、ステップA1で受け付けたデータ格納処理はタイムアウトしており、別のデータノード管理装置10によって書き換えられてしまっている。分割フラグがL以外になっていた場合も同様である。従って、この場合は、
ペアデータ変換処理部12は、ステップA15を実行し、書き込み処理は失敗であることを、クライアント端末40に返却し、一連のデータ格納処理を終了とする。
If they do not match as a result of the determination in step A9, the data storage process accepted in step A1 has timed out and has been rewritten by another data node management device 10. The same applies when the division flag is other than L. Therefore, in this case,
The pair data conversion processing unit 12 executes Step A15, returns that the writing process is unsuccessful to the client terminal 40, and ends the series of data storing processes.

一方、ステップA9の判定の結果、一致している場合は、ペアデータ変換処理部12は、図2に示した分割フラグの形式に沿って、親KVペアのValue部において、分割フラグを「flag:D」とし、子KVペアのキー値のリストを更新する(ステップA10)。また、ペアデータ変換処理部12は、データノードアクセス部14を介して、親KVペアへの更新処理としてデータノード20に対して親KVペアの書き込みを実施する。   On the other hand, if they match as a result of the determination in step A9, the pair data conversion processing unit 12 sets the division flag to “flag” in the Value portion of the parent KV pair according to the format of the division flag shown in FIG. : D "and the list of key values of the child KV pair is updated (step A10). Further, the pair data conversion processing unit 12 writes the parent KV pair to the data node 20 through the data node access unit 14 as an update process to the parent KV pair.

その後、ペアデータ変換処理部12は、クライアント端末40に対して、データ格納処理の完了を返却し、一連のデータ格納処理を終了とする(ステップA11)。   Thereafter, the pair data conversion processing unit 12 returns completion of the data storage process to the client terminal 40, and ends the series of data storage processes (step A11).

続いて、図8を用いて、クライアント端末40から読み込み命令が発行されて、データ取得処理が指示された場合について説明する。図8は、本発明の実施の形態におけるデータノード管理装置の読み込み命令発行時の動作を示すフロー図である。   Next, a case where a read command is issued from the client terminal 40 and a data acquisition process is instructed will be described with reference to FIG. FIG. 8 is a flowchart showing an operation when the read instruction is issued by the data node management device according to the embodiment of the present invention.

まず、前提として、クライアント端末40がデータ取得処理を実施する場合、クライアント端末40は、get要求とgetするKVペアとを、データノード管理装置10に発行する。これにより、図8に示す処理が実行される。   First, as a premise, when the client terminal 40 performs a data acquisition process, the client terminal 40 issues a get request and a KV pair to get to the data node management apparatus 10. Thereby, the process shown in FIG. 8 is executed.

図8に示すように、最初に、指示受付部11は、クライアント端末40から、データノード20に対する、データ取得処理を受け付ける(ステップB1)。   As shown in FIG. 8, first, the instruction receiving unit 11 receives a data acquisition process for the data node 20 from the client terminal 40 (step B1).

次に、ペアデータ変換処理部12は、「元のキー値-0000」を用いて、データノード20に対して、読み込み処理(get処理)を行い(ステップB2)、「親KVペア」の存在有無を確認する(ステップB3)。   Next, the pair data conversion processing unit 12 performs a read process (get process) on the data node 20 using “original key value −0000” (step B2), and the existence of the “parent KV pair”. The presence or absence is confirmed (step B3).

ステップB3の判定の結果、既に親KVペアが存在していない場合は、ペアデータ変換処理部12は、該当するキー値のKVペアは存在しなかったという結果を、クライアント端末40に返却し、一連のデータ取得処理を終了とする(ステップB8)。   As a result of the determination in step B3, when the parent KV pair does not already exist, the pair data conversion processing unit 12 returns the result that the KV pair of the corresponding key value does not exist to the client terminal 40, A series of data acquisition processing is terminated (step B8).

一方、ステップB3の判定の結果、既に親KVペアが存在している場合は、ペアデータ変換処理部12は、このKVペアを取得し、図3に示した分割フラグを確認する。そして、ペアデータ変換処理部12は、取得したKVペアの分割フラグが「flag:L」であるかどうかを判定する(ステップB4)。   On the other hand, if the result of determination in step B3 is that a parent KV pair already exists, the pair data conversion processing unit 12 acquires this KV pair and checks the division flag shown in FIG. And the pair data conversion process part 12 determines whether the division | segmentation flag of the acquired KV pair is "flag: L" (step B4).

ステップB4の判定の結果、分割フラグが「flag:L」(ロック中)である場合は、ペアデータ変換処理部12は、該当するキー値のKVペアは「書き込み中」であることを、クライアント端末40に返却し、一連のデータ取得処理を終了とする(ステップB9)。また、「書き込み中」の情報を受け取ったクライアント端末40は、データ取得処理を失敗としてもよいし、一定時間待機してリトライしてもよい。   If the result of determination in step B4 is that the split flag is “flag: L” (locking), the pair data conversion processing unit 12 indicates that the KV pair of the corresponding key value is “writing”. It returns to the terminal 40, and a series of data acquisition processing is complete | finished (step B9). Further, the client terminal 40 that has received the “writing” information may fail the data acquisition process, or may retry after waiting for a certain period of time.

一方、ステップB4の判定の結果、分割フラグが「flag:L」でない場合は、ペアデータ変換処理部12は、更に、取得したKVペアの分割フラグが「flag:N」(分割なし)であるかどうかを判定する(ステップB5)。   On the other hand, if the result of determination in step B4 is that the split flag is not “flag: L”, the pair data conversion processing unit 12 further indicates that the acquired split flag of the KV pair is “flag: N” (no split). Whether or not (step B5).

ステップB5の判定の結果、分割フラグが「flag:N」(分割なし)である場合は、ペアデータ変換処理部12は、取得したKVペアのValue部から分割フラグの情報を除いたものをValue値とし、このValue値をクライアント端末40に返却し、一連のデータ取得処理を終了とする(ステップB9)。   If the result of determination in step B5 is that the split flag is “flag: N” (no split), the pair data conversion processing unit 12 sets Value obtained by removing the split flag information from the Value part of the acquired KV pair as Value This value is returned to the client terminal 40, and a series of data acquisition processing is terminated (step B9).

一方、ステップB5の判定の結果、分割フラグが「flag:N」(分割なし)でない場合、即ち、分割フラグが「flag:D」(分割あり)である場合は、ペアデータ変換処理部12は、Value部にある子KVペアのキー値リストを元に、データノード20に対して読み込み処理を実施し、リストにある子KVペアのデータを全て取得する(ステップB6)。   On the other hand, as a result of the determination in step B5, when the division flag is not “flag: N” (no division), that is, when the division flag is “flag: D” (with division), the pair data conversion processing unit 12 Based on the key value list of the child KV pair in the Value part, the data node 20 is read to acquire all the child KV pair data in the list (step B6).

次に、ステップB6の実行後、ペアデータ変換処理部12は、取得した子KVペアのValue部のデータを、キー値の添え字の識別番号の順に沿って結合し、結合できたデータをValue値としてクライアント端末40に返却し、一連のデータ取得処理を終了とする(ステップB7)。   Next, after the execution of step B6, the pair data conversion processing unit 12 combines the acquired data of the Value part of the child KV pair in the order of the identification number of the subscript of the key value, and combines the combined data with Value A value is returned to the client terminal 40, and a series of data acquisition processing is terminated (step B7).

[実施の形態における効果]
以上のように、本実施の形態では、データサイズの大きなKVペアは、格納先のデータノードの数に応じて分割され、分散されて格納されるので、特定のノードにデータが偏ることが、格納の段階で回避される。
[Effects of the embodiment]
As described above, in this embodiment, a KV pair having a large data size is divided according to the number of data nodes at the storage destination and is distributed and stored, so that data is biased to a specific node. Avoided at the storage stage.

また、本実施の形態では、分割されたKVペアは、各ノードに分散されているため、データノードの数だけ並列して読み込み処理又は書き込み処理を実施することが可能となるので、レイテンシの改善が期待できる。   In the present embodiment, since the divided KV pairs are distributed to each node, it is possible to perform the reading process or the writing process in parallel by the number of data nodes, thereby improving the latency. Can be expected.

KVペアの分割及び結合は、データノード管理装置10を経由して、システム内部で自動的に実行されるので、ユーザは、分割及び結合の処理を意識せずに、分散KVSシステムを運用できる。更に、ユーザは、データモデル設計時において、データサイズの大きなKVペアが生成されることを考慮しなくても良く、自由に設計を行なうことができる。   Since the division and combination of KV pairs are automatically executed inside the system via the data node management apparatus 10, the user can operate the distributed KVS system without being aware of the division and combination processing. Furthermore, the user does not need to consider that a KV pair having a large data size is generated at the time of designing the data model, and can design freely.

[変形例]
ここで、本実施の形態における変形例について図9を用いて説明する。図9は、本発明の実施の形態におけるデータノードの他の例を示すブロック図である。図9に示すように、本変形例では、データノード20は、通信部21と、ストレージ22と、ペアデータ削除部23とを備えている。
[Modification]
Here, a modification of the present embodiment will be described with reference to FIG. FIG. 9 is a block diagram showing another example of the data node in the embodiment of the present invention. As shown in FIG. 9, in the present modification, the data node 20 includes a communication unit 21, a storage 22, and a pair data deletion unit 23.

このうち、通信部21は、データノード管理装置10からの命令の受信、KVペアの送受信を行なっている。ストレージ22は、KVペア(親KVペア、子KVペア)を格納する。ペアデータ削除部23は、データノード20が格納するKVペアの中から子KVペアを特定し、特定した子KVペアのうち、設定条件を満たす子ペアデータを削除する。   Among these, the communication unit 21 receives commands from the data node management device 10 and transmits / receives KV pairs. The storage 22 stores KV pairs (parent KV pair, child KV pair). The pair data deletion unit 23 specifies a child KV pair from among the KV pairs stored in the data node 20, and deletes child pair data satisfying the setting condition from the specified child KV pairs.

図5に示した処理が実行され、何らかの原因で一連の書き込み処理が中断されてしまった場合に、途中まで書き込まれた子KVペアが、その後どのデータノード管理装置からも参照されず、不要なデータとしてデータノード20に残り続けてしまう可能性がある。このような中断が生じる場合としては、分割及び書き込みが決定され、先に親KVペアがロック中で書き込まれた後、分割後の子KVペアが書き込まれている途中で、データノード管理装置10がダウンしたり、タイムアウトと判定され、他のデータノード管理装置に親KVペアが書き換えられたりした場合である。このような場合、親KVペアのロックはタイムアウトにより解除されるが、途中まで書き込まれた子KVペアは、データノード20に残り続けてしまう。   When the processing shown in FIG. 5 is executed and a series of write processing is interrupted for some reason, the child KV pair written halfway is not referred to by any data node management device after that and is unnecessary. There is a possibility that data remains in the data node 20 as data. In the case where such an interruption occurs, the data node management device 10 determines that the split and write are decided, and after the parent KV pair is written in the locked state, the split child KV pair is being written. Or when it is determined that a timeout has occurred and the parent KV pair has been rewritten to another data node management device. In such a case, the lock of the parent KV pair is released due to timeout, but the child KV pair written halfway continues to remain in the data node 20.

これに対して、本変形例では、ペアデータ削除部23は、このような不要な子KVペアを削除する。具体的には、ペアデータ削除部23は、定期的に(ユーザが予め設定したタイミングで)、ストレージ22内の子KVペア(添え字が-0000ではないもの)を全件走査する。そして、ペアデータ削除部23は、走査において、例えば、親KVペア(添え字が-0000のもの)をgetできない子KVペア、親KVペアのValue部内のキー値リストに含まれていない子KVペアを見つけると、これらを削除する。この結果、障害又はタイムアウトによって書き込み処理が中断され、不要な子KVペアがストレージ22内に溜まってしまうことが回避される。   On the other hand, in the present modification, the pair data deletion unit 23 deletes such unnecessary child KV pairs. Specifically, the pair data deletion unit 23 periodically scans all child KV pairs (subscripts whose subscript is not −0000) in the storage 22 (at a timing set in advance by the user). The pair data deletion unit 23 then scans, for example, a child KV pair that cannot get a parent KV pair (subscript is −0000), and a child KV not included in the key value list in the Value part of the parent KV pair. If you find a pair, delete them. As a result, it is avoided that the writing process is interrupted due to a failure or timeout, and unnecessary child KV pairs are accumulated in the storage 22.

[プログラム]
本発明の実施の形態におけるプログラムは、コンピュータに、図5に示すステップA1〜A15、図8に示すB1〜B10を実行させるプログラムであれば良い。このプログラムをコンピュータにインストールし、実行することによって、本実施の形態におけるデータノード管理装置10とデータノード管理方法とを実現することができる。この場合、コンピュータのCPU(Central Processing Unit)は、指示受付部11、ペアデータ変換処理部12、ペアデータ分割部13、データノードアクセス部14、データ統合部15、及びタイムスタンプ判定部16として機能し、処理を行なう。
[program]
The program in the embodiment of the present invention may be a program that causes a computer to execute steps A1 to A15 shown in FIG. 5 and B1 to B10 shown in FIG. By installing and executing this program on a computer, the data node management device 10 and the data node management method in the present embodiment can be realized. In this case, the CPU (Central Processing Unit) of the computer functions as the instruction receiving unit 11, the pair data conversion processing unit 12, the pair data dividing unit 13, the data node access unit 14, the data integration unit 15, and the time stamp determination unit 16. And process.

また、本実施の形態におけるプログラムは、複数のコンピュータによって構築されたコンピュータシステムによって実行されても良い。この場合は、例えば、各コンピュータが、それぞれ、指示受付部11、ペアデータ変換処理部12、ペアデータ分割部13、データノードアクセス部14、データ統合部15、及びタイムスタンプ判定部16のいずれかとして機能しても良い。   The program in the present embodiment may be executed by a computer system constructed by a plurality of computers. In this case, for example, each computer is any one of the instruction receiving unit 11, the pair data conversion processing unit 12, the pair data dividing unit 13, the data node access unit 14, the data integration unit 15, and the time stamp determination unit 16. May function as

ここで、本実施の形態におけるプログラムを実行することによって、データノード管理装置10を実現するコンピュータについて図10を用いて説明する。図10は、本発明の実施の形態におけるデータノード管理装置10を実現するコンピュータの一例を示すブロック図である。   Here, a computer that realizes the data node management apparatus 10 by executing the program according to the present embodiment will be described with reference to FIG. FIG. 10 is a block diagram illustrating an example of a computer that implements the data node management apparatus 10 according to the embodiment of the present invention.

図10に示すように、コンピュータ110は、CPU111と、メインメモリ112と、記憶装置113と、入力インターフェイス114と、表示コントローラ115と、データリーダ/ライタ116と、通信インターフェイス117とを備える。これらの各部は、バス121を介して、互いにデータ通信可能に接続される。   As shown in FIG. 10, the computer 110 includes a CPU 111, a main memory 112, a storage device 113, an input interface 114, a display controller 115, a data reader / writer 116, and a communication interface 117. These units are connected to each other via a bus 121 so that data communication is possible.

CPU111は、記憶装置113に格納された、本実施の形態におけるプログラム(コード)をメインメモリ112に展開し、これらを所定順序で実行することにより、各種の演算を実施する。メインメモリ112は、典型的には、DRAM(Dynamic Random Access Memory)等の揮発性の記憶装置である。また、本実施の形態におけるプログラムは、コンピュータ読み取り可能な記録媒体120に格納された状態で提供される。なお、本実施の形態におけるプログラムは、通信インターフェイス117を介して接続されたインターネット上で流通するものであっても良い。   The CPU 111 performs various calculations by developing the program (code) in the present embodiment stored in the storage device 113 in the main memory 112 and executing them in a predetermined order. The main memory 112 is typically a volatile storage device such as a DRAM (Dynamic Random Access Memory). Further, the program in the present embodiment is provided in a state of being stored in a computer-readable recording medium 120. Note that the program in the present embodiment may be distributed on the Internet connected via the communication interface 117.

また、記憶装置113の具体例としては、ハードディスクドライブの他、フラッシュメモリ等の半導体記憶装置が挙げられる。入力インターフェイス114は、CPU111と、キーボード及びマウスといった入力機器118との間のデータ伝送を仲介する。表示コントローラ115は、ディスプレイ装置119と接続され、ディスプレイ装置119での表示を制御する。   Specific examples of the storage device 113 include a hard disk drive and a semiconductor storage device such as a flash memory. The input interface 114 mediates data transmission between the CPU 111 and an input device 118 such as a keyboard and a mouse. The display controller 115 is connected to the display device 119 and controls display on the display device 119.

データリーダ/ライタ116は、CPU111と記録媒体120との間のデータ伝送を仲介し、記録媒体120からのプログラムの読み出し、及びコンピュータ110における処理結果の記録媒体120への書き込みを実行する。通信インターフェイス117は、CPU111と、他のコンピュータとの間のデータ伝送を仲介する。   The data reader / writer 116 mediates data transmission between the CPU 111 and the recording medium 120, and reads a program from the recording medium 120 and writes a processing result in the computer 110 to the recording medium 120. The communication interface 117 mediates data transmission between the CPU 111 and another computer.

また、記録媒体120の具体例としては、CF(Compact Flash(登録商標))及びSD(Secure Digital)等の汎用的な半導体記憶デバイス、フレキシブルディスク(Flexible Disk)等の磁気記録媒体、又はCD−ROM(Compact Disk Read Only Memory)などの光学記録媒体が挙げられる。   Specific examples of the recording medium 120 include general-purpose semiconductor storage devices such as CF (Compact Flash (registered trademark)) and SD (Secure Digital), magnetic recording media such as a flexible disk, or CD- An optical recording medium such as ROM (Compact Disk Read Only Memory) can be used.

なお、本実施の形態におけるデータノード管理装置10は、プログラムがインストールされたコンピュータではなく、各部に対応したハードウェアを用いることによっても実現可能である。更に、データノード管理装置10は、一部がプログラムで実現され、残りの部分がハードウェアで実現されていてもよい。   The data node management apparatus 10 according to the present embodiment can be realized by using hardware corresponding to each unit instead of a computer in which a program is installed. Further, the data node management device 10 may be partially realized by a program and the remaining portion may be realized by hardware.

上述した実施の形態の一部又は全部は、以下に記載する(付記1)〜(付記11)によって表現することができるが、以下の記載に限定されるものではない。   Part or all of the above-described embodiment can be expressed by (Appendix 1) to (Appendix 11) described below, but is not limited to the following description.

(付記1)
データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、指示受付部と、
受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ペアデータ変換処理部と、
書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ペアデータ分割部と、
分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかの前記データノードに格納する、データノードアクセス部と、
受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、データ結合部と、
を備えている、ことを特徴とするデータノード管理装置。
(Appendix 1)
An instruction receiving unit that receives an instruction to a data node that stores data and a corresponding key value as pair data;
A pair data conversion processing unit that assigns a preset subscript to a key value in the pair data to be written when the received instruction is a write instruction;
The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and each divided data and the key value of the parent pair data are combined to generate child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number different for each child pair data, and further, a list of key values of each child pair data is added to the data of the parent pair data. A pair data dividing unit for storing
A data node access unit that stores child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of each child pair data;
When the received instruction is a read instruction, based on the list, obtain a child pair node of the pair data to be read, and combine the acquired child pair node;
A data node management device comprising:

(付記2)
前記ペアデータ変換処理部が、前記書き込み命令が受け付けられると前記書き込み対象となるペアデータにおいて、データに、分割の有無及び状態を示すフラグを付与し、そして、前記子ペアデータの前記データノードへの格納が終了すると、前記親ペアデータの前記フラグを分割ありに設定し、
前記ペアデータ分割部が、前記書き込み対象となるペアデータにおいて、設定された分割数に応じて子ペアデータヘの分割を行なう、
付記1に記載のデータノード管理装置。
(Appendix 2)
When the write command is received, the pair data conversion processing unit gives a flag indicating the presence / absence and state of division to the data to be written in the pair data to be written, and sends the data to the data node of the child pair data When the storage of is completed, the flag of the parent pair data is set to be divided,
In the pair data to be written, the pair data dividing unit performs division into child pair data according to the set number of divisions.
The data node management device according to attachment 1.

(付記3)
前記書き込み命令が受け付けられた場合に、前記書き込み対象となるペアデータのデータに、当該データノード管理装置の識別子とタイムスタンプとを付与し、
更に、前記子ペアノードの前記データノードへの格納が終了した場合に、前記親ペアデータのデータに付与されている、前記識別子と前記タイムスタンプとを取得し、取得した前記識別子と前記タイムスタンプとが、当該データノード管理装置によって付与されたものかどうかを判定し、付与されたものでない場合は、前記書き込み命令はタイムアウトしているとする、タイムスタンプ判定部を備えている、
付記2に記載のデータノード管理装置。
(Appendix 3)
When the write command is accepted, the identifier of the data node management device and a time stamp are given to the data of the pair data to be written,
Further, when the storage of the child pair node in the data node is completed, the identifier and the time stamp given to the data of the parent pair data are acquired, and the acquired identifier and the time stamp are Is determined by the data node management device, and if not, the write command is timed out, provided with a time stamp determination unit,
The data node management device according to attachment 2.

(付記4)
データとそれに対応するキー値とをペアデータとして格納するデータノードと、データノード管理装置とを備え、
前記データノード管理装置は、
前記データノードに対する命令を受け付ける、指示受付部と、
受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ペアデータ変換処理部と、
書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ペアデータ分割部と、
分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかの前記データノードに格納する、データノードアクセス部と、
受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、データ結合部と、
を備えている、ことを特徴とするストレージシステム。
(Appendix 4)
A data node that stores data and a corresponding key value as pair data, and a data node management device,
The data node management device includes:
An instruction receiving unit for receiving an instruction for the data node;
A pair data conversion processing unit that assigns a preset subscript to a key value in the pair data to be written when the received instruction is a write instruction;
The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and each divided data and the key value of the parent pair data are combined to generate child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number different for each child pair data, and further, a list of key values of each child pair data is added to the data of the parent pair data. A pair data dividing unit for storing
A data node access unit that stores child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of each child pair data;
When the received instruction is a read instruction, based on the list, obtain a child pair node of the pair data to be read, and combine the acquired child pair node;
A storage system characterized by comprising:

(付記5)
前記データノードが、
前記データノードが格納する前記ペアデータの中から前記子ペアデータを特定し、特定した前記子ペアデータのうち、設定条件を満たす子ペアデータを削除する、ペアデータ削除部を更に備えている、
付記4に記載のストレージシステム。
(Appendix 5)
The data node is
The child node data is specified from the pair data stored in the data node, and the child data pair is further deleted.
The storage system according to appendix 4.

(付記6)
(a)データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、ステップと、
(b)受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ステップと、
(c)書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ステップと、
(d)分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかのデータノードに格納する、ステップと、
(e)受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、ステップと、
を有する、ことを特徴とするデータノード管理方法。
(Appendix 6)
(A) receiving a command for a data node that stores data and a corresponding key value as pair data; and
(B) when the received command is a write command, a preset subscript is added to the key value in the pair data to be written; and
(C) The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and the divided paired data and the key value of the parent pair data are combined to obtain the child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number that differs for each child pair data, and further, the key of each child pair data is added to the data of the parent pair data. Storing a list of values, steps;
(D) storing the child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of the respective child pair data;
(E) when the received instruction is a read instruction, acquiring a child pair node of the pair data to be read based on the list, and combining the acquired child pair nodes;
A data node management method characterized by comprising:

(付記7)
前記(b)のステップにおいて、前記書き込み命令が受け付けられると前記書き込み対象となるペアデータにおいて、データに、分割の有無及び状態を示すフラグを付与し、そして、前記子ペアデータの前記データノードへの格納が終了すると、前記親ペアデータの前記フラグを分割ありに設定し、
前記(c)のステップにおいて、前記書き込み対象となるペアデータで、設定された分割数に応じて子ペアデータヘの分割を行なう、
付記6に記載のデータノード管理方法。
(Appendix 7)
In the step (b), when the write command is accepted, in the pair data to be written, a flag indicating the presence / absence and state of division is added to the data, and the child pair data is sent to the data node. When the storage of is completed, the flag of the parent pair data is set to be divided,
In the step (c), the pair data to be written is divided into child pair data according to the set number of divisions.
The data node management method according to attachment 6.

(付記8)
(f)前記書き込み命令が受け付けられた場合に、前記書き込み対象となるペアデータのデータに、当該データノード管理装置の識別子とタイムスタンプとを付与する、ステップと、
(g)前記子ペアノードの前記データノードへの格納が終了した場合に、前記親ペアデータのデータに付与されている、前記識別子と前記タイムスタンプとを取得し、取得した前記識別子と前記タイムスタンプとが、当該データノード管理装置によって付与されたものかどうかを判定し、付与されたものでない場合は、前記書き込み命令はタイムアウトしているとする、ステップと、
を更に有する、付記7に記載のデータノード管理方法。
(Appendix 8)
(F) when the write command is accepted, adding an identifier and a time stamp of the data node management device to the data of the pair data to be written;
(G) When storing the child pair node in the data node is completed, the identifier and the time stamp given to the data of the parent pair data are acquired, and the acquired identifier and the time stamp are acquired. Are determined to be given by the data node management device, and if not given, the write command is timed out, and
The data node management method according to appendix 7, further comprising:

(付記9)
コンピュータに、
(a)データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、ステップと、
(b)受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ステップと、
(c)書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ステップと、
(d)分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかのデータノードに格納する、ステップと、
(e)受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、ステップと、
を有する、ことを特徴とするプログラム。
(Appendix 9)
On the computer,
(A) receiving a command for a data node that stores data and a corresponding key value as pair data; and
(B) when the received command is a write command, a preset subscript is added to the key value in the pair data to be written; and
(C) The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and the divided paired data and the key value of the parent pair data are combined to obtain the child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number that differs for each child pair data, and further, the key of each child pair data is added to the data of the parent pair data. Storing a list of values, steps;
(D) storing the child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of the respective child pair data;
(E) when the received instruction is a read instruction, acquiring a child pair node of the pair data to be read based on the list, and combining the acquired child pair nodes;
The program characterized by having.

(付記10)
前記(b)のステップにおいて、前記書き込み命令が受け付けられると前記書き込み対象となるペアデータにおいて、データに、分割の有無及び状態を示すフラグを付与し、そして、前記子ペアデータの前記データノードへの格納が終了すると、前記親ペアデータの前記フラグを分割ありに設定し、
前記(c)のステップにおいて、前記書き込み対象となるペアデータで、設定された分割数に応じて子ペアデータヘの分割を行なう、
付記9に記載のプログラム。
(Appendix 10)
In the step (b), when the write command is accepted, in the pair data to be written, a flag indicating the presence / absence and state of division is added to the data, and the child pair data is sent to the data node. When the storage of is completed, the flag of the parent pair data is set to be divided,
In the step (c), the pair data to be written is divided into child pair data according to the set number of divisions.
The program according to appendix 9.

(付記11)
前記コンピュータに、
(f)前記書き込み命令が受け付けられた場合に、前記書き込み対象となるペアデータのデータに、当該データノード管理装置の識別子とタイムスタンプとを付与する、ステップと、
(g)前記子ペアノードの前記データノードへの格納が終了した場合に、前記親ペアデータのデータに付与されている、前記識別子と前記タイムスタンプとを取得し、取得した前記識別子と前記タイムスタンプとが、当該データノード管理装置によって付与されたものかどうかを判定し、付与されたものでない場合は、前記書き込み命令はタイムアウトしているとする、ステップと、
を更に実行させる、付記10に記載のプログラム。
(Appendix 11)
In the computer,
(F) when the write command is accepted, adding an identifier and a time stamp of the data node management device to the data of the pair data to be written;
(G) When storing the child pair node in the data node is completed, the identifier and the time stamp given to the data of the parent pair data are acquired, and the acquired identifier and the time stamp are acquired. Are determined to be given by the data node management device, and if not given, the write command is timed out, and
The program according to appendix 10, wherein the program is further executed.

以上のように、本発明によれば、KVペアのデータサイズに偏りがあっても、パーティションの再配置を行なうことなく、データ量の偏りの抑制と負荷の分散化とを図ることができる。本発明は、ストレージシステム、特に分散KVSシステムに有用である。   As described above, according to the present invention, even if the data size of the KV pair is uneven, it is possible to suppress the uneven amount of data and to distribute the load without rearranging the partitions. The present invention is useful for storage systems, particularly distributed KVS systems.

10 データノード管理装置
11 指示受付部
12 ペアデータ変換処理部
13 ペアデータ分割部
14 データノードアクセス部
15 データ統合部
16 タイムスタンプ判定部
20 データノード
21 通信部
22 ストレージ
23 ペアデータ削除部
30 ネットワーク
40 クライアント端末
100 ストレージシステム
110 コンピュータ
111 CPU
112 メインメモリ
113 記憶装置
114 入力インターフェイス
115 表示コントローラ
116 データリーダ/ライタ
117 通信インターフェイス
118 入力機器
119 ディスプレイ装置
120 記録媒体
121 バス
DESCRIPTION OF SYMBOLS 10 Data node management apparatus 11 Instruction reception part 12 Pair data conversion process part 13 Pair data division part 14 Data node access part 15 Data integration part 16 Time stamp judgment part 20 Data node 21 Communication part 22 Storage 23 Pair data deletion part 30 Network 40 Client terminal 100 Storage system 110 Computer 111 CPU
112 Main Memory 113 Storage Device 114 Input Interface 115 Display Controller 116 Data Reader / Writer 117 Communication Interface 118 Input Device 119 Display Device 120 Recording Medium 121 Bus

Claims (7)

データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、指示受付部と、
受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ペアデータ変換処理部と、
書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ペアデータ分割部と、
分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかの前記データノードに格納する、データノードアクセス部と、
受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、データ結合部と、
を備えている、ことを特徴とするデータノード管理装置。
An instruction receiving unit that receives an instruction to a data node that stores data and a corresponding key value as pair data;
A pair data conversion processing unit that assigns a preset subscript to a key value in the pair data to be written when the received instruction is a write instruction;
The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and each divided data and the key value of the parent pair data are combined to generate child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number different for each child pair data, and further, a list of key values of each child pair data is added to the data of the parent pair data. A pair data dividing unit for storing
A data node access unit that stores child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of each child pair data;
When the received instruction is a read instruction, based on the list, obtain a child pair node of the pair data to be read, and combine the acquired child pair node;
A data node management device comprising:
前記ペアデータ変換処理部が、前記書き込み命令が受け付けられると前記書き込み対象となるペアデータにおいて、データに、分割の有無及び状態を示すフラグを付与し、そして、前記子ペアデータの前記データノードへの格納が終了すると、前記親ペアデータの前記フラグを分割ありに設定し、
前記ペアデータ分割部が、前記書き込み対象となるペアデータにおいて、設定された分割数に応じて子ペアデータヘの分割を行なう、
請求項1に記載のデータノード管理装置。
When the write command is received, the pair data conversion processing unit gives a flag indicating the presence / absence and state of division to the data to be written in the pair data to be written, and sends the data to the data node of the child pair data When the storage of is completed, the flag of the parent pair data is set to be divided,
In the pair data to be written, the pair data dividing unit performs division into child pair data according to the set number of divisions.
The data node management device according to claim 1.
前記書き込み命令が受け付けられた場合に、前記書き込み対象となるペアデータのデータに、当該データノード管理装置の識別子とタイムスタンプとを付与し、
更に、前記子ペアノードの前記データノードへの格納が終了した場合に、前記親ペアデータのデータに付与されている、前記識別子と前記タイムスタンプとを取得し、取得した前記識別子と前記タイムスタンプとが、当該データノード管理装置によって付与されたものかどうかを判定し、付与されたものでない場合は、前記書き込み命令はタイムアウトしているとする、タイムスタンプ判定部を備えている、
請求項2に記載のデータノード管理装置。
When the write command is accepted, the identifier of the data node management device and a time stamp are given to the data of the pair data to be written,
Further, when the storage of the child pair node in the data node is completed, the identifier and the time stamp given to the data of the parent pair data are acquired, and the acquired identifier and the time stamp are Is determined by the data node management device, and if not, the write command is timed out, provided with a time stamp determination unit,
The data node management device according to claim 2.
データとそれに対応するキー値とをペアデータとして格納するデータノードと、データノード管理装置とを備え、
前記データノード管理装置は、
前記データノードに対する命令を受け付ける、指示受付部と、
受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ペアデータ変換処理部と、
書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ペアデータ分割部と、
分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかの前記データノードに格納する、データノードアクセス部と、
受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、データ結合部と、
を備えている、ことを特徴とするストレージシステム。
A data node that stores data and a corresponding key value as pair data, and a data node management device,
The data node management device includes:
An instruction receiving unit for receiving an instruction for the data node;
A pair data conversion processing unit that assigns a preset subscript to a key value in the pair data to be written when the received instruction is a write instruction;
The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and each divided data and the key value of the parent pair data are combined to generate child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number different for each child pair data, and further, a list of key values of each child pair data is added to the data of the parent pair data. A pair data dividing unit for storing
A data node access unit that stores child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of each child pair data;
When the received instruction is a read instruction, based on the list, obtain a child pair node of the pair data to be read, and combine the acquired child pair node;
A storage system characterized by comprising:
前記データノードが、
前記データノードが格納する前記ペアデータの中から前記子ペアデータを特定し、特定した前記子ペアデータのうち、設定条件を満たす子ペアデータを削除する、ペアデータ削除部を更に備えている、
請求項4に記載のストレージシステム。
The data node is
The child node data is specified from the pair data stored in the data node, and the child data pair is further deleted.
The storage system according to claim 4.
(a)データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、ステップと、
(b)受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ステップと、
(c)書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ステップと、
(d)分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかのデータノードに格納する、ステップと、
(e)受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、ステップと、
を有する、ことを特徴とするデータノード管理方法。
(A) receiving a command for a data node that stores data and a corresponding key value as pair data; and
(B) when the received command is a write command, a preset subscript is added to the key value in the pair data to be written; and
(C) The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and the divided paired data and the key value of the parent pair data are combined to obtain the child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number that differs for each child pair data, and further, the key of each child pair data is added to the data of the parent pair data. Storing a list of values, steps;
(D) storing the child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of the respective child pair data;
(E) when the received instruction is a read instruction, acquiring a child pair node of the pair data to be read based on the list, and combining the acquired child pair nodes;
A data node management method characterized by comprising:
コンピュータに、
(a)データとそれに対応するキー値とをペアデータとして格納するデータノードに対する命令を受け付ける、ステップと、
(b)受け付けられた前記命令が書き込み命令である場合に、書き込み対象となるペアデータにおいて、キー値に、予め設定された添え字を付与する、ステップと、
(c)書き込み対象となるペアデータを親ペアデータとして、親ペアデータに含まれるデータを設定数に分割し、分割された各データと親ペアデータのキー値とを合わせて、子ペアデータを生成し、その際、各子ペアデータのキー値に付与されている添え字を、子ペアデータ毎に異なる連続した識別番号に書き換え、更に、親ペアデータのデータに、各子ペアデータのキー値のリストを格納する、ステップと、
(d)分割によって生成した子ペアデータを、各子ペアデータのキー値に付与されている前記識別番号の順に、いずれかのデータノードに格納する、ステップと、
(e)受け付けられた命令が読み込み命令である場合に、前記リストに基づいて、読込対象となるペアデータの子ペアノードを取得し、取得した子ペアノードを結合する、ステップと、
を有する、ことを特徴とするプログラム。
On the computer,
(A) receiving a command for a data node that stores data and a corresponding key value as pair data; and
(B) when the received command is a write command, a preset subscript is added to the key value in the pair data to be written; and
(C) The pair data to be written is the parent pair data, the data included in the parent pair data is divided into a set number, and the divided paired data and the key value of the parent pair data are combined to obtain the child pair data. At that time, the subscript attached to the key value of each child pair data is rewritten to a continuous identification number that differs for each child pair data, and further, the key of each child pair data is added to the data of the parent pair data. Storing a list of values, steps;
(D) storing the child pair data generated by the division in any of the data nodes in the order of the identification numbers given to the key values of the respective child pair data;
(E) when the received instruction is a read instruction, acquiring a child pair node of the pair data to be read based on the list, and combining the acquired child pair nodes;
The program characterized by having.
JP2017055492A 2017-03-22 2017-03-22 Data node management apparatus, storage system, data node management method and program Pending JP2018159987A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017055492A JP2018159987A (en) 2017-03-22 2017-03-22 Data node management apparatus, storage system, data node management method and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017055492A JP2018159987A (en) 2017-03-22 2017-03-22 Data node management apparatus, storage system, data node management method and program

Publications (1)

Publication Number Publication Date
JP2018159987A true JP2018159987A (en) 2018-10-11

Family

ID=63796669

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017055492A Pending JP2018159987A (en) 2017-03-22 2017-03-22 Data node management apparatus, storage system, data node management method and program

Country Status (1)

Country Link
JP (1) JP2018159987A (en)

Similar Documents

Publication Publication Date Title
US9971823B2 (en) Dynamic replica failure detection and healing
US11442961B2 (en) Active transaction list synchronization method and apparatus
US20150324371A1 (en) Data Processing Method and Device in Distributed File Storage System
US20130218934A1 (en) Method for directory entries split and merge in distributed file system
US9031906B2 (en) Method of managing data in asymmetric cluster file system
US10908834B2 (en) Load balancing for scalable storage system
US9372879B1 (en) Balanced append tree data structure
JP6582445B2 (en) Thin client system, connection management device, virtual machine operating device, method, and program
US11663192B2 (en) Identifying and resolving differences between datastores
US11675743B2 (en) Web-scale distributed deduplication
JP6405255B2 (en) COMMUNICATION SYSTEM, QUEUE MANAGEMENT SERVER, AND COMMUNICATION METHOD
US10673713B2 (en) Communication control device, communication device, and computer program product for dynamic group management
US10440523B2 (en) Communication control device, communication device, and computer program product for managing a group of devices
US9262219B2 (en) Distributed processing system, distributed processing method, and distributed processing program
JP6951846B2 (en) Computer system and task allocation method
CN113760847A (en) Log data processing method, device, equipment and storage medium
JP4891657B2 (en) Data storage system, file search device and program
US9578120B1 (en) Messaging with key-value persistence
KR20130038517A (en) System and method for managing data using distributed containers
US10083121B2 (en) Storage system and storage method
KR100983479B1 (en) Method, system and computer readable recording medium for providing a distributed programming environment using distributed space
US10185735B2 (en) Distributed database system and a non-transitory computer readable medium
JP2018159987A (en) Data node management apparatus, storage system, data node management method and program
CN112181899A (en) Metadata processing method and device and computer readable storage medium
US20240004712A1 (en) Fencing off cluster services based on shared storage access keys