Hello, I'm testing a search engine that should retrieve documents with synonyms to the search term.
Version: 6.4.2
Example:
Search term='good'; Synonyms='right, in_effect, proficient, in_force, unspoiled'
Index: syn_search_test
Code:
PUT /syn_search_test
{
"settings": {
"index": {
"analysis": {
"filter": {
"search_synonym_filter": {
"type": "synonym",
"lenient": true,
"synonyms": ["right, in_effect, proficient, in_force, unspoiled"]
},
"analyzer": {
"search_synonyms": {
"type": "custom",
"tokenizer": "keyword",
"filter": ["lowercase", "search_synonym_filter"]
}
}
}
}
}
}
}
I'm getting the following error even after deleting and rebuilding the index with the documents:
{
"error": {
"root_cause": [
{
"type": "resource_already_exists_exception",
"reason": "index [syn_search_test/1Q38vCelTAuxVagoiKqRrg] already exists",
"index_uuid": "1Q38vCelTAuxVagoiKqRrg",
"index": "syn_search_test"
}
],
"type": "resource_already_exists_exception",
"reason": "index [syn_search_test/1Q38vCelTAuxVagoiKqRrg] already exists",
"index_uuid": "1Q38vCelTAuxVagoiKqRrg",
"index": "syn_search_test"
},
"status": 400
}
Can you tell me what am I doing wrong?
Cheers,
Rony