// Constructors public DomoEngine(InMemDbContextFactory contextFactory, ILogger <DomoEngine> logger) { // GRPC setup // TODO: create channel for each output device var httpHandler = new HttpClientHandler(); httpHandler.ServerCertificateCustomValidationCallback = HttpClientHandler.DangerousAcceptAnyServerCertificateValidator; GrpcChannel channel = GrpcChannel.ForAddress("https://192.168.0.236:5001", new GrpcChannelOptions { HttpHandler = httpHandler }); client = new Shared.GrpcProtos.Output.OutputClient(channel); this.contextFactory = contextFactory; this.logger = logger; }
public InputService(ILogger <InputService> logger, InMemDbContextFactory contextFactory) { this.logger = logger; this.contextFactory = contextFactory; }