-
-
Save clintongormley/fa32a01ff47b2c2377d9 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# [Wed Mar 16 16:26:13 2011] Protocol: http, Server: 192.168.5.103:9200 | |
curl -XPUT 'http://127.0.0.1:9200/test/?pretty=1' | |
# [Wed Mar 16 16:26:13 2011] Response: | |
# { | |
# "ok" : true, | |
# "acknowledged" : true | |
# } | |
# [Wed Mar 16 16:26:16 2011] Protocol: http, Server: 192.168.5.103:9200 | |
curl -XPOST 'http://127.0.0.1:9200/test/doc?pretty=1' -d ' | |
{ | |
"text" : "I have in iPhone" | |
} | |
' | |
# [Wed Mar 16 16:26:16 2011] Response: | |
# { | |
# "ok" : true, | |
# "_index" : "test", | |
# "_id" : "O9tKwG64Td2_lRhfBm_jag", | |
# "_type" : "doc", | |
# "_version" : 1 | |
# } | |
# [Wed Mar 16 16:26:27 2011] Protocol: http, Server: 192.168.5.103:9200 | |
curl -XGET 'http://127.0.0.1:9200/test/_search?pretty=1' -d ' | |
{ | |
"query" : { | |
"field" : { | |
"_all" : "*phon*" | |
} | |
} | |
} | |
' | |
# [Wed Mar 16 16:26:27 2011] Response: | |
# { | |
# "hits" : { | |
# "hits" : [ | |
# { | |
# "_source" : { | |
# "text" : "I have in iPhone" | |
# }, | |
# "_score" : 1, | |
# "_index" : "test", | |
# "_id" : "O9tKwG64Td2_lRhfBm_jag", | |
# "_type" : "doc" | |
# } | |
# ], | |
# "max_score" : 1, | |
# "total" : 1 | |
# }, | |
# "timed_out" : false, | |
# "_shards" : { | |
# "failed" : 0, | |
# "successful" : 5, | |
# "total" : 5 | |
# }, | |
# "took" : 3 | |
# } | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment