# sandinacharles1/sandinify architecture

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

- Interactive diagram: https://gitdiagram.com/sandinacharles1/sandinify
- Repository: https://github.com/sandinacharles1/sandinify

## Overview

Sandinify combines a React music-app interface with a Spring Boot authentication and song-upload backend. The visible user journey is signup/login, authenticated entry to a placeholder music homepage, and MP3 upload; the README also describes frequency analysis and book matching, though their implementation is not shown in the excerpts. Backend relationships follow the README’s architecture and project-structure descriptions; frontend relationships use sampled imports and calls. Analysis details are therefore represented only as an unverified capability, not a confirmed processing pipeline.

Main entry points: [`user_management/frontend/src/main.jsx`](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/main.jsx) (App entry), [`user_management/frontend/src/home_page/Homepage.jsx`](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Homepage.jsx) (Music homepage), [`user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/SongUploadController.java`](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/SongUploadController.java) (Song upload endpoint), [`user_management/backend/server/sandinify/src/main/java/com/example/sandinify/auth/api/AuthController.java`](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/auth/api/AuthController.java) (Auth endpoints)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_frontend["Music app interface"]
  node_app_entry["App entry<br/>[main.jsx]"]
  node_auth_ui["Sign-in UI<br/>[App.jsx]"]
  node_home["Music homepage<br/>[Homepage.jsx]"]
  node_header["Navigation header<br/>[Header.jsx]"]
  node_sidebar["Playlist sidebar<br/>[Sidebar.jsx]"]
  node_song_card["Song cards<br/>[Songcard.jsx]"]
  node_decor["Page decoration<br/>[Decor.jsx]"]
  node_styles["Page styling<br/>[Styles.jsx]"]
  node_upload_ui["Upload form<br/>[UploadPage.jsx]"]
  node_song_api["Song API client<br/>[songApi.js]"]
end

subgraph group_identity["Identity and access"]
  node_rate_filter["Rate-limit filter"]
  node_rate_limiter["Rate limiter"]
  node_redis[("Redis")]
  node_jwt_filter["JWT filter<br/>[JwtAuthFilter.java]"]
  node_auth_controller["Auth endpoints"]
  node_auth_services["Auth services"]
  node_user_store["User repository"]
  node_refresh_store["Refresh-token repository"]
  node_postgres[("PostgreSQL")]
end

subgraph group_uploads["Song uploads"]
  node_song_controller["Song upload endpoint"]
  node_s3_storage["S3 storage service"]
  node_song_store["Song repository"]
  node_s3[("AWS S3")]
end

subgraph group_analysis["Music discovery"]
  node_analysis["Frequency analysis<br/>[AnalysisQueue.java]"]
  node_book_match["Book matching"]
end

node_listener(("Listener"))

node_listener -->|"opens app"| node_app_entry
node_app_entry -->|"renders"| node_auth_ui
node_app_entry -->|"renders after login"| node_home
node_app_entry -->|"routes to upload"| node_upload_ui
node_auth_ui -->|"posts credentials"| node_auth_controller
node_auth_ui -->|"refreshes token"| node_auth_controller
node_home -->|"renders"| node_header
node_home -->|"renders"| node_sidebar
node_home -->|"renders songs"| node_song_card
node_header -->|"renders graphics"| node_decor
node_upload_ui -->|"calls upload"| node_song_api
node_upload_ui -->|"renders"| node_header
node_song_api -->|"posts MP3"| node_song_controller
node_rate_filter -->|"checks requests"| node_rate_limiter
node_rate_limiter -->|"runs token bucket"| node_redis
node_jwt_filter -->|"protects routes"| node_auth_controller
node_auth_controller -->|"delegates auth"| node_auth_services
node_auth_services -->|"uses repository"| node_user_store
node_auth_services -->|"uses repository"| node_refresh_store
node_user_store -->|"persists users"| node_postgres
node_refresh_store -->|"persists tokens"| node_postgres
node_song_controller -->|"stores audio"| node_s3_storage
node_song_controller -->|"saves metadata"| node_song_store
node_s3_storage -->|"uploads audio"| node_s3
node_song_store -->|"persists metadata"| node_postgres
node_song_controller -.->|"may enqueue analysis"| node_analysis
node_analysis -.->|"may inform matching"| node_book_match

