There are a few places I've seen where we hold onto fragment references in other classes, for example. That's almost certainly leaking memory. There's usually a way to engineer it so you don't need to wrap these things in a WeakReference, but that can be used as a last resort if we absolutely need a reference to an object with an Android lifecycle.
Memory leaks are super common in Android. Luckily, there's a nice library that can automatically detect them: https://square.github.io/leakcanary/getting_started/
There are a few places I've seen where we hold onto fragment references in other classes, for example. That's almost certainly leaking memory. There's usually a way to engineer it so you don't need to wrap these things in a
WeakReference
, but that can be used as a last resort if we absolutely need a reference to an object with an Android lifecycle.