# ggingggang/dashboard architecture

> Architecture diagram of the GitHub repository ggingggang/dashboard, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-19). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ggingggang/dashboard
- Repository: https://github.com/ggingggang/dashboard

## Overview

IDP Dashboard is a Windows desktop operations view that connects to existing CI/CD and observability services using read-only requests. Developers configure connections and targets, then view collected build, queue, deployment, and metric status or run on-demand metric, log, trace, and JSON queries. Results can be arranged into a persistent personal dashboard; build history is stored locally. Frontend-to-frontend edges follow indexed references or excerpts. Backend relationships and the native bridge are shown as unverified where the excerpts do not establish the call path.

Main entry points: [`frontend/src/main.ts`](https://github.com/ggingggang/dashboard/blob/main/frontend/src/main.ts) (Page navigation), [`internal/collector/collector.go`](https://github.com/ggingggang/dashboard/blob/main/internal/collector/collector.go) (Snapshot collection), [`frontend/src/components/dashboard.ts`](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard.ts) (Personal dashboard), [`internal/application/service.go`](https://github.com/ggingggang/dashboard/blob/main/internal/application/service.go) (Application service)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["Desktop interface"]
  node_main_ui["Page navigation<br/>[main.ts]"]
  node_bridge["Native bridge<br/>[index.ts]"]
end

subgraph group_domain["Operations views"]
  node_dashboard["Personal dashboard<br/>[dashboard.ts]"]
  node_dashboard_data["Widget data<br/>[dashboard-data.ts]"]
  node_layout["Dashboard layout"]
  node_chart["Metric charts<br/>[chart.ts]"]
  node_explorer["Metric, log, trace explorer<br/>[explorer.ts]"]
  node_api_query["JSON API query<br/>[api-query.ts]"]
  node_json_filter["JSON query validation<br/>[json-query.ts]"]
end

subgraph group_backend["Application services"]
  node_app["Desktop API<br/>[app.go]"]
  node_service["Application service<br/>[service.go]"]
  node_collector["Snapshot collection<br/>[collector.go]"]
  node_build_collection["Build history collection<br/>[collect_builds.go]"]
  node_queue_collection["Queue collection<br/>[collect_queue.go]"]
  node_deployment_collection["Deployment collection"]
  node_metric_collection["Metric collection<br/>[collect_metrics.go]"]
end

subgraph group_integrations["Provider adapters"]
  node_jenkins["Jenkins adapter<br/>[jenkins.go]"]
  node_argocd["Argo CD adapter<br/>[argocd.go]"]
  node_prometheus["Prometheus adapter<br/>[prometheus.go]"]
  node_loki["Loki adapter<br/>[loki.go]"]
  node_tempo["Tempo adapter<br/>[tempo.go]"]
end

subgraph group_state["Local state"]
  node_sqlite[("SQLite history<br/>[sqlite.go]")]
  node_registry["Provider registry<br/>[registry.go]"]
end

node_developer(("Developer"))

node_developer -->|"uses"| node_main_ui
node_main_ui -->|"opens"| node_dashboard
node_main_ui -->|"mounts"| node_api_query
node_main_ui -->|"renders"| node_explorer
node_main_ui -->|"renders"| node_chart
node_dashboard -->|"updates"| node_dashboard_data
node_dashboard -->|"validates layout"| node_layout
node_dashboard -->|"loads preferences"| node_bridge
node_dashboard_data -->|"queries data"| node_bridge
node_dashboard_data -.->|"shows metrics"| node_chart
node_api_query -->|"reads JSON"| node_bridge
node_api_query -->|"validates request"| node_json_filter
node_bridge -.->|"invokes native API"| node_app
node_app -.->|"delegates"| node_service
node_service -.->|"coordinates collection"| node_collector
node_collector -.->|"collects builds"| node_build_collection
node_collector -.->|"collects queue"| node_queue_collection
node_collector -.->|"collects deployments"| node_deployment_collection
node_collector -.->|"collects metrics"| node_metric_collection
node_build_collection -.->|"fetches builds"| node_jenkins
node_queue_collection -.->|"fetches queue"| node_jenkins
node_deployment_collection -.->|"fetches applications"| node_argocd
node_metric_collection -.->|"runs queries"| node_prometheus
node_explorer -.->|"searches logs"| node_loki
node_explorer -.->|"searches traces"| node_tempo
node_service -.->|"persists history"| node_sqlite
node_service -.->|"resolves providers"| node_registry
node_jenkins -.->|"reads upstream"| node_developer
node_argocd -.->|"reads upstream"| node_developer
node_prometheus -.->|"reads upstream"| node_developer
node_loki -.->|"reads upstream"| node_developer
node_tempo -.->|"reads upstream"| node_developer

click node_main_ui "https://github.com/ggingggang/dashboard/blob/main/frontend/src/main.ts"
click node_bridge "https://github.com/ggingggang/dashboard/blob/main/frontend/src/bridge/index.ts"
click node_dashboard "https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard.ts"
click node_dashboard_data "https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard-data.ts"
click node_layout "https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard-layout.ts"
click node_chart "https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/chart.ts"
click node_explorer "https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/explorer.ts"
click node_api_query "https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/api-query.ts"
click node_json_filter "https://github.com/ggingggang/dashboard/blob/main/frontend/src/shared/json-query.ts"
click node_app "https://github.com/ggingggang/dashboard/blob/main/app.go"
click node_service "https://github.com/ggingggang/dashboard/blob/main/internal/application/service.go"
click node_collector "https://github.com/ggingggang/dashboard/blob/main/internal/collector/collector.go"
click node_build_collection "https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_builds.go"
click node_queue_collection "https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_queue.go"
click node_deployment_collection "https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_deployments.go"
click node_metric_collection "https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_metrics.go"
click node_jenkins "https://github.com/ggingggang/dashboard/blob/main/internal/providers/jenkins/jenkins.go"
click node_argocd "https://github.com/ggingggang/dashboard/blob/main/internal/providers/argocd/argocd.go"
click node_prometheus "https://github.com/ggingggang/dashboard/blob/main/internal/providers/prometheus/prometheus.go"
click node_loki "https://github.com/ggingggang/dashboard/blob/main/internal/providers/loki/loki.go"
click node_tempo "https://github.com/ggingggang/dashboard/blob/main/internal/providers/tempo/tempo.go"
click node_sqlite "https://github.com/ggingggang/dashboard/blob/main/internal/storage/sqlite.go"
click node_registry "https://github.com/ggingggang/dashboard/blob/main/internal/platform/registry.go"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_main_ui,node_bridge toneBlue
class node_dashboard,node_dashboard_data,node_layout,node_chart,node_explorer,node_api_query,node_json_filter toneAmber
class node_app,node_service,node_collector,node_build_collection,node_queue_collection,node_deployment_collection,node_metric_collection toneMint
class node_jenkins,node_argocd,node_prometheus,node_loki,node_tempo toneRose
class node_sqlite,node_registry,node_developer toneIndigo
```

## Components

### Desktop interface

- [Page navigation](https://github.com/ggingggang/dashboard/blob/main/frontend/src/main.ts): `frontend/src/main.ts`
- [Native bridge](https://github.com/ggingggang/dashboard/blob/main/frontend/src/bridge/index.ts): `frontend/src/bridge/index.ts`

### Operations views

- [Personal dashboard](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard.ts): `frontend/src/components/dashboard.ts`
- [Widget data](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard-data.ts): `frontend/src/components/dashboard-data.ts`
- [Dashboard layout](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/dashboard-layout.ts): `frontend/src/components/dashboard-layout.ts`
- [Metric charts](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/chart.ts): `frontend/src/components/chart.ts`
- [Metric, log, trace explorer](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/explorer.ts): `frontend/src/components/explorer.ts`
- [JSON API query](https://github.com/ggingggang/dashboard/blob/main/frontend/src/components/api-query.ts): `frontend/src/components/api-query.ts`
- [JSON query validation](https://github.com/ggingggang/dashboard/blob/main/frontend/src/shared/json-query.ts): `frontend/src/shared/json-query.ts`

### Application services

- [Desktop API](https://github.com/ggingggang/dashboard/blob/main/app.go): `app.go`
- [Application service](https://github.com/ggingggang/dashboard/blob/main/internal/application/service.go): `internal/application/service.go`
- [Snapshot collection](https://github.com/ggingggang/dashboard/blob/main/internal/collector/collector.go): `internal/collector/collector.go`
- [Build history collection](https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_builds.go): `internal/collector/collect_builds.go`
- [Queue collection](https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_queue.go): `internal/collector/collect_queue.go`
- [Deployment collection](https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_deployments.go): `internal/collector/collect_deployments.go`
- [Metric collection](https://github.com/ggingggang/dashboard/blob/main/internal/collector/collect_metrics.go): `internal/collector/collect_metrics.go`

### Provider adapters

- [Jenkins adapter](https://github.com/ggingggang/dashboard/blob/main/internal/providers/jenkins/jenkins.go): `internal/providers/jenkins/jenkins.go`
- [Argo CD adapter](https://github.com/ggingggang/dashboard/blob/main/internal/providers/argocd/argocd.go): `internal/providers/argocd/argocd.go`
- [Prometheus adapter](https://github.com/ggingggang/dashboard/blob/main/internal/providers/prometheus/prometheus.go): `internal/providers/prometheus/prometheus.go`
- [Loki adapter](https://github.com/ggingggang/dashboard/blob/main/internal/providers/loki/loki.go): `internal/providers/loki/loki.go`
- [Tempo adapter](https://github.com/ggingggang/dashboard/blob/main/internal/providers/tempo/tempo.go): `internal/providers/tempo/tempo.go`

### Local state

- [SQLite history](https://github.com/ggingggang/dashboard/blob/main/internal/storage/sqlite.go): `internal/storage/sqlite.go`
- [Provider registry](https://github.com/ggingggang/dashboard/blob/main/internal/platform/registry.go): `internal/platform/registry.go`

### Other components

- **Developer**

## Connections

- Developer → Page navigation: uses
- Page navigation → Personal dashboard: opens (evidence: `frontend/src/main.ts`)
- Page navigation → JSON API query: mounts (evidence: `frontend/src/main.ts`)
- Page navigation → Metric, log, trace explorer: renders (evidence: `frontend/src/main.ts`)
- Page navigation → Metric charts: renders (evidence: `frontend/src/main.ts`)
- Personal dashboard → Widget data: updates (evidence: `frontend/src/components/dashboard.ts`)
- Personal dashboard → Dashboard layout: validates layout (evidence: `frontend/src/components/dashboard.ts`)
- Personal dashboard → Native bridge: loads preferences (evidence: `frontend/src/components/dashboard.ts`)
- Widget data → Native bridge: queries data (evidence: `frontend/src/components/dashboard-data.ts`)
- Widget data → Metric charts: shows metrics
- JSON API query → Native bridge: reads JSON (evidence: `frontend/src/components/api-query.ts`)
- JSON API query → JSON query validation: validates request (evidence: `frontend/src/components/api-query.ts`)
- Native bridge → Desktop API: invokes native API
- Desktop API → Application service: delegates
- Application service → Snapshot collection: coordinates collection
- Snapshot collection → Build history collection: collects builds
- Snapshot collection → Queue collection: collects queue
- Snapshot collection → Deployment collection: collects deployments
- Snapshot collection → Metric collection: collects metrics
- Build history collection → Jenkins adapter: fetches builds
- Queue collection → Jenkins adapter: fetches queue
- Deployment collection → Argo CD adapter: fetches applications
- Metric collection → Prometheus adapter: runs queries
- Metric, log, trace explorer → Loki adapter: searches logs
- Metric, log, trace explorer → Tempo adapter: searches traces
- Application service → SQLite history: persists history
- Application service → Provider registry: resolves providers
- Jenkins adapter → Developer: reads upstream
- Argo CD adapter → Developer: reads upstream
- Prometheus adapter → Developer: reads upstream
- Loki adapter → Developer: reads upstream
- Tempo adapter → Developer: reads upstream