click node_app_entry "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/main.jsx"
click node_auth_ui "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/App.jsx"
click node_home "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Homepage.jsx"
click node_header "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Header.jsx"
click node_sidebar "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Sidebar.jsx"
click node_song_card "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Songcard.jsx"
click node_decor "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Decor.jsx"
click node_styles "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Styles.jsx"
click node_upload_ui "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/UploadPage.jsx"
click node_song_api "https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/api/songApi.js"
click node_rate_filter "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RateLimitFilter.java"
click node_rate_limiter "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RateLimiterService.java"
click node_jwt_filter "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/JwtAuthFilter.java"
click node_auth_controller "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/auth/api/AuthController.java"
click node_auth_services "https://github.com/sandinacharles1/sandinify/tree/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify"
click node_user_store "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/UserRepository.java"
click node_refresh_store "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RefreshTokenRepository.java"
click node_song_controller "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/SongUploadController.java"
click node_s3_storage "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/S3StorageService.java"
click node_song_store "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/SongRepository.java"
click node_analysis "https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/AnalysisQueue.java"
click node_book_match "https://github.com/sandinacharles1/sandinify/tree/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs"

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_entry,node_auth_ui,node_home,node_header,node_sidebar,node_song_card,node_decor,node_styles,node_upload_ui,node_song_api toneBlue
class node_rate_filter,node_rate_limiter,node_redis,node_jwt_filter,node_auth_controller,node_auth_services,node_user_store,node_refresh_store,node_postgres toneAmber
class node_song_controller,node_s3_storage,node_song_store,node_s3 toneMint
class node_analysis,node_book_match toneRose
class node_listener toneIndigo
```

## Components

### Music app interface

- [App entry](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/main.jsx): `user_management/frontend/src/main.jsx`
- [Sign-in UI](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/App.jsx): `user_management/frontend/src/App.jsx`
- [Music homepage](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Homepage.jsx): `user_management/frontend/src/home_page/Homepage.jsx`
- [Navigation header](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Header.jsx): `user_management/frontend/src/home_page/Header.jsx`
- [Playlist sidebar](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Sidebar.jsx): `user_management/frontend/src/home_page/Sidebar.jsx`
- [Song cards](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Songcard.jsx): `user_management/frontend/src/home_page/Songcard.jsx`
- [Page decoration](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Decor.jsx): `user_management/frontend/src/home_page/Decor.jsx`
- [Page styling](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/Styles.jsx): `user_management/frontend/src/home_page/Styles.jsx`
- [Upload form](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/home_page/UploadPage.jsx): `user_management/frontend/src/home_page/UploadPage.jsx`
- [Song API client](https://github.com/sandinacharles1/sandinify/blob/main/user_management/frontend/src/api/songApi.js): `user_management/frontend/src/api/songApi.js`

### Identity and access

- [Rate-limit filter](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RateLimitFilter.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RateLimitFilter.java`
- [Rate limiter](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RateLimiterService.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RateLimiterService.java`
- **Redis**
- [JWT filter](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/JwtAuthFilter.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/JwtAuthFilter.java`
- [Auth endpoints](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/auth/api/AuthController.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/auth/api/AuthController.java`
- [Auth services](https://github.com/sandinacharles1/sandinify/tree/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify`
- [User repository](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/UserRepository.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/UserRepository.java`
- [Refresh-token repository](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RefreshTokenRepository.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/RefreshTokenRepository.java`
- **PostgreSQL**

### Song uploads

- [Song upload endpoint](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/SongUploadController.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/SongUploadController.java`
- [S3 storage service](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/S3StorageService.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/S3StorageService.java`
- [Song repository](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/SongRepository.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/SongRepository.java`
- **AWS S3**

### Music discovery

- [Frequency analysis](https://github.com/sandinacharles1/sandinify/blob/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/AnalysisQueue.java): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs/api/AnalysisQueue.java`
- [Book matching](https://github.com/sandinacharles1/sandinify/tree/main/user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs): `user_management/backend/server/sandinify/src/main/java/com/example/sandinify/songs`

### Other components

- **Listener**

## Connections

- Listener → App entry: opens app (evidence: `user_management/frontend/src/main.jsx`)
- App entry → Sign-in UI: renders (evidence: `user_management/frontend/src/main.jsx`)
- App entry → Music homepage: renders after login (evidence: `user_management/frontend/src/main.jsx`)
- App entry → Upload form: routes to upload (evidence: `user_management/frontend/src/main.jsx`)
- Sign-in UI → Auth endpoints: posts credentials (evidence: `user_management/frontend/src/App.jsx`)
- Sign-in UI → Auth endpoints: refreshes token (evidence: `user_management/frontend/src/App.jsx`)
- Music homepage → Navigation header: renders (evidence: `user_management/frontend/src/home_page/Homepage.jsx`)
- Music homepage → Playlist sidebar: renders (evidence: `user_management/frontend/src/home_page/Homepage.jsx`)
- Music homepage → Song cards: renders songs (evidence: `user_management/frontend/src/home_page/Homepage.jsx`)
- Navigation header → Page decoration: renders graphics (evidence: `user_management/frontend/src/home_page/Header.jsx`)
- Upload form → Song API client: calls upload (evidence: `user_management/frontend/src/home_page/UploadPage.jsx`)
- Upload form → Navigation header: renders (evidence: `user_management/frontend/src/home_page/UploadPage.jsx`)
- Song API client → Song upload endpoint: posts MP3 (evidence: `README.md`)
- Rate-limit filter → Rate limiter: checks requests (evidence: `README.md`)
- Rate limiter → Redis: runs token bucket (evidence: `README.md`)
- JWT filter → Auth endpoints: protects routes (evidence: `README.md`)
- Auth endpoints → Auth services: delegates auth (evidence: `README.md`)
- Auth services → User repository: uses repository (evidence: `README.md`)
- Auth services → Refresh-token repository: uses repository (evidence: `README.md`)
- User repository → PostgreSQL: persists users (evidence: `README.md`)
- Refresh-token repository → PostgreSQL: persists tokens (evidence: `README.md`)
- Song upload endpoint → S3 storage service: stores audio (evidence: `README.md`)
- Song upload endpoint → Song repository: saves metadata (evidence: `README.md`)
- S3 storage service → AWS S3: uploads audio (evidence: `README.md`)
- Song repository → PostgreSQL: persists metadata (evidence: `README.md`)
- Song upload endpoint → Frequency analysis: may enqueue analysis
- Frequency analysis → Book matching: may inform matching
