lttkgp / R2-D2

Facebook connector for C-3PO
MIT License
7 stars 4 forks source link

Support MongoDB as an alternate data store #7

Open ghostwriternr opened 3 years ago

ghostwriternr commented 3 years ago

Not everyone has access to AWS. MongoDB is free and Open Source, so R2-D2 should be extended to allow the use of either data stores. This won't be straightforward but could be a pretty interesting task : )

feildrixliemdra commented 3 years ago

hi there @ghostwriternr I'd like to help this as a participant of Hacktoberfest. Does this enhancement mean to

  1. add mongodb image in docker-compose for local development
  2. create connection to mongodb from the golang app

Please correct me or add more detail if my opinion above is incorrect. Thanks

ghostwriternr commented 3 years ago

Hi @feildrixliemdra! The goal of this issue is to enable R2-D2 to use MongoDB as a datastore instead of DynamoDB, since DynamoDB is AWS exclusive. Support for MongoDB can enable deployment of R2-D2 completely in non-AWS environments.

So, this would require writing a clean abstration over the DB layer that can be extended by Mongo/Dynamo and have a config that controls which DB will be used. Adding docker-compose support would be an addition after this is done, so that local development becomes easy.

Let me know if you have any further questions! 😄

feildrixliemdra commented 3 years ago

i got it, i think i can help this but i need some time. I will update this through this pr #18 . I tried to run the apps but the documentation only tell to copy the env and docker-compose up while it return errors. If you can provide steps to run R2-D2 apps locally that would be great! thanks @ghostwriternr