Search in sources :

Example 1 with HttpResponse

use of org.xdi.oxauth.audit.debug.entity.HttpResponse in project oxAuth by GluuFederation.

the class ServletLoggingFilter method getResponseDescription.

protected String getResponseDescription(ResponseWrapper responseWrapper) {
    HttpResponse httpResponse = new HttpResponse();
    httpResponse.setStatus(responseWrapper.getStatus());
    httpResponse.setHeaders(responseWrapper.getHeaders());
    try {
        return OBJECT_MAPPER.writeValueAsString(httpResponse);
    } catch (JsonProcessingException e) {
        log.warn("Cannot serialize Response to JSON", e);
        return null;
    }
}
Also used : HttpResponse(org.xdi.oxauth.audit.debug.entity.HttpResponse) JsonProcessingException(com.fasterxml.jackson.core.JsonProcessingException)

Aggregations

JsonProcessingException (com.fasterxml.jackson.core.JsonProcessingException)1 HttpResponse (org.xdi.oxauth.audit.debug.entity.HttpResponse)1