MongoDB Atlas

MongoDB Atlas

Application and Data / Data Stores / MongoDB Hosting
Needs advice
on
MongoDBMongoDB
and
MySQLMySQL

Hello, I wanna build an e-commerce website for myself and planning to build for others in the future. I really like Node.js, React, ExpressJS. But I don't know if MySQL or MongoDB is what suits me the best because at the moment I have a webhotel at a hosting provider and I like that setup, setting up emails, and having more control I guess over my situation.

But is there any way I can use MongoDB on cPanel or direct admin except using MongoDB Atlas which costs a lot of money?

Because I have a setup using React, Node, Express, and MySQL and it works kind of well when working in the direct admin panel. But I just wanna make sure I make the right decision now when I start building an e-commerce website both to be cost effective and also not have to learn too many things.

I am also open to tips for example choosing Next.js instead etc if that is actually necessary and would help me in the long run.

READ MORE
5 upvotes·89.2K views
Replies (5)
Recommends
on
MongoDB
MySQL

Why would you allow your decision to be driven by the limitations of a hosting account? MySQL is a relational database, and typically you need a solid understanding of relational database design and SQL. MongoDB as a so called "Document database" is not relational. You can associate several MongoDB collections together if you understand the basic concepts behind, it, but in general, MongoDB does not have nor require a fixed schema. It can do many of the things a relational database can do, particularly if your data fits nicely into a hierarchical structure. It also often appeals to people like yourself that are working with a javascript stack, as the interface to MongoDB is json. If you can install a package onto your host, then you should be able to use MongoDB. With that said, you can do all your development locally using Docker containers. I would not suggest that you let important design decisions be dictated by what one shared host allows you to do.

READ MORE
9 upvotes·35.3K views
Backend Developer at GBarena·
Recommends
on
MySQL

I think you should use MySQL but with php or Python because e-commerce websites needs to be fast and reliable with more admin tools and you’ll find what you need and more in e-commerce when using php or python frameworks with MySQL database.

Example: Using django (python framework) with MySQL gives you administration dashboard that you can use to edit in a lot of things and django also supports a lot of things like generating ready forms linked to the models you generated

READ MORE
5 upvotes·34.2K views
View all (5)
Needs advice
on
DjangoDjangoFirebaseFirebase
and
MongoDB AtlasMongoDB Atlas

Hi, I'm trying to build a project where companies display some of their data (mostly unstructured) that I want to store on a cloud database. And users will be able to read this data and interact with it (not much interaction tho). the primary focus on the database will be for easy access for displaying, and the data won't change a lot over a time period. I was wondering if I should 1) use Django as a framework to build on, and/or 2) use either Firebase or MongoDB Atlas as a database. In this, I am more inclined to Firebase because I will need to authenticate users and have past experience with Firebase.

READ MORE
4 upvotes·33.5K views
Replies (2)
Full Stack Web Developer ·

If your goal is to display data MongoDB is a good choice in term of storage and cost. The shared instance mostly fit entry level application.

If your unstructured data schema doesn't chance much (fields add/remove) you can even plug-in the GraphQl Api implementation with MongoDB Realm, also MongoDB Realm offer a variety of authentication providers (JWT/JWKS, apiKey, custom scheme). If you go with GraphQL you can skip Django (unless you have custom business logic) and just build a frontend app to display your data (VueJS, React, Svelte, jQuery, vanilla javascript, etc...).

READ MORE
4 upvotes·23.4K views
CTO at Voila Cab's·

If your primary focus is just storage of data and read's and not too many frequent writes, in this case you can build your API on serverless platforms ( AWS Lambda ) and store the Data in Dynamo DB's which comes with decent free tier usage. Firebase is preferably a good choice when you need real-time updates to be synced to clients ( Mobile devices or Web) .

READ MORE
1 upvote·23.6K views
Software Developer ·
Needs advice
on
ElasticsearchElasticsearch
and
MongoDB AtlasMongoDB Atlas

Confused to implement a full-text search feature for a web application. Right now we are storing all the data's in MongoDB Atlas. I know MongoDB Atlas is providing a full-text feature, but it is so limited. Our users should have the ability to search from more than 15 collections. How should I implement this in MongoDB Atlas?. While searching I found Elasticsearch cloud provides a full-text search feature. Should I move our application data from MongoDB Atlas to elastic cloud only for search?.

READ MORE
13 upvotes·14.1K views
Replies (1)
Software Engineer at Blend Labs·

Hey Balaji, What is your use case here? What will be the number of requests you will receive? I have been using Elasticsearch for some time now and don't know much about Atlas. Built on top of Lucene, Elasticsearch is designed for searching, however it can get complex to maintain in production, particularly as data grows. ES offers tons of options for full text searches, for example, ES analyzer makes it easier to write very specific queries that can pull back filtered results immediately. ES is free and open source, so if you run into any difficulties, you will have no problem finding solutions unless you are doing something very niche.

