Expand description
Static port declarations for every node type.
One PortSpec per plugin type, resolved through
crate::plugins::port_spec — the single source of truth shared by the
graph compiler (edge validation), the admin catalog (GET /api/plugins),
and by extension the UI editor. The crate::plugins::Plugin trait has no
port method at all: the registry match in port_spec IS the declaration,
so a plugin cannot drift from its own ports.
Structs§
Enums§
- Port
Kind - The flavor of an output port, driving validation and UI color.
Constants§
- AUTH_
SPEC - Credential-auth plugins: deliberate 401/403 rejections exit on
denied. Genuine infrastructure failures (consumer store unavailable, LDAP unreachable, IdP HTTP errors) remain onerror. - BREAKER_
SPEC api-breaker: the check phase’s open-circuit short-circuit exits onbroken.- CLIENT_
SPEC client: terminal node, the response is sent from here.- CONDITION_
SPEC condition: a pure branching waypoint — nosuccessport, the request always leaves ontrueorfalse. Evaluation is lenient (absent variables compare as empty, a JSONPath over a non-JSON body matches nothing), so the node itself never errors;errorstays declared for compatibility with policies that wired it.- CORS_
SPEC cors: preflight answers short-circuit on their own port.- DEFAULT_
SPEC - The default pair every plugin without alternate outcomes uses.
- DENY_
SPEC - Restriction and request-shape plugins: a deliberate policy rejection
(IP/UA/referer/consumer/group deny, blocked URI, missing/invalid CSRF
token, oversized body, schema mismatch) exits on
denied. Same shape asAUTH_SPECbut kept as its own const so the description can speak to policy rejections rather than credentials. - ERROR 🔒
- FAULT_
INJECTION_ SPEC fault-injection: injected abort responses exit on their own port.- INTERACTIVE_
AUTH_ SPEC - Interactive SSO plugins: denied rejections plus browser redirects.
- LIMIT_
SPEC - Traffic-control plugins (
rate-limit,limit-conn,limit-count): a throttled request exits onlimited. - LISTENER_
SPEC listener: pipeline entry, no input, single exit.- PROXY_
CACHE_ SPEC proxy-cache(lookup phase): a cache hit exits onhit.successcovers a miss or a non-cacheable method/bypass — the request continues to the upstream.- REDIRECT_
SPEC redirect: prepared 3xx responses exit on their own port.- SCRIPT_
SPEC script: a script that preparedctx.responseand asked to answer with it (return ctx, "respond") exits onrespond. It is the same shape asabort/denied/redirect: a deliberate short-circuit on a declared port, never inferred from the response the script left behind.- STORE_
GET_ SPEC store-get: a key that does not exist is a normal outcome, not an error – it exitsmiss, which the compiler forces the policy to wire. A store outage exitserrorinstead, so the two stay distinguishable.- SUCCESS 🔒
- TRAFFIC_
SPLIT_ SPEC traffic-split: a request steered to and served by a weighted split target exits onrouted.successcovers both “no rule matched” and “the default slot was picked” — the request continues to the route’s normal upstream unchanged.- WORKFLOW_
SPEC workflow: a rejectingreturnrule exits ondenied; an exceededlimit-countrule exits onlimited.