Skip to content

feat(console): add five-stage visual pipeline flow with audited tap and SQL Server guided setup (#101, #99) - #307

Merged
jusso-dev merged 1 commit into
mainfrom
feat/console-pipelines-and-sources
Nov 21, 2026
Merged

jusso-dev merged 1 commit into
mainfrom
feat/console-pipelines-and-sources

Conversation

@jusso-dev

Copy link
Copy Markdown
Owner

Summary

Closes #101. Advances #99.

Adds the console's five-stage visual pipeline view backed by collector heartbeat telemetry (bower top & selection counters) and audited Operator-only post-redaction tap sampling, plus the SQL Server guided source setup type:

  • Collector & Management API live pipeline telemetry (CollectorJson.cs, ManagementHeartbeatJob.cs, PipelineLiveModels.cs, ManagementStore.Pipelines.cs, PipelineLiveEndpoints.cs):
    • Extends heartbeat v2 additively with metadata-only pipeline selection counters and capped activity (bower top busiest sources, max 25).
    • Persists snapshots in collector_pipeline_snapshots and serves GET /api/pipelines/live (View role) with five-stage status (Collect → Redact → Select → Queue → Deliver), signal reduction percentage, busiest sources, redaction totals by detector, and per-policy breakdown.
    • Adds POST /api/pipelines/collectors/{id}/tap (Operate role; Viewers receive 403) that audits every request (pipeline.tap-sampled), returns bounded already-redacted frames when an allow-listed ICollectorTapClient is configured, or returns the exact bower tap command in outbound-only deployments (no arbitrary user-supplied URLs / zero SSRF surface).
  • Console visual pipeline view (ui/Bower.Management.Web/src/components/PipelineFlowDiagram.tsx, PipelinesPage.tsx, styles.css, PipelinesPage.test.tsx):
    • Accessible, keyboard-navigable five-stage flow diagram with collector picker, stage detail tabs (top sources, redactions, policy breakdown, queue/DLQ health, delivery outputs), and Operator-only "Sample redacted events" control.
  • Guided source setup: SQL Server (src/Bower.Management.Api/SourceSetupSqlServer.cs, SourceSetupRegistry.cs):
    • Adds sql-server as the 9th guided source type, enforcing safe SQL identifiers, ApplicationIntent=ReadOnly, bounded batches, secret references only (file path or Key Vault URL — rejects inline passwords), least-privilege GRANT SELECT snippet, and a redacted synthetic preview.

Verification

  • dotnet build --configuration Release — 0 warnings, 0 errors
  • dotnet test (PipelineLiveAndSqlSetupTests, SourceSetupApiTests, ManagementApiTests, FleetApiTests) — 101 passed, 0 failed
  • dotnet format --verify-no-changes — passed
  • cd ui/Bower.Management.Web && npm run lint && npm test && npm run build — 17/17 test files (110/110 tests) passed, TypeScript & Vite production build succeeded

Security and compatibility impact

  • All heartbeat, database, API and UI changes are strictly additive and Native AOT source-generated (ManagementJsonContext, CollectorJsonContext).
  • RBAC is enforced server-side (Operate required for tap); every tap request writes an audit row; raw payloads and secrets never leave the collector or enter management storage.

@coderabbitai

coderabbitai Bot commented Nov 21, 2026 •

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 58 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: bb9595cd-bdd3-4642-970f-1baea64f3159
Commits

Reviewing files that changed from the base of the PR and between 7dd9f69 and 0ba4824.

Files selected for processing: 18

  • src/Bower.Collector/CollectorJson.cs
  • src/Bower.Collector/Jobs/ManagementHeartbeatJob.cs
  • src/Bower.Management.Api/ManagementApplication.cs
  • src/Bower.Management.Api/ManagementJson.cs
  • src/Bower.Management.Api/ManagementModels.cs
  • src/Bower.Management.Api/ManagementStore.Pipelines.cs
  • src/Bower.Management.Api/ManagementStore.cs
  • src/Bower.Management.Api/PipelineLiveEndpoints.cs
  • src/Bower.Management.Api/PipelineLiveModels.cs
  • src/Bower.Management.Api/SourceSetupRegistry.cs
  • src/Bower.Management.Api/SourceSetupSqlServer.cs
  • tests/Bower.UnitTests/PipelineLiveAndSqlSetupTests.cs
  • tests/Bower.UnitTests/SourceSetupApiTests.cs
  • ui/Bower.Management.Web/src/components/PipelineFlowDiagram.tsx
  • ui/Bower.Management.Web/src/pages/PipelinesPage.test.tsx
  • ui/Bower.Management.Web/src/pages/PipelinesPage.tsx
  • ui/Bower.Management.Web/src/styles.css
  • ui/Bower.Management.Web/src/types.ts
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@jusso-dev
jusso-dev force-pushed the feat/console-pipelines-and-sources branch from b303b7f to 267ccb0 Compare November 21, 2026 21:45
@jusso-dev
jusso-dev force-pushed the feat/console-pipelines-and-sources branch from 267ccb0 to 0ba4824 Compare November 21, 2026 22:37
@jusso-dev
jusso-dev merged commit 71a3693 into main Nov 21, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Console: visual pipeline view backed by tap and top

1 participant