Remove DbConfig and new constructors on DbContextBase and refactor Migrations to use explcit generation of IOqtaneDatabase instance

This commit is contained in:
Charles Nurse
2021-05-12 15:17:40 -07:00
parent c958f90ee2
commit c036a9d11f
34 changed files with 137 additions and 225 deletions

View File

@ -47,17 +47,6 @@ namespace Microsoft.Extensions.DependencyInjection
}
}
// dynamically register database providers
var databaseTypes = assembly.GetInterfaces<IOqtaneDatabase>();
foreach (var databaseType in databaseTypes)
{
if (databaseType.AssemblyQualifiedName != null)
{
var serviceType = Type.GetType("Oqtane.Interfaces.IOqtaneDatabase, Oqtane.Shared");
services.AddScoped(serviceType ?? databaseType, databaseType);
}
}
// dynamically register hosted services
var serviceTypes = assembly.GetTypes(hostedServiceType);
foreach (var serviceType in serviceTypes)