diff --git a/app/Jobs/ProcessSubmission.php b/app/Jobs/ProcessSubmission.php index dd4fd90e36..c633fbd7f5 100644 --- a/app/Jobs/ProcessSubmission.php +++ b/app/Jobs/ProcessSubmission.php @@ -94,7 +94,14 @@ private function requeueSubmissionFile($buildid): bool // Requeue the file with exponential backoff. PendingSubmissions::IncrementForBuildId($this->buildid); $delay = pow(config('cdash.retry_base'), $retry_handler->Retries); - self::dispatch($this->filename, $this->projectid, $buildid, md5_file(Storage::path("inbox/{$this->filename}")))->delay(now()->addSeconds($delay)); + if (config('queue.default') === 'sqs-fifo') { + // Special handling for sqs-fifo, which does not support per-message delays. + sleep(10); + self::dispatch($this->filename, $this->projectid, $buildid, md5_file(Storage::path("inbox/{$this->filename}"))); + } else { + self::dispatch($this->filename, $this->projectid, $buildid, md5_file(Storage::path("inbox/{$this->filename}")))->delay(now()->addSeconds($delay)); + } + return true; } } diff --git a/app/cdash/include/autoremove.php b/app/cdash/include/autoremove.php index 72d5dee663..6014a7535b 100644 --- a/app/cdash/include/autoremove.php +++ b/app/cdash/include/autoremove.php @@ -91,7 +91,7 @@ function removeFirstBuilds($projectid, $days, $maxbuilds, $force = false, $echo add_log('about to query for builds to remove', 'removeFirstBuilds'); $db = Database::getInstance(); - $builds = $db->executePrepared(' + $builds = $db->executePrepared(" SELECT id FROM build WHERE @@ -99,8 +99,8 @@ function removeFirstBuilds($projectid, $days, $maxbuilds, $force = false, $echo AND starttime