@FunctionalInterface
public interface BlockingStreamingHttpService
extends GracefulAutoCloseable
StreamingHttpService but with synchronous/blocking APIs instead of asynchronous APIs.| Modifier and Type | Method and Description |
|---|---|
default void |
close() |
void |
handle(HttpServiceContext ctx,
BlockingStreamingHttpRequest request,
BlockingStreamingHttpServerResponse response)
Handles a single HTTP request.
|
void handle(HttpServiceContext ctx, BlockingStreamingHttpRequest request, BlockingStreamingHttpServerResponse response) throws Exception
ctx - Context of the service.request - to handle.response - to send to the client. The implementation of this method is responsible for calling
Closeable.close() on the BlockingStreamingHttpServerResponse.payloadWriter().Exception - If an exception occurs during request processing.default void close()
throws Exception
close in interface AutoCloseableException