Ejemplo n.º 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, IServiceProvider serviceProvider)
        {
            IWalletManager walletManager = serviceProvider.GetService <IWalletManager>();

            walletManager.InitWallet();

            app.UseWebSockets();
            app.UseMvc();

            app.Map("/ws", x => x.UseMiddleware <WebSocketMiddleware>(
                        serviceProvider.GetService <ILogger <WebSocketMiddleware> >(),
                        serviceProvider.GetService <IWebSocketManager>()));
        }