rifle 0.0.7 → 0.0.8
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +6 -3
- data/lib/rifle/rifle_client.rb +3 -0
- data/lib/rifle/version.rb +1 -1
- metadata +1 -1
data/README.md
CHANGED
@@ -10,7 +10,9 @@ Just use the gem.
|
|
10
10
|
|
11
11
|
gem 'rifle'
|
12
12
|
|
13
|
-
Now, all of your Rails based servers can write to and query the search engine using the following commands
|
13
|
+
Now, all of your Rails based servers can write to and query the search engine using the following commands.
|
14
|
+
The store method can take a hash, or a json string. The search method returns an array of hashes, each with a
|
15
|
+
urn and a payload
|
14
16
|
|
15
17
|
Rifle::Client.store('urn:monty:sketch:MP3242', {
|
16
18
|
quote: 'I would like to buy a cat license'
|
@@ -18,12 +20,13 @@ Now, all of your Rails based servers can write to and query the search engine us
|
|
18
20
|
|
19
21
|
Rifle::Client.search('Cat')
|
20
22
|
|
21
|
-
# => {
|
23
|
+
# => [{
|
22
24
|
# urn: 'urn:monty:sketch:MP3242',
|
23
25
|
# payload: {
|
24
26
|
# quote: 'I would like to buy a cat license'
|
25
27
|
# }
|
26
|
-
# }
|
28
|
+
# }]
|
29
|
+
|
27
30
|
|
28
31
|
# Payloads
|
29
32
|
|
data/lib/rifle/rifle_client.rb
CHANGED
data/lib/rifle/version.rb
CHANGED