|
20 | 20 | import org.apache.commons.logging.Log;
|
21 | 21 | import org.apache.commons.logging.LogFactory;
|
22 | 22 | import org.springframework.http.HttpStatus;
|
| 23 | +import org.springframework.http.HttpStatusCode; |
23 | 24 | import org.springframework.lang.Nullable;
|
24 | 25 | import org.springframework.util.ObjectUtils;
|
25 | 26 |
|
|
30 | 31 | * @author Mark Paluch
|
31 | 32 | * @author Christoph Strobl
|
32 | 33 | * @author Peter-Josef Meisch
|
| 34 | + * @author Oliver Drotbohm |
33 | 35 | * @since 3.2
|
34 | 36 | */
|
35 | 37 | public abstract class ClientLogger {
|
@@ -125,7 +127,7 @@ public static void logRequest(String logId, String method, String endpoint, Obje
|
125 | 127 | * @param logId the correlation id, see {@link #newLogId()}.
|
126 | 128 | * @param statusCode the HTTP status code.
|
127 | 129 | */
|
128 |
| - public static void logRawResponse(String logId, @Nullable HttpStatus statusCode) { |
| 130 | + public static void logRawResponse(String logId, @Nullable HttpStatusCode statusCode) { |
129 | 131 |
|
130 | 132 | if (isEnabled()) {
|
131 | 133 | WIRE_LOGGER.trace(String.format("[%s] Received raw response: %s", logId, statusCode));
|
@@ -153,7 +155,7 @@ public static void logRawResponse(String logId, @Nullable HttpStatus statusCode,
|
153 | 155 | * @param statusCode the HTTP status code.
|
154 | 156 | * @param body body content.
|
155 | 157 | */
|
156 |
| - public static void logResponse(String logId, HttpStatus statusCode, String body) { |
| 158 | + public static void logResponse(String logId, HttpStatusCode statusCode, String body) { |
157 | 159 |
|
158 | 160 | if (isEnabled()) {
|
159 | 161 | WIRE_LOGGER.trace(String.format("[%s] Received response: %s%nResponse body: %s", logId, statusCode, body));
|
|
0 commit comments