Expand description
CEL everywhere (DW-059).
One CEL surface across four use-sites, following the APISIX
expr/Kong expressions-router precedent of a single expression
language rather than a bespoke DSL per feature.
§Use-sites
- Expression matchers in routes – a CEL expression that evaluates to a bool; if true, the route matches.
- Header/transform logic – a CEL expression that evaluates to a string; the result is used as the header value.
- Rate-limit key derivation – a CEL expression that
evaluates to a string; the result is used as the rate-limit
key (e.g.
request.headers["x-api-key"]). - Policy conditions – a CEL expression that evaluates to a bool; if true, the policy applies.
§Request context
All four use-sites share the same request context: a request
variable with path, method, headers, query, host fields.
This is the standard CEL request variable that the gateway
populates per-request.
§Feature gate
The cel cargo feature must be enabled (this module builds on the
DW-058 CEL engine).
Structs§
- Header
Transform - A CEL-based header transform expression.
- Policy
Condition - A CEL-based policy condition.
- Rate
Limit Key - A CEL-based rate-limit key derivation expression.
- Request
Context - The standard request context for CEL evaluation.
- Route
Condition - A CEL-based route match condition.
Enums§
- CelUse
Site - The kind of CEL use-site.
Functions§
- compile_
for - Compile a CEL expression for a specific use-site.
- evaluate_
for - Evaluate a CEL program for a specific use-site, checking the result type.