Browsed by
Tag: mysql

Boosting Availability and Performance: How to Load Balance a Node API Gateway with Docker

Boosting Availability and Performance: How to Load Balance a Node API Gateway with Docker

Load balancing is an important technique for scaling web applications and ensuring their reliability and availability. In a microservices architecture, a common pattern is to use an API gateway to route incoming requests to the appropriate service instances. However, as the traffic grows, a single API gateway instance may become a bottleneck and a single point of failure. To avoid these issues, we can use multiple API gateway instances and distribute the traffic among them using a load balancer.

In this post, we’ll explore how to set up a load-balanced API gateway using Node.js and Docker. We’ll use Docker Compose to define multiple instances of the API gateway and a load balancer, and we’ll configure the load balancer to distribute the traffic among the instances using a round-robin algorithm.

Read More Read More

Cloud RADIUS: How to Build a Highly-Available and Secure Authentication Cluster

Cloud RADIUS: How to Build a Highly-Available and Secure Authentication Cluster

Creating a high availability (HA) RADIUS cluster in the cloud is a complex but crucial step for ensuring that your network authentication and authorization services are always available to your customers. In this blog post, I will discuss the right way to create a HA RADIUS cluster in the cloud.

High availability RADIUS cluster

Read More Read More

Building a real-time power monitoring dashboard

Building a real-time power monitoring dashboard

Like so many other people in South Africa, the unreliability of our power grid have forced me into taking the plunge and investing in an inverter with a lithium backup battery.

TL;DR

I used a raspberrypi to retrieve modbus data from the SunSynk inverter via a custom RS485 RJ45 to USB cable, logged the data into a MySQL table via a Nodejs app, and then used Grafana to display the data in a custom dashboard.

Read More Read More