Page created: 4 Feb 2020
|
Page updated: 22 Jul 2020
Correlation ID support is enabled by default for each HTTP Connection Handler.
- To enable correlation ID support for the HTTPS Connection
Handler:
$ bin/dsconfig set-connection-handler-prop \ --handler-name "HTTPS Connection Handler" \ --set use-correlation-id-header:true
- To disable correlation ID support for the HTTPS Connection
Handler:
$ bin/dsconfig set-connection-handler-prop \ --handler-name "HTTPS Connection Handler" \ --set use-correlation-id-header:false
Configuring the correlation ID response header
- The server will generate a correlation ID for every HTTP request and send it in
the response through the
Correlation-Id
response header. This response header name can be customized. The following example changes thecorrelation-id-response-header
property to"X-Request-Id."$ bin/dsconfig set-connection-handler-prop \ --handler-name "HTTPS Connection Handler" \ --set correlation-id-response-header:X-Request-Id
Accepting an incoming correlation ID from the request
- By default, the server generates a new, unique correlation ID for each HTTP
request, and ignores any correlation ID that may be set on the request. This can
be changed by designating the names of one or more HTTP request headers that
contain an existing correlation ID value. This enables the server to integrate
with a larger system consisting of every servers using correlation
IDs.
$ bin/dsconfig set-connection-handler-prop \ --handler-name "HTTPS Connection Handler" \ --set correlation-id-request-header:X-Request-Id \ --set correlation-id-request-header:X-Correlation-Id \ --set correlation-id-request-header:Correlation-Id \ --set correlation-id-request-header:X-Amzn-Trace-Id