Tracing Domain
Methods
Events
Types
Methods
Tracing.end #
Stop trace events collection.
Tracing.start #
Start trace events collection.
parameters
- categories
- 
          string
          
      ExperimentalDeprecatedCategory/tag filter 
- options
- 
          string
          
      ExperimentalDeprecatedTracing options 
- bufferUsageReportingInterval
- 
          number
          
      ExperimentalIf set, the agent will issue bufferUsage events at this interval, specified in milliseconds 
- transferMode
- 
          string
          
      Whether to report trace events as series of dataCollected events or to save trace to a stream (defaults to ReportEvents).Allowed Values:ReportEvents,ReturnAsStream
- streamFormat
- 
          StreamFormat
          
      Trace data format to use. This only applies when using ReturnAsStreamtransfer mode (defaults tojson).
- streamCompression
- 
          StreamCompression
          
      ExperimentalCompression format to use. This only applies when using ReturnAsStreamtransfer mode (defaults tonone)
- traceConfig
- 
          TraceConfig
          
      
- perfettoConfig
- 
          string
          
      ExperimentalBase64-encoded serialized perfetto.protos.TraceConfig protobuf message When specified, the parameters categories,options,traceConfigare ignored. (Encoded as a base64 string when passed over JSON)
- tracingBackend
- 
          TracingBackend
          
      ExperimentalBackend type (defaults to auto)
Tracing.getCategories Experimental #
Gets supported tracing categories.
Return Object
- categories
- 
          array[ string ]
          
      A list of supported tracing categories. 
Tracing.recordClockSyncMarker Experimental #
Record a clock sync marker in the trace.
parameters
- syncId
- 
          string
          
      The ID of this clock sync marker 
Tracing.requestMemoryDump Experimental #
Request a global memory dump.
parameters
- deterministic
- 
          boolean
          
      Enables more deterministic results by forcing garbage collection 
- levelOfDetail
- 
          MemoryDumpLevelOfDetail
          
      Specifies level of details in memory dump. Defaults to "detailed". 
Return Object
- dumpGuid
- 
          string
          
      GUID of the resulting global memory dump. 
- success
- 
          boolean
          
      True iff the global memory dump succeeded. 
Events
Tracing.tracingComplete #
Signals that tracing is stopped and there is no trace buffers pending flush, all data were delivered via dataCollected events.
parameters
- dataLossOccurred
- 
          boolean
          
      Indicates whether some trace data is known to have been lost, e.g. because the trace ring buffer wrapped around. 
- stream
- 
          IO.StreamHandle
          
      A handle of the stream that holds resulting trace data. 
- traceFormat
- 
          StreamFormat
          
      Trace data format of returned stream. 
- streamCompression
- 
          StreamCompression
          
      Compression format of returned stream. 
Tracing.bufferUsage Experimental #
parameters
- percentFull
- 
          number
          
      A number in range [0..1] that indicates the used size of event buffer as a fraction of its total size. 
- eventCount
- 
          number
          
      An approximate number of events in the trace log. 
- value
- 
          number
          
      A number in range [0..1] that indicates the used size of event buffer as a fraction of its total size. 
Tracing.dataCollected Experimental #
Contains a bucket of collected trace events. When tracing is stopped collected events will be sent as a sequence of dataCollected events followed by tracingComplete event.
parameters
- value
- 
          array[ object ]
          
      
Types
Tracing.TraceConfig #
Type: object
properties
- recordMode
- 
          string
          
      ExperimentalControls how the trace buffer stores data. The default is recordUntilFull.Allowed Values:recordUntilFull,recordContinuously,recordAsMuchAsPossible,echoToConsole
- traceBufferSizeInKb
- 
          number
          
      ExperimentalSize of the trace buffer in kilobytes. If not specified or zero is passed, a default value of 200 MB would be used. 
- enableSampling
- 
          boolean
          
      ExperimentalTurns on JavaScript stack sampling. 
- enableSystrace
- 
          boolean
          
      ExperimentalTurns on system tracing. 
- enableArgumentFilter
- 
          boolean
          
      ExperimentalTurns on argument filter. 
- includedCategories
- 
          array[ string ]
          
      Included category filters. 
- excludedCategories
- 
          array[ string ]
          
      Excluded category filters. 
- syntheticDelays
- 
          array[ string ]
          
      ExperimentalConfiguration to synthesize the delays in tracing. 
- memoryDumpConfig
- 
          MemoryDumpConfig
          
      ExperimentalConfiguration for memory dump triggers. Used only when "memory-infra" category is enabled. 
Tracing.MemoryDumpConfig Experimental #
Configuration for memory dump. Used only when "memory-infra" category is enabled.
Type: object
Tracing.MemoryDumpLevelOfDetail Experimental #
Details exposed when memory request explicitly declared. Keep consistent with memory_dump_request_args.h and memory_instrumentation.mojom
background, light, detailedType: string
Tracing.StreamCompression Experimental #
Compression type to use for traces returned via streams.
none, gzipType: string
Tracing.StreamFormat Experimental #
Data format of a trace. Can be either the legacy JSON format or the protocol buffer format. Note that the JSON format will be deprecated soon.
json, protoType: string
Tracing.TracingBackend Experimental #
Backend type to use for tracing. chrome uses the Chrome-integrated
tracing service and is supported on all platforms. system is only
supported on Chrome OS and uses the Perfetto system tracing service.
auto chooses system when the perfettoConfig provided to Tracing.start
specifies at least one non-Chrome data source; otherwise uses chrome.
auto, chrome, systemType: string