Skip to content

[FR]: Allow setting the start time of the FIRTraceΒ #11933

Open
@mikeger

Description

@mikeger

Description

FIRTrace class encapsulates information about a single trace in Firebase Performance Analytics. FIRTrace contains a timestamp marking the start of the trace. The existing public API is automatically setting this property to the current time.

There are, however, use cases when setting a start time of the trace is necessary. An example of such a trace could be a performance trace from the earliest application startup time until the app interface is ready for interaction. In that case, we might want to create a custom trace and set its start time to the time we recorded when the app started, even before Firebase SDK was loaded.

API Proposal

Add to FIRTrace.h:

- (void)startWithStartTime:(nullable NSDate *)startTime;

Remove from FIRTrace-Internal.h (same line)

- (void)startWithStartTime:(nullable NSDate *)startTime;

Firebase Product(s)

Performance

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions