• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Elastic Search1.txt
 

Elastic Search1.txt

on

  • 78 views

ES details

ES details

Statistics

Views

Total Views
78
Views on SlideShare
78
Embed Views
0

Actions

Likes
0
Downloads
0
Comments
0

0 Embeds 0

No embeds

Accessibility

Categories

Upload Details

Uploaded via

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Elastic Search1.txt Elastic Search1.txt Document Transcript

    • What is ES? What is a Shard? What is a replica? http://stackoverflow.com/questions/15694724/shards-and-replicas-in-elasticsearch 1. Download elasticsearch from here http://www.elasticsearch.org/download 2. Unzip and run elasticsearch.bat 3. Open cmd and start service using below command C:elasticsearchelasticsearch-0.90.10bin>service install == once installed C:elasticsearchelasticsearch-0.90.10bin>service start 4. Download curl from here http://curl.haxx.se/dlwiz/?type=bin 5. From command prompt, navigate to curl bin path and use below commands Elasticsearch support multiple indices, as well as multiple types per index. In the below example we used an index called twitter, with two types, user and tweet. curl -XPUT http://localhost:9200/twitter/user/giri -d "{ "name" : ""Girish Gukal"" }" curl -XPUT http://localhost:9200/twitter/tweet/1 -d "{ "user": ""giri"" , "message": ""Trying out Elasticsearch, so far so good"" }" curl -XPUT http://localhost:9200/twitter/tweet/2 -d "{ "user": ""giri"" , "message": ""Another tweet"" }" curl -XGET http://localhost:9200/twitter/user/giri?pretty=true curl -XGET http://localhost:9200/twitter/tweet/1?pretty=true curl -XGET http://localhost:9200/twitter/tweet/2?pretty=true To see all tweets posted by "giri" curl -XGET http://localhost:9200/twitter/tweet/_search?q=user:giri&pretty=true To get all docs stored in an index curl -XGET http://localhost:9200/twitter/_search?pretty=true -d "{ "query" : { "matchAll" : {} } }" https://github.com/elasticsearch/elasticsearch [AM 11:32:58] Soumya: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/query-dslquery-string-query.html