Deploy app with NoSQL database - node.js

I usually work with relational databases. Recently I've been learning how to use NoSQL : More precisely MongoDB with NodeJS.
Due to my experience with relational databases; If we code an application locally, when we deploy our application we have to also host the relational database on the server (or a server) in order to be able to connect them.
Now with NodeJS I created a basic app that communicates with a database and one collection in MongoDB. I published my NodeJS app on a debian server and it is now online and running.
What I am wondering about is if there is the same procedure for NoSQL that exists for relational databases :
Should I deploy the DB / publish it to the server? and if so what is the procedure?
Thank you and sorry I am still a beginner at this

Related

How to connect to a SnappDb from NodeJs?

I'm creating a database visualizer in the React/Node app to connect the different databases. I'm able to connect all the standard databases, MySQL, MSSQL, Postgres, Cassandra, etc. I'm looking for the connector for SnappyDb for nodeJs which I didn't get on Google but it is available for Java (JDBC). Any suggestions or alternative approaches appreciated.

Electron Desktop Application communicating with remote NoSql server

I've begun to dive into developing a desktop application with electron. I have been interested in pairing this application with a NoSQL database to create users, display data, and do CRUD operations. I've considered databases such as MongoDB and CouchDB, and I'm curious if creating a desktop application that communicates with a database hosted elsewhere is a feasible goal.
I'm hoping that someone here can help direct me to great resources on creating a desktop application that works with a remote NoSQL database. Any advice here would be greatly appreciated!
I recommend the use of CouchDB, which uses a JSON based document format. CouchDB bundles the server and data storage functionality in a single product, providing a REST-like HTTP interface for document insertion, updates, retrieval and deletion.
Therefore, you'll be able to interact with CouchDB directly from within the Electron desktop application. Apache CouchDB Nano is the official Node.js library for accessing CouchDB.
The following additional factors speach for CouchDB:
It is open source.
It has comprehensive documentation.
It is available for Linux, macOS and Windows.
It's easily installed and quickly set up.
It can be installed on your local computer (for development), on your own servers, or in the cloud.
It supports Mango querying language (inspired from MongoDB).
It is highly scalable.
It is shipped with Fauxton web interface that lets you create, update, delete, view and query documents on the fly.
etc.

How can I decide if I should use a NoSQL vs a SQL database engine?

I plan to build an app using Node.js as my Rest API Service and Angular for my Admin side.
I've tried to create Rest API using Node.js with MongoDB as my database server.
MongoDB is a transactional DB, not a relational DB. So my question is, is MongoDB not good as my database server because it's a transactional DB? (for storing all data let's say data for e-commerce)? How can I know which one to use, MongoDB or a regular SQL database.
Thanks for your answer.
You have a couple of concepts wrong.
First, Angular is a frontend framework not a backend. Angular runs in the browser. Perhaps you mean you will use as your "admin" panel or whatever but it's a frontend technology. It will need to talk to an API server, which is the backend part.
Second, database engine selection is chosen depending on the system non-functional requirements. There are plenty of articles you can research so that you can make the decision, such as this one from MongoDB official site. There's also a video on it too.

PouchDB with CouchDB with Node Web Api Server Layer?

Just trying to spec out a new system. We want to build a mobile app with offline storage using react-native.
We were originally going to use node and create a web api layer that worked with a MongoDB. However after looking into offline storage we found PouchDB. But pouch has to use CouchDB. So we are considering using CouchDb and having a flat db layer with all our business and data logic modelled in the apps.
However there may be some server side things that we need to do (for example pulling other records from somewhere else in the organisation).
So can we deploy a web api using node alongside CouchDb? How would this work? Totally separate or in the same node process?
So can we deploy a web api using node alongside CouchDb?
Yes, of course.
How would this work?
I'm not sure about what solution suites your needs, but one solution is to develop a web app with this tech-stack: NodeJS/Express, CouchDB/PouchDB and ReactJS/MobX. One important point about CouchDB is that, you shouldn't think about it like any other database . Basically, you don't need any server-side code to talk to CouchDB, it can all be done on the client-side with PouchDB. The live sync of PouchDB is extremely convenient at handling offline/online storage. If you're considering ReactJS, take a look at MobX.

Use SQL Server CE with node-webkit

I need to work on an old application written with WPF and MS SQL Server Compact Edition. As a requirement the app is executed from an USB stick (where also all the data is persisted) and the same should apply for the new system.
In the new application I would like to use NoSQL db to store the data (node-sqlite3 or npm-nosql). However the records currently stored on the SQL CE database must be migrated to the new db or the same SQL CE database used again (even if I prefer to avoid this option). In the latter case, I have seen there is node-mssql as database connector, but SQL Server CE is not among the supported databases.
The current SQL CE schema is extremely simple, only 4 tables and less than 300 records in total. The application is executed locally by a single user.
Is there a way to export the SQL CE database so that I can import it into the new database? Are there better databases to be used with node-webkit other than the ones aforementioned?
The driver you're looking for is:
https://www.npmjs.com/package/ce-mssql
However - I'm afraid you'll need to fork a nodejs process from your webkit application, and feature your queries through web API - this will put you at home with Angular.

Resources