Remove duplicated attempts to re-run job and add minor improvements.

This commit is contained in:
2023-02-21 17:23:36 +00:00
parent 55cd8bb7a6
commit 9ab900dbd2
8 changed files with 31 additions and 168 deletions
+2 -2
View File
@@ -64,14 +64,14 @@ func (r *ManagedJobReconciler) Reconcile(ctx context.Context, req ctrl.Request)
// TODO: Re-enable after testing
cp.checkRunningJobsStatus()
cp.runPendingJobs()
cp.checkOverallStatus()
_, theSame, _ := pandati.CompareStructsReplaced(originalMainJobDefinition, cp.mj)
if !theSame {
cp.updateCRDStatusDirectly()
}
// fmt.Printf("Reconcile: %# v", pretty.Formatter(r.Updater))
cp.checkOverallStatus()
// fmt.Printf("Reconcile: %# v", pretty.Formatter(r.Updater))
return ctrl.Result{}, nil
}