Enum Class StreamTerminationReason
- All Implemented Interfaces:
Serializable, Comparable<StreamTerminationReason>, Constable
Reasons why a streaming HTTP response, Server-Sent Event connection, or MCP SSE stream may terminate.
- Author:
- Mark Allen
-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionProducer code intentionally aborted the stream.The stream was closed due to backpressure.The client disconnected before the stream completed.The stream completed normally.An unexpected internal error occurred.The stream producer failed.The request protocol cannot support the stream.The stream exceeded its configured producer idle timeout.The stream exceeded its configured total response timeout.The server stopped before the stream completed.The stream ended because its owning session was terminated.The simulator refused to materialize more streaming response bytes.The stream ended for an unspecified reason.A write to the stream failed. -
Method Summary
Modifier and TypeMethodDescriptionstatic StreamTerminationReasonReturns the enum constant of this class with the specified name.static StreamTerminationReason[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
COMPLETED
The stream completed normally. -
CLIENT_DISCONNECTED
The client disconnected before the stream completed. -
SERVER_STOPPING
The server stopped before the stream completed. -
PROTOCOL_UNSUPPORTED
The request protocol cannot support the stream. -
RESPONSE_TIMEOUT
The stream exceeded its configured total response timeout. -
RESPONSE_IDLE_TIMEOUT
The stream exceeded its configured producer idle timeout. -
APPLICATION_CANCELED
Producer code intentionally aborted the stream. -
BACKPRESSURE
The stream was closed due to backpressure. -
SESSION_TERMINATED
The stream ended because its owning session was terminated. -
WRITE_FAILED
A write to the stream failed. -
PRODUCER_FAILED
The stream producer failed. -
INTERNAL_ERROR
An unexpected internal error occurred. -
SIMULATOR_LIMIT_EXCEEDED
The simulator refused to materialize more streaming response bytes. -
UNKNOWN
The stream ended for an unspecified reason.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-