Setup CI insights routing configuration
Change the routing from pipelines/charts
to pipelines/analytics
since charts
is a really restrictive terminology when talking about data visualization. It also doesn't really convey what this page is, which is a way to get information, not just nice charts. Then we can also get rid of the query parameter for the tabs and instead support first-class routing.
Currently, each graph has its own tab, but some of them are related and should live on the same page. We want to give easier visibility to each sections and a quick link that can be added in other areas of the platform to redirect to useful metrics. Over time, we should also aim to have more CTA from this data.
To support redirects from pipelines/charts
to pipelines/analytics
, we can add a simple redirect on the controller side. Then we have current query parameter to determine which tab to load chart=
and the value of this query parameter is equal to the copy of the tab name. To support first class routing, we'd add each of these as a valid route in the rails/config/project/routes.rb
, add them the in pipelines_controller
and then change the VueRouter behavior from the tabs query parameter to pushing the route directly. This will make each of these entity more separate and easier to access, which will support our goal to make this area more well known and remembered.
-
pipelines/charts?chart=pipelines
=>pipelines/analytics
(we drop thepipelines
because implicitly, this is what we expect since we are already on thepipelines/
route.) -
pipelines/charts?chart=deployment-frequency
=>pipelines/analytics/deployments
-
pipelines/charts?chart=lead-time
=>pipelines/analytics/deployments
(merged with the above because they relate to each others) -
pipelines/charts?chart=time-to-restore-service
=>pipelines/analytics/incidents
-
pipelines/charts?chart=change-failure-rate
=>pipelines/analytics/incidents
(merged with the above as they relate to each others) -
pipelines/charts?chart=project-quality
=>pipelines/analytics/quality
On top of that, some of the tabs fire their query on load and slow the page down quite a bit. We should ensure that they are all lazy loaded.