Parameter Server
Dead simple TCP-based parameter storage that actually works. No cap.
Quick Start
# Install dependencies
make install
# Run server
make server
Note, it uses example parameter yml file.
Python Usage
from param_server.client import AsyncParameterClient
async with AsyncParameterClient() as client:
await client.set("/camera/exposure", 100)
value = await client.get("/camera/exposure")
print(f"Exposure: {value}")
Production Setup
Parameters.yml
Add your production parameters to file config/params.yml.
Docker Compose (recommended)
# Build container
make docker-build
# Start container
make docker-run
# Stop container
make stop
# Server runs on 0.0.0.0:8888
Configuration (when running without make)
Drop a YAML file with your defaults:
camera:
exposure: 100
gain: 1.5
fps: 30
network:
timeout: 5000
retries: 3
Load it: --config your-config.yml
CLI Commands
# Basic operations
param-cli set /path/to/param value
param-cli get /path/to/param
param-cli delete /path/to/param
param-cli list --prefix /camera
# Live monitoring
param-cli watch /camera/exposure
# Health check
param-cli ping
Client Libraries
Async
from param_server.client import AsyncParameterClient
client = AsyncParameterClient("localhost", 8888)
await client.connect()
await client.set("/test", 123)
value = await client.get("/test")
await client.disconnect()
Features
- Persistent connections (low latency)
- Auto-reconnection (handles network issues)
- Type support: str, int, float, bool
- Concurrent operations
- Tree-like parameter paths
- JSON/tree CLI output formats
- Docker ready
Port Configuration
Default port is 8888. Change it:
# Server
param-server --port 9999
# Client
param-cli --port 9999 ping
# Python
AsyncParameterClient("localhost", 9999)
# or
ParameterClient("localhost", 9999)
Troubleshooting
Connection refused
# Check if server is running
param-cli ping
# Check port
netstat -tlnp | grep 8888
Permission denied
# Use different port
param-server --port 9999
Docker issues
# Check logs
docker compose logs param-server
# Rebuild
docker compose build --no-cache
That's it. Simple as.
@themladypan
Release files for async-param-server 1.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| async_param_server-1.1.3.tar.gz | 22.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| async_param_server-1.1.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 34.4 kB
Release files / async_param_server-1.1.3.tar.gz
| Download URL | async_param_server-1.1.3.tar.gz |
|---|---|
| Size | 22.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0506c8b4efeea50fa8f62b14630d7ea7e5ac488b3789b562a070001fe41850f2
|
|
BLAKE2b-256 checksum How to use checksums |
0da4892d01b7abe25e6ee1d81d3f61601144e82642a8e5fe449634dbaf08e08e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.8.11
|
Release files / async_param_server-1.1.3-py3-none-any.whl
| Download URL | async_param_server-1.1.3-py3-none-any.whl |
|---|---|
| Size | 12.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
ce7267ac7ad6d90dabd8c351b75cc048724f2e1474f789c4575554b5761a7100
|
|
BLAKE2b-256 checksum How to use checksums |
b95bfae17778f2eb82af357d0545a18498cb08f9ecc5046231678bfe2fb97a81
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.8.11
|