Skip to content

Instantly share code, notes, and snippets.

@ongaeshi
Last active August 29, 2015 14:16
Show Gist options
  • Save ongaeshi/5171935a133cb1134a80 to your computer and use it in GitHub Desktop.
Save ongaeshi/5171935a133cb1134a80 to your computer and use it in GitHub Desktop.
Groonga 4.0.3 to 5.0.0 test (on Windows)

概要

  • Groonga 5.0.0 のインストールは成功
  • GRN_IO_VERSION=1にして、古いバージョンのデータベースを開こうとしたら動かなかった(command.log)
    • 古いデータベースとの互換性は上手くいっていない気がする
    • 検索しようとしてGroongaに問い合わせるとエラーが出る印象
  • milk rebuild -all してデータベースを作り直したら上手く動いた
    • ディスク容量はとても小さくなった
    • 心なしか動作も軽快な気もする
    • 一週間ほど新データベースで動かした感じ、ちゃんと動いている模様

環境

$ ruby -v
ruby 2.0.0p481 (2014-05-08) [i386-mingw32]

$ gem list rroonga
rroonga (5.0.0 x86-mingw32, 4.0.3 x86-mingw32)

ディスク容量

  • 旧システム: 4.25 GB
  • 新データベースでrebuild-all: 1.50 GB
$ milk list
DL is deprecated, please use Fiddle
project_1
project_2
$ gmilk -a test
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/common/util.rb:229:in `sort': invalid argument: result is not a array: #<Groonga::Hash id: <2147483649>, name: (anonymous), path: (temporary), domain: <documents>, range: (nil), flags: <WITH_SUBREC>, size: <0>, encoding: <:utf8>, default_tokenizer: (nil), token_filters: [], normalizer: (nil)> (Groonga::InvalidArgument)
db.c:10223: grn_table_sort()
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/common/util.rb:229:in `groonga_table_sort'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/database/document_table.rb:330:in `search_with_match'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/database/document_table.rb:342:in `search'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/grep/findgrep.rb:212:in `searchDatabase'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/grep/findgrep.rb:152:in `pickupRecords'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/grep/cli_grep.rb:221:in `execute_in'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/grep/cli_grep.rb:20:in `execute'
from C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/bin/gmilk:11:in `<top (required)>'
from C:/app/ruby/bin/gmilk:23:in `load'
from C:/app/ruby/bin/gmilk:23:in `<main>'
$ milk web
DL is deprecated, please use Fiddle
SECURITY WARNING: No secret option provided to Rack::Session::Cookie.
This poses a security threat. It is strongly recommended that you
provide a secret to prevent exploits that may be possible from crafted
cookies. This will not be supported in future versions of Rack, and
future versions will even invalidate your existing user cookies.
Called from: C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/builder.rb:86:in `new'.
[deprecated] I18n.enforce_available_locales will default to true in the future. If you really want to skip validation of your locale you can set I18n.enforce_available_locales = false to avoid this message.
127.0.0.1 - - [05/Mar/2015 17:21:25] "GET / HTTP/1.1" 200 4848 0.4730
127.0.0.1 - - [05/Mar/2015 17:21:25] "GET /css/milkode.css HTTP/1.1" 200 3930 0.0590
127.0.0.1 - - [05/Mar/2015 17:21:25] "GET /js/milkode.js HTTP/1.1" 200 6709 0.0210
127.0.0.1 - - [05/Mar/2015 17:21:29] "POST /search HTTP/1.1" 303 - 0.0430
Groonga::InvalidArgument - invalid argument: result is not a array: #<Groonga::Hash id: <2147483652>, name: (anonymous), path: (temporary), domain: <documents>, range: (nil), flags: <WITH_SUBREC>, size: <0>, encoding: <:utf8>, default_tokenizer: (nil), token_filters: [], normalizer: (nil)>
db.c:10223: grn_table_sort():
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/common/util.rb:229:in `sort'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/common/util.rb:229:in `groonga_table_sort'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/database/document_table.rb:330:in `search_with_match'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cdweb/lib/database.rb:96:in `search'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cdweb/lib/search_contents.rb:49:in `initialize'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cdweb/lib/command.rb:77:in `new'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cdweb/lib/command.rb:77:in `search'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cdweb/app.rb:124:in `block in <top (required)>'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1602:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1602:in `block in compile!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:966:in `[]'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:966:in `block (3 levels) in route!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:985:in `route_eval'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:966:in `block (2 levels) in route!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1006:in `block in process_route'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1004:in `catch'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1004:in `process_route'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:964:in `block in route!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:963:in `each'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:963:in `route!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1076:in `block in dispatch!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in `block in invoke'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in `catch'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in `invoke'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1073:in `dispatch!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:898:in `block in call!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in `block in invoke'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in `catch'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1058:in `invoke'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:898:in `call!'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:886:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/xss_header.rb:18:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/path_traversal.rb:16:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/json_csrf.rb:18:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/base.rb:49:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-protection-1.5.3/lib/rack/protection/frame_options.rb:31:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:225:in `context'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/session/abstract/id.rb:220:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/logger.rb:15:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:210:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/head.rb:11:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/methodoverride.rb:21:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/show_exceptions.rb:21:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:180:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:2014:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1478:in `block in call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1788:in `synchronize'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:1478:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/builder.rb:138:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/urlmap.rb:65:in `block in call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/urlmap.rb:50:in `each'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/urlmap.rb:50:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/lint.rb:49:in `_call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/lint.rb:37:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/showexceptions.rb:24:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/commonlogger.rb:33:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/sinatra-1.4.5/lib/sinatra/base.rb:217:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/chunked.rb:43:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/content_length.rb:14:in `call'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/connection.rb:86:in `block in pre_process'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/connection.rb:84:in `catch'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/connection.rb:84:in `pre_process'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/connection.rb:53:in `process'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/connection.rb:39:in `receive_data'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/eventmachine-1.0.3-x86-mingw32/lib/eventmachine.rb:187:in `run_machine'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/eventmachine-1.0.3-x86-mingw32/lib/eventmachine.rb:187:in `run'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/backends/base.rb:73:in `start'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thin-1.6.2/lib/thin/server.rb:162:in `start'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/handler/thin.rb:16:in `run'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/rack-1.5.2/lib/rack/server.rb:264:in `start'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cdweb/cli_cdweb.rb:33:in `execute_with_options'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cli.rb:202:in `web'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thor-0.19.1/lib/thor/command.rb:27:in `run'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thor-0.19.1/lib/thor/invocation.rb:126:in `invoke_command'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/lib/milkode/cli.rb:263:in `invoke_command'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thor-0.19.1/lib/thor.rb:359:in `dispatch'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/thor-0.19.1/lib/thor/base.rb:440:in `start'
C:/app/ruby/lib/ruby/gems/2.0.0/gems/milkode-1.8.5/bin/milk:9:in `<top (required)>'
C:/app/ruby/bin/milk:23:in `load'
C:/app/ruby/bin/milk:23:in `<main>'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment