How hemant19singh/uberapp works
Project type and purpose
• This is a Spring Boot backend monolith (“UberApp”) that exposes REST endpoints for a ride-sharing service. It uses Postgres + PostGIS for spatial queries, JWT for security, and external services (OSRM for routing, SMTP for email).
File-structure analysis
• Top-level: pom.xml, src/main/java, src/main/resources.
• Packages under com.codingshuttle.project.uber.uberApp:
• controllers – REST controllers (Auth, Rider, Driver)
• dto – input/output data transfer objects
• entities – JPA entities (User, Rider, Driver, Ride, Wallet, etc.)
• repositories – Spring Data JPA interfaces to Postgres
• services – business-logic interfaces; impl subpackage holds implementations
• strategies – strategy interfaces and implementations for driver matching, fare-calculation, payment
• configs – MapperConfig, SecurityConfig, WebSecurityConfig
• security – JWT filter and service
• advices – global exception/response handlers
• utils – helper classes (e.g., GeometryUtil)
• src/main/resources holds application-*.properties and data.sql.
• Tests mirror the service layer.
README insights
• Core features: user signup/role assignment, ride request → ride creation, two matching strategies (rating, distance), two fare strategies (default, surge), two payment modes (wallet, cash), email notifications on ride start, ratings, wallet.