feat(templateActivator): Методы чтения MQ, обновления состояний шаблонов и расписаний, обновления заданий роботов
This commit is contained in:
24
PARR.TemplateActivator/TemplateActivatorInstaller.cs
Normal file
24
PARR.TemplateActivator/TemplateActivatorInstaller.cs
Normal file
@@ -0,0 +1,24 @@
|
||||
using Microsoft.Extensions.Configuration;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using PARR.BLL;
|
||||
using PARR.DAL;
|
||||
|
||||
namespace PARR.TemplateActivator;
|
||||
|
||||
public static class TemplateActivatorInstaller
|
||||
{
|
||||
|
||||
public static void InstallTemplateActivatorSerivces(this IServiceCollection services, IConfiguration configuration)
|
||||
{
|
||||
services.InstallBllServices(configuration);
|
||||
services.InstallDalServices(configuration);
|
||||
|
||||
var mqSettings = new MqSettings();
|
||||
configuration.GetSection(nameof(MqSettings)).Bind(mqSettings);
|
||||
services.AddSingleton(mqSettings);
|
||||
|
||||
services.AddTransient<ITemplateActivator, TemplateActivator>();
|
||||
services.AddTransient<IMqTemplateActivator, MqTemplateActivator>();
|
||||
services.AddTransient<IValidatorService, ValidatorService>();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user