ios - 在 iOS 应用程序中使用 Flurry Analytics 时,我收到错误 "Terminated due to memory issue"并且内存利用率快速增加

标签 ios swift flurry-analytics

当我在 iOS 应用程序中添加 flurry 分析时。然后我的应用程序内存利用率 swift 增加,应用程序将通过显示此错误消息来终止

"Message from debugger: Terminated due to memory issue".

当我删除困惑 session 时,我的应用程序可以正常运行 检查下面我用来添加困惑分析的代码。

func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {

let builder = FlurrySessionBuilder.init()
            .withLogLevel(FlurryLogLevelAll)
            .withCrashReporting(true)
            .withSessionContinueSeconds(2)
        Flurry.startSession("My_key", with: builder)

}

最佳答案

初始化有延迟,您可能使用了某些第三方 SDK,启动时间可能太长

DispatchQueue.main.asyncAfter(deadline: .now() + 0.5) { 
    //Initialise here
}

关于ios - 在 iOS 应用程序中使用 Flurry Analytics 时,我收到错误 "Terminated due to memory issue"并且内存利用率快速增加,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/55573455/

相关文章:

ios - 是否可以为 SKCalloutView 使用自定义 View ?

ios - 可编码 swift 4

swift - 使用 RGB 将 UIStatusBar 颜色更改为特定颜色?

swift - session 开始时的 Flurry 监听器

ios - 在 UITableViewController 中重新排序行后 UI 更新不正确

ios - 如何测试 Apple 的新搜索广告归因 API?

swift - WatchOS2 连接框架不起作用

ios - 使用 Flurry Analytics 跟踪页面/屏幕浏览量

ios - 为什么我的静态库会出现 iOS 链接器错误?