Skip to content

Commit a2d9b0b

Browse files
authored
Merge pull request #2020 from aaronlehmann/update-unallocated-items
allocator: Update unallocatedServices properly after service updates
2 parents 54cfa17 + 92e74a2 commit a2d9b0b

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

manager/allocator/network.go

+3
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,9 @@ func (a *Allocator) doNetworkAlloc(ctx context.Context, ev events.Event) {
402402
return a.commitAllocatedService(ctx, batch, s)
403403
}); err != nil {
404404
log.G(ctx).WithError(err).Errorf("Failed to commit allocation during update for service %s", s.ID)
405+
nc.unallocatedServices[s.ID] = s
406+
} else {
407+
delete(nc.unallocatedServices, s.ID)
405408
}
406409
case state.EventDeleteService:
407410
s := v.Service.Copy()

0 commit comments

Comments
 (0)