Reputation:
Specifically thinking about the Flash version but I'm sure this applies to the JS version too. Should I cache/queue a number of events before calling the API and then send them all at once or should I simply report them as they happen?
I'd like to track a lot of events, say 50 or so per a minute, but I don't want to completely overwhelm the user or Google with this. From reading the documentation Google provides it's not clear to me that queuing things will help at all, but in that case is there anything I can do?
Thanks in advance
Upvotes: 0
Views: 695
Reputation: 555
I wouldn't do that. I suggest triggering the events one by one.
Imagine the complexity of your javascript code if you have to keep track of each individual event. Also, how do yo plan to send the requests? Once a certain number of events have been reached and/or upon page unload? In each case you will have to make your user wait until all the events have been sent. If you are watching tv, would you prefer to watch 5 one-minute commercials distributed within an episode or all 5 commercials at the end???
In our website, we use GA events to track download links, outbound referrals, and interface actions (e.g. clicking slider, toggling hidden sections, etc). I don't know about your situation, but I don't see how a user can generate so much number of events in just a single page to warrant the headache of creating and setting up a custom bulk-triggering mechanism.
Upvotes: 0
Reputation: 3794
Be aware that Google has certain limitations... One that I remember is this:
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.
http://code.google.com/apis/analytics/docs/tracking/eventTrackerGuide.html
Upvotes: 0
Reputation: 5478
My 2c: Odds are the user would spend a few seconds between events. If you queue them, you'd send 50 or so events all at once, which I don't think is better at all. I'd try to distribute load on the network as evenly as possible. An other dissadvantage is that if your user closes the tab, you would loose the last events in the buffer, because they were never sent.
Upvotes: 1