Implements directory browser dialog, part 3: file system explorer

This commit is contained in:
BinaryAlley committed 2024-09-19 17:40:33 +03:00
1 parent a4f9199d2c
commit 493f34c883
76 files changed
+2377 -437

No files matched your search

@@ -26,11 +26,14 @@ public static class PresentationWebLayerServices
{
// scan the current assembly for validators and register them to the DI container
services.AddValidatorsFromAssemblyContaining<Program>(ServiceLifetime.Singleton);
// handle transient errors like network timeouts or intermittent failures
var retryPolicy = Policy
.Handle<HttpRequestException>()
.OrResult<HttpResponseMessage>(r => !r.IsSuccessStatusCode)
.OrResult<HttpResponseMessage>(r =>
!r.IsSuccessStatusCode &&
r.StatusCode != HttpStatusCode.Forbidden &&
r.StatusCode != HttpStatusCode.BadRequest)
.WaitAndRetryAsync(3, retryAttempt =>
TimeSpan.FromSeconds(Math.Pow(2, retryAttempt)));