barseghyanartur / graphene-elastic

Graphene Elasticsearch/OpenSearch (DSL) integration
https://pypi.org/project/graphene-elastic/
71 stars 17 forks source link

Refresh index before querying #43

Closed CarlosAmaral closed 4 years ago

CarlosAmaral commented 4 years ago

Hi @barseghyanartur ,

How do I make sure the index has been refreshed before querying? Often times, an update/save happens and I want to query right after but that collection will not come with the latest.

For reference: https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-refresh.html#docs-refresh

Thanks for your time.

barseghyanartur commented 4 years ago

Not relevant for this library, but you work with elasticsearch-dsl to update/save your ES data, you could provide a refresh (default is False).