Copy

inner class Copy

One queued copy; decide tells it the local hand-off result.

Properties

Link copied to clipboard
val sent: Mono<Void>

Completes when this copy was sent, or fails with the send error.

Functions

Link copied to clipboard
fun decide(handoff: LocalHandoff)

The local hand-off result; only the first call counts.

Link copied to clipboard
fun decideFrom(handoff: Mono<LocalHandoff>): Mono<LocalHandoff>

Subscribes handoff on behalf of this copy, independently of the sender, in the captured sender context (trace parent, metrics source): the copy is decided by the true local result even when the sender stops waiting (cancels) before it arrives. An error or an empty result counts as refused, and so does a result that does not arrive within the hand-off timeout (the timer is only armed when the result is not immediate). The returned Mono replays the result to the sender.