# pranesh2006-doc/cloud-scale architecture

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

- Interactive diagram: https://gitdiagram.com/pranesh2006-doc/cloud-scale
- Repository: https://github.com/pranesh2006-doc/cloud-scale

## Overview

CloudScale is a React dashboard for exploring simulated cloud infrastructure health and operations. Users enter through the routed dashboard, inspect overview and monitoring data, and use dedicated pages to manage instance state, scaling policies, traffic tests, deployments, and rate limits; preferences and simulated actions are shared through application context. The README describes a future Spring Boot integration, while the sampled traffic tester explicitly sends no real requests. The graph emphasizes documented simulation behavior and source-indexed dependencies; unsampled page internals are not inferred.

Main entry points: [`src/context/AppContext.jsx`](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/context/AppContext.jsx) (App state and actions), [`src/App.jsx`](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/App.jsx) (Route application), [`src/pages/Monitoring.jsx`](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Monitoring.jsx) (Metrics and alerts), [`src/pages/Overview.jsx`](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Overview.jsx) (Infrastructure overview)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_shell["Dashboard Shell"]
  node_app["Route application<br/>[App.jsx]"]
  node_layout["Dashboard layout"]
  node_topbar["Navigation and alerts<br/>[Topbar.jsx]"]
end

subgraph group_state["Shared Simulation State"]
  node_context["App state and actions<br/>[AppContext.jsx]"]
  node_mock["Simulated cloud data<br/>[mockData.js]"]
  node_preferences["Persistent preferences<br/>[useLocalStorage.js]"]
  node_api["Backend-ready API client<br/>[api.js]"]
end

subgraph group_ops["Infrastructure Operations"]
  node_overview["Infrastructure overview<br/>[Overview.jsx]"]
  node_instances["EC2 fleet management<br/>[Instances.jsx]"]
  node_monitoring["Metrics and alerts<br/>[Monitoring.jsx]"]
  node_scaling["Scaling policies"]
  node_traffic["Traffic load testing<br/>[TrafficTesting.jsx]"]
  node_rate["Rate-limit simulator<br/>[RateLimiting.jsx]"]
  node_deployments["Deployment pipeline<br/>[Deployments.jsx]"]
  node_settings["Settings and connection<br/>[Settings.jsx]"]
end

subgraph group_shared["Shared UI Components"]
  node_charts["Chart presentation<br/>[ChartCard.jsx]"]
  node_tables["Sortable data tables<br/>[DataTable.jsx]"]
  node_stats["KPI cards<br/>[StatCard.jsx]"]
  node_badges["Status indicators<br/>[StatusBadge.jsx]"]
  node_formatters["Metric formatters<br/>[formatters.js]"]
end

node_user(("Dashboard user"))
node_spring{{"Future Spring Boot backend"}}

node_user -->|"opens dashboard"| node_app
node_app -->|"provides state"| node_context
node_app -->|"routes through"| node_layout
node_app -->|"routes to"| node_overview
node_app -->|"routes to"| node_instances
node_app -->|"routes to"| node_traffic
node_app -->|"routes to"| node_scaling
node_app -->|"routes to"| node_monitoring
node_app -->|"routes to"| node_deployments
node_app -->|"routes to"| node_rate
node_app -->|"routes to"| node_settings
node_layout -->|"renders"| node_topbar
node_layout -.->|"uses shared state"| node_context
node_topbar -->|"reads and updates"| node_context
node_topbar -->|"links to alerts"| node_monitoring
node_context -->|"initializes and generates"| node_mock
node_context -->|"persists preferences"| node_preferences
node_overview -->|"reads dashboard state"| node_context
node_instances -->|"manages fleet state"| node_context
node_monitoring -->|"reads metrics and alerts"| node_context
node_scaling -->|"reads scaling state"| node_context
node_traffic -->|"posts notifications"| node_context
node_rate -->|"updates limit config"| node_context
node_deployments -->|"uses shared state"| node_context
node_settings -->|"updates preferences"| node_context
node_settings -.->|"tests connection"| node_api
node_api -->|"uses mock fallback"| node_mock
node_overview -->|"renders charts"| node_charts
node_overview -->|"renders KPIs"| node_stats
node_overview -->|"renders health status"| node_badges
node_overview -->|"formats metrics"| node_formatters
node_instances -->|"renders fleet table"| node_tables
node_instances -->|"renders KPIs"| node_stats
node_instances -->|"renders status"| node_badges
node_instances -->|"formats values"| node_formatters
node_monitoring -->|"renders metrics"| node_charts
node_monitoring -->|"renders alert data"| node_tables
node_monitoring -->|"renders KPIs"| node_stats
node_monitoring -->|"renders status"| node_badges
node_monitoring -->|"formats metrics"| node_formatters
node_scaling -->|"renders event data"| node_tables
node_scaling -->|"renders KPIs"| node_stats
node_scaling -->|"renders status"| node_badges
node_traffic -->|"renders RPS history"| node_charts
node_traffic -->|"renders KPIs"| node_stats
node_traffic -->|"formats metrics"| node_formatters
node_rate -->|"renders visualizations"| node_charts
node_rate -->|"renders KPIs"| node_stats

