说,应用程序中有一个后台服务,可以触发分析事件。 现在,我不希望该活动在Google Analytics上创建会话。
有什么办法吗?
答案 0 :(得分:1)
这可以通过在分析跟踪中使用.setNonIntraction(true)来实现。
Tracker t = getGoogleTracker();
t.send(new HitBuilders.EventBuilder().setCategory(category)
.setAction(event)
.setLabel(label).setNonInteraction(true)
.setValue(l)
.build());
这对我来说就像一个魅力!!!