@Nullable
    @Override
    public Boolean isResponseStreaming(Type returnType, @Nullable MediaType produceType) {
        final Class<?> clazz = typeToClass(unwrapUnaryAsyncType(returnType));
        if (clazz == null) {
            return null;
        }

        if (HttpData.class.isAssignableFrom(clazz) || byte[].class.isAssignableFrom(clazz)) {
            return false;
        }

        if (produceType != null && (produceType.is(MediaType.APPLICATION_BINARY) ||
                                    produceType.is(MediaType.OCTET_STREAM))) {
            return Publisher.class.isAssignableFrom(clazz) || Stream.class.isAssignableFrom(clazz);
        }
        return null;
    }
A {@link ResponseConverterFunction} which creates an {@link HttpResponse} when:
<ul>
  <li>the {@code result} is an instance of {@link HttpData} or {@code byte[]}</li>
  <li>the {@code result} is an instance of {@link Publisher} or {@link Stream} while the
      {@code "content-type"} of the {@link ResponseHeaders} is {@code "application/binary"} or
      {@code "application/octet-stream"}</li>
</ul>
Note that this {@link ResponseConverterFunction} is applied to an annotated service by default,
so you don't have to specify this converter explicitly.
core/src/main/java/com/linecorp/armeria/server/annotation/ByteArrayResponseConverterFunction.java