Name Description Size
AppStartReasonProvider.kt Provides the reason this [Application] instance was started: see [StartReason] for options and [reason] for details. This class relies on specific lifecycle method call orders and main thread Runnable scheduling that could potentially change between OEMs and OS versions: **be careful when using it.** This implementation was tested on the Moto G5 Android 8.1.0 and the Pixel 2 Android 11. 4400
DefaultActivityLifecycleCallbacks.kt An inheritance of [Application.ActivityLifecycleCallbacks] where each method has a default implementation that does nothing. This allows classes that extend this interface to have more concise definitions if they don't implement some methods; this is in the spirit of other `Default*` classes, such as [androidx.lifecycle.DefaultLifecycleObserver]. 1253
StartupActivityLog.kt A record of the [Activity] created, started, and stopped events as well as [Application] foreground and background events. See [log] for the log. This class is expected to be registered in [Application.onCreate] by calling [registerInAppOnCreate]. To prevent this list from growing infinitely, we clear the list when the application is stopped. This is acceptable from the current requirements: we never need to inspect more than the current start up. 4258
StartupPathProvider.kt This should be a member variable of [Activity] because its data is tied to the lifecycle of an Activity. Call [attachOnActivityOnCreate] & [onIntentReceived] for this class to work correctly. 4203
StartupStateProvider.kt Identifies the "state" of start up where state can be COLD/WARM/HOT and possibly others. This class is nuanced: **please read the kdoc carefully before using it.** Consider contacting the perf team with your use case. For this class, we use the terminology from the [StartupActivityLog] such as STARTED and STOPPED. However, we're assuming STARTED means foregrounded and STOPPED means backgrounded. If this assumption is false, the logic in this class may be incorrect. 6296
StartupTypeTelemetry.kt Records telemetry for the number of start ups. See the [Fenix perf glossary](https://wiki.mozilla.org/index.php?title=Performance/Fenix/Glossary) for specific definitions. This should be a member variable of [MainActivity] because its data is tied to the lifecycle of an Activity. Call [attachOnMainActivityOnCreate] for this class to work correctly. N.B.: this class is lightly hardcoded to MainActivity. 4389