How ssaisriharsha/cloud-storage works
Project type and purpose
• This is a standalone, monolithic backend service built on Spring Boot that provides REST-based cloud-storage functionality: user registration/login (JWT auth), file upload/download, metadata storage in a relational database, and in-filesystem (or pluggable) file persistence.
File structure
• Top level
• pom.xml, mvnw/mvnw.cmd: Maven wrapper and dependencies
• src/main/java/com/ssaisriharsha/cloud_storage: application root
• src/main/resources: three profiles (dev, test, default)
• Controllers
• AuthController: handles /auth endpoints
• FileHandlingController: handles /files endpoints
• DTOs: payload objects for user signup/login
• Entities: JPA-mapped classes (User, DataFile, AccessTable, FileStatus)
• Repos: Spring Data JPA interfaces (UserRepo, FileRepo)
• Services: business logic
• AuthService, JwtService
• ParentStorageService with two implementations (DbStorageService, FileSystemStorageService)
• SecurityConfig:
• Config: WebSecurityConfigurer with JwtAuthenticationFilter
• Permissions, SecureUser (UserDetails wrapper)
• Exception handling: ControllerAdvice and custom exceptions (e.g. PathTraversalException)
Key insights (README is empty)
• All logic lives in a single Spring Boot application
• Uses JWT for stateless auth
• Persistence layer split between RDBMS (metadata) and filesystem (payload)