Engineering/Elasticsearch 3

Elasticsearch 기본 REST API

도큐멘트(document) 추가: 생성할때는 메소드 핸들러를 PUT 으로 할수도 있지만, 아래 예와 같이 id 값을 지정할때 POST 로 메소드를 선택해야 한다. $ curl -XPOST 'localhost:9200/books/es/1' -d '{"title":"Elasticsearc Server", "published": 2013}'$ curl -XPOST 'localhost:9200/books/es/2' -d '{"title":"Mastering Elasticsearch", "published": 2013}'$ curl -XPOST 'localhost:9200/books/solr/1' -d '{"title":"Apache Solr 4 Cookbook", "published": 2012}' 인덱스 맵핑..

Elasticsearch cluster 테스트

Elasticsearch 의 클러스터 기능 테스트를 위해 같은 네트워크인 두대의 서버에서 같은 버전의 ES(Elasticsearch) 를 실행했다.config/elasticsearch.yml 에서 cluster.name 을 기본값은 elasticsearch 으로 설정했다. - Primary : 192.168.1.230/255.255.254.0/Users/firstboos/Downloads/elasticsearch-1.4.0/bin$ ./elasticsearch[2014-11-25 16:01:48,245][INFO ][node ] [Prodigy] version[1.4.0], pid[16096], build[bc94bd8/2014-11-05T14:26:12Z][2014-11-25 16:01:48,245][..