{% extends "_base.html" %} {% block accent %}#4f46e5{% endblock %} {% block subtitle %}Per-endpoint P50/P95/P99, database load, user-experience (Apdex) and server-cost attribution — sampling-corrected from production telemetry.{% endblock %} {% block body %} {% set max_q = (rows|map(attribute='avg_db_queries')|max) or 1 %} {% set max_share = (rows|map(attribute='db_share')|max) or 1 %}
Health headline — read this first
{{ apdex_gauge|safe }}
{{ "%.2f"|format(apdex) }}
Platform Apdex
{% if apdex >= 0.94 %}Healthy{% elif apdex >= 0.85 %}Watch{% else %}Action needed{% endif %}

Platform Apdex {{ "%.2f"|format(apdex) }} at T = {{ apdex_t }} ms

{% if top_offender %}

{{ top_offender.endpoint }} carries {{ top_offender.db_share }}% of all database time on {{ top_offender.traffic_share }}% of traffic ({{ top_offender.avg_db_queries }} queries/request, p95 {{ top_offender.p95 }} ms) — the clearest optimisation target this window.

{% endif %}
Platform percentiles at a glance
P50 median
{{ kpi_p50 }} ms
Half of requests faster than this
P95 latency
{{ kpi_p95 }} ms
1 in 20 users wait this long
P99 latency
{{ kpi_p99 }} ms
Worst-case tail
Within SLA
{{ kpi_sla_pct }} %
< {{ sla_ms }} ms · avg {{ kpi_avg_rt }} ms
Priority watchlist — what to fix, in order
Ranked by Priority Index = traffic 30% + tail-latency 35% + database-cost 35%, normalised 0–100.
{% for r in rows %} = 50 %}class="hot"{% endif %}> {% endfor %}
#EndpointPriorityP95P99Qry/reqDB-time share
{{ loop.index }} {{ r.endpoint }} {{ r.priority }} {{ r.p95 }} {{ r.p99 }} {{ r.avg_db_queries }}
{{ r.db_share }}%
Where to spend effort — traffic × latency × cost
Right = more traffic · up = slower p95 · bigger = more DB time. Shaded band = slow meets popular.
Endpoint prioritisation map
x: traffic share · y: p95 latency · bubble area: DB-time share
{{ bubble_svg|safe }}
Database load & user experience
Queries/request exposes N+1 loops; DB-bound % says whether latency is the database's fault. Apdex (T = {{ apdex_t }} ms) and tail spread (P99÷P50) capture experience.
{% for r in rows %} {% endfor %}
EndpointQry/reqAvg DBDB-boundTail spreadApdexRating
{{ r.endpoint }}
{{ r.avg_db_queries }}
{{ r.avg_db_ms }} ms {{ r.db_pct }}% {{ r.tail_spread }}× {{ "%.2f"|format(r.apdex) }} {% if r.apdex >= 0.94 %}Excellent {% elif r.apdex >= 0.85 %}Good {% elif r.apdex >= 0.70 %}Fair {% else %}Poor{% endif %}
Server-cost attribution (per period)
Cost = time × volume, scaled to the report window. Compute = request-handling hours · DB = database hours · Egress = response bytes.
{% for r in rows %} {% endfor %}
EndpointRequestsCompute-timeDB-timeEgress
{{ r.endpoint }}{{ r.requests|format_number }} {{ r.compute_h }} h{{ r.db_h }} h{{ r.egress_mb }} MB
{% endblock %}