Core Concepts
The fundamental building blocks of Nolxy: how requests flow through the gateway, how routes are matched, and how each layer of protection and optimization works.
Request Lifecycle
Client → ProxyShield → Auth → Rate Limit → Early Cache → Transform → Proxy → Circuit Breaker → Response Cache → Client
Each request passes through every layer in order. Short-circuit exits (cache hit, rate limit exceeded, circuit open) skip downstream layers entirely.
Routes & Proxying
A Route maps a public path on Nolxy to an upstream backend URL. All traffic matching the path and method is forwarded upstream with the original headers, body, and query string intact.
*) and named params (:id). Matched against the incoming request path./api/* → https://backend.com/api/users).X-Internal-Secret: …). Lets your backend verify traffic comes from Nolxy.Circuit Breaker
The circuit breaker prevents cascading failures by stopping requests to an unhealthy upstream. State is stored in Redis so all workers share the same view. Three states: CLOSED (normal), OPEN (blocking), HALF-OPEN (probing).
Failure Threshold
Number of consecutive failures before the circuit opens. Counts 5xx responses and timeouts.
Monitoring Window
Time window (seconds) over which failures are counted. Resets on successful response.
Success Threshold
Number of consecutive successes in HALF-OPEN state required to close the circuit.
Open Timeout
How long (seconds) the circuit stays OPEN before transitioning to HALF-OPEN for a probe request.
When the circuit is OPEN, Nolxy returns 503 Service Unavailable immediately without hitting the upstream. A webhook notification is sent when the circuit opens and when it recovers.
Response Caching
Two-tier response cache: L1 in-memory LRU (per worker) and L2 Redis (shared across workers). Cache is checked before the proxy — a HIT never reaches the upstream.
GET and HEAD requests are cached by default.200, 203, 204, 206, 300, 301, 404, 405, 410, 414, 501 are cached.Accept-Language). Enables per-locale caching.The X-Cache response header indicates HIT, MISS, or BYPASS. Cache is invalidated automatically when the route configuration changes.
Automatic Retries
Nolxy can automatically retry failed upstream requests with exponential backoff. Only safe, idempotent methods are retried by default.
delay × 2^attempt.5xx responses, connection errors, and timeouts. 4xx errors are never retried.CORS
Nolxy handles CORS preflight requests and injects the appropriate headers on every response. Configure per route.
* to allow all. Requests from unlisted origins receive no CORS headers.Access-Control-Allow-Methods.Access-Control-Allow-Headers.Access-Control-Allow-Credentials: true. Cannot be combined with origin: *.Preflight (OPTIONS) requests are handled entirely by Nolxy and never forwarded to the upstream backend.
Request/Response Transformations
Pipelines apply a sequence of transformation actions to the request before it is proxied, or to the response before it is returned. Actions run in order and can be conditional on method or path.
Available Actions
stringTrim Trim whitespace from a string fieldstringToLower Convert a string field to lowercasestringToUpper Convert a string field to uppercaseremoveFields Remove fields from the bodyaddFields Add or overwrite fields in the bodyrenameFields Rename fields in the bodyAdditional actions include maskFields (PII redaction), injectHeader, removeHeader, jwtClaimToHeader, and securityHeaders. See the Pipelines guide for the full list.