Last active
December 11, 2021 15:55
-
-
Save vishalratna-microsoft/1989bec0aa6084e2a9c203cf34120220 to your computer and use it in GitHub Desktop.
Start and end the measurement using tags.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class NewsApplication : Application() { | |
override fun onCreate() { | |
super.onCreate() | |
if(BuildConfig.DEBUG) { | |
Snippet.install(Snippet.MeasuredExecutionPath()) | |
Snippet.newFilter("Carausell") | |
Snippet.addFlag(Snippet.FLAG_METADATA_LINE or Snippet.FLAG_METADATA_THREAD_INFO) | |
} | |
Snippet.startCapture("app_launch") // Starts the measurements and assigns a tag. Internally a log token is created | |
// representing this measurement that can be fetched using the Snippet.find(String) method. | |
// ... more code followed | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment