Add SQLite setup in CommonPersistenceFeature and remove from Agents

Moved `SetupForSqlite` entity model handler to `CommonPersistenceFeature` to centralize SQLite configuration. Removed it from `Agents.Persistence.EntityFrameworkCore` to avoid redundancy.
This commit is contained in:
Sipke Schoorstra 2024-11-04 11:51:37 +01:00
parent 7129f86e1e
commit d46d0b53bc
2 changed files with 1 additions and 1 deletions

View file

@ -35,6 +35,5 @@ public class EFCoreAgentPersistenceFeature(IModule module) : PersistenceFeatureB
AddEntityStore<ServiceDefinition, EFCoreServiceStore>();
AddEntityStore<AgentDefinition, EFCoreAgentStore>();
Services.AddScoped<IEntityModelCreatingHandler, SetupForOracle>();
Services.AddScoped<IEntityModelCreatingHandler, SetupForSqlite>();
}
}

View file

@ -13,5 +13,6 @@ public class CommonPersistenceFeature(IModule module) : FeatureBase(module)
{
Services.AddScoped<IEntitySavingHandler, ApplyTenantId>();
Services.AddScoped<IEntityModelCreatingHandler, SetTenantIdFilter>();
Services.AddScoped<IEntityModelCreatingHandler, SetupForSqlite>();
}
}