Interface LifecycleInterceptor

All Known Implementing Classes:
DefaultLifecycleInterceptor

public interface LifecycleInterceptor
"Hook" methods for customizing behavior in response to system lifecycle events - server started, request received, response written, and so on.

The ability to modify request processing control flow is provided via wrapRequest(Request, ResourceMethod, Consumer) and interceptRequest(Request, ResourceMethod, Function, Consumer).

Note: some of these methods are "fail-fast" - exceptions thrown will bubble out and stop execution - and for others, Soklet will catch exceptions and surface separately via didReceiveLogEvent(LogEvent). Generally speaking, lifecycle events that are scoped at the server level (e.g. willStartServer(Server)) will fail-fast and events that are scoped at the request level (e.g. didStartRequestHandling(Request, ResourceMethod)) will not fail-fast.

Full documentation is available at https://www.soklet.com/docs/request-lifecycle.

Author:
Mark Allen