class DataSourceBase

Defined at line 90 of file ../../third_party/perfetto/include/perfetto/tracing/data_source.h

Base class with the virtual methods to get start/stop notifications.

Embedders are supposed to derive the templated version below, not this one.

Public Methods

void ~DataSourceBase ()
void OnSetup (const SetupArgs & )
void OnStart (const StartArgs & )

Invoked after tracing is actually started.

Can be called from any thread.

void OnStop (const StopArgs & )

Invoked before tracing is stopped.

Can be called from any thread. Blocking this for too long it's not a good

idea and can cause deadlocks. Use HandleAsynchronously() to postpone

disabling the data source instance.

void WillClearIncrementalState (const ClearIncrementalStateArgs & )

Invoked before marking the thread local per-instance incremental state

outdated.

Can be called from any thread.

void OnFlush (const FlushArgs & )

Called when the tracing service requests a Flush. Users can override this

to tell other threads to flush their TraceContext for this data source

(the library cannot execute code on all the threads on its own).

Can be called from any thread. Blocking this for too long it's not a good

idea and can cause deadlocks. Use HandleAsynchronously() to postpone

sending the flush acknowledgement to the service.

bool CanAdoptStartupSession (const DataSourceConfig & startup_config, const DataSourceConfig & service_config)

Determines whether a startup session can be adopted by a service-initiated

tracing session (i.e. whether their configs are compatible).

Records