Dashboard Reference

The nine v3 dashboards Sophonz provides, panel by panel — which table each panel reads, what it computes and how, and how variables and drill-down links tie the dashboards together.

Every Sophonz dashboard reads spans, errors, sessions and logs straight out of ClickHouse with SQL. This page is a reference for developers: it takes the dashboards apart panel by panel so you can check how a number is defined and rewrite a query when you need to. How the custom panel plugins themselves behave, and their options, is covered in Custom Panels and Sophonz Chart Panels.

At a glance

DashboarduidWhat it showsPanels
Sophonz Service (v3)sophonz-service-v3Health of the whole service. Most investigations start here39
Session (v3)sophonz-session-v3A session list and the selected session's timeline on one screen5
Sophonz Session Listsophonz-session-list-v3A session list with many filters1
Sophonz Session Detailsophonz-session-detail-v3One session in depth — timeline, screen flow, service flow, traces5
Sophonz Tracessophonz-traces-v3Trace and span search with a Gantt view2
Sophonz Logssophonz-logs-v3OpenTelemetry log search2
Request Map (v3)sophonz-requestmap-v3A single request response-time heatmap1
Sophonz RUM (v3)sophonz-rum-v3Browser real-user monitoring — web vitals, page loads, fetch/XHR latency, browsers18
Sophonz Charts (v3)sophonz-charts-v3Latency and span breakdowns drawn with the Sophonz Chart panels5

The Service, RUM and Charts dashboards default to the last 6 hours and refresh every minute.

The # in the tables below is the panel id. To open a single panel full size, add viewPanel to the URL.

/d/sophonz-service-v3/?viewPanel=26

Moving between dashboards

The links below fill in the variables they need and open another dashboard. Every link also passes ${__url_time_range}, so the time range you were looking at comes along.

FromClickToVariables passed
Service #14 Recent tracesTrace IDGantt view #23 on the same dashboardtraceId
Service #15 Slowest tracesTrace IDGantt view #23 on the same dashboardtraceId
Service #29 Session listsessionIdSession (v3)sessionId
Session #1 Session listsessionIdSame dashboardsessionId
Session #4 Trace listtitleGantt view #5 on the same dashboardtraceId
Session List #2sessionIdSession DetailsessionId
Session Detail #4 Trace listtitleTrace view #5 on the same dashboardtraceId, spanId
Session Detail #4 Trace listLogsLogstraceId
Traces #2 ListNameGantt view #3 on the same dashboardtraceId, spanId
Traces #2 ListLogsLogstraceId
Traces #2 ListsessionIdSession DetailsessionId
Logs #3 LogstraceIDTracestraceId
Logs #3 LogssessionIdSession DetailsessionId

The dashboard header links (← Service metrics, Logs →, Traces →, ← Session list, Clear selection) work the same way. Clear selection reopens the same dashboard with only traceId and spanId emptied.

Where the data comes from

Every panel uses the grafana-clickhouse-datasource data source.

TableOne row isUsed by
sophonz_traces.distributed_sophonz_index_v2One spanNearly every panel
sophonz_traces.distributed_sophonz_error_index_v2One error: exception type, message, groupIDError KPI, error grouping
sophonz_traces.stored_analysis_sessionAggregated session state. …State columns are unpacked with groupUniqArrayMergeSession lists
sophonz_logs.distributed_logs_v2One log recordLogs

This shape repeats in almost every query:

lower(if(appSpanType != '', appSpanType, stringTagMap['span.type']))

Frequently used SDK attributes are copied into dedicated columns (appSpanType, appScreenName, appScreenType, httpURL) at ingest. Data sent by older SDK versions has those columns empty and the value only in stringTagMap. Queries read the column first and fall back to the tag map when it is empty, so a project with mixed SDK versions is counted consistently. Keep the same fallback when you write your own queries.

ColumnTag map fallback
appSpanTypestringTagMap['span.type']
appScreenNamestringTagMap['screen.name']
appScreenTypestringTagMap['screen.type']
httpURLstringTagMap['http.url'], then stringTagMap['url.full']

Macros

MacroWhat it does
$__timeFilter(timestamp)Filters to the dashboard time range
$__timeInterval(timestamp)Rounds down to the time-series bucket
$__fromTime, $__toTimeStart and end of the range. Used by the KPI previous-period comparison
$__conditionalAll(condition, $variable)Drops the whole condition when the variable is All, instead of building an IN list with thousands of values

Variables

