Back to Labs

TakeGate API Gateway & Load Balancer

Production-Ready Load Balancer & API Gateway

A high-performance load balancer and API gateway written in Python with async/await architecture. It supports TCP, UDP, HTTP, HTTPS, HTTP/2, and HTTP/3. You get advanced routing, smart caching, automated health checks, and full monitoring.

Load Balancing

High-Performance & Async Python

Core Features

Production-grade load balancing capabilities similar to AWS ALB and NLB.

Multi-Protocol Support

TCP, UDP, HTTP, HTTPS, HTTP/2, HTTP/3 protocols. HTTP/3 leverages QUIC for reduced latency and connection migration without head-of-line blocking.

Advanced Routing Engine

Path-based, host-based, header-based, and query parameter routing. OpenAPI 3.0+ specification import for automatic microservices route generation.

Blake2 Caching System

Multiple backend options (memory, Redis, disk, hybrid). TTL management, header variance handling, and automatic tier-based fallback mechanisms.

Protocol-Specific Health Checks

TCP connection verification, HTTP/HTTPS status code validation, UDP packet-based checking with configurable intervals and retry logic.

High-Performance Async

1,422 requests/second sustained throughput. Mean latency 28.37ms, P95 48.34ms, P99 56.05ms. 70-90% horizontal scalability efficiency.

Management & Observability

Web dashboard, REST API, CLI tools, Prometheus metrics export, Grafana integration, real-time traffic analytics, and sticky session support.

Advanced Capabilities

Enterprise-grade features comparable to AWS Application Load Balancer and Network Load Balancer.

Application Load Balancing

  • ✓Layer 7 (Application) load balancing
  • ✓Path-based, host-based, header-based routing
  • ✓Query parameter-based routing rules
  • ✓WebSocket support with persistent connections
  • ✓HTTP method filtering and timeout management
  • ✓Request/response modification capabilities

Network Load Balancing

  • ✓Layer 4 (Transport) load balancing
  • ✓Ultra-high performance: 1,422 requests/second
  • ✓Mean latency: 28.37ms, P95: 48.34ms, P99: 56.05ms
  • ✓TCP and UDP protocol support
  • ✓Connection pooling and multiplexing
  • ✓Round Robin, Least Connections, Weighted algorithms

Advanced Routing

  • ✓OpenAPI 3.0+ specification import
  • ✓Automatic route generation from API docs
  • ✓Host-based routing for multi-tenant apps
  • ✓Regex-based custom routing rules
  • ✓Route-level controls and customization
  • ✓Microservices architecture support

Caching & Performance

  • ✓Blake2 caching with multiple backends (memory, Redis, disk)
  • ✓TTL management and header variance handling
  • ✓Compression (gzip, brotli, deflate)
  • ✓Keep-alive connection management
  • ✓Connection pooling optimization
  • ✓Automatic tier-based fallback mechanisms

SSL/TLS & Security

  • ✓SSL termination (edge, bridge, passthrough modes)
  • ✓Certificate management and renewal
  • ✓Per-route and global rate limiting
  • ✓Configurable burst thresholds
  • ✓DDoS protection capabilities
  • ✓Header manipulation and security rules

Monitoring & Management

  • ✓Real-time metrics and Prometheus export
  • ✓Modern web dashboard at port 8000
  • ✓Traffic analytics and performance visibility
  • ✓REST API for programmatic management
  • ✓Health status monitoring with custom checks
  • ✓Grafana dashboard integration support

Open Source & Production Ready

PyLoadBalancer is a fully open-source load balancer built with Python's async/await architecture, designed for production deployments. It gives you the freedom of open source with enterprise-grade performance, similar to AWS load balancing services.

Get Started with TakeGate

Use TakeGate to run your API gateway and load balancing infrastructure. It installs via pipx, pip, or pre-built frozen executables. It includes a web dashboard, REST API, and CLI management tools.

Installation Options: Package installation (pipx/pip), Frozen Linux executables (~74MB), Docker integration daemon (~66MB), or Systemd service integration with automatic post-install setup.

Check out the comprehensive README and documentation on our GitLab repository.

Analytics & Cookies

We use self-hosted Matomo analytics. By default we measure anonymously with no cookies. Enable cookies to help us improve your experience. You can change this anytime.