adjust command

This commit is contained in:
rootdarkarchon
2022-10-20 11:46:07 +02:00
parent 1516ab73c7
commit 25772dade8
3 changed files with 11 additions and 19 deletions

View File

@@ -72,14 +72,14 @@ public abstract class GrpcBaseService : IHostedService, IDisposable
{
try
{
await CheckFaultStateAndResend().ConfigureAwait(false);
await CheckFaultStateAndRestore().ConfigureAwait(false);
}
catch { SetGrpcFaulty(); }
await Task.Delay(250).ConfigureAwait(false);
}
}
private async Task CheckFaultStateAndResend()
private async Task CheckFaultStateAndRestore()
{
if (GrpcIsFaulty)
{
@@ -96,8 +96,6 @@ public abstract class GrpcBaseService : IHostedService, IDisposable
{
var result = await toExecute.ConfigureAwait(false);
await CheckFaultStateAndResend().ConfigureAwait(false);
return result;
}
catch
@@ -113,7 +111,7 @@ public abstract class GrpcBaseService : IHostedService, IDisposable
try
{
await toExecute.ConfigureAwait(false);
await CheckFaultStateAndResend().ConfigureAwait(false);
await CheckFaultStateAndRestore().ConfigureAwait(false);
}
catch
{