VariableKindValuesDashboards
serviceNamespaceQueryProject (service.namespace)All
serviceNameQueryApp (service.name). Depends on serviceNamespaceService, Request Map, RUM, Charts
screenQueryScreen name, from browser spansRUM
sessionIdQueryMost recent sessions firstSession, Session Detail
traceId, spanIdTextFilled by drill-down links. Empty means the most recent traceService, Session, Session Detail, Traces, Logs
screenStart, screenEndText (hidden)The range picked in the screen flowSession, Session Detail
status, appType, appVersion, webVersion, userId, deviceId, sessionIdFilterMixedSession list filtersSession List
view, spanType, errorOnly, userId, qMixedTrace searchTraces
severity, qMixedLog searchLogs

Sophonz Service (v3)

Reads top to bottom through one service's health: flow → KPIs → trends → web vitals → traces → errors → screens → sessions.

Top — request flow

#PanelWhat
25DynamicXHR Monitorxhr/fetch request count, failure count and session count in the range. A status code of 0 or 400 and above counts as a failure. Panel details
26Request heatmapxhr/fetch requests plotted by time (x) and response time (y, log scale). Up to 100,000 requests. Panel details

KPI cards

#NameValueBetter when
1SessionsuniqCombined64(sessionID)Neutral
3Avg renderMean duration of render spans (ms)Lower
4Avg requestMean duration of xhr/fetch spans (ms)Lower
2Slow requestsShare of xhr/fetch over 1 second (%)Lower
52Error sessionsShare of sessions that hit at least one error (%)Lower
5ErrorsRow count of the error indexLower

Each card runs three queries — the current value (A), the value for the previous period of the same length (B), and the sparkline (C). Why it is split in three is explained under KPI in Custom Panels. The error sessions card looks like this:

-- A: current range
SELECT ROUND(100 * uniqCombined64If(sessionID, hasError)
             / nullIf(uniqCombined64(sessionID), 0), 1) AS v
FROM sophonz_traces.distributed_sophonz_index_v2
WHERE $__timeFilter(timestamp)
  AND $__conditionalAll(serviceNamespace IN (${serviceNamespace:singlequote}), $serviceNamespace)
  AND $__conditionalAll(serviceName IN (${serviceName:singlequote}), $serviceName)
 
-- B: the same length immediately before
WHERE timestamp >= $__fromTime - ($__toTime - $__fromTime) AND timestamp < $__fromTime
 
-- C: sparkline
SELECT $__timeInterval(timestamp) AS t, … GROUP BY t ORDER BY t

The card shows the error session rate rather than the error count because the rate does not move with traffic. Twice the visits means twice the errors, but the rate stays the same. Slow requests follow the same idea — an average hides a few very slow requests, while the share over 1 second exposes that tail.

uniqCombined64 is an approximate distinct count. Expect around 1% error with many sessions.

#PanelWhat
6Session trendDistinct sessions per bucket
7Avg render/request time trendPer-bucket mean of render, and of xhr/fetch
9Top request URLsRequest count and mean duration per URL. Top 50 by mean duration

Render figures in #7, #21 and #22 count render spans only. The post-docs spans older views added in are not included, so values can be lower than on those older views.

Web vitals

LCP, INP, CLS, FCP and TTFB are read from webvitals spans.

#PanelWhat
41–45LCP / INP / CLS / FCP / TTFB p75p75 per metric and the sample size n
46Rating distribution by metricShare of good · needs-improvement · poor
47Web vitals p75 trendThe four ms metrics (LCP, INP, FCP, TTFB). Right axis is sample size
48CLS p75 trendCLS on its own. Threshold lines at good 0.1 / poor 0.25
49Load vitals by screenLCP, FCP, TTFB p75 per screen, good rate, poor count
50Interaction vitals by screenINP, CLS p75 per screen, good rate, poor count
51Web vitals by devicep75 of all five metrics per device

Thresholds follow Google's:

Metricgoodpoor
LCP≤ 2500 ms> 4000 ms
INP≤ 200 ms> 500 ms
CLS≤ 0.1> 0.25
FCP≤ 1800 ms> 3000 ms
TTFB≤ 800 ms> 1800 ms

Each measurement is counted once. A web vital is reported several times before its value settles — CLS grows with each layout shift, INP changes when a slower interaction comes along. So queries group by (sessionID, measurement id) and keep only the last value. Older SDKs without a measurement id use spanID instead.

SELECT vital,
       argMax(value, timestamp)  AS value,
       argMax(rating, timestamp) AS rating,
       argMax(screen, timestamp) AS screen,
       argMax(device, timestamp) AS device
