)]}'
{"metropolis/node/core/update/update.go":[{"author":{"_account_id":1000002,"name":"Serge Bazanski","display_name":"Serge","email":"serge@monogon.tech","username":"serge","avatars":[{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d32","height":32},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d56","height":56},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d100","height":100},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d120","height":120}]},"change_message_id":"9cbb0299e087aaaecb0c887846dadbb4506aa133","unresolved":true,"context_lines":[{"line_number":192,"context_line":"// KexecLoadNext loads the slot to be booted next into the kexec staging area."},{"line_number":193,"context_line":"// The next slot can then be launched by executing kexec via the reboot"},{"line_number":194,"context_line":"// syscall. Calling this function counts as a next boot for the purposes of"},{"line_number":195,"context_line":"// A/B state tracking, so it should not be called without kexecing afterwards."},{"line_number":196,"context_line":"func (s *Service) KexecLoadNext() error {"},{"line_number":197,"context_line":"\tstate, err :\u003d s.getABState()"},{"line_number":198,"context_line":"\tif err !\u003d nil {"}],"source_content_type":"text/x-go","patch_set":1,"id":"292a7337_6d628352","line":195,"range":{"start_line":195,"start_character":23,"end_line":195,"end_character":78},"updated":"2024-09-09 16:45:11.000000000","message":"Why not combine this with an immediate kexec so that we can avoid the \u0027should not\u0027 / human-readable contract?","commit_id":"027c8963260ccba4b30476aa6b04a7f057d5988a"},{"author":{"_account_id":1000001,"name":"Lorenz Brun","display_name":"Lorenz","email":"lorenz@monogon.tech","username":"lorenz","avatars":[{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d32","height":32},{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d56","height":56},{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d100","height":100},{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d120","height":120}]},"change_message_id":"c1334b3ce6530576769fdc8d20430e0733d9829d","unresolved":true,"context_lines":[{"line_number":192,"context_line":"// KexecLoadNext loads the slot to be booted next into the kexec staging area."},{"line_number":193,"context_line":"// The next slot can then be launched by executing kexec via the reboot"},{"line_number":194,"context_line":"// syscall. Calling this function counts as a next boot for the purposes of"},{"line_number":195,"context_line":"// A/B state tracking, so it should not be called without kexecing afterwards."},{"line_number":196,"context_line":"func (s *Service) KexecLoadNext() error {"},{"line_number":197,"context_line":"\tstate, err :\u003d s.getABState()"},{"line_number":198,"context_line":"\tif err !\u003d nil {"}],"source_content_type":"text/x-go","patch_set":1,"id":"9966f967_01bd8bbe","line":195,"range":{"start_line":195,"start_character":23,"end_line":195,"end_character":78},"in_reply_to":"292a7337_6d628352","updated":"2024-09-09 20:36:18.000000000","message":"Because in almost all cases there needs to be work performed between this and the actual kexec call. The amount of time between calling this and kexec is not really relevant, but it should eventually be called and this function should not be repeatedly called before.","commit_id":"027c8963260ccba4b30476aa6b04a7f057d5988a"},{"author":{"_account_id":1000002,"name":"Serge Bazanski","display_name":"Serge","email":"serge@monogon.tech","username":"serge","avatars":[{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d32","height":32},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d56","height":56},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d100","height":100},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d120","height":120}]},"change_message_id":"7fcd1187827824d991233ebd51938d0a278de5f6","unresolved":false,"context_lines":[{"line_number":192,"context_line":"// KexecLoadNext loads the slot to be booted next into the kexec staging area."},{"line_number":193,"context_line":"// The next slot can then be launched by executing kexec via the reboot"},{"line_number":194,"context_line":"// syscall. Calling this function counts as a next boot for the purposes of"},{"line_number":195,"context_line":"// A/B state tracking, so it should not be called without kexecing afterwards."},{"line_number":196,"context_line":"func (s *Service) KexecLoadNext() error {"},{"line_number":197,"context_line":"\tstate, err :\u003d s.getABState()"},{"line_number":198,"context_line":"\tif err !\u003d nil {"}],"source_content_type":"text/x-go","patch_set":1,"id":"c983d7c0_e441d70c","line":195,"range":{"start_line":195,"start_character":23,"end_line":195,"end_character":78},"in_reply_to":"346cb5b2_5bdcc78d","updated":"2024-09-11 12:32:48.000000000","message":"Acknowledged","commit_id":"027c8963260ccba4b30476aa6b04a7f057d5988a"},{"author":{"_account_id":1000002,"name":"Serge Bazanski","display_name":"Serge","email":"serge@monogon.tech","username":"serge","avatars":[{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d32","height":32},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d56","height":56},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d100","height":100},{"url":"https://www.gravatar.com/avatar/52c41428b6369f2c02b9717425216f7d.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d120","height":120}]},"change_message_id":"5f0db76c131ff0f7d00ef5640d167f355f6cc854","unresolved":true,"context_lines":[{"line_number":192,"context_line":"// KexecLoadNext loads the slot to be booted next into the kexec staging area."},{"line_number":193,"context_line":"// The next slot can then be launched by executing kexec via the reboot"},{"line_number":194,"context_line":"// syscall. Calling this function counts as a next boot for the purposes of"},{"line_number":195,"context_line":"// A/B state tracking, so it should not be called without kexecing afterwards."},{"line_number":196,"context_line":"func (s *Service) KexecLoadNext() error {"},{"line_number":197,"context_line":"\tstate, err :\u003d s.getABState()"},{"line_number":198,"context_line":"\tif err !\u003d nil {"}],"source_content_type":"text/x-go","patch_set":1,"id":"9de47255_e60009c9","line":195,"range":{"start_line":195,"start_character":23,"end_line":195,"end_character":78},"in_reply_to":"9966f967_01bd8bbe","updated":"2024-09-10 12:24:00.000000000","message":"The only use I see is in https://review.monogon.dev/c/monogon/+/3354/8 (Reboot RPC).\n\nHow about we roll\n\n```\n\ts.LogTree.MustLeveledFor(\"root.mgmt\").Warning(\"Reboot requested, rebooting in 2s\")\n\tgo func() {\n\t\ttime.Sleep(2 * time.Second)\n\t\tunix.Unmount(s.UpdateService.ESPPath, 0)\n\t\tunix.Sync()\n\t\tunix.Reboot(method)\n\t}()\n```\n\ninto some function in eg. core, and call it both from here directly and whoever else ends up scheduling a reboot? Then we also have only one spot we need to in the future implement correctly tearing down the supervision tree.","commit_id":"027c8963260ccba4b30476aa6b04a7f057d5988a"},{"author":{"_account_id":1000001,"name":"Lorenz Brun","display_name":"Lorenz","email":"lorenz@monogon.tech","username":"lorenz","avatars":[{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d32","height":32},{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d56","height":56},{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d100","height":100},{"url":"https://www.gravatar.com/avatar/75c04f6e9881c24ee621fba80667eed8.jpg?d\u003didenticon\u0026r\u003dpg\u0026s\u003d120","height":120}]},"change_message_id":"cba84c8733099f578871abe738517627bec7b1c1","unresolved":true,"context_lines":[{"line_number":192,"context_line":"// KexecLoadNext loads the slot to be booted next into the kexec staging area."},{"line_number":193,"context_line":"// The next slot can then be launched by executing kexec via the reboot"},{"line_number":194,"context_line":"// syscall. Calling this function counts as a next boot for the purposes of"},{"line_number":195,"context_line":"// A/B state tracking, so it should not be called without kexecing afterwards."},{"line_number":196,"context_line":"func (s *Service) KexecLoadNext() error {"},{"line_number":197,"context_line":"\tstate, err :\u003d s.getABState()"},{"line_number":198,"context_line":"\tif err !\u003d nil {"}],"source_content_type":"text/x-go","patch_set":1,"id":"346cb5b2_5bdcc78d","line":195,"range":{"start_line":195,"start_character":23,"end_line":195,"end_character":78},"in_reply_to":"9de47255_e60009c9","updated":"2024-09-10 17:21:36.000000000","message":"I can factor out that code into a function in metropolis/node/core/mgmt/power.go, but that is an ugly rebase as that file currently doesn\u0027t exist until the Reboot RPC is introduced. I can do that on top of the current stack though. All callers of that function would be in the mgmt package, not the update package which has no reference to that service.","commit_id":"027c8963260ccba4b30476aa6b04a7f057d5988a"}]}
