def Drv.pause
import bend-kube-runtime@0.2.0.0/src/runtime.bend as Runtimeimport Base
import bend-kube-runtime@0.2.0.0/src/watcher.bend as W
187# Sleeps the watcher's backoff, with up to 50% jitter, when asked to.
188def Drv.pause(wait: Bool, +fails: U32, path: String) -> IO(Unit):
189 match wait:
190 case True{}:
191 IO.bind(Result<&1, &1, U32 & String, U32>, Unit, IO.random_u32(),
192 r => Drv.pause.go(Drv.jitter(W.Backoff.delay(fails), r), fails, path))
193 case False{}:
194 IO.pure(Unit, Unit{})