Deployment marks

A deployment mark puts a recorded release in the same view as the measurements around it. This gives an operator a point from which to investigate a change without requiring them to remember the deployment time. The screenshot is from Fission's chart gallery.

What the chart is for

The marker records an event, not a causal conclusion. A response-time rise after deployment may be related, but the chart cannot establish that relationship from timing alone.

Data model

MarkPoint::xy uses chart coordinates. With a category x-axis, x is the category index; y is the response time in milliseconds. Resolve the event to the same sampling buckets used by the line before passing these values to the component.

Authoring from a Fission component

The response-time values and reporting rule arrive as props. Fetch measurements and resolve the rule before building the chart; changing a threshold must not start an implicit request during component conversion.
use fission::prelude::*;
use fission::charts::{Axis, Chart, LineSeries, MarkPoint};

// The parent resolves display labels from its translation bundles.
fission_component! {
    pub DeploymentMarksChart<()> {
        props {
            chart_title: String,
            series_label: String,
            annotation_label: String,
            category_labels: Vec<String>,
            response_ms: Vec<f32>,
            deployment_index: f32,
            deployment_response_ms: f32,
        }
    }
    view(report, _state, cx) {
        let colors = &cx.view.env().theme.tokens.colors;
    } =>
        Chart(
            title: Some(report.chart_title.clone()),
            x_axis: Some(Axis::category(
                report.category_labels.iter().map(String::as_str).collect(),
            )),
            y_axis: Some(Axis::value()),
            mark_points: vec![MarkPoint::xy(
                &report.annotation_label, report.deployment_index, report.deployment_response_ms,
            ).color(colors.primary)],
            series: vec![LineSeries::new(&report.series_label)
                .data(report.response_ms.clone())
                .into()],
        )
}

Testing and accessibility

Check a deployment between samples and a deployment outside the displayed period. Recalculate its category index when filtering the series so the marker remains attached to the correct time.
Give the rule and important values in readable text as well as a coloured mark. Inspect labels and contrast at the actual chart size in both themes.
Tags: markPoint, deploy.