我们正在使用 firebase inapp 消息传递,它似乎在应用程序中任意泄漏(如泄漏金丝雀所示)多个东西。
这种泄漏有时会出现启动活动、OTP 片段或任何其他属于应用程序启动的内容。,
通常,leakcanary 将平台内容报告为排除,但这似乎并没有被排除,令人惊讶的是,在任何这些片段/活动中都没有与 inappmessage 或 firebae 相关的代码。
* Details:
* Instance of com.app.nhs.NHSApplication
| static __nhsApplicationContext = com.app.nhs.NHSApplication@1115479984 (0x427cdfb0)
| static $staticOverhead = byte[48]@1115478585 (0x427cda39)
| static TAG = "NHSApplication"
| exoConfig = im.ene.toro.exoplayer.Config@1121658096 (0x42db24f0)
| profileId = null
| profileObj = null
| simpleCache = com.google.android.exoplayer2.upstream.cache.SimpleCache@1121423792 (0x42d791b0)
| mActivityLifecycleCallbacks = java.util.ArrayList@1115480056 (0x427cdff8)
| mAssistCallbacks = null
| mComponentCallbacks = java.util.ArrayList@1115480032 (0x427cdfe0)
| mLoadedApk = android.app.LoadedApk@1115461752 (0x427c9878)
| mBase = android.app.ContextImpl@1115551592 (0x427df768)
* Instance of java.util.ArrayList
| static $staticOverhead = byte[48]@1105582689 (0x41e5da61)
| static serialVersionUID = 8683452581122892189
| static MIN_CAPACITY_INCREMENT = 12
| array = java.lang.Object[18]@1122366304 (0x42e5f360)
| size = 14
| modCount = 16
* Array of java.lang.Object[]
| [0] = com.google.android.gms.common.api.internal.BackgroundDetector@1116363080 (0x428a5948)
| [1] = com.google.android.gms.measurement.internal.zzdu@1116698784 (0x428f78a0)
| [2] = com.google.firebase.inappmessaging.internal.ForegroundNotifier@1116926112 (0x4292f0a0)
| [3] = com.google.firebase.inappmessaging.display.FirebaseInAppMessagingDisplay@1118986552 (0x42b26138)
| [4] = com.facebook.appevents.internal.ActivityLifecycleTracker$1@1119149432 (0x42b4dd78)
| [5] = com.facebook.marketing.CodelessActivityLifecycleTracker$1@1119211992 (0x42b5d1d8)
| [6] = com.clevertap.android.sdk.ActivityLifecycleCallback$1@1119831616 (0x42bf4640)
| [7] = io.fabric.sdk.android.ActivityLifecycleManager$ActivityLifecycleCallbacksWrapper$1@1120245872 (0x42c59870)
| [8] = com.onesignal.ActivityLifecycleListener@1121849392 (0x42de1030)
| [9] = io.branch.referral.Branch$BranchActivityLifeCycleObserver@1122149928 (0x42e2a628)
| [10] = com.squareup.leakcanary.AndroidHeapDumper$1@1122344520 (0x42e59e48)
| [11] = com.squareup.leakcanary.ActivityRefWatcher$1@1122366288 (0x42e5f350)
| [12] = com.squareup.leakcanary.internal.FragmentRefWatcher$Helper$1@1122371752 (0x42e608a8)
| [13] = com.uxcam.a.a@1123030336 (0x42f01540)
| [14] = null
| [15] = null
| [16] = null
| [17] = null
* Instance of com.google.firebase.inappmessaging.display.firebaseInAppMessagingDisplay
| static $staticOverhead = byte[72]@1116409833 (0x428b0fe9)
| static INTERVAL_MILLIS = 1000
| static IMPRESSION_THRESHOLD_MILLIS = 5000
| static DISMISS_THRESHOLD_MILLIS = 20000
| animator = com.google.firebase.inappmessaging.display.internal.FiamAnimator@1119043488 (0x42b33fa0)
| application = com.app.nhs.NHSApplication@1115479984 (0x427cdfb0)
| autoDismissTimer = com.google.firebase.inappmessaging.display.internal.RenewableTimer@1119043440 (0x42b33f70)
| bindingWrapperFactory = com.google.firebase.inappmessaging.display.internal.BindingWrapperFactory@1119043472 (0x42b33f90)
| callbacks = null
| fiamListener = null
| firebaseInAppMessagingDisplay = com.google.firebase.inappmessaging.display.FirebaseInAppMessagingDisplay$1@1128847240 (0x4348d788)
| headlessInAppMessaging = com.google.firebase.inappmessaging.FirebaseInAppMessaging@1116848760 (0x4291c278)
| imageLoader = com.google.firebase.inappmessaging.display.internal.FiamImageLoader@1118989360 (0x42b26c30)
| impressionTimer = com.google.firebase.inappmessaging.display.internal.RenewableTimer@1119043424 (0x42b33f60)
| inAppMessage = null
| layoutConfigs = java.util.Collections$UnmodifiableMap@1118988472 (0x42b268b8)
| windowManager = com.google.firebase.inappmessaging.display.internal.FiamWindowManager@1119043456 (0x42b33f80)
* Instance of com.google.firebase.inappmessaging.display.FirebaseInAppMessagingDisplay$1
| this$0 = com.google.firebase.inappmessaging.display.FirebaseInAppMessagingDisplay@1118986552 (0x42b26138)
| val$activity = com.app.nhs.activities.auth.LoginActivity@1135077936 (0x43a7ea30)
* Instance of com.app.nhs.activities.auth.LoginActivity
| TAG = "LoginActivity"
| progressDialogFragment = com.app.nhs.util.ProgressDialogFragment@1128844272 (0x4348cbf0)
| mDelegate = androidx.appcompat.app.AppCompatDelegateImpl@1136093920 (0x43b76ae0)
| mResources = androidx.appcompat.widget.VectorEnabledTintResources@1136092752 (0x43b76650)
| mThemeId = 2131886097
| mPendingFragmentActivityResults = androidx.collection.SparseArrayCompat@1118649752 (0x42ad3d98)
| mFragments = androidx.fragment.app.FragmentController@1135412416 (0x43ad04c0)
| mNextCandidateRequestIndex = 0
| mCreated = true
| mRequestedPermissionsFromFragment = false
| mResumed = false
| mStartedActivityFromFragment = false
| mStartedIntentSenderFromFragment = false
| mStopped = true
| mLifecycleRegistry = androidx.lifecycle.LifecycleRegistry@1135411496 (0x43ad0128)
| mOnBackPressedCallbacks = java.util.concurrent.CopyOnWriteArrayList@1135411832 (0x43ad0278)
| mViewModelStore = androidx.lifecycle.ViewModelStore@1136101176 (0x43b78738)
| mExtraDataMap = androidx.collection.SimpleArrayMap@1135411472 (0x43ad0110)
| mActionBar = null
| mActivityInfo = android.content.pm.ActivityInfo@1135407952 (0x43acf350)
| mAllLoaderManagers = android.util.ArrayMap@1128847128 (0x4348d718)
| mApplication = com.app.nhs.NHSApplication@1115479984 (0x427cdfb0)
| mWindowManager = android.view.WindowManagerImpl@1136092728 (0x43b76638)
| mWindow = com.android.internal.policy.impl.MiuiPhoneWindow@1135414400 (0x43ad0c80)
| mUiThread = java.lang.Thread@1105587800 (0x41e5ee58)
| mTranslucentCallback = null
| mComponent = android.content.ComponentName@1135407688 (0x43acf248)
| mToken = android.os.BinderProxy@1135407856 (0x43acf2f0)
| mContainer = android.app.Activity$1@1135411312 (0x43ad0070)
| mCurrentConfig = android.content.res.Configuration@1135413160 (0x43ad07a8)
| mDecor = null
| mTitle = "NHS Debug"
| mDefaultKeySsb = null
| mSearchManager = null
| mResultData = null
| mEmbeddedID = null
| mParent = null
| mMenuInflater = null
| mFragments = android.app.FragmentManagerImpl@1135411192 (0x43acfff8)
| mHandler = android.os.Handler@1135411440 (0x43ad00f0)
| mManagedDialogs = null
| mInstanceTracker = android.os.StrictMode$InstanceTracker@1135411352 (0x43ad0098)
| mInstrumentation = android.app.Instrumentation@1115474480 (0x427cca30)
| mIntent = android.content.Intent@1135407528 (0x43acf1a8)
| mLastNonConfigurationInstances = null
| mLoaderManager = null
| mManagedCursors = java.util.ArrayList@1135411328 (0x43ad0080)
| mMainThread = android.app.ActivityThread@1115428224 (0x427c1580)
| mLoadersStarted = false
| mIdent = 1136558632
| mFinished = true
| mEnableDefaultActionBarUp = false
| mResultCode = 0
| mDoReportFullyDrawn = false
| mResumed = false
| mDestroyed = true
| mStartedActivity = false
| mStopped = true
| mTemporaryPause = false
| mDefaultKeyMode = 0
| mTitleColor = 0
| mTitleReady = true
| mConfigChangeFlags = 0
| mCheckedForLoaderManager = true
| mChangingConfigurations = false
| mVisibleFromClient = true
| mVisibleFromServer = false
| mChangeCanvasToTranslucent = false
| mWindowAdded = true
| mCalled = true
| mBase = android.app.ContextImpl@1135413768 (0x43ad0a08)
| mInflater = com.android.internal.policy.impl.PhoneLayoutInflater@1136092288 (0x43b76480)
| mOverrideConfiguration = null
| mResources = android.content.res.MiuiResources@1115554328 (0x427e0218)
| mTheme = android.content.res.Resources$Theme@1136093792 (0x43b76a60)
| mThemeResource = 2131886097
| mBase = android.app.ContextImpl@1135413768 (0x43ad0a08)
* Excluded Refs:
| Field: android.app.ActivityThread$ActivityClientRecord.nextIdle
| Field: android.widget.Editor$EasyEditSpanController.this$0
| Field: android.widget.Editor$SpanController.this$0
| Field: android.os.Message.obj
| Field: android.os.Message.next
| Field: android.os.Message.target
| Field: android.view.inputmethod.InputMethodManager.mNextServedView
| Field: android.view.inputmethod.InputMethodManager.mServedView
| Field: android.view.inputmethod.InputMethodManager.mServedInputConnection
| Field: android.view.inputmethod.InputMethodManager.mCurRootView
| Field: android.animation.LayoutTransition$1.val$parent
| Field: android.view.textservice.SpellCheckerSession$1.this$0
| Field: androidx.appcompat.internal.widget.ActivityChooserModel.mActivityChoserModelPolicy
| Field: android.widget.ActivityChooserModel.mActivityChoserModelPolicy
| Field: android.speech.SpeechRecognizer$InternalListener.this$0
| Field: android.accounts.AccountManager$AmsTask$Response.this$1
| Field: android.media.MediaScannerConnection.mContext
| Field: android.os.UserManager.mContext
| Field: android.appwidget.AppWidgetHost$Callbacks.this$0
| Field: android.media.AudioManager$1.this$0
| Field: android.widget.Editor$Blink.this$0
| Field: android.net.ConnectivityManager.sInstance
| Field: android.view.Choreographer$FrameDisplayEventReceiver.mMessageQueue (always)
| Static field: android.text.TextLine.sCached
| Thread:FinalizerWatchdogDaemon (always)
| Thread:main (always)
| Thread:LeakCanary-Heap-Dump (always)
| Class:java.lang.ref.WeakReference (always)
| Class:java.lang.ref.SoftReference (always)
| Class:java.lang.ref.PhantomReference (always)
| Class:java.lang.ref.Finalizer (always)
| Class:java.lang.ref.FinalizerReference (always)