How to get same ordered data from elasticsearch as it was indexed

I would like to retrieve documents from elasticsearch in the same order as it was indexed. Timestamp won't work because there will be collisions.
Sequence number won't work because it is unique only per shard.
Does elasticsearch provide such a feature out of the box?

You could create your own indexed timestamp using an ingest pipeline.

1 Like

Welcome to our community! :smiley:

There's nothing in Elasticsearch natively to do this, you would need to create and manage your own sequence ID.

Thank you warkolm, That is probably the solution I am going with :smiley:

Thank you @ritchierich, I wasn't aware about ingest pipelines

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