FROM (
  SELECT timestamp, sessionID,
         if(stringTagMap['browser.web_vital.id'] != '',
            stringTagMap['browser.web_vital.id'], spanID)            AS vid,
         stringTagMap['browser.web_vital.name']                      AS vital,
         numberTagMap['browser.web_vital.value']                     AS value,
         stringTagMap['browser.web_vital.rating']                    AS rating,
         appScreenName                                               AS screen,
         resourceTagsMap['sophonz.browser.device']                   AS device
  FROM sophonz_traces.distributed_sophonz_index_v2
  WHERE $__timeFilter(timestamp) AND appSpanType = 'webvitals'
)
GROUP BY vital, sessionID, vid

The real queries also fall back to the older attribute names (web-vital.name, web-vital.value, web-vital.rating) and use unknown when the device tag is missing.

A few more rules the queries keep:

  • p75 is computed from raw rows. Percentiles do not compose; averaging per-screen p75s does not give the overall p75. quantileExact(0.75) runs over all deduplicated rows.
  • Rates are safe under any grouping. That is why the rating distribution in #46 still means something for screens with few samples.
  • Under 30 samples, p75 is noise. #49–#51 color n red but do not hide small groups.
  • Sorted by poor count, not p75. A screen where many users actually had a bad experience matters more than the worst p75 on a screen three people visit a day.
  • Load and interaction vitals are separate tables. LCP, FCP and TTFB happen once per hard navigation and belong to the entry screen; INP and CLS accumulate across SPA route changes and belong to the last reported screen.
  • Device is resourceTagsMap['sophonz.browser.device'], matching how Google reports mobile and desktop separately.

Traces

#PanelWhat
12Trace trendRoot spans per bucket, and root spans with an error
13Span type distributionSpan count per type (render, xhr, longtask, anr …)
14Recent tracesLatest 200 root spans. Clicking a Trace ID loads it into #23
15Slowest tracesTop 50 root spans by duration
23Trace Gantt viewGrafana's built-in traces visualization. With traceId empty, the most recent trace in range

A trace counts as one row with isRootSpan = true. The Gantt view unfolds stringTagMap and resourceTagsMap into {key, value} arrays for the span and resource attribute tabs, and draws up to 1000 spans.

Error grouping

#PanelWhat
17Error groupsPer groupID: exception type, message, occurrences, affected sessions, affected devices, last seen. Top 100 by occurrences
18Error trend by typeCount per bucket and exception type
10Top errorsCount per exception type, message, serviceVersion and webVersion

Errors are grouped by the groupID the error index assigns. Occurrences alone push up errors that one user hit over and over, so look at affected sessions too. #10 has version columns for finding errors introduced by a particular release.

Screens

#PanelWhat
20Top 20 screens by visitsrender and route spans per screen
21Top 20 screens by avg renderMean render per screen
22Screen detailsType, screen, visits, render, request, errors, error rate

Type in #22 is appScreenType. Web reports page, Android activity, iOS view and Jetpack Compose composable, so a mixed-platform project still compares screen to screen in one table.

Sessions

#PanelWhat
29Session listPer session: status (error/ok), user, device, app type, web version, start, length (s), trace count. Clicking sessionId opens Session (v3)

The session list reads stored_analysis_session, not the span index. It only merges pre-aggregated state per session, so long ranges stay cheap.

Session (v3)

A one-screen dashboard: pick a session and see it right below.

#PanelWhat
1Session listSame list as Service #29. Clicking sessionId switches everything below to that session
2Session TimelineThe session's root spans on a time axis, one lane per type. Panel details
6Session Timeline GraphScreen navigation as a graph. Panel details
4Trace listThe session's root spans in time order, up to 1000. The span picked in the timeline is marked ●
5Trace Gantt viewThe picked trace, or the session's most recent trace

Clicking a span in the timeline fills spanId and traceId: the trace list marks it with ● and the Gantt view loads that trace. Picking a screen in the screen flow puts the time spent on it into the hidden screenStart and screenEnd variables, and the timeline zooms to that range.

Sophonz Session List

A single table, #2, with eight filters. Use it to find sessions for a particular user, device or version.

FilterFilters on
statusAll / error / ok
appTypeclientPlatform — the platform value the SDK reported
appVersionserviceVersion
webVersionwebVersion
userId, deviceId, sessionIdFilterThe value you type

Clicking sessionId opens Session Detail.

Sophonz Session Detail

One session in depth. Unlike Session (v3) it has no session list; instead it has Service Flow and log links.

#PanelWhat
3Session TimelineTimeline with one lane per type
2Screen FlowScreen navigation graph
6Service FlowEvery span of the session (up to 20,000) as service nodes and call edges. Panel details
4Trace listRoot spans in time order. The Logs column opens that trace's logs
5Trace viewGantt of the picked trace

