Sitecore的分析机器人SessionTimeout造成premature会话超时机器人、Sitecore、premature、SessionTimeout

2023-09-08 08:35:13 作者:挽袖

在我们的项目之一,我们一直在经历随机​​会话超时问题。随着最近发现我已经注意到,Sitecore的Analytics.Robots.SessionTimeout也许这就是导致它的东西。

我们注意到,在随机会话超时,超时值设置为1分钟我们120分钟,而不是。

Time Out

在通过所有我们注意到只有一个配置已超时设置为1分钟。在配置文件中搜索

我们认为通过提高分析机器人会话超时为120分钟将解决我们的随机超时问题,但我的问题是,这必须通过让机器人会为120分钟,而不是1分住任何负面影响性能或安全性问题?

感谢您的建议。

解决方案

我已经登录的问题Sitecore的,这里是他们的应对问题。

  

我不认为该行为应被视为是因为一个bug   Sitecore的CMS被设计为与ASP.NET WebForms的技术中使用。   当使用Web表单中,机器人检测依赖于    在控制   该页面。这是自然的,你不能在ASP.NET MVC使用   应用程序,但有一个简单的解决方案 - 把下面的code   里面的元素:

 <%
如果(Context.Diagnostics.Tracing || Context.Diagnostics.Profiling)
{
  回复于(<! - 游客身份被禁用,因为调试激活 - >。);
}
否则,如果(Tracker.IsActive&安培;及(Tracker.Visitor.VisitorClassification == 925))
{
  回复于(<链接的href = \/布局/系统/ VisitorIdentification.aspx \相对= \样式\类型= \文/ CSS \/>中);
}
%>
 

On one of our project we been experiencing random session timeout issues. With recent discovery I've notice that Sitecore Analytics.Robots.SessionTimeout maybe the thing that's causing it.

We notice that at random session timeout, the timeout value was set to 1min instead of our 120min.

After searching through all the config files we notice only one configuration has timeout set to 1min.

We think by increasing the analytics robots session timeout to 120min will fix our random timeout issue, but my question is, will this have any negative performance impact or security issue by allowing robot sessions to live for 120min instead of 1min?

Thanks you for your suggestions.

解决方案

I've log the issue with Sitecore and here's their response to the issue.

I don't think that the behaviour should be considered as a bug because Sitecore CMS was designed to be used with ASP.NET WebForms technology. While using web forms, the bot detection relies on the control in the of the page. It's natural that you can't use it in the ASP.NET MVC application, but there is an easy solution - put the following code inside the element:

<%
if (Context.Diagnostics.Tracing || Context.Diagnostics.Profiling)
{
  Response.Write("<!-- Visitor identification is disabled because debugging is active. -->");
}
else if (Tracker.IsActive && (Tracker.Visitor.VisitorClassification == 925))
{
  Response.Write("<link href=\"/layouts/System/VisitorIdentification.aspx\" rel=\"stylesheet\" type=\"text/css\" />");
}
%>