Elasticsearch is open-source and NoSQL based distributed search engine which is written in JAVA.
It is designed for high-performance searches on large data.
For data storing it uses indexes which is the collection of different types of document and properties.
Compares to the relational database is very fast.
- A relational database consists of –
Databases -> Tables -> Row/Columns - But the Elasticsearch consists of –
Indices -> Types -> Documents with properties
To communicate with it requires REST APIs.
It is supported by various languages – JAVA, PHP, Python, JavaScript, Node.js and many others.
In this tutorial, I am using XAMPP for its installation.
Contents
1. Download
- If Java is not installed on your system then download the JAVA SDK from here. and install it. Restart the system to set the
JAVA_HOME
environment variable. - Download Elasticsearch zip file from its Offical website.
2. Start
- Extract the downloaded zip file in
htdocs
folder e.g.htdocs\elasticsearch-5.6.3
. - Now to start the Elasticsearch need to run the
elasticsearch.bat
file using Command Prompt. - Open Command Prompt and navigate to the elasticsearch bin directory.
C:\>cd xampp\htdocs\elasticsearch-5.6.3\bin C:\xampp\htdocs\elasticsearch-5.6.3\bin>elasticsearch
- Now it is started.
3. Check
To check it is running or not open localhost:9200
in your browser.
You will see the similar type of output where it shows version details, tagline, etc.
4. Conclusion
It is better to use it when there is the huge number of data and require to retrieve data very fastly.
You have first need to run the elasticsearch.bat
file if it is not running to starting working with Elasticsearch.