jeudi 3 août 2017

Laravel with MongoDB only or MongoDB + MySQL for authentication?

I'm building a Laravel app. My data requires me to have a mongoDB database, so I'm building the app with Laravel + MongoDB. Works well so far, but when condidering user authentication, I'm not sure Mongo is the best option, so I'm divided between using Mongo or having an extra Mysql database just for user auth.

Using only Mongo keeps the app simpler(just one db adapter), but it seems that saving users as json documents a bit of bad design (sorry, I come from a SQL background). Not only that, but as my data increases, seems that query calls for users would take longer and longer to return.

On the other hand, MySQL would add an extra db adapter to the app, extra server memory load to keep mysql running, and one more endpoint that can fail or crash on the long run, but I have a feeling that it would retrieve users and authenticate them faster.

Are there any big drawbacks on having my user data stored in MongoDB instead of Mysql or any great benefits in using MySQL instead of Mongo to store users?



from Newest questions tagged laravel-5 - Stack Overflow http://ift.tt/2u83c4C
via IFTTT

Aucun commentaire:

Enregistrer un commentaire