updates

fun updates(subscription: UpdateSubscription): Flow<LedgerUpdate>

Streams ledger updates for subscription, transparently reconnecting on retryable failures and resuming from the offset of the last received update — consumers see one uninterrupted, gap-free stream. The retry budget resets only once a connection has proven healthy: it delivered at least one update and stayed alive for RetryPolicy.streamHealthyWindow. Shorter-lived connections keep escalating the backoff until RetryPolicy.maxAttempts is exhausted.

The flow completes normally when the server ends the stream (only for subscriptions with UpdateSubscription.endInclusive set) and throws CantonException on non-retryable failures.