gall: kill subscriptions after agents reload

This commit is contained in:
Ted Blackman 2022-07-05 14:06:58 +01:00 committed by yosoyubik
parent 78b1c521c7
commit 5f8378e1b7

View File

@ -204,8 +204,10 @@
=. state.adult
[%9 system-duct outstanding contacts yokes=~ blocked bug]:spore
=/ mo-core (mo-abed:mo:adult system-duct.state.adult)
=/ apps=(list [dap=term =egg]) ~(tap by eggs.spore)
:: upgrade %base apps and suspend others
::
=. mo-core
=/ apps=(list [dap=term =egg]) ~(tap by eggs.spore)
|- ^+ mo-core
?~ apps mo-core
?. =(%base q.beak.egg.i.apps)
@ -220,17 +222,23 @@
=? ap-core ?=(%& -.old-state.egg.i.apps)
=^ tan ap-core (ap-install:ap-core `p.old-state.egg.i.apps)
?^ tan
(mean u.tan)
=? ap-core (lth -.spore %9)
~> %slog.[0 leaf+"gall: running +ap-kill-down"]
=/ boats=(list [=wire =dock])
~(tap in ~(key by boat.egg.i.apps))
|- ^+ ap-core
?~ boats ap-core
=/ [=wire =dock] i.boats
$(boats t.boats, ap-core (ap-kill-down:ap-core wire dock))
(mean u.tan)
ap-core
$(apps t.apps, mo-core ap-abet:ap-core)
:: kill subscriptions when upgrading to gall request queue fix
::
=. mo-core
|- ^+ mo-core
?~ apps mo-core
=? ap-core (lth -.spore %9)
~> %slog.[0 leaf+"gall: running +ap-kill-down"]
=/ boats=(list [=wire =dock])
~(tap in ~(key by boat.egg.i.apps))
|- ^+ ap-core
?~ boats ap-core
=/ [=wire =dock] i.boats
$(boats t.boats, ap-core (ap-kill-down:ap-core wire dock))
$(apps t.apps, mo-core ap-abet:ap-core)
=. mo-core (mo-subscribe-to-agent-builds:mo-core now)
=^ moves adult-gate mo-abet:mo-core
=? moves ?=(^ fec) (weld moves [u.fec]~)