fix(service): Clear SQLite connection pools on service stop

Should fix manual delete of Regression tests which create a temp SQLite DB for their tests.
This commit is contained in:
omgbeez 2026-04-28 14:30:10 -04:00 committed by Clifford Roche
parent 7f60f9de5a
commit 9ea2219df7

View file

@ -1,4 +1,5 @@
using System.Reflection;
using Microsoft.Data.Sqlite;
using Microsoft.EntityFrameworkCore;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Hosting;
@ -39,6 +40,9 @@ public class Startup(IServiceProvider serviceProvider) : IHostedService
public Task StopAsync(CancellationToken cancellationToken)
{
Ready = false;
SqliteConnection.ClearAllPools();
return Task.CompletedTask;
}
}