Class SSEParserConfig.Builder

java.lang.Object
org.a2aproject.sdk.client.http.SSEParserConfig.Builder
Enclosing class:
SSEParserConfig

public static final class SSEParserConfig.Builder extends Object
  • Method Details

    • maxLineLength

      public SSEParserConfig.Builder maxLineLength(int maxLineLength)
      Sets the maximum number of bytes allowed in a single raw SSE line. Set to 0 to disable the per-line check.

      Security note: disabling this check removes the first line of defence against memory exhaustion from oversized SSE lines. Ensure maxBufferChars is set to an acceptable upper bound when disabling.

    • maxBufferLines

      public SSEParserConfig.Builder maxBufferLines(int maxBufferLines)
      Sets the maximum number of data: lines allowed in a single event block.
    • maxBufferChars

      public SSEParserConfig.Builder maxBufferChars(int maxBufferChars)
      Sets the maximum total characters across all data: values in a single event.
    • build

      public SSEParserConfig build()