@SuppressWarnings("unused")
    static <T> HttpResponse fromStream(ResponseHeaders headers, Stream<T> contentStream,
                                       HttpHeaders trailers, Executor executor,
                                       Function<? super T, String> contentConverter) {
        requireNonNull(contentConverter, "contentConverter");
        return streamingFrom(contentStream, sanitizeHeaders(headers), trailers,
                             o -> toHttpData(contentConverter, o), executor);
    }
Creates a new JSON Text Sequences from the specified {@link Stream}.

<p>Note that this method is intentionally hidden from the public API for use only with
{@code ScalaPbResponseConverterFunction} and {@code ProtobufResponseConverterFunction}.
Because the {@code contentConverter} can easily produce a malformed string which violates the
<a href="https://datatracker.ietf.org/doc/rfc8259/">JSON format</a>.

@param headers the HTTP headers supposed to send
@param contentStream the {@link Stream} which publishes the objects supposed to send as contents
@param trailers the HTTP trailers
@param executor the executor which iterates the stream
@param contentConverter the function which converts the content object into a UTF-8 JSON string
core/src/main/java/com/linecorp/armeria/server/streaming/JsonTextSequences.java