-
public class StreamSocketConfig.CompanionDefault values for StreamSocketConfig fields.
-
-
Field Summary
Fields Modifier and Type Field Description private final LongDEFAULT_HEALTH_INTERVAL_MSprivate final LongDEFAULT_LIVENESS_MSprivate final LongDEFAULT_CONNECTION_TIMEOUT_MSprivate final IntegerDEFAULT_AGGREGATION_THRESHOLDprivate final LongDEFAULT_AGGREGATION_MAX_WINDOW_MSprivate final IntegerDEFAULT_AGGREGATION_DISPATCH_QUEUE_CAPACITYpublic final static StreamSocketConfig.CompanionINSTANCE
-
Method Summary
Modifier and Type Method Description final StreamSocketConfigjwt(StreamWsUrl url, StreamApiKey apiKey, StreamHttpClientInfoHeader clientInfoHeader, Long healthCheckIntervalMs, Long livenessThresholdMs, Long connectionTimeoutMs, Integer aggregationThreshold, Long aggregationMaxWindowMs, Integer aggregationDispatchQueueCapacity)Creates a JWT-based StreamSocketConfig. final StreamSocketConfiganonymous(StreamWsUrl url, StreamApiKey apiKey, StreamHttpClientInfoHeader clientInfoHeader, Long healthCheckIntervalMs, Long livenessThresholdMs, Long connectionTimeoutMs, Integer aggregationThreshold, Long aggregationMaxWindowMs, Integer aggregationDispatchQueueCapacity)Creates an anonymous StreamSocketConfig. final StreamSocketConfigcustom(StreamWsUrl url, StreamApiKey apiKey, String authType, StreamHttpClientInfoHeader clientInfoHeader, Long healthCheckIntervalMs, Long livenessThresholdMs, Long connectionTimeoutMs, Integer aggregationThreshold, Long aggregationMaxWindowMs, Integer aggregationDispatchQueueCapacity)Creates a custom StreamSocketConfig. final LonggetDEFAULT_HEALTH_INTERVAL_MS()Default health check ping interval: 25 seconds. final LonggetDEFAULT_LIVENESS_MS()Default liveness threshold: 60 seconds without ack. final LonggetDEFAULT_CONNECTION_TIMEOUT_MS()Default connection timeout: 10 seconds. final IntegergetDEFAULT_AGGREGATION_THRESHOLD()Default aggregation threshold: 50 events trigger aggregated delivery. final LonggetDEFAULT_AGGREGATION_MAX_WINDOW_MS()Default aggregation max window: 500ms latency ceiling. final IntegergetDEFAULT_AGGREGATION_DISPATCH_QUEUE_CAPACITY()Default dispatch queue capacity: 16 items. -
-
Method Detail
-
jwt
final StreamSocketConfig jwt(StreamWsUrl url, StreamApiKey apiKey, StreamHttpClientInfoHeader clientInfoHeader, Long healthCheckIntervalMs, Long livenessThresholdMs, Long connectionTimeoutMs, Integer aggregationThreshold, Long aggregationMaxWindowMs, Integer aggregationDispatchQueueCapacity)
Creates a JWT-based StreamSocketConfig.
- Parameters:
url- WebSocket endpoint URL.apiKey- Stream API key for authentication.clientInfoHeader- X-Stream-Client header value.healthCheckIntervalMs- Interval between health check pings in milliseconds.livenessThresholdMs- Liveness threshold in milliseconds.connectionTimeoutMs- WebSocket connection timeout in milliseconds.aggregationThreshold- Events before aggregated delivery triggers.aggregationMaxWindowMs- Maximum collection window in milliseconds.aggregationDispatchQueueCapacity- Dispatch queue capacity.
-
anonymous
final StreamSocketConfig anonymous(StreamWsUrl url, StreamApiKey apiKey, StreamHttpClientInfoHeader clientInfoHeader, Long healthCheckIntervalMs, Long livenessThresholdMs, Long connectionTimeoutMs, Integer aggregationThreshold, Long aggregationMaxWindowMs, Integer aggregationDispatchQueueCapacity)
Creates an anonymous StreamSocketConfig.
- Parameters:
url- WebSocket endpoint URL.apiKey- Stream API key for authentication.clientInfoHeader- X-Stream-Client header value.healthCheckIntervalMs- Interval between health check pings in milliseconds.livenessThresholdMs- Liveness threshold in milliseconds.connectionTimeoutMs- WebSocket connection timeout in milliseconds.aggregationThreshold- Events before aggregated delivery triggers.aggregationMaxWindowMs- Maximum collection window in milliseconds.aggregationDispatchQueueCapacity- Dispatch queue capacity.
-
custom
final StreamSocketConfig custom(StreamWsUrl url, StreamApiKey apiKey, String authType, StreamHttpClientInfoHeader clientInfoHeader, Long healthCheckIntervalMs, Long livenessThresholdMs, Long connectionTimeoutMs, Integer aggregationThreshold, Long aggregationMaxWindowMs, Integer aggregationDispatchQueueCapacity)
Creates a custom StreamSocketConfig.
- Parameters:
url- WebSocket endpoint URL.apiKey- Stream API key for authentication.authType- Authentication type (e.g., "jwt", "anonymous").clientInfoHeader- X-Stream-Client header value.healthCheckIntervalMs- Interval between health check pings in milliseconds.livenessThresholdMs- Liveness threshold in milliseconds.connectionTimeoutMs- WebSocket connection timeout in milliseconds.aggregationThreshold- Events before aggregated delivery triggers.aggregationMaxWindowMs- Maximum collection window in milliseconds.aggregationDispatchQueueCapacity- Dispatch queue capacity.
-
getDEFAULT_HEALTH_INTERVAL_MS
final Long getDEFAULT_HEALTH_INTERVAL_MS()
Default health check ping interval: 25 seconds.
-
getDEFAULT_LIVENESS_MS
final Long getDEFAULT_LIVENESS_MS()
Default liveness threshold: 60 seconds without ack.
-
getDEFAULT_CONNECTION_TIMEOUT_MS
final Long getDEFAULT_CONNECTION_TIMEOUT_MS()
Default connection timeout: 10 seconds.
-
getDEFAULT_AGGREGATION_THRESHOLD
final Integer getDEFAULT_AGGREGATION_THRESHOLD()
Default aggregation threshold: 50 events trigger aggregated delivery.
-
getDEFAULT_AGGREGATION_MAX_WINDOW_MS
final Long getDEFAULT_AGGREGATION_MAX_WINDOW_MS()
Default aggregation max window: 500ms latency ceiling.
-
getDEFAULT_AGGREGATION_DISPATCH_QUEUE_CAPACITY
final Integer getDEFAULT_AGGREGATION_DISPATCH_QUEUE_CAPACITY()
Default dispatch queue capacity: 16 items.
-
-
-
-