groonga-query-log 1.1.7 → 1.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/doc/text/news.md +7 -0
- data/lib/groonga/query-log/command/run-regression-test.rb +29 -27
- data/lib/groonga/query-log/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: aaabf9dcf5e2c0d920723823b2af18b26c294833
|
|
4
|
+
data.tar.gz: dd30e8dd1b30eaf4b6826b27d5cce8a005b04e7d
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 03c75ec34ed6ba0a8e2c847af95c6ec2394d8621eff4ad284319dc5fdf66e4cfe47f289d20e548ca9b64756038d13dda1bb36a49b52d7cc1dd480778b36a0eba
|
|
7
|
+
data.tar.gz: 76996bcc32200f01073310d6ba1ed3f4c24b8d457f51fd9818f6a3132ddcf7e57182ce762bc5df82ccebc5cd0baab5f5f03328fb701adc5ad484989e38a077ba
|
data/doc/text/news.md
CHANGED
|
@@ -184,7 +184,6 @@ module Groonga
|
|
|
184
184
|
end
|
|
185
185
|
|
|
186
186
|
def run
|
|
187
|
-
ensure_database
|
|
188
187
|
return unless @options[:run_queries]
|
|
189
188
|
|
|
190
189
|
arguments = [
|
|
@@ -213,32 +212,6 @@ module Groonga
|
|
|
213
212
|
yield
|
|
214
213
|
end
|
|
215
214
|
|
|
216
|
-
def shutdown
|
|
217
|
-
begin
|
|
218
|
-
send_command("shutdown")
|
|
219
|
-
rescue SystemCallError
|
|
220
|
-
end
|
|
221
|
-
Process.waitpid(@pid)
|
|
222
|
-
end
|
|
223
|
-
|
|
224
|
-
private
|
|
225
|
-
def find_unused_port
|
|
226
|
-
server = TCPServer.new(@host, 0)
|
|
227
|
-
begin
|
|
228
|
-
server.addr[1]
|
|
229
|
-
ensure
|
|
230
|
-
server.close
|
|
231
|
-
end
|
|
232
|
-
end
|
|
233
|
-
|
|
234
|
-
def log_path
|
|
235
|
-
@database_path.dirname + "groonga.log"
|
|
236
|
-
end
|
|
237
|
-
|
|
238
|
-
def query_log_path
|
|
239
|
-
@database_path.dirname + "query.log"
|
|
240
|
-
end
|
|
241
|
-
|
|
242
215
|
def ensure_database
|
|
243
216
|
if @options[:recreate_database]
|
|
244
217
|
FileUtils.rm_rf(@database_path.dirname.to_s)
|
|
@@ -269,6 +242,32 @@ module Groonga
|
|
|
269
242
|
end
|
|
270
243
|
end
|
|
271
244
|
|
|
245
|
+
def shutdown
|
|
246
|
+
begin
|
|
247
|
+
send_command("shutdown")
|
|
248
|
+
rescue SystemCallError
|
|
249
|
+
end
|
|
250
|
+
Process.waitpid(@pid)
|
|
251
|
+
end
|
|
252
|
+
|
|
253
|
+
private
|
|
254
|
+
def find_unused_port
|
|
255
|
+
server = TCPServer.new(@host, 0)
|
|
256
|
+
begin
|
|
257
|
+
server.addr[1]
|
|
258
|
+
ensure
|
|
259
|
+
server.close
|
|
260
|
+
end
|
|
261
|
+
end
|
|
262
|
+
|
|
263
|
+
def log_path
|
|
264
|
+
@database_path.dirname + "groonga.log"
|
|
265
|
+
end
|
|
266
|
+
|
|
267
|
+
def query_log_path
|
|
268
|
+
@database_path.dirname + "query.log"
|
|
269
|
+
end
|
|
270
|
+
|
|
272
271
|
def send_command(name)
|
|
273
272
|
Net::HTTP.start(@host, @port) do |http|
|
|
274
273
|
response = http.get("/d/#{name}")
|
|
@@ -308,6 +307,9 @@ module Groonga
|
|
|
308
307
|
end
|
|
309
308
|
|
|
310
309
|
def run
|
|
310
|
+
@old.ensure_database
|
|
311
|
+
@new.ensure_database
|
|
312
|
+
|
|
311
313
|
old_thread = Thread.new do
|
|
312
314
|
@old.run do
|
|
313
315
|
run_test
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: groonga-query-log
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.1.
|
|
4
|
+
version: 1.1.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Kouhei Sutou
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-09-
|
|
11
|
+
date: 2015-09-14 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: groonga-command-parser
|