Elasticsearch Study Notes

Source: Internet
Author: User
Tags cassandra

Only need JDK, download unzip can, best modified under ELASTICSEARCH.YML

Cluster.namenode.name

ES has a very rich plugin, it is recommended to install the following several

Bigdesk

resource monitoring and cluster management plug-in bin/plugin-install lukas-vlcek/bigdeskhttp://127.0.0.1:9200/_plugin/ Bigdesk

Elasticsearch-head

data Query Plugin bin/plugin-install mobz/elasticsearch-headhttp://localhost:9200/_plugin/ head/

Elasticsearch-inquisitor

plugin for debugging query statements bin/plugin-install polyfractal/elasticsearch-inquisitorhttp://  localhost:9200/_plugin/inquisitor/

ES is a document database, and an analogy to a general RDBMS

relational database     ⇒ database ⇒ table    ⇒ row    ⇒ column (Columns) Elasticsearch  ⇒ index   ⇒ type  ⇒ document  ⇒ field (fields)

Specific can be viewed through the head plugin

Build 3 test data

put/megacorp/employee/1{    "first_name":"John",    "last_name":"Smith",    " Age": -,    " About":"I love to go rock climbing",    "Interests": ["Sports","Music"]}put/megacorp/employee/2{    "first_name":"Jane",    "last_name":"Smith",    " Age": +,    " About":"I like to collect rock albums",    "Interests":  ["Music"]}put/megacorp/employee/3{    "first_name":"Douglas",    "last_name":"Fir",    " Age": *,    " About":"I like to build cabinets",    "Interests":  ["Forestry" ]}

The query of ES is very powerful, for example, a fuzzy query that makes Cassandra Egg ache.

{  "query":    {"wildcard":      {  "last_name""*mi*"}}  } 

One more and a query

{  "Query": {    "BOOL": {      "must": [        {          "Wildcard": {            "last_name":"*mi*"          }        },        {          "Match": {            "first_name":"John"          }        }      ]    }  }}

About ES cluster, although the master-slave configuration, but use, basically do not need to consider these problems, Master,slave switch is ES internal processing, completely transparent to the outside, can be viewed with bigdesk plug-in; Cluster support dynamic add nodes, and Cassandra almost, Very convenient.

When you create an index (database), you can specify the number of shards and replicas, or you can dynamically modify the number of replicas, which is useful when you need to scale out.

Paste a great God's translation, thank him very much for his hard work

http://fuxiaopang.gitbooks.io/learnelasticsearch/

Elasticsearch Study Notes

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.