Do not retry /renewjob on 404 (#3828)

This commit is contained in:
eric sciple
2025-04-30 14:44:40 -05:00
committed by GitHub
parent 1c319b4d42
commit 9155c42c09

View File

@@ -94,7 +94,9 @@ namespace GitHub.Runner.Common
{
CheckConnection();
return RetryRequest<RenewJobResponse>(
async () => await _runServiceHttpClient.RenewJobAsync(requestUri, planId, jobId, cancellationToken), cancellationToken);
async () => await _runServiceHttpClient.RenewJobAsync(requestUri, planId, jobId, cancellationToken), cancellationToken,
shouldRetry: ex =>
ex is not TaskOrchestrationJobNotFoundException); // HTTP status 404
}
}
}