fixes
parent
42964bcf5d
commit
6dbd40358e
|
|
@ -3342,6 +3342,7 @@ class KubernetesJobSpecFactory {
|
||||||
],
|
],
|
||||||
containers: [
|
containers: [
|
||||||
{
|
{
|
||||||
|
ttlSecondsAfterFinished: 9999,
|
||||||
name: KubernetesJobSpecFactory.MainContainerName,
|
name: KubernetesJobSpecFactory.MainContainerName,
|
||||||
image,
|
image,
|
||||||
command: ['/bin/sh'],
|
command: ['/bin/sh'],
|
||||||
|
|
@ -3703,7 +3704,15 @@ class KubernetesTaskRunner {
|
||||||
logs = await cloud_runner_system_1.CloudRunnerSystem.Run(`kubectl logs ${podName}${extraFlags} -f -c ${containerName} --timestamps${sinceTime}`, false, true);
|
logs = await cloud_runner_system_1.CloudRunnerSystem.Run(`kubectl logs ${podName}${extraFlags} -f -c ${containerName} --timestamps${sinceTime}`, false, true);
|
||||||
}
|
}
|
||||||
catch (error) {
|
catch (error) {
|
||||||
cloud_runner_logger_1.default.log(`K8s logging error ${error}`);
|
const continueStreaming = error.includes(`dial timeout, backstop`) ||
|
||||||
|
error.includes(`HttpError: HTTP request failed`) ||
|
||||||
|
error.includes(`an error occurred when try to find container`) ||
|
||||||
|
error.includes(`not found`) ||
|
||||||
|
error.includes(`Not Found`);
|
||||||
|
cloud_runner_logger_1.default.log(`K8s logging error ${error} ${continueStreaming}`);
|
||||||
|
if (continueStreaming) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
throw error;
|
throw error;
|
||||||
}
|
}
|
||||||
const splitLogs = logs.split(`\n`);
|
const splitLogs = logs.split(`\n`);
|
||||||
|
|
|
||||||
File diff suppressed because one or more lines are too long
|
|
@ -102,6 +102,7 @@ class KubernetesJobSpecFactory {
|
||||||
],
|
],
|
||||||
containers: [
|
containers: [
|
||||||
{
|
{
|
||||||
|
ttlSecondsAfterFinished: 9999,
|
||||||
name: KubernetesJobSpecFactory.MainContainerName,
|
name: KubernetesJobSpecFactory.MainContainerName,
|
||||||
image,
|
image,
|
||||||
command: ['/bin/sh'],
|
command: ['/bin/sh'],
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,16 @@ class KubernetesTaskRunner {
|
||||||
true,
|
true,
|
||||||
);
|
);
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
CloudRunnerLogger.log(`K8s logging error ${error}`);
|
const continueStreaming =
|
||||||
|
error.includes(`dial timeout, backstop`) ||
|
||||||
|
error.includes(`HttpError: HTTP request failed`) ||
|
||||||
|
error.includes(`an error occurred when try to find container`) ||
|
||||||
|
error.includes(`not found`) ||
|
||||||
|
error.includes(`Not Found`);
|
||||||
|
CloudRunnerLogger.log(`K8s logging error ${error} ${continueStreaming}`);
|
||||||
|
if (continueStreaming) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
throw error;
|
throw error;
|
||||||
}
|
}
|
||||||
const splitLogs = logs.split(`\n`);
|
const splitLogs = logs.split(`\n`);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue