Interface SseSourceConfigurer


@Experimental @NoImplement @MinMuleVersion("4.10.0") public interface SseSourceConfigurer
Allows to configure parameters to the SseSource.
Since:
0.12.0
  • Method Details

    • withResponse

      SseSourceConfigurer withResponse(HttpResponse response)
      Useful when you already have an HttpResponse with an SSE stream. The resulting SSE Source won't do automatic retries.
      Parameters:
      response - a response that has a text/event-stream as payload.
      Returns:
      this configurer.
    • withUrl

      Sets the URL of the server to send the SSE initiator request to.
      Parameters:
      url - the server URL.
      Returns:
      this configurer.
    • withAllowRetryDelayOverride

      SseSourceConfigurer withAllowRetryDelayOverride(boolean allow)
      Configures whether the resulting source allows the server to override the delay for retries.
      Parameters:
      allow - whether the source allows the override or not.
      Returns:
      this configurer.
    • withInitialRetryDelayMillis

      SseSourceConfigurer withInitialRetryDelayMillis(long initialRetryDelayMillis)
      Configures the initial retry delay of the resulting source.
      Parameters:
      initialRetryDelayMillis - the delay in milliseconds.
      Returns:
      this configurer.
    • withRetry

      SseSourceConfigurer withRetry(boolean shouldRetryOnStreamEnd)
      Configures whether the source will retry when the SSE stream ends.
      Parameters:
      shouldRetryOnStreamEnd - whether retry or not.
      Returns:
      this configurer.
    • withRequestCustomizer

      SseSourceConfigurer withRequestCustomizer(Consumer<HttpRequestBuilder> requestCustomizer)
      Configures a callback to customize the initiator request builder.
      Parameters:
      requestCustomizer - the callback.
      Returns:
      this configurer.
    • withRequestOptions

      SseSourceConfigurer withRequestOptions(Consumer<HttpRequestOptionsConfigurer> requestOptions)
      Configures a callback to customize the initiator request options.
      Parameters:
      requestOptions - the callback.
      Returns:
      this configurer.
    • withPreserveHeadersCase

      SseSourceConfigurer withPreserveHeadersCase(boolean preserveHeadersCase)
      Configures whether the initiator request has to preserve the header case or not.
      Parameters:
      preserveHeadersCase - whether the initiator request has to preserve the header case or not.
      Returns:
      this configurer.