public Handler() { _slackService = new SlackService(); _dynamoRepository = new DynamoRepository(); _slackMessage = new SlackMessage(_dynamoRepository); //hacky... _eventIdList = new List <EventId>(); }
public Communicator(ILogger <Communicator> logger, Mapper mapper, ISlackService slackService) { client = new HttpClient { Timeout = TimeSpan.FromSeconds(15) }; this.logger = logger; this.mapper = mapper; this.slackService = slackService; statsCache = new(); patientsCache = new(); hospitalsCache = new(); hospitalsListCache = new(); municipalitiesListCache = new(); retirementHomesListCache = new(); retirementHomesCache = new(); municipalityCache = new(); regionCasesCache = new(); healthCentersDayCache = new(); statsWeeklyDayCache = new(); owidCountriesCache = new(); monthlyDeathsSloveniaCache = new(); labTestsCache = new(); dailyDeathsSloveniaCache = new(); ageDailyDeathsSloveniaCache = new(); sewageCache = new(); schoolCasesCache = new(); schoolAbsencesCache = new(); schoolRegimesCache = new(); vaccinationsCache = new(); summaryCache = new SummaryCache(default, default, default, default, default, default, default);
public SlackController(IRestaurantService restaurantService, ISlackService slackService, IStorageService storageService, ILogger <SlackController> log) { RestaurantService = restaurantService; SlackService = slackService; StorageService = storageService; Log = log; }
public SlackNotifyer(IServiceProvider serviceProvider) { this._slackService = serviceProvider.GetService <ISlackService>(); var configuration = serviceProvider.GetService <IConfiguration>(); this._webHookUrl = configuration["Slack:WebHookUrl"]; }
public Communicator(ILogger <Communicator> logger, Mapper mapper, ISlackService slackService) { client = new HttpClient { Timeout = TimeSpan.FromSeconds(15) }; this.logger = logger; this.mapper = mapper; this.slackService = slackService; statsCache = new ArrayEndpointCache <StatsDaily>(); regionCache = new ArrayEndpointCache <RegionsDay>(); patientsCache = new ArrayEndpointCache <PatientsDay>(); hospitalsCache = new ArrayEndpointCache <HospitalsDay>(); hospitalsListCache = new ArrayEndpointCache <Hospital>(); municipalitiesListCache = new ArrayEndpointCache <Municipality>(); retirementHomesListCache = new ArrayEndpointCache <RetirementHome>(); retirementHomesCache = new ArrayEndpointCache <RetirementHomesDay>(); deceasedPerRegionsDayCache = new ArrayEndpointCache <DeceasedPerRegionsDay>(); municipalityDayCache = new ArrayEndpointCache <MunicipalityDay>(); healthCentersDayCache = new ArrayEndpointCache <HealthCentersDay>(); statsWeeklyDayCache = new ArrayEndpointCache <StatsWeeklyDay>(); owidCountriesCache = new DictionaryEndpointCache <string, Models.Owid.Country>(); monthlyDeathsSloveniaCache = new ArrayEndpointCache <MonthlyDeathsSlovenia>(); labTestsCache = new ArrayEndpointCache <LabTestDay>(); dailyDeathsSloveniaCache = new ArrayEndpointCache <DailyDeathsSlovenia>(); ageDailyDeathsSloveniaCache = new ArrayEndpointCache <AgeDailyDeathsSloveniaDay>(); errors = new ConcurrentDictionary <string, object>(); }
public CeoPersonaAsistantService(ISlackService slackService, IFirebaseService firebaseService , IConfiguration configuration) { _slackService = slackService; _firebaseService = firebaseService; _ceoMemberId = configuration["SlackSettings:CeoMemberId"]; }
public TaskRepeater(ILogger <TaskRepeater> logger, IQueuingService queuingService, ISapService sapService, ISlackService slackService) { _logger = logger; _queuingService = queuingService; _sapService = sapService; _slackService = slackService; }
public JwtSecurity(UserManager <Dal.Entities.Identity.ApplicationUser> userManager, ILogger <JwtSecurity> logger, IMapper mapper, IEmailService emailService, ISlackService slackService) { _userManager = userManager; _logger = logger; _mapper = mapper; _emailService = emailService; _slackService = slackService; }
public RunCommand(IMediator mediator, IIdGenerator <long> idGenerator, ISystemClock clock, ISlackService slackService, ILogger <RunCommand> logger) : base(slackService) { _mediator = mediator; _idGenerator = idGenerator; _clock = clock; _slackService = slackService; _logger = logger; }
public SlackController(ICommandRunner commandRunner, ISlackService slackService, ISlackMessageVerifier messageVerifier, ILogger <SlackController> logger) { _commandRunner = commandRunner; _slackService = slackService; _messageVerifier = messageVerifier; _logger = logger; }
public ContractNotificationService(IESIService esiService, IMapper mapper, IDiscordService discordService, ISlackService slackService, IDataStorageService dataStorageService) { _esiService = esiService; _mapper = mapper; _slackService = slackService; _discordService = discordService; _dataStorageService = dataStorageService; }
public SlackNotifyerTest() { this._stubSlackService = Substitute.For <ISlackService>(); this._stubConfiguration = Substitute.For <IConfiguration>(); this._stubServiceProvider = Substitute.For <IServiceProvider>(); this._stubServiceProvider.GetService <ISlackService>().Returns(this._stubSlackService); this._stubServiceProvider.GetService <IConfiguration>().Returns(this._stubConfiguration); }
public SlackNotifyer(IServiceProvider serviceProvider) { _slackService = serviceProvider.GetService <ISlackService>(); var configuration = serviceProvider.GetService <IConfiguration>(); _webHookUrl = configuration["Slack:WebHookUrl"]; _slackGroupIdDictionary = configuration.GetSection("Slack:GroupId").Get <Dictionary <string, string> >(); }
public SlackTenant( ILogger logger, ISlackService slackService, IComponentContext componentContext) { _logger = logger; _slackService = slackService; _componentContext = componentContext; }
public BusinessPartnerController( ILogger <BusinessPartnerController> logger, IBusinessPartnerService businessPartnerService, ISlackService slackService) { _logger = logger; _businessPartnerService = businessPartnerService; _slackService = slackService; }
public Worker(ILogger <Worker> logger, IServiceScopeFactory serviceScopeFactory, ISlackService serviceSlack) { _logger = logger; _serviceScopeFactory = serviceScopeFactory; _schedule = CrontabSchedule.Parse(Schedule, new CrontabSchedule.ParseOptions { IncludingSeconds = true }); _nextRun = _schedule.GetNextOccurrence(DateTime.Now); _serviceSlack = serviceSlack; }
public LimboAction(IServiceProvider services, LimboSettings settings) { this.Settings = settings; this.GitHub = services.GetService <IGitHubService>(); this.GitHub.SetCredentials(settings.GitHubUsername, settings.GitHubPersonalAccessToken); this.GitHub.BaseAddress = settings.GithubApiBaseUrl; this.Slack = services.GetService <ISlackService>(); this.Slack.SetCredentials(settings.SlackBotApiToken); }
public App( ISlackService slack, IStatisticsService statistics, IOptions <AppSettings> config, ILogger <App> logger) { _slack = slack; _statistics = statistics; _logger = logger; _config = config.Value; }
public SlackMemberJoinedCapabilityDomainEventHandler( ILogger <SlackMemberJoinedCapabilityDomainEventHandler> logger, ISlackFacade slackFacade, ICapabilityRepository capabilityRepository, ISlackService slackService) { _logger = logger; _slackFacade = slackFacade; _capabilityRepository = capabilityRepository; _slackService = slackService; }
public GitHubController( IDataStore dataStore, IGitHubService gitHubService, ISlackService slackService, IDevOpsService devOpsService) { this.dataStore = dataStore; _gitHubService = gitHubService; _slackService = slackService; _devOpsService = devOpsService; }
public EntitySubscriber( ICapturedRouterUrlHelper capturedRouterUrlHelper, ILogger <EntitySubscriber> logger, ISlackService slackService, IBroker broker) { _capturedRouterUrlHelper = capturedRouterUrlHelper; _slackService = slackService; _broker = broker; _logger = logger; }
public JobsController(IJobsService jobsService, ICategoriesService categoriesService, IHireTypesService hiretypesService, ITwitterService twitterService, LegacyApiClient apiClient, IConfiguration configuration, ICompaniesService companiesService, ISlackService slackService) { _jobsService = jobsService; _categoriesService = categoriesService; _hiretypesService = hiretypesService; _twitterService = twitterService; _apiClient = apiClient; _configuration = configuration; _companiesService = companiesService; _slackService = slackService; }
public SlackIntegration(SlackIntegrationConfiguration configuration) { if (configuration == null) { throw new ArgumentNullException(nameof(configuration), "Slack Integration configuration has not been provided."); } _configuration = configuration; _slackService = _configuration.SlackServiceProvider(); }
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, ISlackService slackService, ICommunicator communicator) { if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } app.UseRouting(); app.UseCors(CorsPolicy); app.UseResponseCompression(); app.UseResponseCaching(); app.UseAuthorization(); app.Use(async(context, next) => { context.Response.Headers.Add("SchemaVersion", SchemaVersion); context.Response.GetTypedHeaders().CacheControl = new Microsoft.Net.Http.Headers.CacheControlHeaderValue() { Public = true, MaxAge = System.TimeSpan.FromSeconds(10) }; context.Response.Headers[Microsoft.Net.Http.Headers.HeaderNames.Vary] = new string[] { "Accept-Encoding" }; await next.Invoke(); }); // Register the Swagger generator and the Swagger UI middleware app.UseOpenApi(); app.UseSwaggerUi3(); // notifies slack when an exception occurs app.UseExceptionHandler(errorApp => { errorApp.Run(async context => { //var exceptionHandlerPathFeature = context.Features.Get<IExceptionHandlerPathFeature>(); //var exception = exceptionHandlerPathFeature?.Error; try { await slackService.SendNotificationAsync($"DATA API REST service failed on {context.Request?.Path}", CancellationToken.None); } catch { } }); }); app.UseEndpoints(endpoints => { endpoints.MapMetrics(); endpoints.MapControllers(); }); }
public EntityReplySubscriber( ICapturedRouterUrlHelper capturedRouterUrlHelper, ILogger <EntitySubscriber> logger, IEntityStore <Question> entityStore, ISlackService slackService, IBroker broker) { _capturedRouterUrlHelper = capturedRouterUrlHelper; _slackService = slackService; _entityStore = entityStore; _broker = broker; _logger = logger; }
public NotificationService( ILogger <NotificationService> logger, IConfiguration config, IDataContext context, IEmailService email, ISlackService slack ) { _logger = logger; _config = config; _context = context; _email = email; _slack = slack; }
public ConnectionsController( IQueryHandler <FindConnectionsByClientTypeClientIdChannelTypeChannelId, IEnumerable <Connection> > findConnectionsByClientTypeClientIdChannelTypeChannelIdQueryHandler, ISlackFacade slackFacade, ICapabilityRepository capabilityRepository, ISlackService slackService) { _findConnectionsByClientTypeClientIdChannelTypeChannelIdQueryHandler = findConnectionsByClientTypeClientIdChannelTypeChannelIdQueryHandler; _slackFacade = slackFacade; _capabilityRepository = capabilityRepository; _slackService = slackService; }
public BillingService( IQueuingService queuingService, IDateTimeProvider dateTimeProvider, ILogger <BillingService> logger, ISlackService slackService, IEnumerable <IBillingMapper> billingMappers, IEnumerable <IBillingValidation> billingValidations) { _queuingService = queuingService; _dateTimeProvider = dateTimeProvider; _logger = logger; _slackService = slackService; _billingMappers = billingMappers; _billingValidations = billingValidations; }
public PhotosService( IUnitOfWork unitOfWork, IUsersService usersService, IImageUploader imageUploader, IClassMapper mapper, IConfiguration configuration, ISlackService slackService ) { _unitOfWork = unitOfWork ?? throw new ArgumentNullException(nameof(unitOfWork)); _usersService = usersService ?? throw new ArgumentNullException(nameof(usersService)); _imageUploader = imageUploader ?? throw new ArgumentNullException(nameof(imageUploader)); _mapper = mapper ?? throw new ArgumentNullException(nameof(mapper)); _configuration = configuration ?? throw new ArgumentNullException(nameof(configuration)); _slackService = slackService ?? throw new ArgumentNullException(nameof(slackService)); }
public Worker(ILogger <Worker> logger, IConfiguration configuration, ISlackService slackService) { _logger = logger; _slackService = slackService; _cancellationTokenSource = new CancellationTokenSource(); var conf = new ConsumerConfig { GroupId = "aoj69-consumer", BootstrapServers = configuration.GetSection("KafkaServer").Value, AutoOffsetReset = AutoOffsetReset.Earliest, EnableAutoCommit = false }; _consumer = new ConsumerBuilder <Ignore, string>(conf).Build(); _consumer.Subscribe(configuration.GetSection("KafkaTopic").Value); }
public Security() { _message = new SlackMessage(); _service = new SlackService(); }
public LoggedIn() { _message = new SlackMessage(); _service = new SlackService(); }
public LoggedIn(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public TeamAuthenticationTest(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public TeamAuthenticationTest() { _message = new SlackMessage(); _service = new SlackService(); }
public TestStart() { _message = new SlackMessage(); _service = new SlackService(); }
public TestStart(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Shutdown() { _message = new SlackMessage(); _service = new SlackService(); }
public Publish(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Security(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Event() { _message = new SlackMessage(); _service = new SlackService(); }
public ListDeletion() { _message = new SlackMessage(); _service = new SlackService(); }
public Initialize() { _message = new SlackMessage(); _service = new SlackService(); }
public Social(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Shutdown(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Social() { _message = new SlackMessage(); _service = new SlackService(); }
public Initialize(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Membership() { _message = new SlackMessage(); _service = new SlackService(); }
public ListDeletion(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public MvcException() { _message = new SlackMessage(); _service = new SlackService(); }
public Event(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Indexing(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Membership(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Indexing() { _message = new SlackMessage(); _service = new SlackService(); }
//TODO: After the hackathon we should introduce Dependency Injection public Publish() { _message = new SlackMessage(); _service = new SlackService(); }
public MvcException(ISlackService service, ISlackMessage message) { _message = message; _service = service; }
public Campaign() { _message = new SlackMessage(); _service = new SlackService(); }
public Campaign(ISlackService service, ISlackMessage message) { _message = message; _service = service; }