Skip to content

Commit 2a9649b

Browse files
committed
Inline loggingMaxBody
1 parent e2f42e7 commit 2a9649b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

client/src/main/java/io/avaje/http/client/DHttpClientContext.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@ final class DHttpClientContext implements HttpClientContext {
3333
private final boolean withAuthToken;
3434
private final AuthTokenProvider authTokenProvider;
3535
private final AtomicReference<AuthToken> tokenRef = new AtomicReference<>();
36-
private int loggingMaxBody = 1_000;
3736

3837
private final LongAdder metricResTotal = new LongAdder();
3938
private final LongAdder metricResError = new LongAdder();
@@ -316,6 +315,6 @@ private String authToken() {
316315
}
317316

318317
String maxResponseBody(String body) {
319-
return body.length() > loggingMaxBody ? body.substring(0, loggingMaxBody) + " <truncated> ..." : body;
318+
return body.length() > 1_000 ? body.substring(0, 1_000) + " <truncated> ..." : body;
320319
}
321320
}

0 commit comments

Comments
 (0)