How hiandbye-1/linkflow works
LinkFlow is a Spring Boot link-management backend. Its primary workflow is an authenticated user submitting a URL, the API validating and shortening it, and a public redirect resolving the short code. Separate branches cover registration and sessions, email verification, employee records, and the documented security and analytics capabilities. The graph follows sampled calls and SOURCE INDEX references; click-tracking internals and some security wiring were not sampled, so their relationships are left out where unsupported.
Main entry points: UrlShortenerService.java Shortener · EmailVertificationService.java Email verification · NormalUserRepository.java User records · NormalUserController.java User API
Components 27
Link management
- Link API
src/main/java/Jar/url/controller/UrlMappingController.java - Shortener
src/main/java/Jar/url/service/UrlShortenerService.java - Code generator
src/main/java/Jar/util/ShortCodeGenerator.java - Link mappings
src/main/java/Jar/url/repository/UrlMappingRepository.java - Link record
src/main/java/Jar/url/entities/UrlMapping.java
Identity and verification
- User API
src/main/java/Jar/auth/controller/NormalUserController.java - Registration
src/main/java/Jar/auth/service/NormalUserService.java - Session and profile
src/main/java/Jar/auth/service/AuthenticationService.java - User records
src/main/java/Jar/auth/repository/NormalUserRepository.java - User account
src/main/java/Jar/auth/entities/NormalUser.java - Email verification API
src/main/java/Jar/auth/controller/EmailController.java - Email verification
src/main/java/Jar/auth/service/EmailVertificationService.java - Temporary email records
src/main/java/Jar/auth/repository/TempEmailRepository.java - Verification record
src/main/java/Jar/auth/entities/TempEmails.java
Employee operations
- Employee API
src/main/java/Jar/employee/controller/EmployeeController.java - Employee service
src/main/java/Jar/employee/service/EmployeeService.java - Employee records
src/main/java/Jar/employee/repository/EmployeeRepository.java - Employee record
src/main/java/Jar/employee/entities/Employee.java - Click tracking
src/main/java/Jar/analytics/service/ClickTrackingService.java
Platform services
- Input validation
src/main/java/Jar/InputValidator/InputValidator.java - Security policy
src/main/java/Jar/security/SecurityConfig.java - User details lookup
src/main/java/Jar/security/UserDetailService.java - CSRF endpoint
src/main/java/Jar/security/controller/CSRFController.java - Exception handling
src/main/java/Jar/exception/GlobalExceptionHandler.java
Other components
- User
- MySQL
- SMTP mail service
Connections 28
- User → Link API: submits URL
README.md - Link API → Shortener: delegates to
src/main/java/Jar/url/controller/UrlMappingController.java - Shortener → Input validation: validates URL
src/main/java/Jar/url/service/UrlShortenerService.java - Shortener → Code generator: generates code
src/main/java/Jar/url/service/UrlShortenerService.java - Shortener → User records: looks up owner
src/main/java/Jar/url/service/UrlShortenerService.java - Shortener → Link mappings: saves and resolves
src/main/java/Jar/url/service/UrlShortenerService.java - Link mappings → Link record: persists
src/main/java/Jar/url/repository/UrlMappingRepository.java - User → Link API: requests redirect
README.md - Shortener → User: returns destination
README.md - User → User API: registers or logs in
README.md - User API → Registration: registers account
src/main/java/Jar/auth/controller/NormalUserController.java - User API → Session and profile: authenticates and profiles
src/main/java/Jar/auth/controller/NormalUserController.java - Registration → Input validation: validates credentials
src/main/java/Jar/auth/service/NormalUserService.java - Registration → User records: checks and saves
src/main/java/Jar/auth/service/NormalUserService.java - User records → User account: loads and stores
src/main/java/Jar/auth/repository/NormalUserRepository.java - Security policy → User details lookup: configures lookup
src/main/java/Jar/security/SecurityConfig.java - User details lookup → User records: loads account
src/main/java/Jar/security/UserDetailService.java - User → CSRF endpoint: requests token
README.md - User → Email verification API: requests verification
src/main/java/Jar/auth/controller/EmailController.java - Email verification API → Email verification: delegates to
src/main/java/Jar/auth/controller/EmailController.java - Email verification → User records: loads and updates account
src/main/java/Jar/auth/service/EmailVertificationService.java - Email verification → Temporary email records: stores verification code
src/main/java/Jar/auth/service/EmailVertificationService.java - Temporary email records → Verification record: loads and stores
src/main/java/Jar/auth/repository/TempEmailRepository.java - Email verification → Input validation: validates email
src/main/java/Jar/auth/service/EmailVertificationService.java - Email verification → SMTP mail service: sends code
src/main/java/Jar/auth/service/EmailVertificationService.java - Employee API → Employee service: delegates to
src/main/java/Jar/employee/controller/EmployeeController.java - Employee service → Employee records: reads and writes
src/main/java/Jar/employee/service/EmployeeService.java - Employee records → Employee record: persists
src/main/java/Jar/employee/repository/EmployeeRepository.java