Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions cni/network/invoker_azure.go
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,10 @@ func (invoker *AzureIPAMInvoker) Add(addConfig IPAMAddConfig) (IPAMAddResult, er

if err != nil && strings.Contains(err.Error(), ipam.ErrNoAvailableAddressPools.Error()) {
invoker.deleteIpamState()
logger.Info("Retry pool allocation after deleting IPAM state")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did you validate and it worked? Like CNI able to recover and second DelegateAdd call succeeded?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I checked the logs and there was no follow-up Delete and Add call by containerd after this change was made - the container was created with the single ADD call.

addResult.ipv4Result, err = invoker.plugin.DelegateAdd(addConfig.nwCfg.IPAM.Type, addConfig.nwCfg)
}

if err != nil {
err = invoker.plugin.Errorf("Failed to allocate pool: %v", err)
return addResult, err
Expand Down