Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

Refocus v6 resource history on investigation timeline

rcourtman2c0217ecfcc2
diff --git a/docs/release-control/control_plane.json b/docs/release-control/control_plane.json
index e071a2869f..038c322279 100644
--- a/docs/release-control/control_plane.json
+++ b/docs/release-control/control_plane.json
@@ -6,7 +6,7 @@
"control_plane_doc": "docs/release-control/internal/CONTROL_PLANE.md",
"control_plane_schema": "docs/release-control/control_plane.schema.json",
"active_profile_id": "v6",
- "active_target_id": "v6-product-lane-expansion",
+ "active_target_id": "v6-rc-stabilization",
"profiles": [
{
"id": "v6",
@@ -38,8 +38,8 @@
"id": "v6-rc-stabilization",
"profile_id": "v6",
"kind": "stabilization",
- "status": "superseded",
- "summary": "Keep Pulse v6 in RC stabilization until remaining product/runtime concerns are resolved or normalized into governed proofs before GA promotion is resumed, while broader post-RC polish stays out of the release floor by default.",
+ "status": "active",
+ "summary": "Keep Pulse v6 centered on the proven monitoring-and-alerting RC floor, using timeline/change intelligence only where it materially improves investigation or safe AI flows while broader control-plane expansion stays out of the default target until it is proven.",
"completion_rule": "manual",
"proof_scope": "none"
},
@@ -55,8 +55,8 @@
"id": "v6-product-lane-expansion",
"profile_id": "v6",
"kind": "feature",
- "status": "active",
- "summary": "Default v6 engineering work to the bridge-release foundation by promoting and landing the known resource-graph, policy-governance, action-governance, and fleet-governance gaps ahead of further local RC cleanup.",
+ "status": "planned",
+ "summary": "Promote the known resource-graph, policy-governance, action-governance, and fleet-governance gaps only after the monitoring-first RC target is satisfied and the broader surfaced product case is proven.",
"completion_rule": "manual",
"proof_scope": "none"
}
diff --git a/docs/release-control/v6/internal/subsystems/performance-and-scalability.md b/docs/release-control/v6/internal/subsystems/performance-and-scalability.md
index 2a26fc6f75..3ebfc63aa1 100644
--- a/docs/release-control/v6/internal/subsystems/performance-and-scalability.md
+++ b/docs/release-control/v6/internal/subsystems/performance-and-scalability.md
@@ -96,12 +96,22 @@ forking separate table-only presentation logic. That component now also
consumes the shared `frontend-modern/src/utils/resourceChangePresentation.ts`
label helper for canonical change kinds, source types, and adapter provenance
so the chip wording stays consistent without adding extra hot-path branching.
+The default table hot path now scopes those summary chips to timeline and
+change-provenance badges only. Generic capability and relationship counts are
+kept out of the main row budget until the underlying data is proven populated,
+which preserves the fleet-table scan path and avoids spending hot-path visual
+budget on model nouns that do not yet clear the product bar.
Row summaries now also prefer canonical `facetCounts` on each resource when
they are available, so the hot path can stay within the same budget while
still reading totals from the shared resource contract. The drawer history
surface reuses the same governed resource route helpers for relationship and
related-resource links, so cross-resource navigation stays within the existing
infrastructure surface rather than branching into custom detail-only routing.
+The detail drawer now follows the same default posture by collapsing its
+history overview down to timeline counts and timeline-summary chips, so the
+performance-sensitive shared presentation path stays aligned with the
+investigation-first product contract instead of rendering low-signal generic
+facet sections by default.
Governance metadata such as sensitivity and routing scope may be visible in
the table, but it must remain on the same bounded row-windowing and mounted-row
budget proved by `UnifiedResourceTable.performance.contract.test.tsx` rather
diff --git a/docs/release-control/v6/internal/subsystems/unified-resources.md b/docs/release-control/v6/internal/subsystems/unified-resources.md
index db5d5b3b12..7f02ec71c7 100644
--- a/docs/release-control/v6/internal/subsystems/unified-resources.md
+++ b/docs/release-control/v6/internal/subsystems/unified-resources.md
@@ -212,14 +212,22 @@ The frontend now also consumes those facet reads through
`frontend-modern/src/api/resources.ts` and the dedicated resource detail
drawer, which keeps the presentation surface aligned with the governed API
contract instead of rebuilding the graph and timeline inline.
+The shared `ResourceFacetSummary` consumer can now explicitly suppress
+capability and relationship badges, and the canonical table/detail surfaces
+use that narrower mode by default. That keeps the proven monitoring UX
+centered on factual timeline investigation while the richer facet payloads
+remain available as backend and AI-facing foundations instead of being
+presented as first-class product facts before they are fully populated.
That drawer now also uses a shared frontend relationship-presentation helper
for graph labels and provenance wording, so the UI stays aligned with the
canonical relationship semantics instead of keeping drawer-local token
humanization.
The same facet bundle now also returns grouped recent-change counts by
canonical change kind, so the detail drawer can surface the distribution of
-state transitions, restarts, config updates, anomalies, relationships, and
-capabilities without recomputing timeline history in the browser.
+state transitions, restarts, config updates, and anomalies without
+recomputing timeline history in the browser, while broader graph or
+capability facets stay available behind the same contract for non-default
+consumers that can prove they are populated and justified.
That same facet bundle now also returns grouped recent-change provenance
counts by source type, so the detail drawer can distinguish platform events,
pulse diffs, heuristics, user actions, and agent actions without re-deriving
diff --git a/frontend-modern/src/components/Infrastructure/ResourceDetailDrawer.tsx b/frontend-modern/src/components/Infrastructure/ResourceDetailDrawer.tsx
index 2469a941c7..180b70d12d 100644
--- a/frontend-modern/src/components/Infrastructure/ResourceDetailDrawer.tsx
+++ b/frontend-modern/src/components/Infrastructure/ResourceDetailDrawer.tsx
@@ -1,4 +1,12 @@
-import { Show, Suspense, createMemo, For, createSignal, createEffect, createResource } from 'solid-js';
+import {
+ Show,
+ Suspense,
+ createMemo,
+ For,
+ createSignal,
+ createEffect,
+ createResource,
+} from 'solid-js';
import type { Component } from 'solid-js';
import type {
Resource,
@@ -52,12 +60,10 @@ import {
getResourceRoutingScopeLabel,
getResourceSensitivityLabel,
} from '@/utils/resourcePolicyPresentation';
-import { describeResourceRelationship } from '@/utils/resourceRelationshipPresentation';
import { ResourceGraphSummary } from './ResourceGraphSummary';
import { ResourceChangeSummary } from './ResourceChangeSummary';
import { ResourceFacetSummary } from './ResourceFacetSummary';
import { ResourcePolicySummary } from './ResourcePolicySummary';
-import { getResourceApprovalLevelLabel } from '@/utils/approvalPresentation';
import {
RESOURCE_CHANGE_KIND_ORDER,
RESOURCE_CHANGE_SOURCE_ADAPTER_ORDER,
@@ -67,7 +73,7 @@ import {
getResourceChangeSourceTypePresentation,
} from '@/utils/resourceChangePresentation';
import { formatConfidenceLabel } from '@/utils/confidencePresentation';
-import { formatIdentifierLabel, humanizeToken } from '@/utils/textPresentation';
+import { formatIdentifierLabel } from '@/utils/textPresentation';
import type { ResourceIntelligence } from '@/types/aiIntelligence';
import { buildInfrastructureResourceHref } from '@/routing/resourceLinks';
@@ -109,14 +115,16 @@ const timelineSourceTypeOptions: Array<{ label: string; value: ResourceChangeSou
})),
];
-const timelineSourceAdapterOptions: Array<{ label: string; value: ResourceChangeSourceAdapter | '' }> =
- [
- { label: 'All adapters', value: '' },
- ...RESOURCE_CHANGE_SOURCE_ADAPTER_ORDER.map((sourceAdapter) => ({
- label: getResourceChangeSourceAdapterPresentation(sourceAdapter).label,
- value: sourceAdapter,
- })),
- ];
+const timelineSourceAdapterOptions: Array<{
+ label: string;
+ value: ResourceChangeSourceAdapter | '';
+}> = [
+ { label: 'All adapters', value: '' },
+ ...RESOURCE_CHANGE_SOURCE_ADAPTER_ORDER.map((sourceAdapter) => ({
+ label: getResourceChangeSourceAdapterPresentation(sourceAdapter).label,
+ value: sourceAdapter,
+ })),
+];
const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
type DrawerTab =
@@ -149,7 +157,9 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
});
const hasUnifiedSources = createMemo(() => unifiedSourceBadges().length > 0);
const policyBadges = createMemo(() => getResourcePolicyBadges(props.resource.policy));
- const policyRedactions = createMemo(() => getResourcePolicyRedactionLabels(props.resource.policy));
+ const policyRedactions = createMemo(() =>
+ getResourcePolicyRedactionLabels(props.resource.policy),
+ );
const policyRoutingDecisions = createMemo(() =>
getResourcePolicyRoutingDecisionSummaries(props.resource.policy),
);
@@ -260,10 +270,12 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
const [k8sDeploymentsPrefillNamespace, setK8sDeploymentsPrefillNamespace] = createSignal('');
const resourceFacetId = createMemo(() => props.resource.id.trim());
const [timelineKindFilter, setTimelineKindFilter] = createSignal<ResourceChangeKind | ''>('');
- const [timelineSourceTypeFilter, setTimelineSourceTypeFilter] =
- createSignal<ResourceChangeSourceType | ''>('');
- const [timelineSourceAdapterFilter, setTimelineSourceAdapterFilter] =
- createSignal<ResourceChangeSourceAdapter | ''>('');
+ const [timelineSourceTypeFilter, setTimelineSourceTypeFilter] = createSignal<
+ ResourceChangeSourceType | ''
+ >('');
+ const [timelineSourceAdapterFilter, setTimelineSourceAdapterFilter] = createSignal<
+ ResourceChangeSourceAdapter | ''
+ >('');
const resourceFacetRequest = createMemo(() => {
const id = resourceFacetId();
return id ? { id } : null;
@@ -381,12 +393,6 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
const nonZero = all.filter((entry) => entry.value > 0);
return nonZero.length > 0 ? nonZero : all;
});
- const resourceCapabilities = createMemo(
- () => resourceFacets()?.capabilities ?? props.resource.capabilities ?? [],
- );
- const resourceRelationships = createMemo(
- () => resourceFacets()?.relationships ?? props.resource.relationships ?? [],
- );
const resourceTimeline = createMemo(
() => resourceFacets()?.recentChanges ?? props.resource.recentChanges ?? [],
);
@@ -394,44 +400,36 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
() => resourceFacets()?.counts ?? props.resource.facetCounts ?? null,
);
const historyFacetBundle = createMemo(() =>
- timelineFacetRequest() ? timelineFacets() ?? resourceFacets() : resourceFacets(),
- );
- const historyCapabilities = createMemo(
- () => historyFacetBundle()?.capabilities ?? resourceCapabilities(),
+ timelineFacetRequest() ? (timelineFacets() ?? resourceFacets()) : resourceFacets(),
);
- const historyRelationships = createMemo(
- () => historyFacetBundle()?.relationships ?? resourceRelationships(),
+ const historyTimeline = createMemo(
+ () => historyFacetBundle()?.recentChanges ?? resourceTimeline(),
);
- const historyTimeline = createMemo(() => historyFacetBundle()?.recentChanges ?? resourceTimeline());
const historyFacetCounts = createMemo(
() => historyFacetBundle()?.counts ?? resourceFacetCounts(),
);
- const hasTimelineFilters = createMemo(
- () =>
- Boolean(
- timelineKindFilter() || timelineSourceTypeFilter() || timelineSourceAdapterFilter(),
- ),
- );
- const resourceCapabilityCount = createMemo(
- () => resourceFacetCounts()?.capabilities ?? resourceCapabilities().length,
- );
- const resourceRelationshipCount = createMemo(
- () => resourceFacetCounts()?.relationships ?? resourceRelationships().length,
+ const hasTimelineFilters = createMemo(() =>
+ Boolean(timelineKindFilter() || timelineSourceTypeFilter() || timelineSourceAdapterFilter()),
);
const resourceTimelineCount = createMemo(
() => resourceFacetCounts()?.recentChanges ?? resourceTimeline().length,
);
+ const historyTimelineCount = createMemo(
+ () => historyFacetCounts()?.recentChanges ?? historyTimeline().length,
+ );
const sortedResourceTimeline = createMemo(() =>
[...historyTimeline()].sort((left, right) => {
const leftTime = Date.parse(left.observedAt || '');
const rightTime = Date.parse(right.observedAt || '');
- return (Number.isFinite(rightTime) ? rightTime : 0) - (Number.isFinite(leftTime) ? leftTime : 0);
+ return (
+ (Number.isFinite(rightTime) ? rightTime : 0) - (Number.isFinite(leftTime) ? leftTime : 0)
+ );
}),
);
const facetBundleError = createMemo(() => {
const error = timelineFacetRequest() ? timelineFacets.error : resourceFacets.error;
if (!error) return '';
- return (error as Error)?.message || 'Failed to load resource facets';
+ return (error as Error)?.message || 'Failed to load resource history';
});
const refetchHistoryFacets = () => {
if (timelineFacetRequest()) {
@@ -784,7 +782,7 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
)}
</Show>
</div>
- </Show>
+ </Show>
<div class="grid gap-3 md:grid-cols-2 lg:grid-cols-3 mt-3">
<Show when={resourceIntelligence()}>
@@ -874,20 +872,14 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
</span>
</div>
</Show>
- <Show
- when={
- resourceCapabilities().length > 0 ||
- resourceRelationships().length > 0 ||
- resourceTimeline().length > 0
- }
- >
+ <Show when={resourceTimelineCount() > 0}>
<div class="flex flex-col gap-1">
- <span class="text-muted">Facets</span>
+ <span class="text-muted">Timeline</span>
<ResourceFacetSummary
- capabilities={resourceCapabilities()}
- relationships={resourceRelationships()}
recentChanges={resourceTimeline()}
counts={resourceFacetCounts()}
+ showCapabilities={false}
+ showRelationships={false}
/>
</div>
</Show>
@@ -1113,7 +1105,9 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
<span
class={`font-medium ${dockerHostCommandActive() ? 'text-sky-700 dark:text-sky-300' : 'text-base-content'}`}
>
- {formatIdentifierLabel(dockerHostCommand()?.status, { fallback: 'unknown' })}
+ {formatIdentifierLabel(dockerHostCommand()?.status, {
+ fallback: 'unknown',
+ })}
</span>
</div>
<Show when={dockerHostCommand()?.message}>
@@ -1455,16 +1449,14 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
<div>
{timelineFacetRequest()
? timelineFacets.loading
- ? 'Refreshing filtered facet data...'
- : 'Filtered facet data loaded'
+ ? 'Refreshing filtered history...'
+ : 'Filtered history loaded'
: resourceFacets.loading
- ? 'Refreshing facet data...'
- : 'Facet data loaded'}
+ ? 'Refreshing history...'
+ : 'History loaded'}
</div>
<Show when={hasTimelineFilters()}>
- <div class="mt-0.5 text-blue-700 dark:text-blue-300">
- History filters active
- </div>
+ <div class="mt-0.5 text-blue-700 dark:text-blue-300">History filters active</div>
</Show>
</div>
</div>
@@ -1476,7 +1468,9 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
class="w-full rounded border border-border bg-base px-2 py-1 text-[11px] text-base-content"
value={timelineKindFilter()}
onChange={(event) =>
- setTimelineKindFilter((event.currentTarget.value || '') as ResourceChangeKind | '')
+ setTimelineKindFilter(
+ (event.currentTarget.value || '') as ResourceChangeKind | '',
+ )
}
>
<For each={timelineKindOptions}>
@@ -1486,9 +1480,9 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
</label>
<label class="space-y-1 text-[10px]">
<span class="text-muted">Source type</span>
- <select
- class="w-full rounded border border-border bg-base px-2 py-1 text-[11px] text-base-content"
- value={timelineSourceTypeFilter()}
+ <select
+ class="w-full rounded border border-border bg-base px-2 py-1 text-[11px] text-base-content"
+ value={timelineSourceTypeFilter()}
onChange={(event) =>
setTimelineSourceTypeFilter(
(event.currentTarget.value || '') as ResourceChangeSourceType | '',
@@ -1498,8 +1492,8 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
<For each={timelineSourceTypeOptions}>
{(option) => <option value={option.value}>{option.label}</option>}
</For>
- </select>
- </label>
+ </select>
+ </label>
<label class="space-y-1 text-[10px]">
<span class="text-muted">Source adapter</span>
<select
@@ -1549,234 +1543,25 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
</div>
</Show>
- <div class="mt-3 grid gap-2 sm:grid-cols-3">
- <div class="rounded border border-border bg-surface-hover px-2 py-1.5">
- <div class="text-[10px] text-muted">Capabilities</div>
- <div class="text-sm font-semibold text-base-content">
- {historyFacetCounts()?.capabilities ?? resourceCapabilityCount()}
- </div>
- </div>
- <div class="rounded border border-border bg-surface-hover px-2 py-1.5">
- <div class="text-[10px] text-muted">Relationships</div>
- <div class="text-sm font-semibold text-base-content">
- {historyFacetCounts()?.relationships ?? resourceRelationshipCount()}
- </div>
- </div>
+ <div class="mt-3 flex flex-wrap gap-2">
<div class="rounded border border-border bg-surface-hover px-2 py-1.5">
<div class="text-[10px] text-muted">Timeline Events</div>
- <div class="text-sm font-semibold text-base-content">
- {historyFacetCounts()?.recentChanges ?? resourceTimelineCount()}
- </div>
+ <div class="text-sm font-semibold text-base-content">{historyTimelineCount()}</div>
</div>
</div>
- <Show
- when={
- historyCapabilities().length > 0 ||
- historyRelationships().length > 0 ||
- historyTimeline().length > 0
- }
- >
+ <Show when={historyTimelineCount() > 0}>
<div class="mt-2 flex flex-col gap-1">
- <span class="text-muted">Facet chips</span>
+ <span class="text-muted">Timeline summary</span>
<ResourceFacetSummary
- capabilities={historyCapabilities()}
- relationships={historyRelationships()}
recentChanges={historyTimeline()}
counts={historyFacetCounts()}
+ showCapabilities={false}
+ showRelationships={false}
/>
</div>
</Show>
</div>
- <div class="rounded border border-border bg-surface p-3">
- <div class="text-[11px] font-medium uppercase tracking-wide text-base-content mb-2">
- Capabilities
- </div>
- <Show
- when={historyCapabilities().length > 0}
- fallback={
- <div class="rounded border border-dashed border-border bg-surface-hover px-2 py-2 text-[10px] text-muted">
- No capability records are available for this resource yet.
- </div>
- }
- >
- <div class="space-y-2">
- <For each={historyCapabilities()}>
- {(capability) => (
- <details class="rounded border border-border bg-surface-hover px-2 py-1.5">
- <summary class="flex cursor-pointer list-none items-center justify-between gap-2 text-[10px] font-medium text-base-content">
- <span class="truncate" title={capability.name}>
- {capability.name}
- </span>
- <span class="text-muted">
- {humanizeToken(capability.type, {
- fallback: '—',
- preserveShortAllCaps: true,
- })}
- </span>
- </summary>
- <div class="mt-2 space-y-1.5 border-t border-border pt-2 text-[10px]">
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">Approval</span>
- <span class="font-medium text-base-content">
- {getResourceApprovalLevelLabel(capability.minimumApprovalLevel)}
- </span>
- </div>
- <Show when={capability.platform}>
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">Platform</span>
- <span class="font-medium text-base-content">
- {capability.platform}
- </span>
- </div>
- </Show>
- <Show when={capability.description}>
- <div class="rounded border border-border bg-base px-2 py-1 text-[10px] text-base-content">
- {capability.description}
- </div>
- </Show>
- <Show when={capability.params && capability.params.length > 0}>
- <div class="space-y-1">
- <div class="text-[10px] font-medium uppercase tracking-wide text-muted">
- Params
- </div>
- <For each={capability.params ?? []}>
- {(param) => (
- <div class="rounded border border-border bg-base px-2 py-1 text-[10px]">
- <div class="flex items-center justify-between gap-2">
- <span class="font-medium text-base-content">{param.name}</span>
- <span class="text-muted">
- {param.type}
- {param.required ? ' • required' : ''}
- </span>
- </div>
- <Show when={param.description}>
- <div class="mt-1 text-muted">{param.description}</div>
- </Show>
- <Show when={param.enum && param.enum.length > 0}>
- <div class="mt-1 text-muted">
- Allowed: {param.enum?.join(', ')}
- </div>
- </Show>
- <Show when={param.pattern}>
- <div class="mt-1 text-muted">Pattern: {param.pattern}</div>
- </Show>
- </div>
- )}
- </For>
- </div>
- </Show>
- </div>
- </details>
- )}
- </For>
- </div>
- </Show>
- </div>
-
- <div class="rounded border border-border bg-surface p-3">
- <div class="text-[11px] font-medium uppercase tracking-wide text-base-content mb-2">
- Relationships
- </div>
- <Show
- when={historyRelationships().length > 0}
- fallback={
- <div class="rounded border border-dashed border-border bg-surface-hover px-2 py-2 text-[10px] text-muted">
- No relationship edges are available for this resource yet.
- </div>
- }
- >
- <div class="space-y-2">
- <For each={historyRelationships()}>
- {(relationship) => {
- const presentation = describeResourceRelationship(relationship);
- return (
- <div class="rounded border border-border bg-surface-hover px-2 py-1.5 text-[10px]">
- <div class="flex items-center justify-between gap-2">
- <span class="font-medium text-base-content">
- <Show
- when={buildInfrastructureResourceHref(relationship.sourceId)}
- fallback={<span>{relationship.sourceId}</span>}
- >
- {(href) => (
- <a
- class="rounded px-0.5 text-blue-700 hover:underline dark:text-blue-300"
- href={href()}
- aria-label={`Open source resource ${relationship.sourceId} in Infrastructure`}
- >
- {relationship.sourceId}
- </a>
- )}
- </Show>
- {' → '}
- <Show
- when={buildInfrastructureResourceHref(relationship.targetId)}
- fallback={<span>{relationship.targetId}</span>}
- >
- {(href) => (
- <a
- class="rounded px-0.5 text-blue-700 hover:underline dark:text-blue-300"
- href={href()}
- aria-label={`Open target resource ${relationship.targetId} in Infrastructure`}
- >
- {relationship.targetId}
- </a>
- )}
- </Show>
- </span>
- <span class="text-muted">{presentation.typeLabel}</span>
- </div>
- <div class="mt-1 grid gap-1 sm:grid-cols-2">
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">Confidence</span>
- <span class="font-medium text-base-content">
- {formatConfidenceLabel(relationship.confidence)}
- </span>
- </div>
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">State</span>
- <span class="font-medium text-base-content">
- {relationship.active ? 'Active' : 'Historical'}
- </span>
- </div>
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">Discoverer</span>
- <span class="font-medium text-base-content">
- {presentation.provenance || '—'}
- </span>
- </div>
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">Observed</span>
- <span class="font-medium text-base-content">
- {formatRelativeTime(relationship.observedAt)}
- </span>
- </div>
- <div class="flex items-center justify-between gap-2">
- <span class="text-muted">Last Seen</span>
- <span class="font-medium text-base-content">
- {formatRelativeTime(relationship.lastSeenAt) ||
- formatRelativeTime(relationship.observedAt)}
- </span>
- </div>
- </div>
- <Show when={hasMetadataEntries(relationship.metadata)}>
- <details class="mt-2 rounded border border-border bg-base px-2 py-1">
- <summary class="cursor-pointer list-none text-[10px] font-medium text-muted">
- Metadata
- </summary>
- <pre class="mt-2 overflow-auto whitespace-pre-wrap break-words text-[10px] text-base-content">
- {JSON.stringify(relationship.metadata ?? {}, null, 2)}
- </pre>
- </details>
- </Show>
- </div>
- );
- }}
- </For>
- </div>
- </Show>
- </div>
-
<div class="rounded border border-border bg-surface p-3">
<div class="text-[11px] font-medium uppercase tracking-wide text-base-content mb-2">
Timeline
@@ -1804,7 +1589,9 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
<div class="rounded border border-border bg-surface-hover px-2 py-1.5 text-[10px]">
<div class="flex items-start justify-between gap-3">
<div class="min-w-0">
- <div class="font-medium text-base-content">{kindPresentation.label}</div>
+ <div class="font-medium text-base-content">
+ {kindPresentation.label}
+ </div>
<div class="mt-0.5 text-muted">
{formatRelativeTime(change.observedAt)}
<Show when={change.occurredAt}>
diff --git a/frontend-modern/src/components/Infrastructure/ResourceFacetSummary.tsx b/frontend-modern/src/components/Infrastructure/ResourceFacetSummary.tsx
index ae2c7e3374..8c83c619ed 100644
--- a/frontend-modern/src/components/Infrastructure/ResourceFacetSummary.tsx
+++ b/frontend-modern/src/components/Infrastructure/ResourceFacetSummary.tsx
@@ -25,6 +25,9 @@ export interface ResourceFacetSummaryProps {
relationships?: readonly ResourceRelationship[] | null;
recentChanges?: readonly ResourceChange[] | null;
counts?: ResourceFacetCounts | null;
+ showCapabilities?: boolean;
+ showRelationships?: boolean;
+ showTimeline?: boolean;
class?: string;
testId?: string;
}
@@ -40,13 +43,18 @@ const buildFacetBadges = (
relationships?: readonly ResourceRelationship[] | null,
recentChanges?: readonly ResourceChange[] | null,
counts?: ResourceFacetCounts | null,
+ visibility: { showCapabilities: boolean; showRelationships: boolean; showTimeline: boolean } = {
+ showCapabilities: true,
+ showRelationships: true,
+ showTimeline: true,
+ },
): FacetBadge[] => {
const badges: FacetBadge[] = [];
const capabilityCount = counts?.capabilities ?? capabilities?.length ?? 0;
const relationshipCount = counts?.relationships ?? relationships?.length ?? 0;
const changeCount = counts?.recentChanges ?? recentChanges?.length ?? 0;
- if (capabilityCount > 0) {
+ if (visibility.showCapabilities && capabilityCount > 0) {
badges.push({
label: `Capabilities ${capabilityCount}`,
title: countLabel(capabilityCount, 'capability'),
@@ -54,7 +62,7 @@ const buildFacetBadges = (
});
}
- if (relationshipCount > 0) {
+ if (visibility.showRelationships && relationshipCount > 0) {
badges.push({
label: `Relationships ${relationshipCount}`,
title: countLabel(relationshipCount, 'relationship'),
@@ -62,7 +70,7 @@ const buildFacetBadges = (
});
}
- if (changeCount > 0) {
+ if (visibility.showTimeline && changeCount > 0) {
badges.push({
label: `Timeline ${changeCount}`,
title: countLabel(changeCount, 'timeline event'),
@@ -70,7 +78,7 @@ const buildFacetBadges = (
});
}
- const kindCounts = counts?.recentChangeKinds;
+ const kindCounts = visibility.showTimeline ? counts?.recentChangeKinds : null;
if (kindCounts) {
for (const kind of RESOURCE_CHANGE_KIND_ORDER) {
const count = kindCounts[kind];
@@ -84,7 +92,7 @@ const buildFacetBadges = (
}
}
- const sourceTypeCounts = counts?.recentChangeSourceTypes;
+ const sourceTypeCounts = visibility.showTimeline ? counts?.recentChangeSourceTypes : null;
if (sourceTypeCounts) {
for (const sourceType of RESOURCE_CHANGE_SOURCE_TYPE_ORDER) {
const count = sourceTypeCounts[sourceType];
@@ -102,7 +110,7 @@ const buildFacetBadges = (
}
}
- const sourceAdapterCounts = counts?.recentChangeSourceAdapters;
+ const sourceAdapterCounts = visibility.showTimeline ? counts?.recentChangeSourceAdapters : null;
if (sourceAdapterCounts) {
for (const sourceAdapter of RESOURCE_CHANGE_SOURCE_ADAPTER_ORDER) {
const count = sourceAdapterCounts[sourceAdapter];
@@ -125,7 +133,11 @@ const buildFacetBadges = (
export const ResourceFacetSummary: Component<ResourceFacetSummaryProps> = (props) => {
const badges = createMemo(() =>
- buildFacetBadges(props.capabilities, props.relationships, props.recentChanges, props.counts),
+ buildFacetBadges(props.capabilities, props.relationships, props.recentChanges, props.counts, {
+ showCapabilities: props.showCapabilities ?? true,
+ showRelationships: props.showRelationships ?? true,
+ showTimeline: props.showTimeline ?? true,
+ }),
);
return (
diff --git a/frontend-modern/src/components/Infrastructure/UnifiedResourceTable.tsx b/frontend-modern/src/components/Infrastructure/UnifiedResourceTable.tsx
index 050429b124..191c0a71ad 100644
--- a/frontend-modern/src/components/Infrastructure/UnifiedResourceTable.tsx
+++ b/frontend-modern/src/components/Infrastructure/UnifiedResourceTable.tsx
@@ -165,9 +165,7 @@ const getPMGTableRow = (resource: Resource): PMGTableRow | null => {
nodes: (pmg?.nodeCount || 0) > 0 ? pmg?.nodeCount || 0 : null,
health,
tone:
- backlog > 0
- ? 'warning'
- : getServiceHealthSummaryPresentation(resource.status, health).tone,
+ backlog > 0 ? 'warning' : getServiceHealthSummaryPresentation(resource.status, health).tone,
};
};
@@ -691,6 +689,8 @@ export const UnifiedResourceTable: Component<UnifiedResourceTableProps> = (props
relationships={resource.relationships}
recentChanges={resource.recentChanges}
counts={resource.facetCounts}
+ showCapabilities={false}
+ showRelationships={false}
class="mt-0.5"
/>
</div>
@@ -1059,9 +1059,10 @@ export const UnifiedResourceTable: Component<UnifiedResourceTableProps> = (props
getUnifiedSourceBadges(getUnifiedSources(resource)),
);
const hasUnifiedSources = createMemo(() => unifiedSourceBadges().length > 0);
- const healthClass = createMemo(() =>
- getServiceHealthSummaryPresentation(resource.status, pbsRow()?.health)
- .textClass,
+ const healthClass = createMemo(
+ () =>
+ getServiceHealthSummaryPresentation(resource.status, pbsRow()?.health)
+ .textClass,
);
const rowClass = createMemo(() => {
@@ -1144,6 +1145,8 @@ export const UnifiedResourceTable: Component<UnifiedResourceTableProps> = (props
relationships={resource.relationships}
recentChanges={resource.recentChanges}
counts={resource.facetCounts}
+ showCapabilities={false}
+ showRelationships={false}
class="mt-0.5"
/>
</div>
@@ -1362,9 +1365,10 @@ export const UnifiedResourceTable: Component<UnifiedResourceTableProps> = (props
getUnifiedSourceBadges(getUnifiedSources(resource)),
);
const hasUnifiedSources = createMemo(() => unifiedSourceBadges().length > 0);
- const healthClass = createMemo(() =>
- getServiceHealthSummaryPresentation(resource.status, pmgRow()?.health)
- .textClass,
+ const healthClass = createMemo(
+ () =>
+ getServiceHealthSummaryPresentation(resource.status, pmgRow()?.health)
+ .textClass,
);
const queueClass = createMemo(() =>
(pmgRow()?.deferred || 0) + (pmgRow()?.hold || 0) > 0
@@ -1452,6 +1456,8 @@ export const UnifiedResourceTable: Component<UnifiedResourceTableProps> = (props
relationships={resource.relationships}
recentChanges={resource.recentChanges}
counts={resource.facetCounts}
+ showCapabilities={false}
+ showRelationships={false}
class="mt-0.5"
/>
</div>
diff --git a/frontend-modern/src/components/Infrastructure/__tests__/ResourceDetailDrawer.history.test.tsx b/frontend-modern/src/components/Infrastructure/__tests__/ResourceDetailDrawer.history.test.tsx
index 746c646287..9f05815ecf 100644
--- a/frontend-modern/src/components/Infrastructure/__tests__/ResourceDetailDrawer.history.test.tsx
+++ b/frontend-modern/src/components/Infrastructure/__tests__/ResourceDetailDrawer.history.test.tsx
@@ -76,7 +76,7 @@ const baseResource = (overrides: Partial<Resource>): Resource => ({
});
describe('ResourceDetailDrawer history tab', () => {
- it('surfaces compact facet summary chips in the overview runtime card', async () => {
+ it('surfaces compact timeline summary chips in the overview and history cards', async () => {
facetBundleMock.getFacetBundle.mockResolvedValueOnce({
capabilities: [
{
@@ -154,8 +154,7 @@ describe('ResourceDetailDrawer history tab', () => {
render(() => <ResourceDetailDrawer resource={resource} />);
- expect(await screen.findAllByText('Capabilities 1')).toHaveLength(2);
- expect(screen.getAllByText('Relationships 1')).toHaveLength(2);
+ await screen.findByText('History loaded');
expect(screen.getAllByText('Timeline 3')).toHaveLength(2);
expect(screen.getAllByText('Restart 2')).toHaveLength(2);
expect(screen.getAllByText('Anomaly 1')).toHaveLength(2);
@@ -163,9 +162,11 @@ describe('ResourceDetailDrawer history tab', () => {
expect(screen.getAllByText('Pulse diff 2')).toHaveLength(2);
expect(screen.getAllByText('Docker adapter 2')).toHaveLength(2);
expect(screen.getAllByText('Proxmox adapter 1')).toHaveLength(2);
+ expect(screen.queryByText('Capabilities 1')).toBeNull();
+ expect(screen.queryByText('Relationships 1')).toBeNull();
});
- it('renders resource capability, relationship, and timeline facets', async () => {
+ it('renders timeline history without surfacing unsupported capability or relationship facets', async () => {
facetBundleMock.getFacetBundle.mockResolvedValueOnce({
capabilities: [
{
@@ -254,28 +255,25 @@ describe('ResourceDetailDrawer history tab', () => {
await screen.findByText('Resource History');
const historyPanel = screen.getByTestId('resource-history-tab');
const panel = within(historyPanel);
- expect(await panel.findByText('restart')).toBeInTheDocument();
- expect(panel.getAllByText('Capabilities')).toHaveLength(2);
- expect(panel.getAllByText('Relationships')).toHaveLength(2);
+ expect(await panel.findByText('History loaded')).toBeInTheDocument();
+ expect(panel.getByText('Routine restart requested')).toBeInTheDocument();
+ expect(panel.getByText('Timeline Events')).toBeInTheDocument();
+ expect(panel.getByText('Timeline summary')).toBeInTheDocument();
expect(panel.getByText('Timeline')).toBeInTheDocument();
expect(panel.getByText('Timeline 3')).toBeInTheDocument();
- expect(panel.getByText('Runs on')).toBeInTheDocument();
expect(panel.getByText('Docker adapter 1')).toBeInTheDocument();
expect(panel.getByText('Proxmox adapter 2')).toBeInTheDocument();
- expect(
- panel.getByRole('link', { name: 'Open source resource node:pve-1 in Infrastructure' }),
- ).toHaveAttribute('href', '/infrastructure?resource=node%3Apve-1');
- expect(
- panel.getByRole('link', { name: 'Open target resource vm:42 in Infrastructure' }),
- ).toHaveAttribute('href', '/infrastructure?resource=vm%3A42');
expect(
panel.getByRole('link', { name: 'Open related resource node:pve-1 in Infrastructure' }),
).toHaveAttribute('href', '/infrastructure?resource=node%3Apve-1');
expect(panel.getByText('Routine restart requested')).toBeInTheDocument();
- expect(panel.getByText('Last Seen')).toBeInTheDocument();
- expect(panel.getAllByText('Metadata')).toHaveLength(2);
- expect(panel.getByText(/"hypervisor": "pve-1"/)).toBeInTheDocument();
+ expect(panel.getByText('Confidence')).toBeInTheDocument();
+ expect(panel.getByText('Adapter')).toBeInTheDocument();
+ expect(panel.getByText('Metadata')).toBeInTheDocument();
expect(panel.getByText(/"ticket": "INC-1234"/)).toBeInTheDocument();
+ expect(panel.queryByText('Capabilities')).toBeNull();
+ expect(panel.queryByText('Relationships')).toBeNull();
+ expect(panel.queryByText('Runs on')).toBeNull();
});
it('filters timeline entries by kind and source type', async () => {
@@ -402,7 +400,7 @@ describe('ResourceDetailDrawer history tab', () => {
await screen.findByText('Resource History');
const historyPanel = screen.getByTestId('resource-history-tab');
const panel = within(historyPanel);
- expect(await panel.findByText('restart')).toBeInTheDocument();
+ expect(await panel.findByText('History loaded')).toBeInTheDocument();
expect(panel.getByText('CPU spike detected')).toBeInTheDocument();
fireEvent.change(panel.getByLabelText('Change kind'), {
@@ -412,7 +410,7 @@ describe('ResourceDetailDrawer history tab', () => {
target: { value: 'platform_event' },
});
- expect(await panel.findByText('Filtered facet data loaded')).toBeInTheDocument();
+ expect(await panel.findByText('Filtered history loaded')).toBeInTheDocument();
expect(await panel.findByText('Routine restart requested')).toBeInTheDocument();
expect(panel.queryByText('CPU spike detected')).toBeNull();
});
@@ -553,14 +551,14 @@ describe('ResourceDetailDrawer history tab', () => {
await screen.findByText('Resource History');
const historyPanel = screen.getByTestId('resource-history-tab');
const panel = within(historyPanel);
- expect(await panel.findByText('restart')).toBeInTheDocument();
+ expect(await panel.findByText('History loaded')).toBeInTheDocument();
expect(panel.getByText('CPU spike detected')).toBeInTheDocument();
fireEvent.change(panel.getByLabelText('Source adapter'), {
target: { value: 'docker_adapter' },
});
- expect(await panel.findByText('Filtered facet data loaded')).toBeInTheDocument();
+ expect(await panel.findByText('Filtered history loaded')).toBeInTheDocument();
expect(await panel.findByText('CPU spike detected')).toBeInTheDocument();
expect(panel.queryByText('Routine restart requested')).toBeNull();
});
diff --git a/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.performance.contract.test.tsx b/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.performance.contract.test.tsx
index c84a86eb62..645008da75 100644
--- a/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.performance.contract.test.tsx
+++ b/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.performance.contract.test.tsx
@@ -126,8 +126,8 @@ describe('UnifiedResourceTable performance contract', () => {
});
});
- it('renders the shared facet summary component for canonical resource counts', async () => {
- const { getByText } = render(() => (
+ it('renders the shared facet summary component in timeline-only mode for canonical resource counts', async () => {
+ const { getByText, queryByText } = render(() => (
<ResourceFacetSummary
capabilities={[
{
@@ -168,11 +168,11 @@ describe('UnifiedResourceTable performance contract', () => {
},
}}
recentChanges={[]}
+ showCapabilities={false}
+ showRelationships={false}
/>
));
- expect(getByText('Capabilities 1')).toBeInTheDocument();
- expect(getByText('Relationships 1')).toBeInTheDocument();
expect(getByText('Timeline 3')).toBeInTheDocument();
expect(getByText('Restart 2')).toBeInTheDocument();
expect(getByText('Config update 1')).toBeInTheDocument();
@@ -181,6 +181,8 @@ describe('UnifiedResourceTable performance contract', () => {
expect(getByText('Pulse diff 2')).toBeInTheDocument();
expect(getByText('Docker adapter 2')).toBeInTheDocument();
expect(getByText('Proxmox adapter 1')).toBeInTheDocument();
+ expect(queryByText('Capabilities 1')).toBeNull();
+ expect(queryByText('Relationships 1')).toBeNull();
});
it('formats sensor labels through the shared resource detail mapper helper', () => {
@@ -233,17 +235,17 @@ describe('UnifiedResourceTable performance contract', () => {
config_update: 1,
metric_anomaly: 1,
},
- recentChangeSourceTypes: {
- platform_event: 1,
- pulse_diff: 2,
- },
- recentChangeSourceAdapters: {
- docker_adapter: 2,
- proxmox_adapter: 1,
+ recentChangeSourceTypes: {
+ platform_event: 1,
+ pulse_diff: 2,
+ },
+ recentChangeSourceAdapters: {
+ docker_adapter: 2,
+ proxmox_adapter: 1,
+ },
},
- },
- recentChanges: [],
- }
+ recentChanges: [],
+ }
: {},
);
const { container, getByText } = render(() => (
@@ -259,8 +261,6 @@ describe('UnifiedResourceTable performance contract', () => {
expect(container.querySelector('table')).toBeInTheDocument();
});
await waitFor(() => {
- expect(getByText('Capabilities 1')).toBeInTheDocument();
- expect(getByText('Relationships 1')).toBeInTheDocument();
expect(getByText('Timeline 3')).toBeInTheDocument();
expect(getByText('Config update 1')).toBeInTheDocument();
});
@@ -382,18 +382,18 @@ describe('UnifiedResourceTable performance contract', () => {
expect(pbsRow).toBeTruthy();
if (pbsRow) {
const row = within(pbsRow);
- expect(row.getByText('Capabilities 1')).toBeInTheDocument();
- expect(row.getByText('Relationships 1')).toBeInTheDocument();
expect(row.getByText('Timeline 1')).toBeInTheDocument();
+ expect(row.queryByText('Capabilities 1')).toBeNull();
+ expect(row.queryByText('Relationships 1')).toBeNull();
}
const pmgRow = getByText('pmg-service').closest('tr');
expect(pmgRow).toBeTruthy();
if (pmgRow) {
const row = within(pmgRow);
- expect(row.getByText('Capabilities 1')).toBeInTheDocument();
- expect(row.getByText('Relationships 1')).toBeInTheDocument();
expect(row.getByText('Timeline 1')).toBeInTheDocument();
+ expect(row.queryByText('Capabilities 1')).toBeNull();
+ expect(row.queryByText('Relationships 1')).toBeNull();
}
});
});
diff --git a/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.policy-governance.test.tsx b/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.policy-governance.test.tsx
index 55f1bf5e2e..70ec0896c2 100644
--- a/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.policy-governance.test.tsx
+++ b/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.policy-governance.test.tsx
@@ -100,7 +100,7 @@ describe('UnifiedResourceTable governance presentation', () => {
});
it('surfaces resource facet counts in the resource row', () => {
- const { getByText } = render(() => (
+ const { getByText, queryByText } = render(() => (
<UnifiedResourceTable
resources={[resource]}
expandedResourceId={null}
@@ -109,8 +109,8 @@ describe('UnifiedResourceTable governance presentation', () => {
/>
));
- expect(getByText('Capabilities 2')).toBeInTheDocument();
- expect(getByText('Relationships 1')).toBeInTheDocument();
expect(getByText('Timeline 1')).toBeInTheDocument();
+ expect(queryByText('Capabilities 2')).toBeNull();
+ expect(queryByText('Relationships 1')).toBeNull();
});
});
diff --git a/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.workloads-link.test.tsx b/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.workloads-link.test.tsx
index b8cfef45c7..2dc65ac209 100644
--- a/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.workloads-link.test.tsx
+++ b/frontend-modern/src/components/Infrastructure/__tests__/UnifiedResourceTable.workloads-link.test.tsx
@@ -272,9 +272,9 @@ describe('UnifiedResourceTable workloads links', () => {
const row = within(pbsRow);
expect(row.getByText('2')).toBeInTheDocument();
expect(row.getByText('1')).toBeInTheDocument();
- expect(row.getByText('Capabilities 1')).toBeInTheDocument();
- expect(row.getByText('Relationships 1')).toBeInTheDocument();
expect(row.getByText('Timeline 1')).toBeInTheDocument();
+ expect(row.queryByText('Capabilities 1')).toBeNull();
+ expect(row.queryByText('Relationships 1')).toBeNull();
}
const pmgRow = getByText('pmg-main').closest('tr');
@@ -283,9 +283,9 @@ describe('UnifiedResourceTable workloads links', () => {
const row = within(pmgRow);
expect(row.getByText('519')).toBeInTheDocument();
expect(row.getByText('1')).toBeInTheDocument();
- expect(row.getByText('Capabilities 1')).toBeInTheDocument();
- expect(row.getByText('Relationships 1')).toBeInTheDocument();
expect(row.getByText('Timeline 1')).toBeInTheDocument();
+ expect(row.queryByText('Capabilities 1')).toBeNull();
+ expect(row.queryByText('Relationships 1')).toBeNull();
}
const pbsLink = getByRole('link', { name: /open pbs backups/i });
diff --git a/scripts/release_control/control_plane_audit_test.py b/scripts/release_control/control_plane_audit_test.py
index 88ecfc3783..ef8acb5fe5 100644
--- a/scripts/release_control/control_plane_audit_test.py
+++ b/scripts/release_control/control_plane_audit_test.py
@@ -98,16 +98,20 @@ class ControlPlaneAuditTest(unittest.TestCase):
entrypoint["startup_commands"],
["python3 scripts/release_control/status_audit.py --pretty"],
)
- self.assertEqual(entrypoint["default_pick_surface"], "available_candidate_lane_queue")
- self.assertIn("candidate lanes", entrypoint["selection_rule"])
- self.assertIn(
- "python3 scripts/release_control/status_lookup.py --candidate-lane <CANDIDATE_LANE_ID> --pretty",
- entrypoint["targeted_lookup_commands"],
- )
- self.assertIn(
- "python3 scripts/release_control/status_lookup.py --coverage-gap <COVERAGE_GAP_ID> --pretty",
- entrypoint["targeted_lookup_commands"],
- )
+ if entrypoint["active_target_id"] == "v6-product-lane-expansion":
+ self.assertEqual(entrypoint["default_pick_surface"], "available_candidate_lane_queue")
+ self.assertIn("candidate lanes", entrypoint["selection_rule"])
+ self.assertIn(
+ "python3 scripts/release_control/status_lookup.py --candidate-lane <CANDIDATE_LANE_ID> --pretty",
+ entrypoint["targeted_lookup_commands"],
+ )
+ self.assertIn(
+ "python3 scripts/release_control/status_lookup.py --coverage-gap <COVERAGE_GAP_ID> --pretty",
+ entrypoint["targeted_lookup_commands"],
+ )
+ else:
+ self.assertEqual(entrypoint["default_pick_surface"], "lanes")
+ self.assertIn("lane map", entrypoint["selection_rule"])
self.assertIn(
"python3 scripts/release_control/status_lookup.py --lane <LANE_ID> --pretty",
entrypoint["targeted_lookup_commands"],