Skip to content

[AWS Onboarding] Add 'take me to my data' functionality - #290579

Merged
Supplementing merged 16 commits into
elastic:mainfrom
Supplementing:aws-overview-dashboard-navigation
Sep 15, 2026
Merged

Supplementing merged 16 commits into
elastic:mainfrom
Supplementing:aws-overview-dashboard-navigation

Conversation

@Supplementing

@Supplementing Supplementing commented Sep 11, 2026

Copy link
Copy Markdown
Contributor

Summary

Closes elastic/ingest-dev#9232 (navigation portion)

The "Take me to my data" button in Step 4 (Detect & Review) was a no-op — it marked the step complete but navigated nowhere. This wires it to the [Metrics AWS] Overview dashboard installed with the AWS integration.

Important

Needs discussion — elastic/ingest-dev#9232
The second line item in the issue (adding cross-dashboard navigation links to [Metrics AWS] Overview) is deferred pending discussion with both this team and the aws package owners. The core tension is that any useful nav needs to be contextual — showing only the services the user actually deployed — which the static package dashboard cannot support today. Options under consideration:

Option What Owner Problem
A — Modify the package dashboard Add a static Links panel in elastic/integrations pointing to all AWS service sub-dashboards aws package owners Static — shows all 50+ service links regardless of deployment. Impractical at that scale.
B — Custom Kibana landing page ingest_hub renders a curated tile grid for only deployed services; each tile links to its service dashboard Us Adds a navigation hop before seeing data; context tied to session storage.
C — Wrapper page ingest_hub renders a dynamic nav strip above the embedded [Metrics AWS] Overview dashboard Us Nav strip and dashboard are visually independent; slightly "bolted on".
D — Package nav-slot + Kibana runtime injection (preferred, not yet possible) Package declares a nav slot in its manifest; Kibana fills it at render time based on which services are installed/active Kibana platform + package-spec Requires changes to package-spec (to support the slot declaration) and Kibana's dashboard rendering pipeline (to inject context-aware links). Neither exists today.

Option D is the architecturally correct answer — the package signals intent, Kibana owns the runtime logic — but it requires upstream investment in package-spec and the Dashboard app before it can be built. Options B and C are viable near-term alternatives and are being discussed with both teams before a direction is chosen.

Testing

  1. Go through the AWS onboarding flow with the aws integration installed.
  2. Reach Step 4 (Detect & Review).
  3. Click Take me to my data — you should land on the [Metrics AWS] Overview dashboard.
  4. With the aws integration not installed (or with no package data), the button should still be clickable and complete the step without navigating.

Checklist

  • Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n support
  • Documentation was added for features that require explanation or tutorials
  • Unit or functional tests were updated or added to match the most common scenarios
  • If a plugin configuration key changed, check if it needs to be allowlisted in the cloud and added to the docker list
  • This was checked for breaking HTTP API changes, and any breaking changes have been approved by the breaking-change committee. The release_note:breaking label should be applied in these situations.
  • Flaky Test Runner was used on any tests changed
  • The PR description includes the appropriate Release Notes section, and the correct release_note:* label is applied per the guidelines
  • Review the backport guidelines and apply applicable backport:* labels.

Identify risks

No significant risks. The href is only set when the overview dashboard is found in the bulk assets response; the button degrades gracefully to a step-complete-only action otherwise.

…tep 4

Wires the 'Take me to my data' button in the Detect & Review step
(Step 4) to navigate to the '[Metrics AWS] Overview' dashboard
installed with the AWS integration.

- Export InstalledAsset type from use_installed_content so the parent
  can consume individual dashboard entries
- Call useInstalledContent in DetectAndReviewStep to find the overview
  dashboard by its canonical title; React Query deduplicates the
  bulk_assets request with the one already made inside <InstalledContent>
- Prepend basePath to the appLink and set it as the button href so the
  user lands on the correct dashboard; falls back to a plain step-complete
  when the overview dashboard is not yet installed
- Add four focused RTL tests covering href present / absent scenarios

Closes elastic/ingest-dev#9232 (navigation portion)

Note: the secondary item — modifying the [Metrics AWS] Overview dashboard
to add cross-dashboard links like the [Elastic Agent] Overview — requires
approval from the aws integration package owners before any changes to that
asset.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Supplementing Supplementing added release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting Team:streams-ui Streams UI team labels Sep 11, 2026
@Supplementing
Supplementing marked this pull request as ready for review September 11, 2026 14:11
@Supplementing
Supplementing requested a review from a team as a code owner September 11, 2026 14:11
@infra-vault-gh-plugin-prod

Copy link
Copy Markdown

Pinging @elastic/streams-ui (Team:streams-ui)

Supplementing and others added 5 commits September 11, 2026 08:11
…rviewDashboardUrl hook

The previous implementation called useInstalledContent inside DetectAndReviewStep
and then filtered its result to find the overview dashboard URL. Under CI's
tsconfig.type_check.json (composite mode with project references), Fleet's type
chain for GetBulkAssetsResponse couldn't be resolved from compiled .d.ts files,
producing TS2339 and TS7006 type errors.

