]
Kabir Khan updated WFCORE-972:
------------------------------
Fix Version/s: 3.0.0.Beta2
(was: 3.0.0.Beta1)
Provide a way to correlate HTTP management requests
---------------------------------------------------
Key: WFCORE-972
URL:
https://issues.jboss.org/browse/WFCORE-972
Project: WildFly Core
Issue Type: Enhancement
Components: Domain Management
Reporter: Heiko Braun
Assignee: Brian Stansberry
Fix For: 3.0.0.Beta2
{noformat}
public class CorrelationHandler implements HttpHandler {
private static final HttpString HEADER = new HttpString("X-CORR-ID");
private final HttpHandler next;
public CorrelationHandler(HttpHandler next) {
this.next = next;
}
@Override
public void handleRequest(HttpServerExchange exchange) throws Exception {
String corr = exchange.getRequestHeaders().getFirst(HEADER);
if(corr != null) {
exchange.getResponseHeaders().put(HEADER, corr);
}
next.handleRequest(exchange);
}
}
{noformat}