Skip to main content

Backend.AI App Proxy Worker

Purpose

The App Proxy Worker is a high-performance reverse proxy that routes user traffic to compute session services (Jupyter, SSH, TensorBoard, etc.) running on agents. It receives routing information from the Coordinator and handles SSL/TLS termination, load balancing, and traffic forwarding.

Key Responsibilities

1. Traffic Proxying

  • Proxy HTTP/HTTPS requests to session services
  • Proxy WebSocket connections for interactive services
  • Handle SSL/TLS termination
  • Stream responses efficiently

2. Route Resolution

  • Receive routing tables from Coordinator
  • Resolve session services from URLs
  • Cache routing information locally
  • Update routes dynamically

3. Health Checking

  • Monitor backend service health
  • Detect failed services
  • Report health status to Coordinator
  • Handle service failover

Architecture

1. Traffic Proxy (Main)

Framework: aiohttp + custom reverse proxy

Port: 5050 (default, HTTPS)

Protocol: HTTP/HTTPS, WebSocket

Key Features:

HTTP/HTTPS Proxy

  • Route user requests to session services
  • URL Pattern: https://<worker-domain>/<session-id>/<service-name>/...

WebSocket Proxy

  • Interactive service communication (Jupyter Kernel, SSH, etc.)
  • Real-time log streaming

Key Characteristics:

  • SSL/TLS termination (Let's Encrypt auto-certificate)
  • High-performance async proxy
  • Connection pooling and reuse
  • Streaming support (large file downloads)
  • Sticky session support
  • Auto-retry and failover

Processing Flow:

HTTP Proxy Flow

User → HTTPS Request → Worker (SSL termination)
                           ↓
                       Parse URL (extract session_id, service_name)
                           ↓
                       Lookup route from local cache
                           ↓
                       Resolve backend address (agent:port)
                           ↓
                       Proxy request to agent
                           ↓
                       Stream response back to user

WebSocket Proxy Flow

User → WS Upgrade Request → Worker
                               ↓
                           Establish WS connection to agent
                               ↓
                           Bidirectional message forwarding

2. REST API (Management)

Framework: aiohttp (async HTTP server)

Port: 6040 (default, separate management port)

Key Features:

  • Communication with Coordinator
  • Health check endpoints
  • Metrics exposure (Prometheus)
  • Internal management (no external access)

Component Interaction

Traffic Proxy Flow:

User (Browser) → Worker (Port 5050) → Kernel (on Agent)
                    │
                    ├─ SSL/TLS termination
                    ├─ Route resolution
                    └─ Traffic proxying

Management Flow:

Coordinator → Worker REST API (Port 6040) → Route updates

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

backend_ai_appproxy_worker-26.4.10.tar.gz (57.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

backend_ai_appproxy_worker-26.4.10-py3-none-any.whl (78.5 kB view details)

Uploaded Python 3

File details

Details for the file backend_ai_appproxy_worker-26.4.10.tar.gz.

File metadata

File hashes

Hashes for backend_ai_appproxy_worker-26.4.10.tar.gz
Algorithm Hash digest
SHA256 9e18217e7d9a1308d4ee4923de0a92cdc664690a008522fb0392c545f84daee8
MD5 b5cd2bc8667684f520929f23277bc2e6
BLAKE2b-256 5f9899ab78eb2736066dfa686e8f8eb58df631efb4d5a99ea1578de0423700e7

See more details on using hashes here.

File details

Details for the file backend_ai_appproxy_worker-26.4.10-py3-none-any.whl.

File metadata

File hashes

Hashes for backend_ai_appproxy_worker-26.4.10-py3-none-any.whl
Algorithm Hash digest
SHA256 4dc88e714f03e43066d6e375bc80cbc261f21c9a5ef6b7914616f812f513d199
MD5 7ab345086494ac3653e0cbd4fb38d37e
BLAKE2b-256 ebc7f5633f270f907f43939232569eaa4047b620e08979cdd2e1e04bf249a646

See more details on using hashes here.

Release history Release notifications | RSS feed

26.8.1

2 files

26.8.0

2 files

26.7.0

2 files

This release

26.4.10 This release

2 files

26.4.9

2 files

26.4.8

2 files

26.4.7

2 files

26.4.6

2 files

26.4.5

2 files

26.4.4

2 files

26.4.3

2 files

26.4.2

2 files

26.4.1

2 files

26.4.0

2 files

26.3.3

2 files

26.3.2

2 files

26.3.1

2 files

26.3.0

2 files

26.2.5

2 files

26.2.4

2 files

26.2.3

2 files

26.2.2

2 files

26.2.1

2 files

26.2.0

2 files

26.1.0

2 files

25.19.2

2 files

25.19.1

2 files

25.19.0

2 files

25.18.1

2 files

25.18.0

2 files

25.17.1

2 files

25.17.0

2 files

25.16.0

2 files

25.15.12

2 files

25.15.11

2 files

25.15.10

2 files

25.15.9

2 files

25.15.8

2 files

25.15.7

2 files

25.15.6

2 files

25.15.5

2 files

25.15.4

2 files

25.15.3

2 files

25.15.2

2 files

25.15.1

2 files

25.15.0

2 files

25.14.5

2 files

25.14.4

2 files

25.14.3

2 files

25.14.2

2 files

25.14.1

2 files

25.14.0

2 files

25.13.4

2 files

25.13.3

2 files

25.13.2

2 files

25.13.1

2 files

25.13.0

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page