Skip to main content

Module hooks

Module hooks 

Source
Expand description

Lua hook pipeline for folk-plugin-http.

Hook scripts are pre-compiled to Lua bytecode at startup and executed per-request on a fresh mlua::Lua VM instance. Sync hooks run in the request critical path; async hooks fire-and-forget via tokio::spawn.

Structs§

HookEngine
Holds all pre-compiled hooks for the lifetime of the server.
RequestContext
Context passed to request.before and request.error hooks.
ResponseContext
Context passed to response.headers and response.after hooks.

Enums§

HookResult
Outcome of running a hook stage.