The timeline and screen flow read root spans only. Service Flow has to connect calls between services, so it reads every span in the session without the isRootSpan condition.

Sophonz Traces

Search traces and spans.

#PanelWhat
2Trace / span listWith view = trace, root spans only (one row per trace); with span, every span
3Trace Gantt viewThe trace whose name you clicked, or the most recent one in range

List columns are time, user, type, screen, name, root (●), status, duration, HTTP status code, logs and session. Filter with spanType, errorOnly, userId and q (name search).

Sophonz Logs

Search OpenTelemetry logs.

#PanelWhat
2Log volumeStacked count per severity. Empty severity shows as UNSET
3LogsTime, severity, body, traceID, spanID, session, service. Latest 2000

Logs carry no session id. #3 LEFT JOINs the span index for the same time range on traceID to find and attach the session, so logs not tied to a trace have an empty session cell.

Filter with severity (TRACE, DEBUG, INFO, WARN, ERROR, FATAL), q (case-insensitive substring of the body), traceId and spanId. WARN and WARNING count as the same.

Request Map (v3)

The heatmap from Service #26 on a dashboard of its own. Filter with serviceNamespace and serviceName.

Sophonz RUM (v3)

Browser real-user monitoring on one screen, in the RUM folder. Every query keeps only browser spans with webVersion != '', and the screen variable narrows all panels to the chosen screens. Apart from the four stat panels at the top, the dashboard is built from the Sophonz Chart panels.

#PanelWhat
1–4Page loads, Sessions, Errors, Average LCPStat panels. render span count, uniqExact(sessionID), spans with hasError, and the mean of numberTagMap['browser.web_vital.value'] for lcp
10–14LCP, FCP, INP, CLS, TTFBThe mean of each web vital on an arc, coloured good / needs improvement / poor. Panel details
15Web Vitals rating distributionOne ring per vital, split by stringTagMap['browser.web_vital.rating']. Panel details
20LCP trendMean LCP, FCP and TTFB per bucket over the LCP bands at 2.5 s and 4 s. Panel details
21Page loads by screen TopNrender spans per screen over time, with the busiest screens ranked below. Panel details
30Fetch/XHR response time distributionfetch and xhr spans as a density heatmap on a log axis, with errors in their own colour. Up to 200,000 spans. Panel details
31, 32Sessions by browser, Sessions by OSDistinct sessions per resourceTagsMap['sophonz.browser.name'] and resourceTagsMap['os.name'], as donuts. Panel details
40User actions TopNInteraction spans counted by event type and element tag (stringTagMap['event_type'], stringTagMap['target_element_tag']). Panel details
41Fetch/XHR speed distributionRequests under 300 ms, under 1 s and slower, as shares of one band. Panel details
42Spans by typeSpan count per type over time

The band limits on the gauges are the thresholds web.dev recommends for each metric.

VitalGood up toPoor fromGauge max
LCP2500 ms4000 ms6000
FCP1800 ms3000 ms5000
INP200 ms500 ms800
CLS0.10.250.5
TTFB800 ms1800 ms3000

The gauges show the mean of each vital over the range. The web vitals rows on Service (v3) are the place to read p75.

Sophonz Charts (v3)

Five Sophonz Chart panels over live spans, in the Service folder. It filters with serviceNamespace and serviceName and works for any platform.

#PanelWhat
1XHR/Fetch response time distributionxhr and fetch spans as a density heatmap on a log axis. Up to 200,000 spans. Panel details
2Response speed distributionxhr and fetch spans under 500 ms (Normal), under 2 s (Slow) and above (Very Slow). Panel details
3Query phase durationsTotal time in the Planner, ExecutorRun and Result components of the sophonz-postgres service. Panel details
4Span count by type TopNSpan count per type over time, with a ranking. Panel details
5Response speed by serviceOne ring per service, split into the same three speed groups as #2, over every span. Panel details

#3 reads spans from one service by name. On a project without a service called sophonz-postgres it is empty.

When you edit a query

  • Do not build distinct session counts by summing buckets. Sessions that cross a bucket boundary get counted twice; on a real day of traffic that came out 31% high.
  • Do not average percentiles. Recompute p75 from raw rows.
  • Rates and counts are fine to combine. Like the rating distribution, they hold up when split and regrouped.
  • Keep the promoted column → tag map fallback. Leave it out and data from older SDKs silently drops.
  • Wrap filter variables in $__conditionalAll. The condition disappears for All and the query gets lighter.