示例#1
0
        // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
        {
            var handler = new GatewayHttpClientHandler(new Uri("fabric:/Hosting/CounterService"), message => message.GetHashCode());

            var proxyOptions = new ProxyOptions() { Host = "unused", BackChannelMessageHandler = handler };

            app.RunProxy(proxyOptions);
        }
示例#2
0
        // This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
        public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory)
        {
            var handler = new GatewayHttpClientHandler(new Uri("fabric:/Hosting/CounterService"), message => message.GetHashCode());

            var proxyOptions = new ProxyOptions()
            {
                Host = "unused", BackChannelMessageHandler = handler
            };

            app.RunProxy(proxyOptions);
        }