public static <T> HttpResponse fromPublisher(ResponseHeaders headers,
                                                 Publisher<T> contentPublisher,
                                                 HttpHeaders trailers,
                                                 Function<? super T, ? extends ServerSentEvent> converter) {
        requireNonNull(headers, "headers");
        requireNonNull(contentPublisher, "contentPublisher");
        requireNonNull(trailers, "trailers");
        requireNonNull(converter, "converter");
        return streamingFrom(contentPublisher, sanitizeHeaders(headers), trailers,
                             o -> toHttpData(converter, o));
    }
Creates a new Server-Sent Events stream from the specified {@link Publisher} and {@code converter}.

@param headers the HTTP headers supposed to send
@param contentPublisher the {@link Publisher} which publishes the objects supposed to send as contents
@param trailers the HTTP trailers
@param converter the converter which converts published objects into {@link ServerSentEvent}s
core/src/main/java/com/linecorp/armeria/server/streaming/ServerSentEvents.java