Steps for Configuring AWS Elastic Search
Step 1: Sign up with your AWS account or create a new AWS account on it , the button will be present on the top right corner.
Step 2: While creating the account provide all the essential details asked and after filling each one correctly , Click on the CONTINUE Button.
After setting up everything and Configuring your Domain, we will proceed towards Step number 3
Step 3: Is to Upload the data for the Indexing Purpose,By the help of command line interface, Upload data to Amazon EC2 domain service On your Windows operating system , CURL can be installed to use as cmd (command promt), but. the best and the most recommended operating system is the LINUX OS.
Apply and execute the code command mentioned below as the the first document
Code:
C++
curl -XPUT -u master-user:master-user-password domain-endpoint/books/_doc/1 '{ "book_name" : "Know your Worth" , "author" : [ "NK Sondhi" , "Vibha Malhotra" ], "publisher" : "General Press" , "publishing_date" : "Feburary 2017" , "ISBN" : "8180320235" , "length" : "224 pages" }' -H 'Content-Type: application/json' |
Now, multiple documents of json file . Just user has to copy and paste these commands.
C++
{ "index" : { "_index" : "books" , "_id" : "2" } } { "book_name" : "The End of Imagination" , "author" : "Arundhati Roy" , "publisher" : "Haymarket Books" , "publishing_date" : "December 1998" , "ISBN" : "9781608466191" , "length" : "408 pages" } { "index" : { "_index" : "books" , "_id" : "3" } } { "book_name" : "Power of Positive Thinking" , "author" : "Norman Vincent Peale" , "publisher" : "Prentice Hall" , "publishing_date" : "October 1952" , "ISBN" : "9780671635305" , "length" : "240 pages" } |
Step 4: Search document through the command line and execute the below code mentioned
C++
curl XGET -u master-user:master-user-password 'domain-endpoint/books/_search?q=technical&pretty=true' |
Alternative Python code for the same are mentioned below:
How to Configure AWS Elasticsearch For Full-Text Search?
The Elasticsearch built on Apache Lucene is a search and analytics engine . Since from its release in (2010), Elasticsearch has become one of the most popular search engine and a compulsion used for log analytics, full-text search, security intelligence and operational intelligence cases. To ensure that the open source community and our customers continue to have a secure, high-quality, fully open source search and analytics suite, AWS has introduced the OpenSearch project. The data can be in the form of JSON documents to Elasticsearch using the API like the Logstash and Amazon Kinesis Firehose.