Looks like we finally have a solution.

Change logging to just log a message, instead of the exception.
Moved logic to Syncer involvement.  When posting the data, if a 500 is
returned, then it is up to the Syncer to re-submit it.
This commit is contained in:
Mario Steele 2025-08-09 04:09:17 -05:00
parent 73955353cb
commit 004c490dd8
23 changed files with 529 additions and 177 deletions

View file

@ -7,10 +7,10 @@ public static class PingEndpoint
public static void MapPingEndpoints(this WebApplication app)
{
var group = app.MapGroup("ping");
group.MapGet("/", async (CancellationToken token) =>
group.MapGet("/", async (DataContext dbContext, CancellationToken token) =>
{
await Task.Delay(10);
var dict = new { AppVersion = "0.1.4" };
await dbContext.CleanupChangeLogAsync(token);
var dict = new { AppVersion = "0.1.5" };
return Results.Ok(dict);
});
@ -22,6 +22,7 @@ public static class PingEndpoint
return Results.NotFound();
var dict = new { LastUpdated = log.ChangeTime };
await dbContext.CleanupChangeLogAsync(token);
return Results.Ok(dict);
});
}