4

我知道 Flurry 的报告有延迟,但是,我们在第二天的 Flurry 报告中没有看到任何结果。

    [Flurry setDebugLogEnabled:YES];
    [Flurry setLogLevel:FlurryLogLevelDebug];
    [Flurry startSession:_appSettings.flurryAppId];
    [Flurry setSessionReportsOnCloseEnabled:YES];
    [Flurry setSessionReportsOnPauseEnabled:YES];
    [Flurry setEventLoggingEnabled:YES];
    UIDevice *device = [UIDevice currentDevice];
    [Flurry logEvent:@"SESSION_START"
      withParameters:[NSDictionary dictionaryWithObjectsAndKeys:[device systemVersion], @"OS", nil]
               timed:YES];

我们的日志显示了应用程序中发生的各个 Flurry 日志调用。我们没有看到任何暗示信息已发送给 Flurry 的信息。

两者setSessionReportsOnPauseEnabled:setSessionReportsOnCloseEnabled:都设置为YES,但当应用程序暂停或关闭时,没有与会话数据的 Flurry 通信。当我重新启动应用程序时,Flurry 尝试发送会话数据,但不幸的是:

FlurrySession: Add crashed former session

按照指示,我们在以下位置开始了 Flurry 会话:

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions method of your AppDelegate

根据 Flurry 的网站,我们没有跟踪任何事件

我们正在使用 Flurry 4.2.2 SDK

4

1 回答 1

14

Flurry SDK 4.2.2 似乎独有的问题:

在 4.2.2 中有一个新方法:

+ (void)setBackgroundSessionEnabled:(BOOL)setBackgroundSessionEnabled;

YES如果您的应用程序有任何UIBackgroundModes应用程序,它会自动设置为。我们的应用程序在后台使用 GPS。因此 Flurry 在进入后台时永远不会发布会话数据。

当我强制[Flurry setBackgroundSessionEnabled:NO];时,它会在按下主页按钮并且应用程序进入后台时发送会话数据。

我不确定这将如何运作。我们不需要使用 Flurry 来更新 GPS 位置,因此现在可以为我们工作。

希望这可以帮助其他人解决这个问题。

更新:2014 年 6 月 17 日:

我在 Flurry 的常见问题解答中找到了更多相关信息

于 2013-07-24T17:13:02.893 回答