Skip to content

product-selector: v1 alt_link key collides between InfluxDB OSS v1 and InfluxDB Cloud 1 #7113

@jstirnaman

Description

@jstirnaman

Problem

layouts/partials/topnav/product-selector.html uses the alt_link key v1 for both InfluxDB OSS v1 (line 16) and InfluxDB Cloud 1 (line 31):

{{ $influxdbOSSv1 := dict "influxdb/v1" (slice "InfluxDB OSS v1" "v1") }}
...
{{ $influxdbCloud1 := dict "influxcloud/v1" (slice $.Site.Data.products.influxdb_cloud1.name "v1") }}

When a page's frontmatter declares alt_links: { v1: /some/path/ }, the productLink template looks up the key and applies the same URL to both the OSS v1 slot and the Cloud 1 slot of the product selector dropdown — regardless of which product the link was intended for.

Repro

  1. Visit a page whose frontmatter sets alt_links: { v1: /influxdb/v1/some-path/ } (for example, any v1 release-notes or API page).
  2. Open the product selector.
  3. Both InfluxDB OSS v1 and InfluxDB Cloud 1 entries point to the same OSS v1 URL.

Fix options

  • Give Cloud 1 a distinct key, e.g. cloud_v1 (parallel with enterprise_v1).
  • Or: drop alt_link support for influxcloud/v1 entirely and always use its special-link path (it already has a $specialLink branch in productLink).

Either way, any existing page-level v1: alt_links will still resolve correctly for OSS v1, and Cloud 1 will route through an unambiguous key or the special-link branch.

Context

Found while auditing alt_link keys during #6622 (feat-api-uplift). Separate from that PR's fix for the enterprise-v1enterprise_v1 mismatch in data/api_products.yml.

Recap:

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:site-uiDocumentation site UI: templates, styles, JS/TSproduct:v1InfluxDB v1 OSS

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions