javascript - 谷歌分析 session 多长时间?超过每个 session 的最大命中数,中止命中

标签 javascript debugging google-chrome-extension google-analytics

我有一个 Chrome 扩展程序,我对我的分析代码进行了调试,生成了一条控制台消息“超出了每个 session 的最大点击数,正在中止点击”。请注意,这只发生在生产中。

我理解为什么会发生这种情况,因为每个 session 有大约 500 个 utm 请求的限制。但是,这些 session 什么时候到期?有没有办法强制 session 或 session 过期?我只需要在解决了一些问题的更新后使这些 session 过期一次。

由于该应用程序遇到导致“过度生成事件”的错误,我已经解决了这个问题,我想使所有这些 session 过期或知道它们何时过期。

非常感谢任何帮助。

_gaq.push processing "_setAccount" for args: "[UA-XXXXXX-X]":  ssl.google-analytics.com/u/ga_debug.js:18
_gaq.push processing "_trackPageview" for args: "[]":  ssl.google-analytics.com/u/ga_debug.js:18
Track Pageview ssl.google-analytics.com/u/ga_debug.js:18
Exceeded maximum hits per session. Aborting hit. 

最佳答案

我个人认为不应达到每个 session 500 个请求的限制。也许您的网站生成的事件过多。

以下是关于可能产生如此多事件的一些线索:

Events Per Session Limit

For each visit (user session), a maximum of approximately 500 combined GATC requests (both events and page views) can be tracked. Keep this in mind when programmatically generating events. Note that—as the number of events in a session approaches the limit—additional events might not be tracked. For example, you should:

  • avoid scripting a video to send an event for every second played and other highly repetitive event triggers
  • avoid excessive mouse movement tracking
  • avoid time-lapse mechanisms that generate high event counts

(来自 Google Analytic 的 Event Tracking Guide )

根据以下内容,访问似乎从月初持续到月底:

In order to understand how the Count of visits dimension works, it helps first to understand how sessions are counted in Analytics. Each time a user visits your site, there is a counter applied to their visit that increments with each new session by that visitor. For example, if Visitor A visits your site for the first time in January, their session count is 1. If that visitor then returns in February, their session count will be 2, and so on for each subsequent visit.

(基于 session 的更多背景信息,请参阅 Google Analytics Help Center on this topic)

或许您可以考虑更改 session timeout .

关于javascript - 谷歌分析 session 多长时间?超过每个 session 的最大命中数,中止命中,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/13961143/

相关文章:

c# - 不寻常的异常行为?

javascript - Chrome 扩展程序 : Automatically download a screenshot taken with 'chrome.tabs.captureVisibleTab'

JavaScript 执行不一致 (V8)

java - 如何在 3 种不同的浏览器中在同一台电脑上并行运行 selenium html 套件?

javascript - Android 键盘在验证后无法在 webview 中工作

javascript - 使用 JavaScript 隐藏 SVG 元素

c++ - 有选择地编译宏外部的代码

javascript - 在 Chrome 中使用 React Native 调试 ES6 import 语句

javascript - 使用 Chrome 扩展为每个新选项卡创建多个 session

file - 隐身访问扩展文件