如何保持我的Blazor Server端应用程序IIS 8.5正常运行 [英] how to keep alive my Blazor Server side app IIS 8.5

查看:112
本文介绍了如何保持我的Blazor Server端应用程序IIS 8.5正常运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要一直保持blazor服务器端应用程序的生命.

I need to keep my blazor server side app alive all time.

我试图将iis 8.5启动模式设置设置为alwaysrunning和idle设置为0但仍然关闭了该应用程序并在23h至29h之间捕获了停止信号...

I tried to set my iis 8.5 start mode setting to alwaysrunning and idle to 0 but still shutting down the app and caught stopping signal... after between 23h to 29h...

我必须做些什么才能保持它的生命,我错过了哪个设置?我必须在web.config上添加代码吗?

what i have to do to keep it alive, which setting i missed? Do i have to add code on web.config?

推荐答案

在IIS中,默认情况下,应用程序池每29小时进行一次回收.这是可配置的设置.请将常规时间间隔(分钟)从1740更改为0.设置为0表示应用程序池将永远不会回收.(有关默认设置,请参见图片)

In IIS the application pool recycles every 29 hours by default. This is a configurable setting. Please change the Regular Time Interval (minutes) from 1740 to 0. A setting of 0 means the application pool will never recycle. (see picture for the default setting)

更改此设置对Blazor Server应用程序很有帮助,因为否则,当应用程序池回收时,客户端将与服务器断开连接.这是Blazor Server使用的SignalR协议的一个怪癖.

Changing this setting is helpful for a Blazor Server app, because otherwise clients will get disconnected from the server when the application pool recycles. This is a quirk of SignalR protocol which is used by Blazor Server.

这篇关于如何保持我的Blazor Server端应用程序IIS 8.5正常运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