My full-text search is not working properly and also it's taking too much time to execute elasticsearch query I am using following code to get the data from elasticsearch using java.
where pageable and query is the parameter coming from the front end and Jankalyan_new is my index name.
If I type Bangalore in the search text field it is giving other address data on the top and after that Bangalore address data is coming which is wrong. could you please suggest me is I am going correctly? if correct then why its giving wrong result and taking too much time. And If I am going wrong then could you please suggest me a better solution on the same?
Could you provide a full recreation script as described in About the Elasticsearch category. It will help to better understand what you are doing. Please, try to keep the example as simple as possible.
A full reproduction script will help readers to understand, reproduce and if needed fix your problem. It will also most likely help to get a faster answer.
I have missed this line from code
searchResponse = restHighLevelClient.search(searchRequest);
using this response I am returning a string from rest API and It's simple text search query where I have added sort filter also to get records in sorted order.
My problem is getting wrong result and taking too much time for execution.
you can go through www.jankalyan.online website there is search field we have provided. We want data from elastic search who will match with the text entered in search input text field. I have written service in java for the same. Above code is present in that but its not working correctly means getting wrong result. I have given bangalore search text example before.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.