Deploy current MiniRedis system using multi-port architecture while enabling:
- terminal access via redis-cli
- external project integration
- stable node lifecycle
Frontend → API Gateway → Node Manager → Tenant Node (Port-based)
Each tenant gets:
- dedicated port
- isolated in-memory instance
PORT RANGE: REDIS_PORT_START=6000 REDIS_PORT_END=6999
MAX NODES: TOTAL = END - START + 1
Example: 6000–6999 → 1000 nodes
POST /create-node
PORT=$(get_free_port)
start_node --port=$PORT --tenant_id=$TENANT_ID
{ "host": "your-server-ip", "port": 6001 }
redis-cli -h -p
redis-cli -h 127.0.0.1 -p 6001
SET key value GET key
const client = redis.createClient({ socket: { host: "HOST", port: PORT } });
r = redis.Redis(host="HOST", port=PORT)
free_ports = [6000...6999] used_ports = {}
PORT = free_ports.pop() used_ports.add(PORT)
sleep 30 free_ports.push(PORT)
stop_node(PORT)
flush_all()
close(PORT)
ports:
- "6000-6999:6000-6999"
- health check endpoint
- auto-restart node
- monitoring integration
- port exhaustion possible
- TIME_WAIT delay on reuse
- not horizontally scalable
This approach enables:
- fast deployment
- CLI compatibility
- real usage testing
Future upgrade required: → single-port multi-tenant system