public ServicesController( ILogger <ServicesController> logger, IOptionsSnapshot <FortuneServiceOptions> config, IOptionsSnapshot <ConfigServerData> configServerData, FortuneServiceCommand fortunes, IOptions <CloudFoundryApplicationOptions> appOptions, IOptions <CloudFoundryServicesOptions> servOptions, IConfiguration configApp, IConfigurationRoot configRoot, IDistributedCache cache, [FromServices] IDiscoveryClient client ) { if (configServerData != null) { IConfigServerData = configServerData; } _logger = logger; if (fortunes != null) { _fortunes = fortunes; } CloudFoundryServices = servOptions.Value; CloudFoundryApplication = appOptions.Value; _fortunesConfig = config; discoveryClient = client; RedisCacheStore = cache; Config = configApp; ConfigRoot = configRoot; }
/// <summary> /// Initializes a new instance of the <see cref="WorkshopController"/> class. /// </summary> /// <param name="logger">The logger.</param> /// <param name="config">The configuration.</param> /// <param name="configServerData">The configuration server data.</param> /// <param name="fortunes">The fortunes.</param> /// <param name="appOptions">The application options.</param> /// <param name="servOptions">The serv options.</param> /// <param name="configApp">The configuration application.</param> /// <param name="configRoot">The configuration root.</param> /// <param name="cache">The cache.</param> /// <param name="connectionFactory">The connection factory.</param> /// <param name="client">The client.</param> public WorkshopController( ILogger <WorkshopController> logger, IOptionsSnapshot <FortuneServiceOptions> config, IOptionsSnapshot <ConfigServerData> configServerData, FortuneServiceCommand fortunes, IOptions <CloudFoundryApplicationOptions> appOptions, IOptions <CloudFoundryServicesOptions> servOptions, IConfiguration configApp, IConfigurationRoot configRoot, IDistributedCache cache, [FromServices] ConnectionFactory connectionFactory, [FromServices] IDiscoveryClient client ) { if (configServerData != null) { IConfigServerData = configServerData; } _logger = logger; _fortunes = fortunes; CloudFoundryServices = servOptions.Value; CloudFoundryApplication = appOptions.Value; _fortunesConfig = config; discoveryClient = client; RedisCacheStore = cache; Config = configApp; ConfigRoot = configRoot; // Set up RabbitMQ Connection ConnectionFactory = connectionFactory; SslOption opt = ConnectionFactory.Ssl; if (opt != null && opt.Enabled) { opt.Version = SslProtocols.Tls | SslProtocols.Tls11 | SslProtocols.Tls12; // Only needed if want to disable certificate validations opt.AcceptablePolicyErrors = SslPolicyErrors.RemoteCertificateChainErrors | SslPolicyErrors.RemoteCertificateNameMismatch | SslPolicyErrors.RemoteCertificateNotAvailable; } }
public RandomModel(FortuneServiceCommand fortuneService) { _fortunes = fortuneService; }
public HomeController(FortuneServiceCommand fortuneServiceCommand, IFakeService1 service1) { _fortuneServiceCommand = fortuneServiceCommand; _service1 = service1; }
public FortunesController(ILogger <FortunesController> logger, FortuneServiceCommand fortunes) { _logger = logger; _fortunes = fortunes; }
public RandomModel(FortuneServiceCommand fortuneServiceCommand) { _fortuneServiceCommand = fortuneServiceCommand; }