Skip to content

Files

Latest commit

ed62b6d · Jun 3, 2019

History

History
262 lines (230 loc) · 7.24 KB

dataobjects.adoc

File metadata and controls

262 lines (230 loc) · 7.24 KB

Cheatsheets

AccessLogOptions

Name

Type

Description

@format

LoggerFormat

Set format of access log. Default is LoggerFormat.DEFAULT. Available values are:

  • DEFAULT remote-client - - [timestamp] "method uri version" status content-length "referrer" "user-agent
  • SHORT remote-client - method uri version status content-length duration ms
  • TINY method uri status - content-length duration

@immediate

Boolean

Configure when to collect access log. True if after request arrives, false after sending response.

AuthHandlerOptions

Handler definition that contains name and JSON configuration. During link deployment all implementations of are loaded from the classpath and based on are initiated.

Name

Type

Description

@config

Json object

Sets link configuration.

@factory

String

Sets name

@schema

String

Sets security schema name

BodyHandlerOptions

Name

Type

Description

@fileUploadDirectory

String

Set the location on Knot.x environment when uploaded files will be stored. These must be an absolute path.

@fileUploadLimit

Number (Long)

Set the file upload limit in bytes

CSRFOptions

Name

Type

Description

@cookieName

String

Set the name of the CSRF cookie

@cookiePath

String

Set of the path of the CSRF cookie

@headerName

String

Set the CSRF token header name

@secret

String

Set the secret used to generate CSRF token

@timeout

Number (long)

Set the timeout of the CSRF token

CustomHttpHeaderOptions

Describes a custom header that is send with every HTTP response from the server

Name

Type

Description

@name

String

Name of the request header.

@value

String

Value of the request header.

DropRequestOptions

Describes Knot.x HTTP Server dropping request options

Name

Type

Description

@backpressureBufferCapacity

Number (long)

Sets the backpressure buffer capacity, the number of request that single Server instance can support concurrently. Default value is 1000.

@backpressureStrategy

BackpressureOverflowStrategy

Sets the strategy how to deal with backpressure buffer overflow. Default is DROP_LATEST.

Available values:

  • ERROR - terminates the whole sequence
  • DROP_OLDEST - drops the oldest value from the buffer
  • DROP_LATEST - drops the latest value from the buffer

@dropRequestResponseCode

Number (int)

Sets the HTTP response code returned wheb request is dropped. Default is TOO_MANY_REQUESTS(429)

@enabled

Boolean

Enabled/disables request dropping (backpressure) on heavy load. Default is true - enabled.

HystrixMetricsOptions

Describes Knot.x Hystrix metrics options

Name

Type

Description

@enabled

Boolean

Enabled/disables Hystrix metrics exposed by Knot.x Server, by default - disabled.

@endpoint

String

Sets Hystrix metrics endpoint under which it will expose the metrics. By default /hystrix-metrics

KnotxServerOptions

Describes a Knot.x HTTP Server configuration

Name

Type

Description

@displayExceptionDetails

Boolean

Set whether to display or not the exception on error pages

@dropRequestOptions

DropRequestOptions

Set the drop request options (see DropRequestOptions)

@globalHandlers

Array of RoutingHandlerOptions

List of RoutingHandlerOptions containing handlers configurations which are initiated (loaded from classpath via java.util.ServiceLoader) during server setup and applied to each route.

@hystrixMetricsOptions

HystrixMetricsOptions

Set the Hystrix Metrics options (see HystrixMetricsOptions).

@routingOperations

Array of RoutingOperationOptions

Set list of RoutingOperationOptions.

@routingSpecificationLocation

String

Location of your spec. It can be an absolute path, a local path or remote url (with HTTP protocol).

@securityHandlers

Array of AuthHandlerOptions

Set list of AuthHandlerOptions.

@serverOptions

HttpServerOptions

Set the HTTP Server options

RoutingHandlerOptions

Handler definition that contains name and JSON configuration. During link deployment all implementations of are loaded from the classpath and based on are initiated.

Name

Type

Description

@config

Json object

Configuration for the Handler created by associated RoutingHandlerFactory.

@name

String

Name of the RoutingHandlerFactory registered via java.util.ServiceLoader.

RoutingOperationOptions

Routing operation settings that define handlers / error handlers taking part in HTTP request processing. link loads link containing Open API specification which describes all endpoints with request / response schemas. Each endpoint defines operationId used in link.

Name

Type

Description

@failureHandlers

Array of RoutingHandlerOptions

Sets list of error handlers definitions for particular operationId.

@handlers

Array of RoutingHandlerOptions

Sets list of handlers definitions for particular operationId.

@operationId

String

Sets operationId name.