Nicens up the timeouts for the net deployer.

This commit is contained in:
benbierens 2023-09-22 10:02:16 +02:00
parent ea09605827
commit b8b59508aa
No known key found for this signature in database
GPG Key ID: FE44815D96D0A1AA
4 changed files with 6 additions and 6 deletions

View File

@ -39,7 +39,7 @@ namespace KubernetesWorkflow
return Configuration.OperationTimeout;
}
public TimeSpan WaitForK8sServiceDelay()
public TimeSpan K8sOperationRetryDelay()
{
return Configuration.RetryDelay;
}

View File

@ -702,7 +702,7 @@ namespace KubernetesWorkflow
var sw = Stopwatch.Begin(log, true);
try
{
Time.WaitUntil(predicate, cluster.K8sOperationTimeout(), cluster.WaitForK8sServiceDelay());
Time.WaitUntil(predicate, cluster.K8sOperationTimeout(), cluster.K8sOperationRetryDelay());
}
finally
{

View File

@ -28,7 +28,7 @@
WaitUntil(predicate, TimeSpan.FromMinutes(1), TimeSpan.FromSeconds(1));
}
public static void WaitUntil(Func<bool> predicate, TimeSpan timeout, TimeSpan retryTime)
public static void WaitUntil(Func<bool> predicate, TimeSpan timeout, TimeSpan retryDelay)
{
var start = DateTime.UtcNow;
var state = predicate();
@ -39,7 +39,7 @@
throw new TimeoutException("Operation timed out.");
}
Sleep(retryTime);
Sleep(retryDelay);
state = predicate();
}
}

View File

@ -81,8 +81,8 @@ namespace CodexNetDeployer
var configuration = new KubernetesWorkflow.Configuration(
kubeConfig,
operationTimeout: TimeSpan.FromSeconds(30),
retryDelay: TimeSpan.FromSeconds(10),
operationTimeout: TimeSpan.FromSeconds(120),
retryDelay: TimeSpan.FromSeconds(3),
kubernetesNamespace: config.KubeNamespace);
return new EntryPoint(log, configuration, string.Empty);