Interface TimeoutHandler
- All Superinterfaces:
Handler<RoutingContext>, PlatformHandler
Handler that will timeout requests if the response has not been written after a certain time.
Timeout requests will be ended with an HTTP status code `503`.
- Author:
- Tim Fox
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe default error codestatic final longThe default timeout, in ms -
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic TimeoutHandlercreate()Create a handlerstatic TimeoutHandlercreate(long timeout) Create a handlerstatic TimeoutHandlercreate(long timeout, int errorCode) Create a handler
-
Field Details
-
DEFAULT_TIMEOUT
static final long DEFAULT_TIMEOUTThe default timeout, in ms- See Also:
-
DEFAULT_ERRORCODE
static final int DEFAULT_ERRORCODEThe default error code- See Also:
-
-
Method Details
-
create
-
create
Create a handler- Parameters:
timeout- the timeout, in ms- Returns:
- the handler
-
create
Create a handler- Parameters:
timeout- the timeout, in ms- Returns:
- the handler
-