Syncing external mongodb database info with neptune database

0

I have data in mongodb and I want to use some of the properties saved in that database to start and maintain a graph database using amazon neptune. I can use aws dms to get the initial batch of data, but how about maintaining and updating the data as it changes in mongodb? Essentially I need to keep the neptune database synced up with the mongodb database because mongodb remains my primary database. As a simple example, consider that mongodb contains, among other things, users' lists of subscribers. I want this info available for graph queries in neptune, but changes to that info are saved in mongodb primiarily so they need to be forwarded to neptune to keep neptune current. Is there a best-practice for doing something like this? The bulk loader and dms options implicitly assume that I'd be inserting large amounts of data at a time, but these may be simple small changes like one user subscribing to another user. What's the best/correct/recommended way to go about this?

1 個回答
0

You can use the Kafka Change Data Capture handler: https://www.mongodb.com/docs/kafka-connector/master/sink-connector/fundamentals/change-data-capture/

Connect that to our Managed Service for Kafka: https://docs.aws.amazon.com/msk/latest/developerguide/what-is-msk.html

Then use a Kafka Worker in Lambda to apply the necessary modification in Neptune: https://docs.aws.amazon.com/lambda/latest/dg/with-msk.html

profile pictureAWS
已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南