diff --git a/core/src/main/java/com/linecorp/armeria/common/logging/DefaultRequestLog.java b/core/src/main/java/com/linecorp/armeria/common/logging/DefaultRequestLog.java index e4a7d804371..250eed2fae3 100644 --- a/core/src/main/java/com/linecorp/armeria/common/logging/DefaultRequestLog.java +++ b/core/src/main/java/com/linecorp/armeria/common/logging/DefaultRequestLog.java @@ -992,11 +992,7 @@ public void requestContent(@Nullable Object requestContent, @Nullable Object raw ctx.updateRpcRequest((RpcRequest) requestContent); } updateFlags(RequestLogProperty.REQUEST_CONTENT); - - final int requestCompletionFlags = RequestLogProperty.FLAGS_REQUEST_COMPLETE & ~deferredFlags; - if (isAvailable(requestCompletionFlags)) { - setNamesIfAbsent(); - } + setNamesIfAbsent(); } @Nullable @@ -1118,14 +1114,6 @@ private void endRequest0(@Nullable Throwable requestCause, long requestEndTimeNa this.requestCause = requestCause; } updateFlags(flags); - - // The check here covers two cases: - // 1) #endRequest has completed all flags except name. - // 2) #requestContent has been called from a different thread, but names hasn't been set - if (hasInterestedFlags(deferredFlags, RequestLogProperty.REQUEST_CONTENT) && - isAvailable(RequestLogProperty.REQUEST_CONTENT)) { - setNamesIfAbsent(); - } } private void setNamesIfAbsent() {