maxRetries property
How many times a batch handed back through the retry buffer is retried before it is dropped.
Counts a run of failures, not the lifetime of the publisher: a batch
that gets through resets the budget, so a sink that comes back gets
the full allowance again. When the budget is spent the batch goes to
onDropped and the queue moves on.
There is no unbounded setting, and that is the point. Retrying for
ever is not "never lose a log": a deterministically failing batch — a
toString that throws, a value that cannot be serialised — is never
delivered and never dropped either, it just holds the queue and burns
a core. Measured before this existed: 242 820 handler calls and as
many onError calls in half a second, from one log.
Zero means a batch that is handed back is dropped at once.
Together with retryDelay this also bounds how long a publisher
nobody closes keeps the isolate alive: a pending retry timer is
a live root for the event loop, so before the budget existed a
worker with a dead sink returned from main and never exited.
close does not wait any of it out — it cancels the pending
timer and makes one prompt final attempt.
Implementation
final int maxRetries;