Elasticsearch refreshing indices, but documents still don't show up in search

I'm creating some documents on an index, using bulk. I can access them using get or mget. When I did a search, those documents didn't show up. So, I decided to refresh the indices. However, in some cases, it still happens that even after refreshing, the search can't find those documents, even though they exist.

I've read the official documentation, and it seems that bulk allows for a refresh parameter, but I'm not sure if it's really what I want, or whether there's something better.

Also, this problem appears quite randomly...

Can you share a replication of the documents, query and responses you are getting so we can try to mirror what you are seeing?

Hi @warkolm, thanks for your interest in this question... I'm afraid that there's no simple minimal working example, since I'm not sure how to replicate it, and I'm dealing with proprietary data... I was hoping that there would be a simple way to deal with this, that I may have missed something simple... Right now, I had to create a while loop (I'm using the high-level python client) that only ends my function after I've confirmed the accessibility of the documents with a search/query object (with an exponential waiting time).

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.