Error: 'Operator "retry" requires asynchronous pipeline'
when used inside a synchronous pipeline.
When an asynchronous iterable rejects, the callback is to return the flag, indicating whether we should retry getting the value one more time.
The callback is only invoked when there is a failure, and it receives:
index
- index of the iterable value that we failed to acquireattempts
- number of retry attempts made so far (starts with 0)state
- state for the entire iteration sessionNote that retries deplete values prior the operator that threw the error, and so it is often used in combination with operator repeat.
Error: 'Operator "retry" requires asynchronous pipeline'
when used inside a synchronous pipeline.
When an asynchronous iterable rejects, it retries getting the value specified number of times.
Note that retries deplete values prior the operator that threw the error, and so it is often used in combination with operator repeat.
Above, we end up with just odd numbers, because we do not provide any repeat logic, and as a result, the
retry
simply jumps to the next value on each error.