You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"## Custom settings to apply when creating the index (optional)
elasticsearch.index.settings="{'_ttl' : { 'enabled' : true, 'default' : '60s' }"
But results are still searchable even after hour. is there need for another setting or have i set it with some kind of annotation? Currently have only one annotation
"@IndexType(name = "searchResult")
public class SearchResult extends Index { ..."
Or maybe is missing specification for timestamp (also some kind of annotation?)
Tnx for help.
The text was updated successfully, but these errors were encountered:
Hello again, above code work well but i got to special situation. I reindex whole search every 4 hours
SearchResult searchResult = new SearchResult();
...
searchResult.index();
Always using same ids. I also have 12 ttl by annotation.
Expected : items that are not reindexed by "searchResult.index();" will expire after 12h others wil stay.
Reality : All items get deleted after 12h, even if they are reindexed 3 times.
How can i set "ttl" "time to live" on index (so all results older than 60s would get removed from search for example https://www.elastic.co/guide/en/elasticsearch/reference/current/mapping-ttl-field.html)
i tried to use custom settings part:
"## Custom settings to apply when creating the index (optional)
elasticsearch.index.settings="{'_ttl' : { 'enabled' : true, 'default' : '60s' }"
But results are still searchable even after hour. is there need for another setting or have i set it with some kind of annotation? Currently have only one annotation
"@IndexType(name = "searchResult")
public class SearchResult extends Index { ..."
Or maybe is missing specification for timestamp (also some kind of annotation?)
Tnx for help.
The text was updated successfully, but these errors were encountered: