tire 0.1.7 → 0.1.8
Sign up to get free protection for your applications and to get access to all the features.
- data/README.markdown +63 -2
- data/Rakefile +5 -8
- data/examples/tire-dsl.rb +118 -21
- data/lib/tire/search.rb +3 -4
- data/lib/tire/search/query.rb +0 -3
- data/lib/tire/version.rb +1 -1
- data/test/unit/search_query_test.rb +2 -2
- data/test/unit/search_test.rb +11 -30
- data/tire.gemspec +2 -1
- metadata +42 -28
data/README.markdown
CHANGED
@@ -189,8 +189,69 @@ count for articles tagged 'php' is excluded, since they don't match the current
|
|
189
189
|
# java 1
|
190
190
|
```
|
191
191
|
|
192
|
-
|
193
|
-
|
192
|
+
Notice, that only variables from the enclosing scope are accesible.
|
193
|
+
If we want to access the variables or methods from outer scope,
|
194
|
+
we have to use a slight variation of the DSL, by passing the
|
195
|
+
`search` and `query` objects around.
|
196
|
+
|
197
|
+
```ruby
|
198
|
+
@query = 'title:T*'
|
199
|
+
|
200
|
+
Tire.search 'articles' do |search|
|
201
|
+
search.query do |query|
|
202
|
+
query.string @query
|
203
|
+
end
|
204
|
+
end
|
205
|
+
```
|
206
|
+
|
207
|
+
Quite often, we need complex queries with boolean logic.
|
208
|
+
Instead of composing long query strings such as `tags:ruby OR tags:java AND NOT tags:python`,
|
209
|
+
we can use the [_bool_](http://www.elasticsearch.org/guide/reference/query-dsl/bool-query.html)
|
210
|
+
query. In _Tire_, we build them declaratively.
|
211
|
+
|
212
|
+
```ruby
|
213
|
+
Tire.search('articles') do
|
214
|
+
query do
|
215
|
+
boolean do
|
216
|
+
should { string 'tags:ruby' }
|
217
|
+
should { string 'tags:java' }
|
218
|
+
must_not { string 'tags:python' }
|
219
|
+
end
|
220
|
+
end
|
221
|
+
end
|
222
|
+
```
|
223
|
+
|
224
|
+
The best thing about `boolean` queries is that we can easily save these partial queries as Ruby blocks,
|
225
|
+
to mix and reuse them later. So, we may define a query for the _tags_ property:
|
226
|
+
|
227
|
+
```ruby
|
228
|
+
tags_query = lambda do
|
229
|
+
boolean.should { string 'tags:ruby' }
|
230
|
+
boolean.should { string 'tags:java' }
|
231
|
+
end
|
232
|
+
```
|
233
|
+
|
234
|
+
And a query for the _published_on_ property:
|
235
|
+
|
236
|
+
```ruby
|
237
|
+
published_on_query = lambda do
|
238
|
+
boolean.must { string 'published_on:[2011-01-01 TO 2011-01-02]' }
|
239
|
+
end
|
240
|
+
```
|
241
|
+
|
242
|
+
Now, we can combine these queries for different searches:
|
243
|
+
|
244
|
+
```ruby
|
245
|
+
Tire.search('articles') do
|
246
|
+
query do
|
247
|
+
boolean &tags_query
|
248
|
+
boolean &published_on_query
|
249
|
+
end
|
250
|
+
end
|
251
|
+
```
|
252
|
+
|
253
|
+
If configuring the search payload with blocks somehow feels too weak for you, you can pass
|
254
|
+
a plain old Ruby `Hash` (or JSON string) with the query declaration to the `search` method:
|
194
255
|
|
195
256
|
```ruby
|
196
257
|
Tire.search 'articles', :query => { :fuzzy => { :title => 'Sour' } }
|
data/Rakefile
CHANGED
@@ -25,11 +25,8 @@ namespace :test do
|
|
25
25
|
end
|
26
26
|
|
27
27
|
# Generate documentation
|
28
|
-
begin
|
29
|
-
|
30
|
-
rescue LoadError
|
31
|
-
end
|
32
|
-
require 'rake/rdoctask'
|
28
|
+
begin; require 'sdoc'; rescue LoadError; end
|
29
|
+
require 'rdoc/task'
|
33
30
|
Rake::RDocTask.new do |rdoc|
|
34
31
|
rdoc.rdoc_dir = 'rdoc'
|
35
32
|
rdoc.title = "Tire"
|
@@ -58,17 +55,17 @@ namespace :web do
|
|
58
55
|
task :update => :generate do
|
59
56
|
current_branch = `git branch --no-color`.split("\n").select { |line| line =~ /^\* / }.to_s.gsub(/\* (.*)/, '\1')
|
60
57
|
(puts "Unable to determine current branch"; exit(1) ) unless current_branch
|
61
|
-
system "git
|
58
|
+
system "git checkout web"
|
62
59
|
system "cp examples/tire-dsl.html index.html"
|
63
60
|
system "git add index.html && git co -m 'Updated Tire website'"
|
64
61
|
system "git push origin web:gh-pages -f"
|
65
|
-
system "git checkout #{current_branch}
|
62
|
+
system "git checkout #{current_branch}"
|
66
63
|
end
|
67
64
|
|
68
65
|
desc "Generate the Rocco documentation page"
|
69
66
|
task :generate do
|
70
67
|
system "rocco examples/tire-dsl.rb"
|
71
|
-
html = File.read('examples/tire-dsl.html').gsub!(
|
68
|
+
html = File.read('examples/tire-dsl.html').gsub!(/>tire\-dsl\.rb</, '>tire.rb<')
|
72
69
|
File.open('examples/tire-dsl.html', 'w') { |f| f.write html }
|
73
70
|
system "open examples/tire-dsl.html"
|
74
71
|
end
|
data/examples/tire-dsl.rb
CHANGED
@@ -14,13 +14,13 @@
|
|
14
14
|
|
15
15
|
# Note, that this file can be executed directly:
|
16
16
|
#
|
17
|
-
# ruby examples/tire-dsl.rb
|
17
|
+
# ruby -I lib examples/tire-dsl.rb
|
18
18
|
#
|
19
19
|
|
20
20
|
|
21
21
|
#### Installation
|
22
22
|
|
23
|
-
# Install _Tire_ with
|
23
|
+
# Install _Tire_ with _Rubygems_:
|
24
24
|
|
25
25
|
#
|
26
26
|
# gem install tire
|
@@ -38,7 +38,7 @@ require 'tire'
|
|
38
38
|
|
39
39
|
#### Prerequisites
|
40
40
|
|
41
|
-
#
|
41
|
+
# We'll need a working and running _ElasticSearch_ server, of course. Thankfully, that's easy.
|
42
42
|
( puts <<-"INSTALL" ; exit(1) ) unless (RestClient.get('http://localhost:9200') rescue false)
|
43
43
|
|
44
44
|
[ERROR] You don’t appear to have ElasticSearch installed. Please install and launch it with the following commands:
|
@@ -82,7 +82,6 @@ Tire.index 'articles' do
|
|
82
82
|
create :mappings => {
|
83
83
|
|
84
84
|
# Specify for which type of documents this mapping should be used.
|
85
|
-
# (The documents must provide a `type` method or property then.)
|
86
85
|
#
|
87
86
|
:article => {
|
88
87
|
:properties => {
|
@@ -95,7 +94,7 @@ Tire.index 'articles' do
|
|
95
94
|
# has [more information](http://elasticsearch.org/guide/reference/mapping/index.html)
|
96
95
|
# about this. Proper mapping is key to efficient and effective search.
|
97
96
|
# But don't fret about getting the mapping right the first time, you won't.
|
98
|
-
# In most cases, the default mapping is just fine for prototyping.
|
97
|
+
# In most cases, the default, dynamic mapping is just fine for prototyping.
|
99
98
|
#
|
100
99
|
:title => { :type => 'string', :analyzer => 'snowball', :boost => 2.0 },
|
101
100
|
:tags => { :type => 'string', :analyzer => 'keyword' },
|
@@ -105,13 +104,13 @@ Tire.index 'articles' do
|
|
105
104
|
}
|
106
105
|
end
|
107
106
|
|
108
|
-
#### Bulk
|
107
|
+
#### Bulk Indexing
|
109
108
|
|
110
109
|
# Of course, we may have large amounts of data, and adding them to the index one by one really isn't the best idea.
|
111
|
-
# We can use _ElasticSearch's_ [bulk
|
110
|
+
# We can use _ElasticSearch's_ [bulk API](http://www.elasticsearch.org/guide/reference/api/bulk.html)
|
112
111
|
# for importing the data.
|
113
112
|
|
114
|
-
# So, for demonstration purposes, let's suppose we have a
|
113
|
+
# So, for demonstration purposes, let's suppose we have a simple collection of hashes to store.
|
115
114
|
#
|
116
115
|
articles = [
|
117
116
|
|
@@ -134,7 +133,7 @@ end
|
|
134
133
|
Tire.index 'articles' do
|
135
134
|
delete
|
136
135
|
|
137
|
-
# ... by
|
136
|
+
# ... by passing a block to the `import` method. The collection will
|
138
137
|
# be available in the block argument.
|
139
138
|
#
|
140
139
|
import articles do |documents|
|
@@ -152,8 +151,7 @@ end
|
|
152
151
|
|
153
152
|
# With the documents indexed and stored in the _ElasticSearch_ database, we can search them, finally.
|
154
153
|
#
|
155
|
-
#
|
156
|
-
|
154
|
+
# _Tire_ exposes the search interface via simple domain-specific language.
|
157
155
|
|
158
156
|
#### Simple Query String Searches
|
159
157
|
|
@@ -161,7 +159,7 @@ end
|
|
161
159
|
#
|
162
160
|
s = Tire.search('articles') do
|
163
161
|
query do
|
164
|
-
string "title:
|
162
|
+
string "title:one"
|
165
163
|
end
|
166
164
|
end
|
167
165
|
|
@@ -189,12 +187,14 @@ s.results.each do |document|
|
|
189
187
|
puts "* #{ document.title } [published: #{document.published_on}]"
|
190
188
|
end
|
191
189
|
|
192
|
-
#
|
193
|
-
#
|
190
|
+
# Notice, that we can access local variables from the _enclosing scope_.
|
191
|
+
# (Of course, we may write the blocks in shorter notation.)
|
194
192
|
|
195
|
-
#
|
193
|
+
# We will define the query in a local variable named `q`...
|
196
194
|
#
|
197
195
|
q = "title:T*"
|
196
|
+
# ... and we can use it inside the `query` block.
|
197
|
+
#
|
198
198
|
s = Tire.search('articles') { query { string q } }
|
199
199
|
|
200
200
|
# The results:
|
@@ -205,17 +205,50 @@ s.results.each do |document|
|
|
205
205
|
puts "* #{ document.title } [tags: #{document.tags.join(', ')}]"
|
206
206
|
end
|
207
207
|
|
208
|
-
#
|
209
|
-
#
|
208
|
+
# Often, we need to access variables or methods defined in the _outer scope_.
|
209
|
+
# To do that, we have to use a slight variation of the DSL.
|
210
|
+
#
|
211
|
+
|
212
|
+
# Let's assume we have a plain Article class.
|
213
|
+
#
|
214
|
+
class Article
|
215
|
+
|
216
|
+
# We will define the query in a class method...
|
217
|
+
#
|
218
|
+
def self.q
|
219
|
+
"title:T*"
|
220
|
+
end
|
221
|
+
|
222
|
+
# ... and wrap the _Tire_ search method.
|
223
|
+
def self.search
|
224
|
+
|
225
|
+
# Notice how we pass the `search` object around as a block argument.
|
226
|
+
#
|
227
|
+
Tire.search('articles') do |search|
|
228
|
+
|
229
|
+
# And we pass the query object in a similar matter.
|
230
|
+
#
|
231
|
+
search.query do |query|
|
232
|
+
|
233
|
+
# Which means we can access the `q` class method.
|
234
|
+
#
|
235
|
+
query.string self.q
|
236
|
+
end
|
237
|
+
end.results
|
238
|
+
end
|
239
|
+
end
|
240
|
+
|
241
|
+
# We may use any valid [Lucene query syntax](http://lucene.apache.org/java/3_0_3/queryparsersyntax.html)
|
242
|
+
# for the `query_string` queries.
|
210
243
|
|
211
|
-
# For debugging, we can display the JSON which is being sent to _ElasticSearch_.
|
244
|
+
# For debugging our queries, we can display the JSON which is being sent to _ElasticSearch_.
|
212
245
|
#
|
213
246
|
# {"query":{"query_string":{"query":"title:T*"}}}
|
214
247
|
#
|
215
248
|
puts "", "Query:", "-"*80
|
216
249
|
puts s.to_json
|
217
250
|
|
218
|
-
# Or better, we may display a complete `curl` command to recreate the request in terminal,
|
251
|
+
# Or better yet, we may display a complete `curl` command to recreate the request in terminal,
|
219
252
|
# so we can see the naked response, tweak request parameters and meditate on problems.
|
220
253
|
#
|
221
254
|
# curl -X POST "http://localhost:9200/articles/_search?pretty=true" \
|
@@ -279,8 +312,6 @@ end
|
|
279
312
|
|
280
313
|
### Complex Searching
|
281
314
|
|
282
|
-
#### Other Types of Queries
|
283
|
-
|
284
315
|
# Query strings are convenient for simple searches, but we may want to define our queries more expressively,
|
285
316
|
# using the _ElasticSearch_ [Query DSL](http://www.elasticsearch.org/guide/reference/query-dsl/index.html).
|
286
317
|
#
|
@@ -326,6 +357,71 @@ s.results.each do |document|
|
|
326
357
|
puts "* #{ document.title } [tags: #{document.tags.join(', ')}]"
|
327
358
|
end
|
328
359
|
|
360
|
+
#### Boolean Queries
|
361
|
+
|
362
|
+
# Quite often, we need complex queries with boolean logic.
|
363
|
+
# Instead of composing long query strings such as `tags:ruby OR tags:java AND NOT tags:python`,
|
364
|
+
# we can use the [_bool_](http://www.elasticsearch.org/guide/reference/query-dsl/bool-query.html)
|
365
|
+
# query.
|
366
|
+
|
367
|
+
s = Tire.search('articles') do
|
368
|
+
query do
|
369
|
+
|
370
|
+
# In _Tire_, we can build `bool` queries declaratively, as usual.
|
371
|
+
boolean do
|
372
|
+
|
373
|
+
# Let's define a `should` (`OR`) query for _ruby_,
|
374
|
+
#
|
375
|
+
should { string 'tags:ruby' }
|
376
|
+
|
377
|
+
# as well as for _java_,
|
378
|
+
should { string 'tags:java' }
|
379
|
+
|
380
|
+
# while defining a `must_not` (`AND NOT`) query for _python_.
|
381
|
+
must_not { string 'tags:python' }
|
382
|
+
end
|
383
|
+
end
|
384
|
+
end
|
385
|
+
|
386
|
+
# The search returns these documents:
|
387
|
+
#
|
388
|
+
# * One [tags: ruby]
|
389
|
+
# * Three [tags: java]
|
390
|
+
# * Four [tags: ruby, php]
|
391
|
+
#
|
392
|
+
s.results.each do |document|
|
393
|
+
puts "* #{ document.title } [tags: #{document.tags.join(', ')}]"
|
394
|
+
end
|
395
|
+
|
396
|
+
# The best thing about `boolean` queries is that we can very easily save these partial queries as Ruby blocks,
|
397
|
+
# to mix and reuse them later, since we can call the `boolean` method multiple times.
|
398
|
+
#
|
399
|
+
|
400
|
+
# Let's define the query for the _tags_ property,
|
401
|
+
#
|
402
|
+
tags_query = lambda do |boolean|
|
403
|
+
boolean.should { string 'tags:ruby' }
|
404
|
+
boolean.should { string 'tags:java' }
|
405
|
+
end
|
406
|
+
|
407
|
+
# ... and a query for the _published_on_ property.
|
408
|
+
published_on_query = lambda do |boolean|
|
409
|
+
boolean.must { string 'published_on:[2011-01-01 TO 2011-01-02]' }
|
410
|
+
end
|
411
|
+
|
412
|
+
# Now, we can use the `tags_query` on its own.
|
413
|
+
#
|
414
|
+
Tire.search('articles') { query { boolean &tags_query } }
|
415
|
+
|
416
|
+
# Or, we can combine it with the `published_on` query.
|
417
|
+
#
|
418
|
+
Tire.search('articles') do
|
419
|
+
query do
|
420
|
+
boolean &tags_query
|
421
|
+
boolean &published_on_query
|
422
|
+
end
|
423
|
+
end
|
424
|
+
|
329
425
|
# _ElasticSearch_ supports many types of [queries](http://www.elasticsearch.org/guide/reference/query-dsl/).
|
330
426
|
#
|
331
427
|
# Eventually, _Tire_ will support all of them. So far, only these are supported:
|
@@ -333,6 +429,7 @@ end
|
|
333
429
|
# * [string](http://www.elasticsearch.org/guide/reference/query-dsl/query-string-query.html)
|
334
430
|
# * [term](http://elasticsearch.org/guide/reference/query-dsl/term-query.html)
|
335
431
|
# * [terms](http://elasticsearch.org/guide/reference/query-dsl/terms-query.html)
|
432
|
+
# * [bool](http://www.elasticsearch.org/guide/reference/query-dsl/bool-query.html)
|
336
433
|
# * [all](http://www.elasticsearch.org/guide/reference/query-dsl/match-all-query.html)
|
337
434
|
# * [ids](http://www.elasticsearch.org/guide/reference/query-dsl/ids-query.html)
|
338
435
|
|
data/lib/tire/search.rb
CHANGED
@@ -9,10 +9,9 @@ module Tire
|
|
9
9
|
@options = indices.last.is_a?(Hash) ? indices.pop : {}
|
10
10
|
@indices = indices
|
11
11
|
raise ArgumentError, 'Please pass index or indices to search' if @indices.empty?
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
instance_eval(&block) if block_given?
|
12
|
+
|
13
|
+
Configuration.wrapper @options[:wrapper] if @options[:wrapper]
|
14
|
+
block.arity < 1 ? instance_eval(&block) : block.call(self) if block_given?
|
16
15
|
end
|
17
16
|
|
18
17
|
def query(&block)
|
data/lib/tire/search/query.rb
CHANGED
@@ -25,9 +25,6 @@ module Tire
|
|
25
25
|
end
|
26
26
|
|
27
27
|
def boolean(options={}, &block)
|
28
|
-
# TODO: Try to get rid of the `boolean` method
|
29
|
-
raise ArgumentError, "Please pass a block to boolean query" unless block_given?
|
30
|
-
|
31
28
|
@boolean ||= BooleanQuery.new(options)
|
32
29
|
block.arity < 1 ? @boolean.instance_eval(&block) : block.call(@boolean) if block_given?
|
33
30
|
@value[:bool] = @boolean.to_hash
|
data/lib/tire/version.rb
CHANGED
@@ -67,8 +67,8 @@ module Tire::Search
|
|
67
67
|
|
68
68
|
context "BooleanQuery" do
|
69
69
|
|
70
|
-
should "raise
|
71
|
-
|
70
|
+
should "not raise an error when no block is given" do
|
71
|
+
assert_nothing_raised { Query.new.boolean }
|
72
72
|
end
|
73
73
|
|
74
74
|
should "encode options" do
|
data/test/unit/search_test.rb
CHANGED
@@ -11,22 +11,24 @@ module Tire
|
|
11
11
|
assert_raise(ArgumentError) { Search::Search.new }
|
12
12
|
end
|
13
13
|
|
14
|
-
should "have the query method" do
|
15
|
-
assert_respond_to Search::Search.new('index'), :query
|
16
|
-
end
|
17
|
-
|
18
14
|
should "allow to pass block to query" do
|
19
15
|
Search::Query.any_instance.expects(:instance_eval)
|
20
16
|
|
21
|
-
Search::Search.new('index')
|
17
|
+
Search::Search.new('index') do
|
18
|
+
query { string 'foo' }
|
19
|
+
end
|
22
20
|
end
|
23
21
|
|
24
|
-
should "allow to pass block with argument to query
|
25
|
-
foo
|
26
|
-
|
22
|
+
should "allow to pass block with argument to query (use variables from outer scope)" do
|
23
|
+
def foo; 'bar'; end
|
24
|
+
|
27
25
|
Search::Query.any_instance.expects(:instance_eval).never
|
28
26
|
|
29
|
-
Search::Search.new('index')
|
27
|
+
Search::Search.new('index') do |search|
|
28
|
+
search.query do |query|
|
29
|
+
query.string foo
|
30
|
+
end
|
31
|
+
end
|
30
32
|
end
|
31
33
|
|
32
34
|
should "store indices as an array" do
|
@@ -253,27 +255,6 @@ module Tire
|
|
253
255
|
assert_equal( { 'terms' => { 'tags' => ['baz'] } }, query['must'].last)
|
254
256
|
end
|
255
257
|
|
256
|
-
should "allow passing variables from outer scope" do
|
257
|
-
q1 = 'foo'
|
258
|
-
q2 = 'bar'
|
259
|
-
|
260
|
-
assert_nothing_raised do
|
261
|
-
@search = Search::Search.new('index') do
|
262
|
-
query do
|
263
|
-
boolean do
|
264
|
-
must { string q1 }
|
265
|
-
must { string q2 }
|
266
|
-
end
|
267
|
-
end
|
268
|
-
end
|
269
|
-
end
|
270
|
-
|
271
|
-
hash = MultiJson.decode(@search.to_json)
|
272
|
-
query = hash['query']['bool']
|
273
|
-
|
274
|
-
assert_equal 2, query['must'].size
|
275
|
-
end
|
276
|
-
|
277
258
|
end
|
278
259
|
|
279
260
|
end
|
data/tire.gemspec
CHANGED
@@ -25,15 +25,16 @@ Gem::Specification.new do |s|
|
|
25
25
|
s.required_rubygems_version = ">= 1.3.6"
|
26
26
|
|
27
27
|
s.add_dependency "rake", ">= 0.8.0"
|
28
|
-
s.add_dependency "bundler", "~> 1.0.0"
|
29
28
|
s.add_dependency "rest-client", "~> 1.6.0"
|
30
29
|
s.add_dependency "multi_json", "~> 1.0"
|
31
30
|
s.add_dependency "activemodel", "~> 3.0"
|
32
31
|
|
32
|
+
s.add_development_dependency "bundler", "~> 1.0.0"
|
33
33
|
s.add_development_dependency "yajl-ruby", "~> 0.8.0"
|
34
34
|
s.add_development_dependency "turn"
|
35
35
|
s.add_development_dependency "shoulda"
|
36
36
|
s.add_development_dependency "mocha"
|
37
|
+
s.add_development_dependency "rdoc"
|
37
38
|
s.add_development_dependency "sdoc"
|
38
39
|
s.add_development_dependency "rcov"
|
39
40
|
s.add_development_dependency "activerecord", "~> 3.0.7"
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tire
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 11
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 8
|
10
|
+
version: 0.1.8
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Karel Minarik
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2011-06-
|
18
|
+
date: 2011-06-08 00:00:00 +02:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|
@@ -35,23 +35,23 @@ dependencies:
|
|
35
35
|
type: :runtime
|
36
36
|
version_requirements: *id001
|
37
37
|
- !ruby/object:Gem::Dependency
|
38
|
-
name:
|
38
|
+
name: rest-client
|
39
39
|
prerelease: false
|
40
40
|
requirement: &id002 !ruby/object:Gem::Requirement
|
41
41
|
none: false
|
42
42
|
requirements:
|
43
43
|
- - ~>
|
44
44
|
- !ruby/object:Gem::Version
|
45
|
-
hash:
|
45
|
+
hash: 15
|
46
46
|
segments:
|
47
47
|
- 1
|
48
|
+
- 6
|
48
49
|
- 0
|
49
|
-
|
50
|
-
version: 1.0.0
|
50
|
+
version: 1.6.0
|
51
51
|
type: :runtime
|
52
52
|
version_requirements: *id002
|
53
53
|
- !ruby/object:Gem::Dependency
|
54
|
-
name:
|
54
|
+
name: multi_json
|
55
55
|
prerelease: false
|
56
56
|
requirement: &id003 !ruby/object:Gem::Requirement
|
57
57
|
none: false
|
@@ -61,40 +61,40 @@ dependencies:
|
|
61
61
|
hash: 15
|
62
62
|
segments:
|
63
63
|
- 1
|
64
|
-
- 6
|
65
64
|
- 0
|
66
|
-
version: 1.
|
65
|
+
version: "1.0"
|
67
66
|
type: :runtime
|
68
67
|
version_requirements: *id003
|
69
68
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
69
|
+
name: activemodel
|
71
70
|
prerelease: false
|
72
71
|
requirement: &id004 !ruby/object:Gem::Requirement
|
73
72
|
none: false
|
74
73
|
requirements:
|
75
74
|
- - ~>
|
76
75
|
- !ruby/object:Gem::Version
|
77
|
-
hash:
|
76
|
+
hash: 7
|
78
77
|
segments:
|
79
|
-
-
|
78
|
+
- 3
|
80
79
|
- 0
|
81
|
-
version: "
|
80
|
+
version: "3.0"
|
82
81
|
type: :runtime
|
83
82
|
version_requirements: *id004
|
84
83
|
- !ruby/object:Gem::Dependency
|
85
|
-
name:
|
84
|
+
name: bundler
|
86
85
|
prerelease: false
|
87
86
|
requirement: &id005 !ruby/object:Gem::Requirement
|
88
87
|
none: false
|
89
88
|
requirements:
|
90
89
|
- - ~>
|
91
90
|
- !ruby/object:Gem::Version
|
92
|
-
hash:
|
91
|
+
hash: 23
|
93
92
|
segments:
|
94
|
-
-
|
93
|
+
- 1
|
95
94
|
- 0
|
96
|
-
|
97
|
-
|
95
|
+
- 0
|
96
|
+
version: 1.0.0
|
97
|
+
type: :development
|
98
98
|
version_requirements: *id005
|
99
99
|
- !ruby/object:Gem::Dependency
|
100
100
|
name: yajl-ruby
|
@@ -155,7 +155,7 @@ dependencies:
|
|
155
155
|
type: :development
|
156
156
|
version_requirements: *id009
|
157
157
|
- !ruby/object:Gem::Dependency
|
158
|
-
name:
|
158
|
+
name: rdoc
|
159
159
|
prerelease: false
|
160
160
|
requirement: &id010 !ruby/object:Gem::Requirement
|
161
161
|
none: false
|
@@ -169,7 +169,7 @@ dependencies:
|
|
169
169
|
type: :development
|
170
170
|
version_requirements: *id010
|
171
171
|
- !ruby/object:Gem::Dependency
|
172
|
-
name:
|
172
|
+
name: sdoc
|
173
173
|
prerelease: false
|
174
174
|
requirement: &id011 !ruby/object:Gem::Requirement
|
175
175
|
none: false
|
@@ -183,9 +183,23 @@ dependencies:
|
|
183
183
|
type: :development
|
184
184
|
version_requirements: *id011
|
185
185
|
- !ruby/object:Gem::Dependency
|
186
|
-
name:
|
186
|
+
name: rcov
|
187
187
|
prerelease: false
|
188
188
|
requirement: &id012 !ruby/object:Gem::Requirement
|
189
|
+
none: false
|
190
|
+
requirements:
|
191
|
+
- - ">="
|
192
|
+
- !ruby/object:Gem::Version
|
193
|
+
hash: 3
|
194
|
+
segments:
|
195
|
+
- 0
|
196
|
+
version: "0"
|
197
|
+
type: :development
|
198
|
+
version_requirements: *id012
|
199
|
+
- !ruby/object:Gem::Dependency
|
200
|
+
name: activerecord
|
201
|
+
prerelease: false
|
202
|
+
requirement: &id013 !ruby/object:Gem::Requirement
|
189
203
|
none: false
|
190
204
|
requirements:
|
191
205
|
- - ~>
|
@@ -197,11 +211,11 @@ dependencies:
|
|
197
211
|
- 7
|
198
212
|
version: 3.0.7
|
199
213
|
type: :development
|
200
|
-
version_requirements: *
|
214
|
+
version_requirements: *id013
|
201
215
|
- !ruby/object:Gem::Dependency
|
202
216
|
name: supermodel
|
203
217
|
prerelease: false
|
204
|
-
requirement: &
|
218
|
+
requirement: &id014 !ruby/object:Gem::Requirement
|
205
219
|
none: false
|
206
220
|
requirements:
|
207
221
|
- - ">="
|
@@ -211,11 +225,11 @@ dependencies:
|
|
211
225
|
- 0
|
212
226
|
version: "0"
|
213
227
|
type: :development
|
214
|
-
version_requirements: *
|
228
|
+
version_requirements: *id014
|
215
229
|
- !ruby/object:Gem::Dependency
|
216
230
|
name: sqlite3
|
217
231
|
prerelease: false
|
218
|
-
requirement: &
|
232
|
+
requirement: &id015 !ruby/object:Gem::Requirement
|
219
233
|
none: false
|
220
234
|
requirements:
|
221
235
|
- - ">="
|
@@ -225,7 +239,7 @@ dependencies:
|
|
225
239
|
- 0
|
226
240
|
version: "0"
|
227
241
|
type: :development
|
228
|
-
version_requirements: *
|
242
|
+
version_requirements: *id015
|
229
243
|
description: " Tire is a Ruby client for the ElasticSearch search engine/database.\n\n It provides Ruby-like API for fluent communication with the ElasticSearch server\n and blends with ActiveModel class for convenient usage in Rails applications.\n\n It allows to delete and create indices, define mapping for them, supports\n the bulk API, and presents an easy-to-use DSL for constructing your queries.\n\n It has full ActiveRecord/ActiveModel compatibility, allowing you to index\n your models (incrementally upon saving, or in bulk), searching and\n paginating the results.\n"
|
230
244
|
email: karmi@karmi.cz
|
231
245
|
executables: []
|