Replace with a standalone useAwsOverviewDashboardUrl hook that has an explicit
string | undefined return type, eliminating the Fleet type inference entirely.
The hook has its own staleTime: Infinity query (same cache behaviour) and avoids
importing KibanaSavedObjectType at runtime (uses the string literal 'dashboard').

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Per Julia's review: use the canonical saved-object ID to locate the
[Metrics AWS] Overview dashboard instead of matching by title, so the
reference stays stable if the dashboard is ever renamed.

Pattern follows Fleet's getDashboardIdForSpace (dashboard_helpers.ts):
match installed_kibana refs by `originId ?? id` against the canonical
package ID. In the default space originId is absent and id equals the
package ID; in non-default spaces Fleet re-keys the saved object so
originId holds the original package ID while id is the space-local UUID.

This also drops the useQuery/bulk-assets HTTP call entirely — the ref
lookup is now synchronous from the already-fetched package info.

Canonical ID sourced from:
packages/aws/kibana/dashboard/aws-fac28650-7349-11e9-816b-07687310a99a.json

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One space-isolation concern on the new useAwsOverviewDashboardUrl hook (inline). Otherwise the change is well-scoped and the graceful no-href fallback is sound.

Generated by Claude Reviewer for #290579 · claude · opus · 207.5 AIC · ⌖ 47.3 AIC · ⊞ 5.5K

Supplementing and others added 4 commits September 14, 2026 11:52
The previous implementation only checked installed_kibana (the primary
installation space). If the current Kibana space is not the space where
the AWS package was originally installed, the dashboard's saved-object
lives in additional_spaces_installed_kibana[currentSpaceId] with a
space-local UUID and originId pointing to the canonical package ID.

Mirrors Fleet's getDashboardIdForSpace pattern exactly:
- Primary space (installed_kibana_space_id === currentSpaceId): use the
  canonical package ID directly from installed_kibana.
- Non-primary space: look in additional_spaces_installed_kibana for a
  ref where originId === canonical ID; use that ref's space-local id.

Also changes the hook signature from installedKibana: KibanaAssetReference[]
to installationInfo: InstallationSnapshot | undefined so all three
required fields (installed_kibana, installed_kibana_space_id,
additional_spaces_installed_kibana) are available. InstallationSnapshot
is a local interface since InstallationInfo is not exported from Fleet
common.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…config.type_check

Under CI's composite tsconfig.type_check.json, KibanaSavedObjectType resolves
from compiled .d.ts files as an enum, making 'dashboard' (string literal)
not assignable. Casting the test fixture objects with 'as KibanaAssetReference'
is a type assertion that satisfies both local tsconfig.json and CI's
tsconfig.type_check.json without needing a runtime enum value.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One space-isolation concern on useAwsOverviewDashboardUrl (inline): the space-aware resolution added since the last review is correct in steady state, but defaulting the space id to 'default' on first render re-opens the non-default-space broken-link case during the async getActiveSpace() window. The rest of the change is well-scoped, and the graceful no-href fallback is otherwise sound.

Generated by Claude Reviewer for #290579 · claude · opus · 129.4 AIC · ⌖ 22.3 AIC · ⊞ 5.5K

kibanamachine and others added 2 commits September 14, 2026 19:36
…ep_components/detect_and_review_step/use_aws_overview_dashboard_url.ts

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>

@juliaElastic juliaElastic left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Supplementing and others added 3 commits September 15, 2026 08:41
… async

Covers the broken-link window: when the spaces service is present,
currentSpaceId starts undefined so the hook returns undefined before
getActiveSpace() resolves rather than emitting a primary-space id that
may not exist in the current space.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@Supplementing
Supplementing enabled auto-merge (squash) September 15, 2026 14:44
@kibanamachine

Copy link
Copy Markdown
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
ingestHub 143.5KB 144.1KB +571.0B

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
ingestHub 7.2KB 7.2KB +1.0B
Unknown metric groups

shared chunks total size

id before after diff
all 7.0MB 7.0MB +1.0B

total optimizer output size

id before after diff
all 63.9MB 63.9MB +573.0B

Test Failures

  • [job] [logs] FTR Configs #83 / lens app - group 1 lens layers should transition from a multi-layer stacked bar to treemap chart using suggestions
  • [job] [logs] Scout Lane #16 - serverless-observability_complete / default / local-serverless-observability_complete - Synthetics manage rules privilege - lets a read user with can_manage_rules enable default alerting
  • [job] [logs] Scout Lane #9 - stateful-classic / default / local-stateful-classic - pingList query - returns a list of pings for the date range and given size
  • [job] [logs] Scout Lane #7 - stateful-classic / default / local-stateful-classic - Synthetics manage rules privilege - lets a read user with can_manage_rules enable default alerting

History

@Supplementing
Supplementing merged commit 1a39be6 into elastic:main Sep 15, 2026
41 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes Team:streams-ui Streams UI team v9.6.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants