Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- retrying :: forall e w u t d r a. TimeUnit w => TimeUnit u => Members [Race, Time t d] r => w -> u -> Sem r (Either e a) -> Sem r (Maybe a)
- retryingWithError :: forall e w u t d r a. TimeUnit w => TimeUnit u => Members [Race, Time t d, Embed IO] r => w -> u -> Sem r (Either e a) -> Sem r (Maybe (Either e a))
Documentation
:: forall e w u t d r a. TimeUnit w | |
=> TimeUnit u | |
=> Members [Race, Time t d] r | |
=> w | The timeout after which the attempt is abandoned. |
-> u | The waiting interval between two tries. |
-> Sem r (Either e a) | |
-> Sem r (Maybe a) |
Run an action repeatedly until it returns Right
or the timout has been exceeded.
:: forall e w u t d r a. TimeUnit w | |
=> TimeUnit u | |
=> Members [Race, Time t d, Embed IO] r | |
=> w | The timeout after which the attempt is abandoned. |
-> u | The waiting interval between two tries. |
-> Sem r (Either e a) | |
-> Sem r (Maybe (Either e a)) |
Run an action repeatedly until it returns Right
or the timout has been exceeded.
If the action failed at least once, the last error will be returned in case of timeout.