Vtadmin monitoring integration #19000
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR implements the frontend support for integrating external monitoring tools (like Grafana and PMM) directly into VTAdmin, addressing some of the goals outlined in RFC: Integrate PMM into vtadmin (#11191).
Added a flexible, configuration-driven mechanism to link VTAdmin entities (Clusters, Tablets, Gates) to external dashboards. This allows VTAdmin to serve as a "single view" for Vitess operations, enabling users to navigate seamlessly from topology views to deep-dive metrics.
Introduced new environment variables to define dashboard URL patterns. These templates support dynamic placeholders that are replaced with context-specific data at runtime.
VITE_VITESS_MONITORING_CLUSTER_TEMPLATE: For cluster-level metrics.VITE_VITESS_MONITORING_VTTABLET_TEMPLATE: For tablet metrics.VITE_VITESS_MONITORING_VTGATE_TEMPLATE: For vtgate metrics.VITE_MYSQL_MONITORING_TEMPLATE: For underlying MySQL instance metrics (e.g., PMM).Supported Placeholders:
{cluster},{keyspace},{shard},{alias},{hostname},{type},{cell},{pool}.UI Integration
vtctld.vtgate.Demo & Verification
To demonstrate this functionality and provide a reference implementation, I have updated the
examples/vtadmindirectory.docker-composesetup with Prometheus, Grafana, and PMM running alongside Vitess.docker-compose.ymlis pre-wired with the newVITE_variables to link VTAdmin to the local monitoring stack.cd examples/vtadmin make upmonitoring_links_demo.mp4