-2

I have tested google cloud function with firebase realtime database. It worked perfectly fine. But what I want to know that can I use google cloud function to send and store data in 3rd party databases like (MongoDb, Dynamodb or any SQL database)?

Not only google cloud function but the other similar services like AWS Lambda and Azure function can I do the same with these. If Yes please do share the details.

Ayush Malviya
  • 991
  • 1
  • 7
  • 20

1 Answers1

0

To answer your question: Yes, you can, provided you have access to your DB instance. As I am more familair with AWS, I will tell you strictly about AWS Lambdas.

You will have to add a library for the language of your choice in order to be able to initiate a connection. You will also need to provide credentials, preferrably as Env variables.

Now, should you do it as simple as this, the answer is "No". You will have to provide some more infrastructure as VPN connections in order not to open your DB to the world.

AlexK
  • 1,380
  • 10
  • 17
  • Thanks for the help. I have one more thing to ask can I use AWS Lambda with firebase Realtime database? – Ayush Malviya Nov 13 '18 at 05:48
  • In practice, you can use whatever you want as Lambda is just a piece of code of your liking. Bear in mind that Lambdas are stateless. Here's a similar question that can be of some help : https://stackoverflow.com/questions/37325775/amazon-lambda-to-firebase – AlexK Nov 13 '18 at 08:32