mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-18 06:57:59 +00:00
changed to sqlite connection to ef core
This commit is contained in:
1 parent
23416b21fc
commit
3d68d73767
8 files changed
+1222
-503
No files matched your search
@@ -0,0 +1,15 @@
|
||||
using System.Diagnostics.CodeAnalysis;
|
||||
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
|
||||
namespace AIStudio.Tools.Databases.EmbeddingState;
|
||||
|
||||
internal static class EmbeddingStateSchemaMigrator
|
||||
{
|
||||
[DynamicDependency(DynamicallyAccessedMemberTypes.All, typeof(Migrations.InitialRagIndex))]
|
||||
public static async Task MigrateAsync(EmbeddingStateDbContext context, CancellationToken token)
|
||||
{
|
||||
await context.Database.MigrateAsync(token);
|
||||
await context.Database.ExecuteSqlRawAsync("PRAGMA journal_mode=WAL;", token);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user