Setting custom Activity Markers
Activity markers are events that occur in an application during runtime.
Activity lifecycle events are automatically captured by Finotes.
Developers can set custom activity markers anywhere in the app using setActivityMarker API. These markers will be shown along with the lifecycle events, when an issue is reported.
Activity markers are displayed in their chronological order.
There is no limit to the number of custom markers that can be set by the developer. Only when an issue is raised, these activity markers are sent to the server.
Please check the documentation page Setting SwiftUI views to activity trail to add lifecycle events of swiftUI views to activity trail.
Any where in the project:
- Objective C
- Swift
[Fn setActivityMarkerAt:self marker:@"clicked on payment_package_two"];
Fn.setActivityMarkerAt(self, marker: "completed login")
How activity trail will look like along with reported issue in Finotes dashboard:
AppDelegate:finishLaunchingOptions 11:19:24:469 45.79% FREE MEMORY
ViewController:viewDidLoad 11:19:24:708 44.39%
ViewController:viewWillAppear 11:19:27:012 45.19%
ViewController:viewDidAppear 11:19:28:515 44.53%
ViewController:clicked on payment_package_two 11:20:24:235 55.20%
Debug level Activity Markers
Developers can set custom activity markers that are active only in debug builds of the app. This can be achieved using setActivityMarkerForDebug API.
These markers are not captured in release or production builds.
Any where in the project:
- Objective C
- Swift
[Fn setActivityMarkerForDebugAt:self marker:@"logout tapped"]
Fn.setActivityMarkerForDebugAt(self, marker: "logout tapped")