From 96704aa2962472528177771ecaff4f1b78d4b0b5 Mon Sep 17 00:00:00 2001 From: vishal Date: Sat, 26 Sep 2020 13:51:24 -0400 Subject: [PATCH 1/2] Update manage_resources_cron.go --- pkg/operator/resources/batchapi/manage_resources_cron.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkg/operator/resources/batchapi/manage_resources_cron.go b/pkg/operator/resources/batchapi/manage_resources_cron.go index 3747e2f15e..9017312484 100644 --- a/pkg/operator/resources/batchapi/manage_resources_cron.go +++ b/pkg/operator/resources/batchapi/manage_resources_cron.go @@ -116,7 +116,6 @@ func ManageJobResources() error { errors.PrintError(err) continue } - if newStatusCode != jobState.Status { err = errors.FirstError( writeToJobLogStream(jobKey, msg), @@ -128,6 +127,10 @@ func ManageJobResources() error { continue } } + if queueURL == nil { + // job has been submitted within the grace period, it may take a while for a newly created queue to be listed in aws api responses + continue + } err = checkIfJobCompleted(jobKey, *queueURL, k8sJob) if err != nil { From 591a798c8b2056c67cb479667682a501ec9a0324 Mon Sep 17 00:00:00 2001 From: vishal Date: Sat, 26 Sep 2020 14:08:31 -0400 Subject: [PATCH 2/2] Update manage_resources_cron.go --- pkg/operator/resources/batchapi/manage_resources_cron.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/operator/resources/batchapi/manage_resources_cron.go b/pkg/operator/resources/batchapi/manage_resources_cron.go index 9017312484..4beb6c3a63 100644 --- a/pkg/operator/resources/batchapi/manage_resources_cron.go +++ b/pkg/operator/resources/batchapi/manage_resources_cron.go @@ -128,7 +128,7 @@ func ManageJobResources() error { } } if queueURL == nil { - // job has been submitted within the grace period, it may take a while for a newly created queue to be listed in aws api responses + // job has been submitted within the grace period, it may take a while for a newly created queue to be listed in SQS api response continue }