Skip to main content

TraceGraphData

from v9.4status Work-in-Progress

TraceGraphData is the Arrow-backed normalized graph snapshot used to construct runtime TraceGraph instances efficiently.

import {buildTraceGraphData, type TraceGraphData} from '@deck.gl-community/trace-layers/trace';

Shape

TraceGraphData contains graph metadata plus row-backed chunks. Each chunk carries:

  • chunkIndex and chunkRef
  • chunkKey
  • represented process refs
  • spanTable
  • localDependencyTable
  • optional span sidecars and other row-aligned tables

Span rows carry explicit processRef and threadRef owner columns. Resolve ownership through refs rather than assuming one chunk belongs to one process.

Use it for

  • compact static graph construction
  • Arrow transport and materialization
  • published streaming snapshots
  • visible window snapshots materialized from TraceChunkStore

Main helpers

  • buildTraceGraphData(...)
  • buildTraceGraphDataFromJSONTrace(...)
  • buildArrowTraceSpanTableFromRows(...)
  • buildArrowTraceLocalDependencyTable(...)
  • serializeArrowTraceJson(...)
  • deserializeArrowTraceJson(...)

Use JSONTrace when you need a JSON-safe boundary. Use TraceChunkData when a store still needs to finalize parser-local chunks before graph materialization.