Skip to main content

Crate apigate

Crate apigate 

Source

Modules§

__private
balancing
Load-balancing traits and built-in balancers.
routing
Route key extraction traits and built-in routing strategies.

Structs§

ApigateError
Error returned from hooks and maps.
App
Built gateway application.
AppBuilder
Builder for an App.
Backend
A configured upstream backend.
BackendPool
Immutable collection of upstream backends for one service.
PartsCtx
Mutable request-head context passed to hooks and maps.
Policy
Routing and balancing policy applied to one or more routes.
RequestScope
Owns the request body and extracted data for a single pipeline invocation.
RouteDef
Macro-generated route definition.
Routes
Macro-generated route collection for a service.
RuntimeEvent
Structured event emitted by the gateway runtime.
ServeConfig
Listener-side options for run_with and run_router_with.
UpstreamConfig
Upstream client and TCP socket configuration.

Enums§

ApigateBuildError
Error returned while building an crate::App.
ApigateCoreError
Core runtime errors produced by request mutation, dispatch, or proxying.
ApigateFrameworkError
Framework-owned error passed to the configured error renderer.
ApigatePipelineError
Errors produced by generated request pipelines.
BaseUriParseError
Error returned when parsing an upstream backend base URI.
Method
HTTP method used in macro-generated route definitions.
RewriteSpec
Rewrite strategy generated by route macros.
RuntimeEventKind
Runtime event kinds.

Functions§

default_error_renderer
Default error renderer that returns plain-text responses.
default_tracing_observer
Default observer: emits structured events through tracing.
run
Serves an App on the provided socket address.
run_router
Runs a pre-built axum router.
run_router_with
Runs a pre-built axum router with custom listener configuration.
run_with
Serves an App with custom listener configuration.

Type Aliases§

HookResult
Result type returned by #[apigate::hook] functions.
MapResult
Result type returned by #[apigate::map] functions.
PipelineFn
Single function that orchestrates all request processing: parse path params, run before hooks, validate/parse body, map, and return body.
PipelineFuture
Boxed future returned by a generated pipeline.
PipelineResult
Result returned by a generated pipeline.
RuntimeObserver
Custom observer for runtime events.

Attribute Macros§

delete
Declares a route inside an #[apigate::service] module.
get
Declares a route inside an #[apigate::service] module.
head
Declares a route inside an #[apigate::service] module.
hook
Marks an async function as a request hook.
map
Marks an async function as a request mapper.
options
Declares a route inside an #[apigate::service] module.
patch
Declares a route inside an #[apigate::service] module.
post
Declares a route inside an #[apigate::service] module.
put
Declares a route inside an #[apigate::service] module.
service
Defines an apigate service module.