What is replacement for mongodb oplog in aws document db to listen to changes in collection?

913 Views Asked by At

We use oplog collection(that is present in local database) in our code to check if an event happens on a specific db and fire an event in our code.But,as aws document db doesn't support oplog as mentioned in "https://docs.aws.amazon.com/documentdb/latest/developerguide/developerguide.pdf",how can we do that?Is there an alternative approach?

1

There are 1 best solutions below

1
On BEST ANSWER

You shouldn't use oplog even with your local mongodb. This is a deprecated approach. The modern way is to use Change Streams, which is supported by Amazon DocumentDB: https://docs.aws.amazon.com/documentdb/latest/developerguide/change_streams.html