Kouhei Sutou
null+****@clear*****
Tue Apr 8 18:54:52 JST 2014
Kouhei Sutou 2014-04-08 18:54:52 +0900 (Tue, 08 Apr 2014) New Revision: 6ba23677594e0df270a4c53023d6b36f96ccf554 https://github.com/droonga/wikipedia-search/commit/6ba23677594e0df270a4c53023d6b36f96ccf554 Message: Run protocol adapter Modified files: lib/wikipedia-search/task.rb Modified: lib/wikipedia-search/task.rb (+7 -0) =================================================================== --- lib/wikipedia-search/task.rb 2014-04-08 18:50:47 +0900 (02eaa5b) +++ lib/wikipedia-search/task.rb 2014-04-08 18:54:52 +0900 (ccc48ef) @@ -201,6 +201,7 @@ module WikipediaSearch puts("127.0.0.1:#{port}/droonga") end front_node_id = node_ids.first + pids << droonga_run_protocol_adapter(front_node_id) droonga_wait_engine_ready(front_node_id) $stdin.gets ensure @@ -266,6 +267,12 @@ module WikipediaSearch :chdir => @path.droonga.working_dir.to_s) end + def droonga_run_protocol_adapter(node_id) + spawn("droonga-http-server", + "--droonga-engine-port", droonga_port(node_id).to_s, + "--default-dataset", "Wikipedia") + end + def droonga_wait_engine_ready(node_id) port = droonga_port(node_id) 3.times do -------------- next part -------------- HTML����������������������������...Download