rroonga 1.2.9 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- data/Gemfile +1 -0
- data/Rakefile +1 -0
- data/bin/grntest-log-analyze +123 -0
- data/bin/groonga-query-log-extract +117 -0
- data/ext/groonga/rb-grn-accessor.c +7 -5
- data/ext/groonga/rb-grn-array-cursor.c +1 -1
- data/ext/groonga/rb-grn-array.c +34 -44
- data/ext/groonga/rb-grn-column.c +74 -38
- data/ext/groonga/rb-grn-context.c +19 -15
- data/ext/groonga/rb-grn-database.c +47 -42
- data/ext/groonga/rb-grn-double-array-trie-cursor.c +40 -0
- data/ext/groonga/rb-grn-double-array-trie.c +530 -0
- data/ext/groonga/rb-grn-encoding-support.c +1 -1
- data/ext/groonga/rb-grn-encoding.c +1 -1
- data/ext/groonga/rb-grn-exception.c +1 -1
- data/ext/groonga/rb-grn-expression-builder.c +1 -1
- data/ext/groonga/rb-grn-expression.c +63 -51
- data/ext/groonga/rb-grn-fix-size-column.c +7 -7
- data/ext/groonga/rb-grn-hash-cursor.c +1 -1
- data/ext/groonga/rb-grn-hash.c +42 -39
- data/ext/groonga/rb-grn-index-column.c +35 -31
- data/ext/groonga/rb-grn-index-cursor.c +1 -1
- data/ext/groonga/rb-grn-logger.c +23 -18
- data/ext/groonga/rb-grn-object.c +40 -27
- data/ext/groonga/rb-grn-operator.c +1 -1
- data/ext/groonga/rb-grn-patricia-trie-cursor.c +1 -1
- data/ext/groonga/rb-grn-patricia-trie.c +122 -90
- data/ext/groonga/rb-grn-plugin.c +8 -7
- data/ext/groonga/rb-grn-posting.c +1 -1
- data/ext/groonga/rb-grn-procedure.c +1 -1
- data/ext/groonga/rb-grn-query.c +12 -12
- data/ext/groonga/rb-grn-record.c +1 -1
- data/ext/groonga/rb-grn-snippet.c +26 -19
- data/ext/groonga/rb-grn-table-cursor-key-support.c +1 -1
- data/ext/groonga/rb-grn-table-cursor.c +4 -3
- data/ext/groonga/rb-grn-table-key-support.c +23 -23
- data/ext/groonga/rb-grn-table.c +268 -153
- data/ext/groonga/rb-grn-type.c +11 -7
- data/ext/groonga/rb-grn-utils.c +4 -1
- data/ext/groonga/rb-grn-variable-size-column.c +1 -1
- data/ext/groonga/rb-grn-variable.c +2 -2
- data/ext/groonga/rb-grn-view-accessor.c +1 -1
- data/ext/groonga/rb-grn-view-cursor.c +1 -1
- data/ext/groonga/rb-grn-view-record.c +1 -1
- data/ext/groonga/rb-grn-view.c +43 -34
- data/ext/groonga/rb-grn.h +6 -2
- data/ext/groonga/rb-groonga.c +1 -1
- data/lib/groonga.rb +4 -2
- data/lib/groonga/context.rb +16 -41
- data/lib/groonga/dumper.rb +6 -4
- data/lib/groonga/expression-builder.rb +52 -26
- data/lib/groonga/grntest-log.rb +206 -0
- data/lib/groonga/pagination.rb +21 -19
- data/lib/groonga/patricia-trie.rb +7 -10
- data/lib/groonga/posting.rb +1 -1
- data/lib/groonga/query-log.rb +348 -0
- data/lib/groonga/record.rb +47 -143
- data/lib/groonga/schema.rb +679 -406
- data/lib/groonga/view-record.rb +4 -10
- data/rroonga-build.rb +1 -1
- data/test/test-array.rb +25 -4
- data/test/test-column.rb +8 -8
- data/test/test-database.rb +2 -3
- data/test/test-double-array-trie.rb +164 -0
- data/test/test-expression-builder.rb +2 -2
- data/test/test-expression.rb +10 -9
- data/test/test-gqtp.rb +2 -2
- data/test/test-hash.rb +32 -8
- data/test/test-patricia-trie.rb +34 -10
- data/test/test-query-log.rb +258 -0
- data/test/test-record.rb +6 -5
- data/test/test-schema-create-table.rb +8 -0
- data/test/test-schema.rb +491 -234
- data/test/test-table.rb +17 -24
- metadata +123 -100
- data/ext/groonga/Makefile +0 -233
data/ext/groonga/Makefile
DELETED
@@ -1,233 +0,0 @@
|
|
1
|
-
|
2
|
-
SHELL = /bin/sh
|
3
|
-
|
4
|
-
#### Start of system configuration section. ####
|
5
|
-
|
6
|
-
srcdir = /home/yue/work/rroonga/ext/groonga
|
7
|
-
topdir = /usr/include/ruby-1.9.1
|
8
|
-
hdrdir = /usr/include/ruby-1.9.1
|
9
|
-
arch_hdrdir = /usr/include/ruby-1.9.1/$(arch)
|
10
|
-
VPATH = $(srcdir):$(arch_hdrdir)/ruby:$(hdrdir)/ruby
|
11
|
-
prefix = $(DESTDIR)/usr
|
12
|
-
rubylibprefix = $(libdir)/$(RUBY_BASE_NAME)
|
13
|
-
exec_prefix = $(prefix)
|
14
|
-
vendorhdrdir = $(rubyhdrdir)/vendor_ruby
|
15
|
-
sitehdrdir = $(rubyhdrdir)/site_ruby
|
16
|
-
rubyhdrdir = $(includedir)/$(RUBY_BASE_NAME)-$(ruby_version)
|
17
|
-
vendordir = $(DESTDIR)/usr/lib/ruby/vendor_ruby
|
18
|
-
sitedir = $(DESTDIR)/usr/local/lib/site_ruby
|
19
|
-
ridir = $(datarootdir)/$(RI_BASE_NAME)
|
20
|
-
mandir = $(prefix)/share/man
|
21
|
-
localedir = $(datarootdir)/locale
|
22
|
-
libdir = $(exec_prefix)/lib
|
23
|
-
psdir = $(docdir)
|
24
|
-
pdfdir = $(docdir)
|
25
|
-
dvidir = $(docdir)
|
26
|
-
htmldir = $(docdir)
|
27
|
-
infodir = $(prefix)/share/info
|
28
|
-
docdir = $(datarootdir)/doc/$(PACKAGE)
|
29
|
-
oldincludedir = $(DESTDIR)/usr/include
|
30
|
-
includedir = $(prefix)/include
|
31
|
-
localstatedir = $(DESTDIR)/var
|
32
|
-
sharedstatedir = $(prefix)/com
|
33
|
-
sysconfdir = $(DESTDIR)/etc
|
34
|
-
datadir = $(datarootdir)
|
35
|
-
datarootdir = $(prefix)/share
|
36
|
-
libexecdir = $(prefix)/lib/ruby1.9.1
|
37
|
-
sbindir = $(exec_prefix)/sbin
|
38
|
-
bindir = $(exec_prefix)/bin
|
39
|
-
rubylibdir = $(rubylibprefix)/$(ruby_version)
|
40
|
-
archdir = $(rubylibdir)/$(arch)
|
41
|
-
sitelibdir = $(sitedir)/$(ruby_version)
|
42
|
-
sitearchdir = $(sitelibdir)/$(sitearch)
|
43
|
-
vendorlibdir = $(vendordir)/$(ruby_version)
|
44
|
-
vendorarchdir = $(vendorlibdir)/$(sitearch)
|
45
|
-
|
46
|
-
CC = gcc
|
47
|
-
CXX = g++
|
48
|
-
LIBRUBY = $(LIBRUBY_SO)
|
49
|
-
LIBRUBY_A = lib$(RUBY_SO_NAME)-static.a
|
50
|
-
LIBRUBYARG_SHARED = -l$(RUBY_SO_NAME)
|
51
|
-
LIBRUBYARG_STATIC = -l$(RUBY_SO_NAME)-static
|
52
|
-
OUTFLAG = -o
|
53
|
-
COUTFLAG = -o
|
54
|
-
|
55
|
-
RUBY_EXTCONF_H =
|
56
|
-
cflags = $(optflags) $(debugflags) $(warnflags)
|
57
|
-
optflags = -O0
|
58
|
-
debugflags = -ggdb3
|
59
|
-
warnflags = -Wextra -Wno-unused-parameter -Wno-parentheses -Wpointer-arith -Wwrite-strings -Wno-missing-field-initializers -Wno-long-long
|
60
|
-
CFLAGS = -fPIC -fno-strict-aliasing -ggdb3 -O0 -fPIC -Wall -I/tmp/local/include/groonga
|
61
|
-
INCFLAGS = -I. -I$(arch_hdrdir) -I$(hdrdir)/ruby/backward -I$(hdrdir) -I$(srcdir)
|
62
|
-
DEFS =
|
63
|
-
CPPFLAGS = -DRB_GRN_COMPILATION -DGRN_MAJOR_VERSION=1 -DGRN_MINOR_VERSION=2 -DGRN_MICRO_VERSION=1 -DHAVE_RB_ERRINFO -DHAVE_TYPE_ENUM_RUBY_VALUE_TYPE $(DEFS) $(cppflags)
|
64
|
-
CXXFLAGS = $(CFLAGS) -fno-strict-aliasing -g
|
65
|
-
ldflags = -L. -rdynamic -Wl,-export-dynamic -L/tmp/local/lib
|
66
|
-
dldflags =
|
67
|
-
ARCH_FLAG =
|
68
|
-
DLDFLAGS = $(ldflags) $(dldflags)
|
69
|
-
LDSHARED = $(CC) -shared
|
70
|
-
LDSHAREDXX = $(CXX) -shared
|
71
|
-
AR = ar
|
72
|
-
EXEEXT =
|
73
|
-
|
74
|
-
RUBY_BASE_NAME = ruby
|
75
|
-
RUBY_INSTALL_NAME = ruby1.9.1
|
76
|
-
RUBY_SO_NAME = ruby-1.9.1
|
77
|
-
arch = x86_64-linux
|
78
|
-
sitearch = $(arch)
|
79
|
-
ruby_version = 1.9.1
|
80
|
-
ruby = /usr/bin/ruby1.9.1
|
81
|
-
RUBY = $(ruby)
|
82
|
-
RM = rm -f
|
83
|
-
RM_RF = $(RUBY) -run -e rm -- -rf
|
84
|
-
RMDIRS = $(RUBY) -run -e rmdir -- -p
|
85
|
-
MAKEDIRS = /bin/mkdir -p
|
86
|
-
INSTALL = /usr/bin/install -c
|
87
|
-
INSTALL_PROG = $(INSTALL) -m 0755
|
88
|
-
INSTALL_DATA = $(INSTALL) -m 644
|
89
|
-
COPY = cp
|
90
|
-
|
91
|
-
#### End of system configuration section. ####
|
92
|
-
|
93
|
-
preload =
|
94
|
-
|
95
|
-
libpath = . $(libdir)
|
96
|
-
LIBPATH = -L. -L$(libdir)
|
97
|
-
DEFFILE =
|
98
|
-
|
99
|
-
CLEANFILES = mkmf.log
|
100
|
-
DISTCLEANFILES =
|
101
|
-
DISTCLEANDIRS =
|
102
|
-
|
103
|
-
extout =
|
104
|
-
extout_prefix =
|
105
|
-
target_prefix =
|
106
|
-
LOCAL_LIBS =
|
107
|
-
LIBS = $(LIBRUBYARG_SHARED) -lgroonga -lpthread -lrt -ldl -lcrypt -lm -lc
|
108
|
-
SRCS = rb-grn-snippet.c rb-grn-view.c rb-grn-query.c rb-grn-encoding-support.c rb-grn-record.c rb-grn-utils.c rb-grn-index-column.c rb-grn-index-cursor.c rb-grn-view-accessor.c rb-grn-object.c rb-grn-patricia-trie.c rb-grn-expression-builder.c rb-grn-variable.c rb-grn-hash-cursor.c rb-grn-fix-size-column.c rb-grn-variable-size-column.c rb-grn-table-key-support.c rb-grn-table.c rb-groonga.c rb-grn-table-cursor.c rb-grn-hash.c rb-grn-exception.c rb-grn-logger.c rb-grn-plugin.c rb-grn-encoding.c rb-grn-view-record.c rb-grn-view-cursor.c rb-grn-column.c rb-grn-procedure.c rb-grn-posting.c rb-grn-accessor.c rb-grn-operator.c rb-grn-type.c rb-grn-array.c rb-grn-patricia-trie-cursor.c rb-grn-context.c rb-grn-database.c rb-grn-array-cursor.c rb-grn-expression.c rb-grn-table-cursor-key-support.c
|
109
|
-
OBJS = rb-grn-snippet.o rb-grn-view.o rb-grn-query.o rb-grn-encoding-support.o rb-grn-record.o rb-grn-utils.o rb-grn-index-column.o rb-grn-index-cursor.o rb-grn-view-accessor.o rb-grn-object.o rb-grn-patricia-trie.o rb-grn-expression-builder.o rb-grn-variable.o rb-grn-hash-cursor.o rb-grn-fix-size-column.o rb-grn-variable-size-column.o rb-grn-table-key-support.o rb-grn-table.o rb-groonga.o rb-grn-table-cursor.o rb-grn-hash.o rb-grn-exception.o rb-grn-logger.o rb-grn-plugin.o rb-grn-encoding.o rb-grn-view-record.o rb-grn-view-cursor.o rb-grn-column.o rb-grn-procedure.o rb-grn-posting.o rb-grn-accessor.o rb-grn-operator.o rb-grn-type.o rb-grn-array.o rb-grn-patricia-trie-cursor.o rb-grn-context.o rb-grn-database.o rb-grn-array-cursor.o rb-grn-expression.o rb-grn-table-cursor-key-support.o
|
110
|
-
TARGET = groonga
|
111
|
-
DLLIB = $(TARGET).so
|
112
|
-
EXTSTATIC =
|
113
|
-
STATIC_LIB =
|
114
|
-
|
115
|
-
BINDIR = $(bindir)
|
116
|
-
RUBYCOMMONDIR = $(sitedir)$(target_prefix)
|
117
|
-
RUBYLIBDIR = $(sitelibdir)$(target_prefix)
|
118
|
-
RUBYARCHDIR = $(sitearchdir)$(target_prefix)
|
119
|
-
HDRDIR = $(rubyhdrdir)/ruby$(target_prefix)
|
120
|
-
ARCHHDRDIR = $(rubyhdrdir)/$(arch)/ruby$(target_prefix)
|
121
|
-
|
122
|
-
TARGET_SO = $(DLLIB)
|
123
|
-
CLEANLIBS = $(TARGET).so
|
124
|
-
CLEANOBJS = *.o *.bak
|
125
|
-
|
126
|
-
all: $(DLLIB)
|
127
|
-
static: $(STATIC_LIB)
|
128
|
-
.PHONY: all install static install-so install-rb
|
129
|
-
.PHONY: clean clean-so clean-rb
|
130
|
-
|
131
|
-
clean-rb-default::
|
132
|
-
clean-rb::
|
133
|
-
clean-so::
|
134
|
-
clean: clean-so clean-rb-default clean-rb
|
135
|
-
@-$(RM) $(CLEANLIBS) $(CLEANOBJS) $(CLEANFILES)
|
136
|
-
|
137
|
-
distclean-rb-default::
|
138
|
-
distclean-rb::
|
139
|
-
distclean-so::
|
140
|
-
distclean: clean distclean-so distclean-rb-default distclean-rb
|
141
|
-
@-$(RM) Makefile $(RUBY_EXTCONF_H) conftest.* mkmf.log
|
142
|
-
@-$(RM) core ruby$(EXEEXT) *~ $(DISTCLEANFILES)
|
143
|
-
@-$(RMDIRS) $(DISTCLEANDIRS)
|
144
|
-
|
145
|
-
realclean: distclean
|
146
|
-
install: install-so install-rb
|
147
|
-
|
148
|
-
install-so: $(RUBYARCHDIR)
|
149
|
-
install-so: $(RUBYARCHDIR)/$(DLLIB)
|
150
|
-
$(RUBYARCHDIR)/$(DLLIB): $(DLLIB)
|
151
|
-
@-$(MAKEDIRS) $(@D)
|
152
|
-
$(INSTALL_PROG) $(DLLIB) $(@D)
|
153
|
-
install-rb: pre-install-rb install-rb-default
|
154
|
-
install-rb-default: pre-install-rb-default
|
155
|
-
pre-install-rb: Makefile
|
156
|
-
pre-install-rb-default: Makefile
|
157
|
-
pre-install-rb: $(RUBYLIBDIR)
|
158
|
-
install-rb: $(RUBYLIBDIR)/groonga.rb
|
159
|
-
$(RUBYLIBDIR)/groonga.rb: $(srcdir)/../../lib/groonga.rb
|
160
|
-
@-$(MAKEDIRS) $(@D)
|
161
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga.rb $(@D)
|
162
|
-
pre-install-rb: $(RUBYLIBDIR)/groonga
|
163
|
-
install-rb: $(RUBYLIBDIR)/groonga/dumper.rb
|
164
|
-
$(RUBYLIBDIR)/groonga/dumper.rb: $(srcdir)/../../lib/groonga/dumper.rb
|
165
|
-
@-$(MAKEDIRS) $(@D)
|
166
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/dumper.rb $(@D)
|
167
|
-
install-rb: $(RUBYLIBDIR)/groonga/pagination.rb
|
168
|
-
$(RUBYLIBDIR)/groonga/pagination.rb: $(srcdir)/../../lib/groonga/pagination.rb
|
169
|
-
@-$(MAKEDIRS) $(@D)
|
170
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/pagination.rb $(@D)
|
171
|
-
install-rb: $(RUBYLIBDIR)/groonga/schema.rb
|
172
|
-
$(RUBYLIBDIR)/groonga/schema.rb: $(srcdir)/../../lib/groonga/schema.rb
|
173
|
-
@-$(MAKEDIRS) $(@D)
|
174
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/schema.rb $(@D)
|
175
|
-
install-rb: $(RUBYLIBDIR)/groonga/expression-builder.rb
|
176
|
-
$(RUBYLIBDIR)/groonga/expression-builder.rb: $(srcdir)/../../lib/groonga/expression-builder.rb
|
177
|
-
@-$(MAKEDIRS) $(@D)
|
178
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/expression-builder.rb $(@D)
|
179
|
-
install-rb: $(RUBYLIBDIR)/groonga/patricia-trie.rb
|
180
|
-
$(RUBYLIBDIR)/groonga/patricia-trie.rb: $(srcdir)/../../lib/groonga/patricia-trie.rb
|
181
|
-
@-$(MAKEDIRS) $(@D)
|
182
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/patricia-trie.rb $(@D)
|
183
|
-
install-rb: $(RUBYLIBDIR)/groonga/view-record.rb
|
184
|
-
$(RUBYLIBDIR)/groonga/view-record.rb: $(srcdir)/../../lib/groonga/view-record.rb
|
185
|
-
@-$(MAKEDIRS) $(@D)
|
186
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/view-record.rb $(@D)
|
187
|
-
install-rb: $(RUBYLIBDIR)/groonga/context.rb
|
188
|
-
$(RUBYLIBDIR)/groonga/context.rb: $(srcdir)/../../lib/groonga/context.rb
|
189
|
-
@-$(MAKEDIRS) $(@D)
|
190
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/context.rb $(@D)
|
191
|
-
install-rb: $(RUBYLIBDIR)/groonga/record.rb
|
192
|
-
$(RUBYLIBDIR)/groonga/record.rb: $(srcdir)/../../lib/groonga/record.rb
|
193
|
-
@-$(MAKEDIRS) $(@D)
|
194
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/record.rb $(@D)
|
195
|
-
install-rb: $(RUBYLIBDIR)/groonga/posting.rb
|
196
|
-
$(RUBYLIBDIR)/groonga/posting.rb: $(srcdir)/../../lib/groonga/posting.rb
|
197
|
-
@-$(MAKEDIRS) $(@D)
|
198
|
-
$(INSTALL_DATA) $(srcdir)/../../lib/groonga/posting.rb $(@D)
|
199
|
-
$(RUBYARCHDIR):
|
200
|
-
$(MAKEDIRS) $@
|
201
|
-
$(RUBYLIBDIR):
|
202
|
-
$(MAKEDIRS) $@
|
203
|
-
$(RUBYLIBDIR)/groonga:
|
204
|
-
$(MAKEDIRS) $@
|
205
|
-
|
206
|
-
site-install: site-install-so site-install-rb
|
207
|
-
site-install-so: install-so
|
208
|
-
site-install-rb: install-rb
|
209
|
-
|
210
|
-
.SUFFIXES: .c .m .cc .cxx .cpp .C .o
|
211
|
-
|
212
|
-
.cc.o:
|
213
|
-
$(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $<
|
214
|
-
|
215
|
-
.cxx.o:
|
216
|
-
$(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $<
|
217
|
-
|
218
|
-
.cpp.o:
|
219
|
-
$(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $<
|
220
|
-
|
221
|
-
.C.o:
|
222
|
-
$(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $<
|
223
|
-
|
224
|
-
.c.o:
|
225
|
-
$(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -c $<
|
226
|
-
|
227
|
-
$(DLLIB): $(OBJS) Makefile
|
228
|
-
@-$(RM) $(@)
|
229
|
-
$(LDSHARED) -o $@ $(OBJS) $(LIBPATH) $(DLDFLAGS) $(LOCAL_LIBS) $(LIBS)
|
230
|
-
|
231
|
-
|
232
|
-
|
233
|
-
$(OBJS): $(hdrdir)/ruby.h $(hdrdir)/ruby/defines.h $(arch_hdrdir)/ruby/config.h
|