Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/dhyanio/golb

The Lightweight, User-Friendly Load Balancer in Go
https://github.com/dhyanio/golb

Last synced: 20 days ago
JSON representation

The Lightweight, User-Friendly Load Balancer in Go

Awesome Lists containing this project

README

        

# GoLB: The Lightweight, User-Friendly Load Balancer for Testing in Go
Discache

GoLB is a simple RoundRobin golang loadbalancer. It performs active cleaning and passive recovery for unhealthy backends.

### Features:

- `Cleans`: Excludes servers marked as unhealthy from the round-robin rotation.
- `Recovers`: Periodically tries to recheck and reintegrate previously unhealthy servers back into service.

```go
package main

import (
"github.com/dhyanio/golb"
)

func main() {
// Slice of servers
servers := []string{"http://localhost:8081", "http://localhost:8082"}

// Start Loadbalancer
golb.Start(serverList, "3000")
}
```