Load Balancing of Web or Application Servers with a NodeJS load balancer (lb) application.
- Load Balancing of Web or Application Servers on AWS EC2 machine.
- The current demonstration is for an AWS EC2 instance but the NodeJS application can be run on any cloud provider VM e.g (Linode, GCP, Azure, OCI, DO, etc.) as long as the network is properly set up.
- Fast.
- Cheaper.
- Easy to deploy.
- Load requests across multiple machines globally.
- NodeJS 19+ or above (https://nodejs.org/en/download)
- To run the load balancing app:
- Download the following source files in this repository:
- appLB.js
- common.js
- config.json
- appLB.js
- Edit relevant input variables within the config.json file, as deem necessary.
- Upload the source files to the same folder on an AWS EC2 machine.
- Then, run the appLB.js script from within the folder as:
sudo node --inspect=$((9233 + $RANDOM % 100)) --trace-warnings --trace-deprecation --watch appLB.js
- Download the following source files in this repository:
Copyright © 2023. MongoExpUser