# bevararaghu5-netizen/go-furniture architecture

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

- Interactive diagram: https://gitdiagram.com/bevararaghu5-netizen/go-furniture
- Repository: https://github.com/bevararaghu5-netizen/go-furniture

## Overview

Go Furniture is a furniture-catalogue web application and a DevOps deployment-and-monitoring portfolio project. Its user workflow runs from browser-rendered catalogue assets through Nginx to the API, which reads product records from PostgreSQL; the frontend also keeps a cart in browser storage. The README documents a separate delivery lifecycle through Jenkins, Docker, Docker Hub, and Kubernetes, plus configured metrics collection and dashboards. Delivery and monitoring links below reflect documented intent, not verified live integrations; source excerpts mainly establish application behavior.

Main entry points: [`frontend/app.js`](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/frontend/app.js) (Catalogue UI), [`nginx/nginx.conf`](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/nginx/nginx.conf) (Nginx proxy), [`backend/server.js`](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/backend/server.js) (Product API), [`Jenkinsfile`](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/Jenkinsfile) (Jenkins pipeline)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_application["Application"]
  node_frontend["Catalogue UI<br/>[app.js]"]
  node_nginx["Nginx proxy<br/>[nginx.conf]"]
  node_api["Product API<br/>[server.js]"]
  node_cart["Browser cart<br/>[app.js]"]
  node_postgres[("Product database<br/>[init.sql]")]
end

subgraph group_delivery["Delivery"]
  node_github["GitHub source"]
  node_jenkins["Jenkins pipeline"]
  node_images["Docker images"]
  node_registry["Docker Hub"]
end

subgraph group_cluster["Deployment"]
  node_kubernetes["Kubernetes workloads"]
end

subgraph group_observability["Monitoring"]
  node_metrics["Metrics targets"]
  node_prometheus["Prometheus"]
  node_grafana["Grafana"]
end

node_browser(("Browser user"))

node_browser -->|"requests site"| node_nginx
node_nginx -->|"serves assets"| node_frontend
node_frontend -->|"requests API"| node_nginx
node_nginx -->|"proxies requests"| node_api
node_api -->|"reads and writes"| node_postgres
node_api -->|"returns products"| node_frontend
node_frontend -->|"stores cart"| node_cart
node_github -->|"triggers pipeline"| node_jenkins
node_jenkins -->|"builds images"| node_images
node_jenkins -->|"publishes images"| node_registry
node_registry -->|"supplies images"| node_kubernetes
node_kubernetes -.->|"exposes metrics"| node_metrics
node_metrics -->|"scrapes targets"| node_prometheus
node_prometheus -->|"feeds dashboards"| node_grafana

click node_frontend "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/frontend/app.js"
click node_nginx "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/nginx/nginx.conf"
click node_api "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/backend/server.js"
click node_cart "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/frontend/app.js"
click node_postgres "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/database/init.sql"
click node_jenkins "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/Jenkinsfile"
click node_images "https://github.com/bevararaghu5-netizen/go-furniture/blob/main/backend/Dockerfile"
click node_kubernetes "https://github.com/bevararaghu5-netizen/go-furniture/tree/main/K8s"

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_frontend,node_nginx,node_api,node_cart,node_postgres,node_browser toneBlue
class node_github,node_jenkins,node_images,node_registry toneAmber
class node_kubernetes toneMint
class node_metrics,node_prometheus,node_grafana toneRose
```

## Components

### Application

- [Catalogue UI](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/frontend/app.js): `frontend/app.js`
- [Nginx proxy](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/nginx/nginx.conf): `nginx/nginx.conf`
- [Product API](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/backend/server.js): `backend/server.js`
- [Browser cart](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/frontend/app.js): `frontend/app.js`
- [Product database](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/database/init.sql): `database/init.sql`

### Delivery

- **GitHub source**
- [Jenkins pipeline](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/Jenkinsfile): `Jenkinsfile`
- [Docker images](https://github.com/bevararaghu5-netizen/go-furniture/blob/main/backend/Dockerfile): `backend/Dockerfile`
- **Docker Hub**

### Deployment

- [Kubernetes workloads](https://github.com/bevararaghu5-netizen/go-furniture/tree/main/K8s): `K8s`

### Monitoring

- **Metrics targets**
- **Prometheus**
- **Grafana**

### Other components

- **Browser user**

## Connections

- Browser user → Nginx proxy: requests site (evidence: `README.md`)
- Nginx proxy → Catalogue UI: serves assets (evidence: `README.md`)
- Catalogue UI → Nginx proxy: requests API (evidence: `README.md`)
- Nginx proxy → Product API: proxies requests (evidence: `README.md`)
- Product API → Product database: reads and writes (evidence: `backend/server.js`)
- Product API → Catalogue UI: returns products (evidence: `README.md`)
- Catalogue UI → Browser cart: stores cart (evidence: `frontend/app.js`)
- GitHub source → Jenkins pipeline: triggers pipeline (evidence: `README.md`)
- Jenkins pipeline → Docker images: builds images (evidence: `README.md`)
- Jenkins pipeline → Docker Hub: publishes images (evidence: `README.md`)
- Docker Hub → Kubernetes workloads: supplies images (evidence: `README.md`)
- Kubernetes workloads → Metrics targets: exposes metrics (evidence: `README.md`)
- Metrics targets → Prometheus: scrapes targets (evidence: `README.md`)
- Prometheus → Grafana: feeds dashboards (evidence: `README.md`)
