private static void maybeSetContentLengthUnknown(boolean hasContentLength, HttpHeadersBuilder out) {
        if (hasContentLength) {
            return;
        }

        HttpMethod method = null;
        if (out instanceof RequestHeadersBuilder) {
            method = ((RequestHeadersBuilder) out).method();
        }

        final boolean isContentAlwaysEmpty;
        if (method != null) {
            isContentAlwaysEmpty = isContentAlwaysEmpty(method);
        } else {
            isContentAlwaysEmpty = false;
        }

        if (!isContentAlwaysEmpty) {
            // Set isContentLengthUnknown to true not to override the content-length when the HTTP objects are
            // aggregated.
            out.contentLengthUnknown();
        }
    }
Removes HTTP/1 specified headers from a mutable headers map.
Functionally this method is expected to behave the same as
{@link #toArmeria(io.netty.handler.codec.http.HttpHeaders, HttpHeadersBuilder)}.
This method should be preferred going forward as we continue implementing zero-copy
for HTTP1 en/decoders.
core/src/main/java/com/linecorp/armeria/internal/common/ArmeriaHttpUtil.java