TaskBridgeConfig
data class TaskBridgeConfig<Ctx>(val baseUrl: String, val transportFactory: TaskBridgeTransportFactory<Ctx>, val routeResolver: TaskBridgeRouteResolver<Ctx> = DefaultTaskBridgeRouteResolver(), val authHeaderProvider: suspend (context: Ctx, forceRefresh: Boolean) -> String?? = null, val checkpointStore: TaskBridgeCheckpointStore = InMemoryTaskBridgeCheckpointStore(), val checkpointNamespace: String? = null, val failureClassifier: TaskBridgeFailureClassifier = DefaultTaskBridgeFailureClassifier(), val retryPolicy: TaskBridgeRetryPolicy = ExponentialBackoffTaskBridgeRetryPolicy(), val retryGate: TransportRetryGate = NoOpTransportRetryGate, val streamTransport: TaskBridgeStreamTransportConfig = TaskBridgeStreamTransportConfig(), val transportEventListener: TaskBridgeTransportEventListener<Ctx>? = null, val json: Json = taskBridgeJson(), val dispatcher: CoroutineDispatcher = Dispatchers.IO, val commandMaxAttempts: Int = 3)
Configuration for TaskBridgeClient.
Constructors
Link copied to clipboard
constructor(baseUrl: String, transportFactory: TaskBridgeTransportFactory<Ctx>, routeResolver: TaskBridgeRouteResolver<Ctx> = DefaultTaskBridgeRouteResolver(), authHeaderProvider: suspend (context: Ctx, forceRefresh: Boolean) -> String?? = null, checkpointStore: TaskBridgeCheckpointStore = InMemoryTaskBridgeCheckpointStore(), checkpointNamespace: String? = null, failureClassifier: TaskBridgeFailureClassifier = DefaultTaskBridgeFailureClassifier(), retryPolicy: TaskBridgeRetryPolicy = ExponentialBackoffTaskBridgeRetryPolicy(), retryGate: TransportRetryGate = NoOpTransportRetryGate, streamTransport: TaskBridgeStreamTransportConfig = TaskBridgeStreamTransportConfig(), transportEventListener: TaskBridgeTransportEventListener<Ctx>? = null, json: Json = taskBridgeJson(), dispatcher: CoroutineDispatcher = Dispatchers.IO, commandMaxAttempts: Int = 3)
Properties
Link copied to clipboard
Optional function to provide "Authorization" header value for requests. The second parameter is forceRefresh, indicating a previous token was rejected with 401.
Link copied to clipboard
Optional namespace to isolate checkpoints in the store.
Link copied to clipboard
Store for persisting task event IDs to allow resuming after app restart.
Link copied to clipboard
Maximum retry attempts for non-streaming HTTP commands.
Link copied to clipboard
Dispatcher for internal asynchronous operations.
Link copied to clipboard
Determines which network or protocol errors are retryable.
Link copied to clipboard
Link copied to clipboard
Strategy for backoff between retries.
Link copied to clipboard
Customizes path resolution for API endpoints.
Link copied to clipboard
Configuration for the event streaming mechanism.
Link copied to clipboard
Listener for internal transport lifecycle events (logging, debugging).
Link copied to clipboard
Factory to create the underlying networking transport.