Requizon

The dashboard

The three pages, the failures-right-now panel, what the charts draw, and where the dashboard lives and who can open it.

The dashboard is served by your application at /requizon, with its own views, stylesheet and script, so it does not depend on your front-end build. It has three levels, each one a drill-down from a row of the one above.

The three pages#

PageListsReads
/requizon Every API, one row per host, with totals, success rate, average duration, failure count and failures right now The hourly rollup, and the detail rows since its last run
/requizon/{api}/paths The API's paths, failing-now first, then most failures. Opened from a host row, only that host's paths The hourly rollup, and the detail rows since its last run
/requizon/{api}/requests Individual calls in the selected window, newest first, with a Details panel on every row that stored something behind it The detail table, 50 rows a page
The paths page for one API: response time per path and responses by status per hour over 72 hours, above a table of three paths across two hosts
The paths page for one API. Its slowest paths get their own line on the response time chart.

The overview and paths page read the rollup as far as requizon:aggregate last got, and count everything after that straight from the detail rows. With the scheduler running every five minutes that is a few minutes of rows, so every page is current to the last call, the hour under way included. A rollup that has fallen behind costs a slower page, not missing numbers.

Failures right now#

Every page opens with what is failing at this moment: the failures of the last 15 minutes, by type, with when the last one happened and a link to them in the requests list. The overview and paths tables carry the same count on each row and sort anything failing now to the top, so an API that broke five minutes ago is the first row, not lost in a 72-hour average.

REQUIZON_RECENT_MINUTES=5   # what "right now" means, 15 by default

The charts#

Every page draws the same two charts over the selected window:

  • Response time: the average across everything on the page, plus a line for each of the three slowest members. APIs on the overview, paths on the paths page, and on the requests list whatever its filters leave.
  • Responses: calls per bucket, stacked by status code or failure type, so the height of each column is the request volume. The seven most frequent outcomes get their own colour and the rest are folded into Other.

Each chart has a Data disclosure underneath with the numbers behind it as a table. Windows longer than four days are drawn in wider buckets (two hours for a week, four for a fortnight), so a fortnight stays readable.

Filtering the requests list#

The requests list filters by host, path, outcome, status code and a date range. Host and path match exactly, using the values as stored, which is why the links from the paths page are the easiest way in.

The list covers the selected window, like the charts above it, so both always count the same period. It pages with Previous and Next rather than numbered pages. The detail table is the largest one Requizon keeps, and both a total to count up to and a jump into the middle of it would cost a scan of the window on every page load. Moving one page at a time costs the same however deep you go.

  • An outcome or status filter narrows the responses chart to the matching calls, so filtering to 503 charts only 503s per hour. Response time is not recorded per outcome, so that chart is hidden while one is applied.
  • A date range replaces the window, widened to whole hours at both ends, because the charts are drawn from hourly buckets.

Opening a row#

A row in the requests list carries a Details button whenever anything was stored behind it. The panel it opens holds these blocks, in this order, and prints each one only when the row has it:

BlockWhat it shows
FailureThe message the call was classified with
Request headersThe headers we sent, as far as header capture kept them
QueryThe query string, redacted, whatever the method was
BodyThe parsed request body, redacted
Response headersThe headers that came back, as far as header capture kept them
Response bodyThe body of a call recorded as a failure

Query and body come from separate columns and are filled for every method, so a POST that also carries a query string shows both, and a name that appears in each is shown in each. Both blocks are redacted by parameter name before anything is stored.

Headers are printed the way they went over the wire, one line per value, so a response that set four cookies shows four Set-Cookie lines instead of one joined string. Which of them reach the panel is decided by header capture, which out of the box keeps the response headers of failed calls and no request headers at all.

Windows#

// config/requizon.php
'dashboard' => [
    'windows' => [24, 72, 168, 336],   // hours offered by the selector
    'default_window' => 72,
    'per_page' => 50,                  // rows per page of the requests list
    'recent_minutes' => 15,            // what counts as "right now"
    'max_paths' => 500,                // rows on an API's paths page
],

A default_window that is not in windows falls back to the first entry, so the selector never claims one window while showing another. Offering a window longer than retention.detail_days works for the charts, which read the rollup, but the requests list will not reach that far back.

max_paths caps the paths page at the paths with the most failures, then the most requests, so an API whose paths the normaliser cannot bound still renders. It is a guard rather than a fix: an API that hits it needs a rewrite or an allow-list, and requizon:merge-paths to fold what is already stored.

Access#

Every dashboard route runs through the middleware in requizon.middleware (['web'] by default) and then Requizon's own check, which answers 403 to anyone it does not let in. The check your published RequizonServiceProvider installs is:

  • In the local environment, everyone.
  • Anywhere else, whoever the viewRequizon gate allows, and nobody until you define it.
protected function gate(): void
{
    Gate::define('viewRequizon', fn ($user) => in_array($user->email, [
        'ops@example.com',
    ]));
}

The gate receives the authenticated user, so a guest is refused without the closure running. For a check that is not about a user at all (an IP allow-list behind a VPN, say), replace the whole callback in the provider's boot() method, after parent::boot():

use BoringO11y\Requizon\Requizon;

Requizon::auth(fn ($request) => $request->ip() === '10.0.0.5');

If the provider is not registered at all, no callback exists and the dashboard is reachable only in the local environment.

Assets are not gated

The dashboard's stylesheet and script are served without the middleware or the gate, so its own error pages stay styled. They are two fixed files with no data in them.

Moving the dashboard#

REQUIZON_PATH=ops/outbound          # served at /ops/outbound
REQUIZON_DOMAIN=ops.example.com      # served only on that host

Add middleware to the list rather than replacing it, so the routes keep their session and cookies:

'middleware' => ['web', 'auth', 'verified'],

php artisan about prints the path the dashboard is currently served from.

Common questions

Can I serve the Requizon dashboard from a subdomain?

Yes. Set REQUIZON_DOMAIN to the host, and REQUIZON_PATH if you want something other than /requizon. The routes still run through the middleware listed in requizon.middleware and still ask the viewRequizon gate.

Install Requizon today.

Checkout ends with your license key, and the installation guide takes it from there.