Пример #1
0
        public override void Init(IServiceContainer serviceContainer, IDictionary <string, string> jobArgsDictionary)
        {
            var configurationFilename = JobConfigurationManager.GetArgument(jobArgsDictionary, ConfigurationArgument);

            _serviceProvider = GetServiceProvider(GetConfigurationRoot(configurationFilename));

            _configuration       = _serviceProvider.GetService <PackageLagMonitorConfiguration>();
            _catalogClient       = _serviceProvider.GetService <ICatalogClient>();
            _httpClient          = _serviceProvider.GetService <IHttpClientWrapper>();
            _searchServiceClient = _serviceProvider.GetService <ISearchServiceClient>();

            _telemetryService = _serviceProvider.GetService <IPackageLagTelemetryService>();
        }