Hold a merge the controller cannot record now, and hand it over again, instead of taking it (issue 921)

This commit is contained in:
2026-10-17 12:03:00 +02:00
parent b0d489a86c
commit 379a52c2e8
4 changed files with 65 additions and 6 deletions
+3 -3
View File
@@ -294,10 +294,10 @@ func (f following) Announceable(ctx context.Context) ([]link.Announcement, error
return out, nil
}
// notNow marks a store that could not be read right now, so the announcement is held rather than
// lost; anything else is returned as it was.
// notNow marks a store that could not be read right now, or plans another controller is working (issue 921), so
// the announcement is held rather than lost; anything else is returned as it was.
func notNow(err error) error {
if inventory.Unreachable(err) {
if inventory.Unreachable(err) || errors.Is(err, inventory.ErrPlansBusy) {
return fmt.Errorf("%w: %w", link.ErrTryAgain, err)
}
return err