Package org.craftercms.commons.rest
Class LoggingRequestInterceptor
- java.lang.Object
-
- org.craftercms.commons.rest.LoggingRequestInterceptor
-
- All Implemented Interfaces:
org.springframework.http.client.ClientHttpRequestInterceptor
public class LoggingRequestInterceptor extends Object implements org.springframework.http.client.ClientHttpRequestInterceptor
REST client request interceptor that logs the whole request and response. Useful for debugging.- Author:
- avasquez
-
-
Constructor Summary
Constructors Constructor Description LoggingRequestInterceptor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.http.client.ClientHttpResponse
intercept(org.springframework.http.HttpRequest request, byte[] body, org.springframework.http.client.ClientHttpRequestExecution execution)
-
-
-
Method Detail
-
intercept
public org.springframework.http.client.ClientHttpResponse intercept(org.springframework.http.HttpRequest request, byte[] body, org.springframework.http.client.ClientHttpRequestExecution execution) throws IOException
- Specified by:
intercept
in interfaceorg.springframework.http.client.ClientHttpRequestInterceptor
- Throws:
IOException
-
-