ObserverWeb.Tracer.Tool.CallSeq (Observer Web v0.2.5)
View SourceBuilds an indented call-sequence tree per process: every traced call is an "enter" line and every matching return is an "exit" line, indented by nesting depth.
Ported and adapted from https://github.com/gabiz/tracer's Tracer.Tool.CallSeq:
- Drops the
start_match/startedgating - upstream can trace a whole process but only start recording once a specific function is called. Observer Web already scopes which functions can be traced from the Profiling page's own function picker, so there's no separate "start match" concept to gate on - every entry/exit is recorded from the start. - Drops the
show_args/show_returntoggles - both are always shown here. Arguments need thecall_seqmatch spec (ObserverWeb.Tracer.Tool.forced_match_spec_keys/1forces it in), and return values come for free oncereturn_trace()is set, so there's no extra cost to always including them. max_depthis a fixed internal safety cap rather than an init option, to keep runaway recursion from growing a process's stack unbounded.
Summary
Functions
Finalizes into a flat, ordered list of %{node:, pid:, pid_label:, depth:, type:, mod:, fun:, arity:, detail:} maps - detail holds the call arguments on :enter and the return value on
:exit, and pid_label is the process's registered name when it has one (see
ObserverWeb.Tracer.Tool.process_label/1), the pid otherwise. Depth here is recomputed fresh
per pid from the (already max-depth-capped) stack, so it's always a valid 0-based nesting level
regardless of how deep the untruncated call actually went.
Types
Functions
Finalizes into a flat, ordered list of %{node:, pid:, pid_label:, depth:, type:, mod:, fun:, arity:, detail:} maps - detail holds the call arguments on :enter and the return value on
:exit, and pid_label is the process's registered name when it has one (see
ObserverWeb.Tracer.Tool.process_label/1), the pid otherwise. Depth here is recomputed fresh
per pid from the (already max-depth-capped) stack, so it's always a valid 0-based nesting level
regardless of how deep the untruncated call actually went.
@spec new() :: t()