READ MORE
analyzer | Elasticsearch Guide [7.15] | Elastic (elastic.co)
4 upvotes·4 comments·4.8K views
shashank agarwal
shashank agarwal
·
October 6th 2021 at 3:11PM

Hi Balaji, I had a similar problem while designing a content app that pulled in thousands of articles each day. However, my backend was Dynamodb which is even more limited than mongoDB. I considered using Algolia for the search but that proved to be a bit expensive so finally decided to use Elasticseach but just for the search, my database was still dynamodb (MongoDB in your case).

I would send all updates/deletes etc from dynamodb to elasticsearch via ddb streams and used elasticseach as the default search for the application and also for any kind of read operations. I would not recommend using Elasticsearch as a database as it is not meant to be used as a database for various reasons. The dual approach with MongoDB/DynamoDB as the database(source of truth) and ElasticSearch as the search/read worked very well for me.

·
Reply
Balaji v
Balaji v
·
February 8th 2022 at 12:50PM

Thank you so much.

Your explanation with Dynamodb and Elasticsearch was so helpful.

·
Reply
Amit Tiwary
Amit Tiwary
·
October 6th 2021 at 4:28PM

Hi Balaji, developers use a combination of elasticsearch and a database like MySQL or MongoDB for such a scenario. So you can save the text, on which you want to add search, in elastic search with an id. This id will be linked to a collection or doc id in MongoDB. When the user searches a string, you will get the corresponding id from elasticsearch and then find the correct collection or doc id in MongoDB.

·
Reply
Balaji v
Balaji v
·
February 8th 2022 at 12:53PM

Thanks

·
Reply

For our web application's backend, we have decided to create our server using Node.js and npm as our package manager, as this allows us to utilize a developer's skills and knowledge in JS for both the frontend and backend. ExpressJS provides us an easy to learn framework that saves us effort, time and improves productivity in creating our server, while affording us room to add complexity. Passport will be used to implement Oauth2.0 authentication for our web application, allowing our users to sign in with their existing accounts (no one wants to create a remember the password for yet another account). Mongoose will be used to make calls to our backend, this framework will help make these calls more accessible and organized. We have decided to use Redis on our server for any caching we need. This will greatly speed up retrieval times and reduce calls to external sources for any data that could instead be cached on our server. Lastly, we will use Jest as our unit testing framework for our backend as it is very popular and has support for Node.js . Furthermore, this is the same testing framework we will be using for our frontend, thus allowing use quickly learn and implement testing in both frontend and backend.

We have decided to use Heroku as our hosting platform for our server. Heroku provides clear documentation and a quick and simple process to host Node.js applications with their service, along with great support with our version control Git. Furthermore, Heroku also provides a free tier, which allows us to deploy and test our web application from the beginning of development.

MongoDB is our chosen database as a NoSQL database will give us flexibility in storing different types of data and room for scaling our product. We have decided to use MongoDB Atlas to host our database. As they provide a quick and simple start up along with a free tier to host database. Thus, allowing us to rapidly test our server's uses with the database.

READ MORE
4 upvotes·83.5K views

Server side

We decided to use Python for our backend because it is one of the industry standard languages for data analysis and machine learning. It also has a lot of support due to its large user base.

  • Web Server: We chose Flask because we want to keep our machine learning / data analysis and the web server in the same language. Flask is easy to use and we all have experience with it. Postman will be used for creating and testing APIs due to its convenience.

  • Machine Learning: We decided to go with PyTorch for machine learning since it is one of the most popular libraries. It is also known to have an easier learning curve than other popular libraries such as Tensorflow. This is important because our team lacks ML experience and learning the tool as fast as possible would increase productivity.

  • Data Analysis: Some common Python libraries will be used to analyze our data. These include NumPy, Pandas , and matplotlib. These tools combined will help us learn the properties and characteristics of our data. Jupyter notebook will be used to help organize the data analysis process, and improve the code readability.

Client side

  • UI: We decided to use React for the UI because it helps organize the data and variables of the application into components, making it very convenient to maintain our dashboard. Since React is one of the most popular front end frameworks right now, there will be a lot of support for it as well as a lot of potential new hires that are familiar with the framework. CSS 3 and HTML5 will be used for the basic styling and structure of the web app, as they are the most widely used front end languages.

  • State Management: We decided to use Redux to manage the state of the application since it works naturally to React. Our team also already has experience working with Redux which gave it a slight edge over the other state management libraries.

  • Data Visualization: We decided to use the React-based library Victory to visualize the data. They have very user friendly documentation on their official website which we find easy to learn from.

Cache

  • Caching: We decided between Redis and memcached because they are two of the most popular open-source cache engines. We ultimately decided to use Redis to improve our web app performance mainly due to the extra functionalities it provides such as fine-tuning cache contents and durability.

