fix(atlas-service): generate correct Atlas URLs for Flex clusters COMPASS-10438#7821
Open
fix(atlas-service): generate correct Atlas URLs for Flex clusters COMPASS-10438#7821
Conversation
…PASS-10438 The URL builder functions were using the generic `#/host/{metricsType}/{metricsId}` pattern for all cluster types, producing broken URLs for Flex clusters. Flex clusters use a `#/flex/<section>/<clusterName>` format instead. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes URL generation for Atlas Flex clusters in Compass. Flex clusters require a different URL pattern (#/flex/<section>/<clusterName>) compared to traditional clusters that use #/host/<metricsType>/<metricsId> or #/metrics/<metricsType>/<metricsId>. The changes ensure that when users click on monitoring, performance metrics, cluster overview, or query insights links for flex clusters, they are directed to the correct Atlas UI pages.
Changes:
- Added flex cluster support to four URL builder functions:
buildPerformanceMetricsUrl,buildMonitoringUrl,buildClusterOverviewUrl, andbuildQueryInsightsUrl - Each function now checks if
metricsType === 'flex'and generates the appropriate flex-specific URL format - Updated function parameters to include
clusterNameandmetricsTypewhere needed
gribnoysup
reviewed
Feb 25, 2026
Collaborator
gribnoysup
left a comment
There was a problem hiding this comment.
Let's add some tests so that this doesn't regress
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
packages/atlas-service/src/url-builders.tsto generate correct URLs for Flex clusters#/flex/<section>/<clusterName>instead of#/host/{metricsType}/{metricsId}buildPerformanceMetricsUrl,buildMonitoringUrl,buildClusterOverviewUrl, andbuildQueryInsightsUrlJira
COMPASS-10438
Test plan
#/flex/monitoring/<clusterName>#/flex/realtime/<clusterName>#/flex/detail/<clusterName>#/flex/queryInsights/<clusterName>🤖 Generated with Claude Code