Navigation Menu

Skip to content

Commit

Permalink
Use droonga-engine-absorb-data command to copy data directly
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Jun 27, 2014
1 parent 7bfbe98 commit 8e3777b
Show file tree
Hide file tree
Showing 3 changed files with 82 additions and 93 deletions.
67 changes: 34 additions & 33 deletions _po/ja/tutorial/1.0.4/dump-restore/index.po
Expand Up @@ -435,48 +435,49 @@ msgid ""
" [[0,1401363465.610241,0],[[[null],[]]]]"
msgstr ""

msgid "### Duplicate data between two Droonga clusters"
msgstr "### 2つのDroongaクラスタの間でデータを複製する"
msgid "### Duplicate data between two Droonga clusters directly"
msgstr "### 2つのDroongaクラスタの間で直接データを複製する"

msgid ""
"To duplicate the source cluster to the destination cluster, run a command line"
" like:"
msgstr "複製元クラスタから複製先クラスタへデータを複製するには、以下のようなコマンドを実行します:"
"The package `droonga-engine` includes a utility command `droonga-engine-absorb"
"-data`.\n"
"It copies all data from an existing cluster to another one directly, so it is "
"recommended if you don't need to save dump file locally."
msgstr ""
"`droonga-engine` パッケージは `droonga-engine-absorb-data` というユーティリティコマンドを含んでいます。\n"
"これを使うと、既存のクラスタから別のクラスタへ直接データをコピーする事ができます。ローカルにダンプファイルを保存する必要がない場合には、この方法がおすすめで"
"す。"

msgid ""
"To copy data between two clusters, run the command *on a node of the destinati"
"on cluster*, like:"
msgstr "2つのクラスタの間でデータをコピーするには、*コピー先となるクラスタのノード上で*以下のようにコマンドを実行します:"

msgid ""
"~~~\n"
"# drndump --host=192.168.0.10 \\\n"
" --receiver-host=192.168.0.12 | \\\n"
" droonga-request --host=192.168.0.20 \\\n"
" --receiver-host=192.168.0.12\n"
"Elapsed time: 0.027541763\n"
"(on 192.168.0.11)\n"
"# droonga-engine-absorb-data --source-host=192.168.0.10 \\\n"
" --receiver-host=192.168.0.11\n"
"{\n"
" \"inReplyTo\": \"1401099940.5548894\",\n"
" \"statusCode\": 200,\n"
" \"type\": \"table_create.result\",\n"
" \"body\": [\n"
" [\n"
" 0,\n"
" 1401099940.591563,\n"
" 0.00031876564025878906\n"
" ],\n"
" true\n"
" ]\n"
" \"type\": \"table_create\",\n"
" \"dataset\": \"Default\",\n"
" \"body\": {\n"
" \"name\": \"Location\",\n"
" \"flags\": \"TABLE_PAT_KEY\",\n"
" \"key_type\": \"WGS84GeoPoint\"\n"
" }\n"
"}\n"
"...\n"
"Elapsed time: 0.008678467\n"
"{\n"
" \"inReplyTo\": \"1401099941.0794394\",\n"
" \"statusCode\": 200,\n"
" \"type\": \"column_create.result\",\n"
" \"body\": [\n"
" [\n"
" 0,\n"
" 1401099941.1154332,\n"
" 0.00027871131896972656\n"
" ],\n"
" true\n"
" ]\n"
" \"type\": \"column_create\",\n"
" \"dataset\": \"Default\",\n"
" \"body\": {\n"
" \"table\": \"Term\",\n"
" \"name\": \"store_name\",\n"
" \"type\": \"Store\",\n"
" \"flags\": \"COLUMN_INDEX|WITH_POSITION\",\n"
" \"source\": \"name\"\n"
" }\n"
"}\n"
"~~~"
msgstr ""
Expand Down
54 changes: 24 additions & 30 deletions ja/tutorial/1.0.4/dump-restore/index.md
Expand Up @@ -264,43 +264,37 @@ Elapsed time: 0.008678467
# curl "http://192.168.0.11:10041/d/select?table=Store&output_columns=name&limit=10"
[[0,1401363465.610241,0],[[[null],[]]]]

