requeue logic for pending NAD#445
Conversation
The operator currently returns a misleading reconcile error when Pod interfaces are not yet ready with assigned IPs. This change introduces a requeue mechanism to allow time for NetworkAttachmentDefinitions (NAD) to be fully provisioned.
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: posikoya The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @posikoya. Thanks for your PR. I'm waiting for a openstack-k8s-operators member to verify that this patch is reasonable to test. If it is, they should reply with Regular contributors should join the org to skip this step. Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
Build failed (check pipeline). Post ✔️ openstack-k8s-operators-content-provider SUCCESS in 2h 44m 52s |
|
/ok-to-test |
| err.Error())) | ||
|
|
||
| return ctrl.Result{}, err | ||
| return ctrl.Result{RequeueAfter: time.Second * 10}, nil |
There was a problem hiding this comment.
I do think it is a good idea to re-queue, but I am concerned what will happen if the NAD is actually faulty. It seems it will re-queue forever without printing any error in the logs. How would you prevent this?
| } | ||
|
|
||
| return ctrl.Result{}, nil | ||
| return ctrl.Result{}, err |
There was a problem hiding this comment.
Returning an error here might mean that when the if networkReady conditions is true, the whole function will return an error, which is not something we want :D
The operator currently returns a misleading reconcile error when Pod interfaces are not yet ready with assigned IPs. This change introduces a requeue mechanism to allow time for NetworkAttachmentDefinitions (NAD) to be fully provisioned.