git clone <<url>>
npm install
Mongoose, mongoDB, express and node js
- Server
- Start mongo server:
mongod <path to db>
- To make our node server continuously running we used Forever. There are couple of other process managers for express app.
- Start node server:
npm run start:dev
- Start mongo server:
Command | Description |
---|---|
npm run server |
Starts the node server, but any change in server files needs restart of node server. |
npm run start:dev |
Starts the node server and forget about it. Forever will do restarting job for you. This command runs forever continuously in terminal and logs output in terminal. |
npm run forever:startdev |
Starts the node server and forget about it. Forever will do restarting job for you. This command spuns up a daemon process and logs the output at ~/.forever/ |
npm run forever:stopAll |
Stops all forever daemons and long running terminal processes |
npm run forever:restartAll |
Restart all forever daemons and long running terminal processes |
npm run forever:list |
List out details of all forever daemons and long running terminal processes |
Purge Process
Data purging is the process of freeing up space in the database or of deleting obsolete data that is not required by the system. The purge process can be based on the age of the data or the type of data.
Archive Process
Data archiving is the process of backing up the obsolete data that will be deleted during the purge process. During the archive process, data will be moved from the main transactional tables to the backup tables.
Know the deference between Purge and delete