firebase-ios-sdk: Memory Leak when calling FirebaseApp.configure

Description

When I was investigating memory leak in our App, after eliminating some of potential codes I found that one of the memory leak issues is actually caused by Firebase iOS SDK and it happens after calling FirebaseApp.configure. I attached the screenshot from memory graph debugger, unfortunately there is no useful information from the backtrace but can confirm all the APMP thing is from Firebase SDK. Screen Shot 2023-04-04 at 11 30 01 Screen Shot 2023-04-04 at 11 29 54

Reproducing the issue

Call FirebaseApp.configure on App Launch and turn on Debug Memory Graph after the app finish launching.

Firebase SDK Version

10.2.0

Xcode Version

14.1

Installation Method

Zip

Firebase Product(s)

AB Testing, Analytics, Crashlytics, DynamicLinks, In-App Messaging, Installations, Messaging, Performance, Remote Config

Targeted Platforms

iOS

Relevant Log Output

No response

If using Swift Package Manager, the project’s Package.resolved

Expand Package.resolved snippet

Replace this line with the contents of your Package.resolved.

If using CocoaPods, the project’s Podfile.lock

Expand Podfile.lock snippet

Replace this line with the contents of your Podfile.lock!

About this issue

  • Original URL
  • State: closed
  • Created a year ago
  • Reactions: 1
  • Comments: 17 (6 by maintainers)

Most upvoted comments

Sorry for the long wait. The fix will be available in the next release in early March.

Sorry again for the long wait. The fix is now available in the Firebase 10.22.0 release.

Thank you for reporting this issue. We have confirmed the issue and are working on a fix. However, the fix requires a number of changes, so it may not be available soon.

The good news is that the memory leak appears to be a fixed amount, i.e. it won’t increase over time, so users shouldn’t see much of an impact.

Any updates on the fix even iam facing the issue

@skuske Instruments is showing the leak in a FirebaseAnalytics module in this report versus a FirebaseSessions module in #11027 - so these are almost certainly different leaks.

Can confirm this as well

Xcode 14.3, Firebase SDK 10.6.0

APMP prefixed symbols are from FirebaseAnalytics