I am trying to use retry with delay function, I expect function will call after 1000ms delay, but it doesnot, what can be error here?
look at conso
I recently had this problem, and found that the accepted solution could be improved.
Observable.pipe(
retryWhen(errors => errors.pipe(
delay(1000),
take(10))),
first(v => true),
timeout(10000))
What it essentially does is to retry as mentioned, but this finishes right away without adding any (erroneous) value using the 'first' operator.
If it cannot find a value within the timeout timeframe, an error is raised.