roundabout

command module
v0.0.0-...-97d4abd Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 2, 2022 License: MIT Imports: 10 Imported by: 0

README

Roundabout Postgres Proxy / Connection Pooler

This is a small postgres proxy that is intended to be an alternative to PgBouncer. It avoids some of the legacy complexity of PgBouncer, like having to pick between session, transaction, or statement modes by automatically detecting transactions and anonymous prepared statements.

Status

I would say this is a rough prototype. There are no tests, and it has not been used in a production environment. It currently lacks TLS support, and it has some references to read replicas, but does not actually support transparently redirecting queries to read replicas yet.

Development

docker-compose up -d # this will start a postgres instance with a password matching the one in `roundabout.yml`
go run main.go # this will compile and start `roundabout`
psql -h localhost -U postgres # this will let you connect to the database through `roundabout`, and you'll need to use the password specified in `roundabout.yml` in virtual.password

License

MIT

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package backend contains the backend manager, which is an actor that oversees the connection to a particular client application.
Package backend contains the backend manager, which is an actor that oversees the connection to a particular client application.
receiver
Package receiver contains an actor that receives messages from a client application and forwards those messages to the backend manager
Package receiver contains an actor that receives messages from a client application and forwards those messages to the backend manager
sender
Package sender contains an actor that receives messages from both the backend manager and postgres, and it forwards those messages to the client application
Package sender contains an actor that receives messages from both the backend manager and postgres, and it forwards those messages to the client application
Package frontend is responsible for handling connections to a postgres database.
Package frontend is responsible for handling connections to a postgres database.
preambler
Package preambler contains an actor whose job is to send the Postgres preamble to each client on demand as clients connect to this particular Postgres frontend
Package preambler contains an actor whose job is to send the Postgres preamble to each client on demand as clients connect to this particular Postgres frontend
receiver
Package receiver contains an actor that receives messages from Postgres and (usually) forwards those messages to the backend manager.
Package receiver contains an actor that receives messages from Postgres and (usually) forwards those messages to the backend manager.
sender
Package sender receives messages from the backend manager and forwards them directly to Postgres
Package sender receives messages from the backend manager and forwards them directly to Postgres

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL