Skip to content

Commit

Permalink
Merge pull request #487 from e0ne/node-state-render
Browse files Browse the repository at this point in the history
Render SriovNetworkNodeState before Device Plugin ConfigMap
  • Loading branch information
adrianchiris authored Aug 8, 2023
2 parents 3500926 + 18a288a commit 7b5ecac
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions controllers/sriovnetworknodepolicy_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,10 @@ func (r *SriovNetworkNodePolicyReconciler) Reconcile(ctx context.Context, req ct

// Sort the policies with priority, higher priority ones is applied later
sort.Sort(sriovnetworkv1.ByPriority(policyList.Items))
// Sync SriovNetworkNodeState objects
if err = r.syncAllSriovNetworkNodeStates(ctx, defaultPolicy, policyList, nodeList); err != nil {
return reconcile.Result{}, err
}
// Sync Sriov device plugin ConfigMap object
if err = r.syncDevicePluginConfigMap(ctx, policyList, nodeList); err != nil {
return reconcile.Result{}, err
Expand All @@ -151,10 +155,6 @@ func (r *SriovNetworkNodePolicyReconciler) Reconcile(ctx context.Context, req ct
if err = r.syncPluginDaemonObjs(ctx, defaultPolicy, policyList); err != nil {
return reconcile.Result{}, err
}
// Sync SriovNetworkNodeState objects
if err = r.syncAllSriovNetworkNodeStates(ctx, defaultPolicy, policyList, nodeList); err != nil {
return reconcile.Result{}, err
}

// All was successful. Request that this be re-triggered after ResyncPeriod,
// so we can reconcile state again.
Expand Down

0 comments on commit 7b5ecac

Please sign in to comment.