3 curl -XDELETE 'http://localhost:9200/twitter'
5 curl -XPUT 'http://localhost:9200/twitter'
7 curl -XPUT 'http://localhost:9200/twitter/_mapping' -d '{
9 "date_formats": ["date_time", "yyyyMMddHHmmss", "yyyyMMddHHmmssSSS"],
11 "user" : { "type" : "string", "index" : "not_analyzed" },
12 "message" : { "type" : "string" },
13 "postDate" : { "type" : "date" },
14 "srcAddr" : { "type" : "ip" },
15 "priority" : { "type" : "integer", null_value: 1 },
16 "rank" : { "type" : "float", null_value: 1.0 },
17 "loc" : { "type": "geo_point" }
22 curl -XPUT 'http://localhost:9200/twitter/tweet/1' -d '{
24 "message" : "developing a tool to search with",
25 "postDate" : "20110220100330",
26 "srcAddr" : "203.19.74.11",
27 "loc" : "-37.86,144.90"
30 curl -XPUT 'http://localhost:9200/twitter/tweet/2' -d '{
32 "message" : "you know, for elastic search",
33 "postDate" : "20110220095900",
34 "srcAddr" : "203.19.74.11",
35 "loc" : "-37.86,144.90"
38 curl -XPUT 'http://localhost:9200/twitter/tweet/3' -d '{
40 "message" : "lets take some matilda bay",
41 "postDate" : "20110221171330",
42 "srcAddr" : "203.19.74.11",
43 "loc" : "-37.86,144.90"