A BPF based PostgreSQL connection pool.
Prerequisites:
- Linux kernel version >= 6.1.0
- Go version >= 1.19
- Docker
make build
docker compose up -d --build --force-recreate kpgpool-bpf-pool kpgpool-pool kpgpool-pgbouncer
Note: add -b
to setup the database for the first time.
Simple query protocol:
./bin/bpfpgpool client bench -c 8 -q 1 -d 10s -u "postgres://postgres:postgres@10.140.0.11:6432/postgres?sslmode=disable&default_query_exec_mode=simple_protocol"
Extended query protocol:
./bin/bpfpgpool client bench -c 8 -q 1 -d 10s -u "postgres://postgres:postgres@10.140.0.11:6432/postgres?sslmode=disable"