Database

  • Database: We decided to use a NoSQL database over a relational database because of its flexibility from not having a predefined schema. The user behavior analytics has to be flexible since the data we plan to store may change frequently. We decided on MongoDB because it is lightweight and we can easily host the database with MongoDB Atlas . Everyone on our team also has experience working with MongoDB.

Infrastructure

  • Deployment: We decided to use Heroku over AWS, Azure, Google Cloud because it is free. Although there are advantages to the other cloud services, Heroku makes the most sense to our team because our primary goal is to build an MVP.

Other Tools

  • Communication Slack will be used as the primary source of communication. It provides all the features needed for basic discussions. In terms of more interactive meetings, Zoom will be used for its video calls and screen sharing capabilities.

  • Source Control The project will be stored on GitHub and all code changes will be done though pull requests. This will help us keep the codebase clean and make it easy to revert changes when we need to.

READ MORE
13 upvotes·1.6M views
Engineering Manager at Taylor and Francis·

We are in the process of building a modern content platform to deliver our content through various channels. We decided to go with Microservices architecture as we wanted scale. Microservice architecture style is an approach to developing an application as a suite of small independently deployable services built around specific business capabilities. You can gain modularity, extensive parallelism and cost-effective scaling by deploying services across many distributed servers. Microservices modularity facilitates independent updates/deployments, and helps to avoid single point of failure, which can help prevent large-scale outages. We also decided to use Event Driven Architecture pattern which is a popular distributed asynchronous architecture pattern used to produce highly scalable applications. The event-driven architecture is made up of highly decoupled, single-purpose event processing components that asynchronously receive and process events.

To build our #Backend capabilities we decided to use the following: 1. #Microservices - Java with Spring Boot , Node.js with ExpressJS and Python with Flask 2. #Eventsourcingframework - Amazon Kinesis , Amazon Kinesis Firehose , Amazon SNS , Amazon SQS, AWS Lambda 3. #Data - Amazon RDS , Amazon DynamoDB , Amazon S3 , MongoDB Atlas

To build #Webapps we decided to use Angular 2 with RxJS

#Devops - GitHub , Travis CI , Terraform , Docker , Serverless

READ MORE
19 upvotes·1 comment·4M views
Jon Senterfitt
Jon Senterfitt
·
January 29th 2021 at 7:07AM

But why not just use Contentful?

·
Reply
Shared insights
at
()

Repost

Overview: To put it simply, we plan to use the MERN stack to build our web application. MongoDB will be used as our primary database. We will use ExpressJS alongside Node.js to set up our API endpoints. Additionally, we plan to use React to build our SPA on the client side and use Redis on the server side as our primary caching solution. Initially, while working on the project, we plan to deploy our server and client both on Heroku . However, Heroku is very limited and we will need the benefits of an Infrastructure as a Service so we will use Amazon EC2 to later deploy our final version of the application.

Serverside: nodemon will allow us to automatically restart a running instance of our node app when files changes take place. We decided to use MongoDB because it is a non relational database which uses the Document Object Model. This allows a lot of flexibility as compared to a RDMS like SQL which requires a very structural model of data that does not change too much. Another strength of MongoDB is its ease in scalability. We will use Mongoose along side MongoDB to model our application data. Additionally, we will host our MongoDB cluster remotely on MongoDB Atlas. Bcrypt will be used to encrypt user passwords that will be stored in the DB. This is to avoid the risks of storing plain text passwords. Moreover, we will use Cloudinary to store images uploaded by the user. We will also use the Twilio SendGrid API to enable automated emails sent by our application. To protect private API endpoints, we will use JSON Web Token and Passport. Also, PayPal will be used as a payment gateway to accept payments from users.

Client Side: As mentioned earlier, we will use React to build our SPA. React uses a virtual DOM which is very efficient in rendering a page. Also React will allow us to reuse components. Furthermore, it is very popular and there is a large community that uses React so it can be helpful if we run into issues. We also plan to make a cross platform mobile application later and using React will allow us to reuse a lot of our code with React Native. Redux will be used to manage state. Redux works great with React and will help us manage a global state in the app and avoid the complications of each component having its own state. Additionally, we will use Bootstrap components and custom CSS to style our app.

Other: Git will be used for version control. During the later stages of our project, we will use Google Analytics to collect useful data regarding user interactions. Moreover, Slack will be our primary communication tool. Also, we will use Visual Studio Code as our primary code editor because it is very light weight and has a wide variety of extensions that will boost productivity. Postman will be used to interact with and debug our API endpoints.

READ MORE
19 upvotes·2 comments·2.1M views
John Akhilomen
John Akhilomen
·
April 1st 2020 at 3:00PM

I like the tech stack you guys have selected. You guys seem to have it all figured out, and well planned. Good luck!

·
Reply
Ne Labs
Ne Labs
·
March 9th 2020 at 12:34PM

RDBMS like Postgres can also store, index and query schemaless data as JSON fields, while also supporting relations where it makes sense. A document model is actually a downside, since usually data will still have relations, and it makes modeling them inconvenient.

·
Reply