### 2つのDroongaクラスタの間でデータを複製する
### 2つのDroongaクラスタの間で直接データを複製する

複製元クラスタから複製先クラスタへデータを複製するには、以下のようなコマンドを実行します:
`droonga-engine` パッケージは `droonga-engine-absorb-data` というユーティリティコマンドを含んでいます。
これを使うと、既存のクラスタから別のクラスタへ直接データをコピーする事ができます。ローカルにダンプファイルを保存する必要がない場合には、この方法がおすすめです。

2つのクラスタの間でデータをコピーするには、*コピー先となるクラスタのノード上で*以下のようにコマンドを実行します:

~~~
# drndump --host=192.168.0.10 \
--receiver-host=192.168.0.12 | \
droonga-request --host=192.168.0.20 \
--receiver-host=192.168.0.12
Elapsed time: 0.027541763
(on 192.168.0.11)
# droonga-engine-absorb-data --source-host=192.168.0.10 \
--receiver-host=192.168.0.11
{
"inReplyTo": "1401099940.5548894",
"statusCode": 200,
"type": "table_create.result",
"body": [
[
0,
1401099940.591563,
0.00031876564025878906
],
true
]
"type": "table_create",
"dataset": "Default",
"body": {
"name": "Location",
"flags": "TABLE_PAT_KEY",
"key_type": "WGS84GeoPoint"
}
}
...
Elapsed time: 0.008678467
{
"inReplyTo": "1401099941.0794394",
"statusCode": 200,
"type": "column_create.result",
"body": [
[
0,
1401099941.1154332,
0.00027871131896972656
],
true
]
"type": "column_create",
"dataset": "Default",
"body": {
"table": "Term",
"name": "store_name",
"type": "Store",
"flags": "COLUMN_INDEX|WITH_POSITION",
"source": "name"
}
}
~~~

Expand Down
54 changes: 24 additions & 30 deletions tutorial/1.0.4/dump-restore/index.md
Expand Up @@ -258,43 +258,37 @@ After that there are two clusters: one contains `192.168.0.10` with data, anothe
# curl "http://192.168.0.11:10041/d/select?table=Store&output_columns=name&limit=10"
[[0,1401363465.610241,0],[[[null],[]]]]

### Duplicate data between two Droonga clusters
### Duplicate data between two Droonga clusters directly

To duplicate the source cluster to the destination cluster, run a command line like:
The package `droonga-engine` includes a utility command `droonga-engine-absorb-data`.
It copies all data from an existing cluster to another one directly, so it is recommended if you don't need to save dump file locally.

To copy data between two clusters, run the command *on a node of the destination cluster*, like:

~~~
# drndump --host=192.168.0.10 \
--receiver-host=192.168.0.12 | \
droonga-request --host=192.168.0.20 \
--receiver-host=192.168.0.12
Elapsed time: 0.027541763
(on 192.168.0.11)
# droonga-engine-absorb-data --source-host=192.168.0.10 \
--receiver-host=192.168.0.11
{
"inReplyTo": "1401099940.5548894",
"statusCode": 200,
"type": "table_create.result",
"body": [
[
0,
1401099940.591563,
0.00031876564025878906
],
true
]
"type": "table_create",
"dataset": "Default",
"body": {
"name": "Location",
"flags": "TABLE_PAT_KEY",
"key_type": "WGS84GeoPoint"
}
}
...
Elapsed time: 0.008678467
{
"inReplyTo": "1401099941.0794394",
"statusCode": 200,
"type": "column_create.result",
"body": [
[
0,
1401099941.1154332,
0.00027871131896972656
],
true
]
"type": "column_create",
"dataset": "Default",
"body": {
"table": "Term",
"name": "store_name",
"type": "Store",
"flags": "COLUMN_INDEX|WITH_POSITION",
"source": "name"
}
}
~~~

Expand Down

0 comments on commit 8e3777b

Please sign in to comment.