click node_app "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/App.jsx"
click node_layout "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/layouts/DashboardLayout.jsx"
click node_topbar "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/Topbar.jsx"
click node_context "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/context/AppContext.jsx"
click node_mock "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/data/mockData.js"
click node_preferences "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/hooks/useLocalStorage.js"
click node_api "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/services/api.js"
click node_overview "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Overview.jsx"
click node_instances "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Instances.jsx"
click node_monitoring "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Monitoring.jsx"
click node_scaling "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/ScalingPolicies.jsx"
click node_traffic "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/TrafficTesting.jsx"
click node_rate "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/RateLimiting.jsx"
click node_deployments "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Deployments.jsx"
click node_settings "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Settings.jsx"
click node_charts "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/ChartCard.jsx"
click node_tables "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/DataTable.jsx"
click node_stats "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/StatCard.jsx"
click node_badges "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/StatusBadge.jsx"
click node_formatters "https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/utils/formatters.js"

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_app,node_layout,node_topbar,node_user toneBlue
class node_context,node_mock,node_preferences,node_api toneAmber
class node_overview,node_instances,node_monitoring,node_scaling,node_traffic,node_rate,node_deployments,node_settings toneMint
class node_charts,node_tables,node_stats,node_badges,node_formatters toneRose
class node_spring toneIndigo
```

## Components

### Dashboard Shell

- [Route application](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/App.jsx): `src/App.jsx`
- [Dashboard layout](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/layouts/DashboardLayout.jsx): `src/layouts/DashboardLayout.jsx`
- [Navigation and alerts](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/Topbar.jsx): `src/components/Topbar.jsx`

### Shared Simulation State

- [App state and actions](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/context/AppContext.jsx): `src/context/AppContext.jsx`
- [Simulated cloud data](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/data/mockData.js): `src/data/mockData.js`
- [Persistent preferences](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/hooks/useLocalStorage.js): `src/hooks/useLocalStorage.js`
- [Backend-ready API client](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/services/api.js): `src/services/api.js`

### Infrastructure Operations

- [Infrastructure overview](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Overview.jsx): `src/pages/Overview.jsx`
- [EC2 fleet management](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Instances.jsx): `src/pages/Instances.jsx`
- [Metrics and alerts](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Monitoring.jsx): `src/pages/Monitoring.jsx`
- [Scaling policies](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/ScalingPolicies.jsx): `src/pages/ScalingPolicies.jsx`
- [Traffic load testing](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/TrafficTesting.jsx): `src/pages/TrafficTesting.jsx`
- [Rate-limit simulator](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/RateLimiting.jsx): `src/pages/RateLimiting.jsx`
- [Deployment pipeline](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Deployments.jsx): `src/pages/Deployments.jsx`
- [Settings and connection](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/pages/Settings.jsx): `src/pages/Settings.jsx`

### Shared UI Components

- [Chart presentation](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/ChartCard.jsx): `src/components/ChartCard.jsx`
- [Sortable data tables](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/DataTable.jsx): `src/components/DataTable.jsx`
- [KPI cards](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/StatCard.jsx): `src/components/StatCard.jsx`
- [Status indicators](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/components/StatusBadge.jsx): `src/components/StatusBadge.jsx`
- [Metric formatters](https://github.com/pranesh2006-doc/cloud-scale/blob/main/src/utils/formatters.js): `src/utils/formatters.js`

### Other components

- **Dashboard user**
- **Future Spring Boot backend**

## Connections

- Dashboard user → Route application: opens dashboard (evidence: `README.md`)
- Route application → App state and actions: provides state (evidence: `src/App.jsx`)
- Route application → Dashboard layout: routes through (evidence: `src/App.jsx`)
- Route application → Infrastructure overview: routes to (evidence: `src/App.jsx`)
- Route application → EC2 fleet management: routes to (evidence: `src/App.jsx`)
- Route application → Traffic load testing: routes to (evidence: `src/App.jsx`)
- Route application → Scaling policies: routes to (evidence: `src/App.jsx`)
- Route application → Metrics and alerts: routes to (evidence: `src/App.jsx`)
- Route application → Deployment pipeline: routes to (evidence: `src/App.jsx`)
- Route application → Rate-limit simulator: routes to (evidence: `src/App.jsx`)
- Route application → Settings and connection: routes to (evidence: `src/App.jsx`)
- Dashboard layout → Navigation and alerts: renders (evidence: `src/layouts/DashboardLayout.jsx`)
- Dashboard layout → App state and actions: uses shared state
- Navigation and alerts → App state and actions: reads and updates (evidence: `src/components/Topbar.jsx`)
- Navigation and alerts → Metrics and alerts: links to alerts (evidence: `src/components/Topbar.jsx`)
- App state and actions → Simulated cloud data: initializes and generates (evidence: `src/context/AppContext.jsx`)
- App state and actions → Persistent preferences: persists preferences (evidence: `src/context/AppContext.jsx`)
- Infrastructure overview → App state and actions: reads dashboard state (evidence: `src/pages/Overview.jsx`)
- EC2 fleet management → App state and actions: manages fleet state (evidence: `src/pages/Instances.jsx`)
- Metrics and alerts → App state and actions: reads metrics and alerts (evidence: `src/pages/Monitoring.jsx`)
- Scaling policies → App state and actions: reads scaling state (evidence: `src/pages/ScalingPolicies.jsx`)
- Traffic load testing → App state and actions: posts notifications (evidence: `src/pages/TrafficTesting.jsx`)
- Rate-limit simulator → App state and actions: updates limit config (evidence: `src/pages/RateLimiting.jsx`)
- Deployment pipeline → App state and actions: uses shared state (evidence: `src/pages/Deployments.jsx`)
- Settings and connection → App state and actions: updates preferences (evidence: `src/pages/Settings.jsx`)
- Settings and connection → Backend-ready API client: tests connection
- Backend-ready API client → Simulated cloud data: uses mock fallback (evidence: `src/services/api.js`)
- Infrastructure overview → Chart presentation: renders charts (evidence: `src/pages/Overview.jsx`)
- Infrastructure overview → KPI cards: renders KPIs (evidence: `src/pages/Overview.jsx`)
- Infrastructure overview → Status indicators: renders health status (evidence: `src/pages/Overview.jsx`)
- Infrastructure overview → Metric formatters: formats metrics (evidence: `src/pages/Overview.jsx`)
- EC2 fleet management → Sortable data tables: renders fleet table (evidence: `src/pages/Instances.jsx`)
- EC2 fleet management → KPI cards: renders KPIs (evidence: `src/pages/Instances.jsx`)
- EC2 fleet management → Status indicators: renders status (evidence: `src/pages/Instances.jsx`)
- EC2 fleet management → Metric formatters: formats values (evidence: `src/pages/Instances.jsx`)
- Metrics and alerts → Chart presentation: renders metrics (evidence: `src/pages/Monitoring.jsx`)
- Metrics and alerts → Sortable data tables: renders alert data (evidence: `src/pages/Monitoring.jsx`)
- Metrics and alerts → KPI cards: renders KPIs (evidence: `src/pages/Monitoring.jsx`)
- Metrics and alerts → Status indicators: renders status (evidence: `src/pages/Monitoring.jsx`)
- Metrics and alerts → Metric formatters: formats metrics (evidence: `src/pages/Monitoring.jsx`)
- Scaling policies → Sortable data tables: renders event data (evidence: `src/pages/ScalingPolicies.jsx`)
- Scaling policies → KPI cards: renders KPIs (evidence: `src/pages/ScalingPolicies.jsx`)
- Scaling policies → Status indicators: renders status (evidence: `src/pages/ScalingPolicies.jsx`)
- Traffic load testing → Chart presentation: renders RPS history (evidence: `src/pages/TrafficTesting.jsx`)
- Traffic load testing → KPI cards: renders KPIs (evidence: `src/pages/TrafficTesting.jsx`)
- Traffic load testing → Metric formatters: formats metrics (evidence: `src/pages/TrafficTesting.jsx`)
- Rate-limit simulator → Chart presentation: renders visualizations (evidence: `src/pages/RateLimiting.jsx`)
- Rate-limit simulator → KPI cards: renders KPIs (evidence: `src/pages/RateLimiting.jsx`)
