Track the ability to rollback our packages
I'd like to start tracking data about our packages/deployments in the context of rollback using delivery-metrics and prometheous:
-
delivery_packages_tagging_total
is a counter that tracks how many auto_deploy packages we tag -
delivery_deployment_started_total
is a counter that tracks how many auto_deploy packages we begin to deploy, it has anenvironment
label to identify the target environment -
delivery_deployment_rollbackable_total
is a counter that tracks how many auto_deploy packages can be rolled back, it has anenvironment
label to identify the target environment
What should we get out of these metrics?
The comparison between delivery_packages_tagging_total
and delivery_deployment_started_total
by environment
should give us an idea of our ability to promote every package we tag.
The comparison between delivery_packages_tagging_total
and delivery_deployment_rollbackable_total
by environment
should help us to figure out the percentage of rollbackable packages and how this is affected by non-promoted builds.
Is a package rollbackable?
There is a caveat in considering a package able to rollback or not. It's the previous package on the target environment.
Package C
may be able to rollback to Package B
in staging but not to Package A
in production. Hence the need to count delivery_packages_rollbackable_total
by environment.