Runtime.Ctl.spawn: def of bend-kube-runtime@0.2.0.0 Import: import bend-kube-runtime@0.2.0.0/src/runtime.bend as Runtime Lines 514-525 of bend-kube-runtime@0.2.0.0/src/runtime.bend: https://jend.leeeet.dev/read.txt?path=bend-kube-runtime@0.2.0.0/src/runtime.bend&start_line=514&end_line=525 import Base import bend-kube-runtime@0.2.0.0/src/json.bend as J import bend-kube-runtime@0.2.0.0/src/config.bend as K import bend-kube-runtime@0.2.0.0/src/queue.bend as Q # Starts a reconcile per job; each answers MDone on the channel. def Ctl.spawn(~rec: U32 -> J.Json -> K.Config -> IO(Q.Action), jobs: List<&2, Job>, +chan: Chan(Msg), +cfg: K.Config, +idx: U32) -> IO(Unit): match jobs: case Nil{}: IO.pure(Unit, Unit{}) case Con{Job{key, o}, t}: IO.bind(Unit, Unit, IO.spawn(Result<&1, &1, Msg, Unit>, IO.bind(Q.Action, Result<&1, &1, Msg, Unit>, rec(idx, o, cfg), a => Chan.send(Msg, chan, MDone{key, a}))), u => Ctl.spawn(~rec, t, chan, cfg, idx)) Uses (15): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Chan https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Chan.send https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.pure https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.spawn https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Unit https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/config.bend&name=Config https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/json.bend&name=Json https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/queue.bend&name=Action https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/runtime.bend&name=Job https://jend.leeeet.dev/definition.txt?path=bend-kube-runtime@0.2.0.0/src/runtime.bend&name=Msg