public OrderRpcService(IOptions <OrderRpcServcieSetting> setting, IHttpContextAccessor httpContext) { _setting = setting.Value; _channel = GrpcServiceHelper.CreateAuthenticatedChannel(_setting.OrderServcieHost, httpContext); _client = new Orders.OrdersClient(_channel); }
public ProductRpcService(IOptions <OrderRpcServcieSetting> setting, IHttpContextAccessor httpContext) { _setting = setting.Value; _httpContext = httpContext; // GrpcChannel.ForAddress(_setting.OrderServcieHost); _channel = GrpcServiceHelper.CreateAuthenticatedChannel(_setting.OrderServcieHost, httpContext); _client = new Products.ProductsClient(_channel); }