Text
Page: 1
Droonga 分散Groongaで 快適レプリケーション生活 結城洋志 Droonga - 分散Groongaで 快適レプリケーション生活 株式会社クリアコード Powered by Rabbit 2.1.3
Page: 2
Droongaって? Distributed Groonga Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 3
要旨 1年間の進捗報告 「分散Groonga」としての Droonga 1.0.8の現状紹介 実際に試してみる (できれば) Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 4
今日話すこと 分散型データ処理エンジン Droongaの 組み込みプラグインの1つ Groongaプラグイン 使い方 Groonga v.s. Droonga Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 5
今日話さないこと Droongaの設計のこと Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 6
Part1 -Part1- 1年間の 進捗報告 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 7
昨年の発表 設計方針 実装 (当時の)現状 (当時の)今後の予定 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 8
大まかに言って 全く新しい・汎用の分散型 データ処理エンジンとして 「こういう設計でこう動きます」 「こういう事も やろうと思えばできます」 「こうやって今すぐ試せます」 という話はあまり無かった Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 9
なんで? どっちかというとフレームワーク 具体的な用途を先に 決めないと話が始まらない 全文検索をやりたいだけでも やり方がGroongaとは全く違う Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 10
ハードル高すぎ Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 11
使うとしても 設計を熟知した人が 用途ごとの最適な構成を考え ログ保存&検索用? 掲示板のバックエンド用? 丁寧な手作業でひとつひとつ セットアップ&設定 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 12
職人芸の世界 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 13
問題 ユーザにとって 気軽に試せない Groongaユーザには馴染みにくい 開発者にとって 「汎用かつ便利」は作るのが大変 Groongaユーザを長く放置してしまう Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 14
当初の開発方針 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 15
進め方を見直し Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 16
どう変わった? 変わらないこと 最終的に作る物 変わったこと 作る順番 プロジェクト外への見せ方 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 17
ここまでの成果(1) Groongaとの互換性向上 簡単インストール& セットアップ 管理コマンドによる 簡単クラスタ管理 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 18
すぐ使える $ curl "http://...engine.../install.sh" | \ sudo bash $ curl "http://...http-server.../install.sh" | \ sudo bash $ service droonga-engine start $ service droonga-http-server start $ droonga-engine-join --host=node1 \ --replica-soruce-host=node0 $ droonga-engine-join --host=node2 \ --replica-soruce-host=node0 $ curl "http://hostname:10041/d/select?..." Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 19
ここまでの成果(2) オーケストレーション (based on Serf) 一部のノードが死んでも クラスタとして動作し続ける チュートリアルの充実 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 20
結果 レプリケーションできるGroonga としてそこそこ 使えるようになってきたはず Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 21
Part2 -Part2- 分散Groonga としての Droongaの紹介 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 22
特徴 特徴 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 23
Groonga互換 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 24
データベースを分散 レプリケーション 現在の開発はここに注力 パーティショニング 現在は部分的に対応(これから改善) Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 25
レプリケーション システムの冗長性や 耐障害性が高まる Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 26
パーティショニング より多くの量のデータを管理できる Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 27
実際の性能は? Groonga v.s. Droonga ベンチマーク Wikipedia日本語版 150万ページ 全文検索+ドリルダウン キャッシュヒット率50% 詳細はリポジトリを参照 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 28
スループットの比較 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 29
レイテンシーの比較 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 30
性能の傾向 スループット性能は良好 レイテンシーは若干ある 同時接続数が多いと性能が逆転 ノード追加でGroongaの 性能上の限界を超えられる Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 31
これからのDroonga Groonga互換 Suggest(ローマ字前方一致検索) 汎用分散データ処理エンジン 完全無停止でのクラスタ構成変更 パーティショニング有りの構成 プラグイン開発をより容易に Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 32
まとめ まとめ Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 33
まとめ Droongaは汎用の 分散型データ処理エンジン 組み込みのプラグインによって レプリケーション有りの Groongaとして使える Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 34
質問? 質問? Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 35
Part3 -Part3- Droongaを 試してみよう Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 36
試してみよう インストールと起動 Groongaからのデータ移行 Groongaアプリケーションの バックエンドを Droongaに切り替え クラスタにノードを追加 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 37
ノードのセットアップ インストールスクリプト (Ubuntu、CentOS7のみ対応) # curl \ https://raw.githubusercontent.com/droonga/droonga-engine/master/install.sh | \ bash # curl \ https://raw.githubusercontent.com/droonga/droonga-http-server/master/install.sh | \ bash Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 38
サービスの起動 serviceコマンドを使用 # service droonga-engine start # service droonga-http-server start Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 39
サービスの終了 serviceコマンドを使用 # service droonga-engine stop # service droonga-http-server stop Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 40
データの移行 % sudo gem install rroonga grn2drn droonga-client % grndump --no-dump-tables /path/to/groonga/db | \ grn2drn | \ droonga-send --server=node0 \ --report-throughput) % grndump --no-dump-schema --no-dump-indexes \ /path/to/groonga/db | \ grn2drn | \ droonga-send --server=node0 \ --server=node1 \ --server=node2 \ ... --report-throughput) Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 41
アプリケーションの移行 GroongaのHTTPインターフェースと 互換性あり curl "http://hostname:10041/d/select?..." アプリケーションは接続先を Droongaに変えるだけでOK Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 42
クラスタへのノード追加 % droonga-engine-join --host=cccc \ --replica-source-host=bbbb Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 43
ノードの切り離し % droonga-engine-unjoin --host=cccc Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 44
再度まとめ Droongaは汎用の 分散型データ処理エンジン 組み込みのプラグインによって レプリケーション有りの Groongaとして使える HTTPインターフェースは Groongaと互換性有り Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 45
宣伝 宣伝 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 46
株式会社クリアコード Groonga有償サポート Groonga以外のGroonga族も Mozilla有償サポート Firefox, Thunderbird, Firefox OS その他OSS開発全般 コードリーダー育成支援 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 47
個人の活動 日経Linux誌にて シェルスクリプト 解説マンガ #!シス管系女子 連載中 Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3
Page: 48
おわり Droonga, Groonga, 株式会社クリアコード を宜しくお願いします 使用画像 写真素材 足成:秋葉原 職人のおじいちゃん by Neil_Scottuk Droonga - 分散Groongaで 快適レプリケーション生活 Powered by Rabbit 2.1.3