Compare commits

...

2 Commits

Author SHA1 Message Date
89e04d0d85 Update backend/src/main/resources/application.properties
.
2026-03-26 04:08:55 +00:00
282bffec76 Add backend/README.txt 2025-09-24 09:43:18 +00:00
2 changed files with 84 additions and 1 deletions

83
backend/README.txt Normal file
View File

@@ -0,0 +1,83 @@
# AuthSec Spring Boot Backend - Feature Inventory
This README summarizes what is already implemented in the attached Spring Boot backend codebase, with exact file locations for quick navigation.
---
## Application Bootstrapping
- Main application entry:
- src/main/java/com/realnet/RealNetApp.java
- Enables Swagger2, JPA Auditing, Transaction Management, Caching
- Standard SpringBootServletInitializer + main()
## Configuration
- Application properties (ports, static resources, DB, mail, OAuth2, file upload, JWT):
- src/main/resources/application.properties
- server.port=9292
- spring.resources.static-locations for serving web assets
- MySQL datasource and Hibernate (ddl-auto=update)
- Mail sender configuration
- OAuth2 client registrations (Google, LinkedIn) scaffolding
- JWT token secret/expiry and authorized redirect URIs
- Multipart upload limits
- Logging banner:
- src/main/resources/banner_txt.txt
- Static web assets (Swagger UI, Redoc, compiled JS/CSS under public/):
- src/main/resources/public/**
## Database Artifacts
- Schema and seed (NorthWind-like demo + RN tables):
- src/main/resources/schema.sql
- Creates schemas/tables: user, customers, employees, orders, order_items, products
- Views: order_info, order_details, customer_orders, employee_orders
- Extra demo tables: RN_INSTRUCTOR, RN_EXT_FIELD_T
- Optional data seed:
- src/main/resources/data.sql (present)
## Gaurav_testing Module (CRUD example)
- REST Controller:
- src/main/java/com/realnet/Gaurav_testing/Controllers/Gaurav_testing_Controller.java
- Base path: /Gaurav_testing
- Endpoints:
- POST /Gaurav_testing → create
- GET /Gaurav_testing → list all
- GET /Gaurav_testing/{id} → get by id
- PUT /Gaurav_testing/{id} → update by id
- DELETE /Gaurav_testing/{id} → delete by id
- GET /Gaurav_testing_custom → first record (custom)
- POST /Gaurav_testing_custom → create (custom subset)
- Service layer:
- src/main/java/com/realnet/Gaurav_testing/Services/Gaurav_testing_Service.java
- Business logic for CRUD + custom methods (findTopByOrderByIdAsc, selective save)
- Repository layer:
- src/main/java/com/realnet/Gaurav_testing/Repository/Gaurav_testing_Repository.java
- Extends JpaRepository<Gaurav_testing_t, Integer>
- Finder: findTopByOrderByIdAsc()
- Entity:
- src/main/java/com/realnet/Gaurav_testing/Entity/Gaurav_testing_t.java
- JPA @Entity with fields: id, name, email, mobno, address, pincode, description
- Lombok @Data for boilerplate
## Swagger / API Docs
- Swagger UI + assets are available under:
- src/main/resources/public/swagger/**
- Swagger is enabled via @EnableSwagger2 in RealNetApp.
## Security (Status)
- No explicit Spring Security config class detected in the attached folder.
- application.properties contains OAuth2 and JWT settings scaffolding; enable and wire security beans to activate.
## Build Outputs (for reference only)
- Compiled assets and classes under target/** (not source of truth).
---
## Quick Start
1. Configure database credentials in src/main/resources/application.properties
2. mvn spring-boot:run (or run RealNetApp from your IDE)
3. API base URL: http://localhost:9292/
4. Swagger UI: http://localhost:9292/swagger/index.html or /public/swagger/index.html
## Notes
- Static UI is served from classpath:/public by default; adjust spring.resources.static-locations if needed.
- To enable security, add Spring Security configuration (filters, providers) and verify OAuth2/JWT property usage.

View File

@@ -23,7 +23,7 @@ System.Net.ServicePointManager.Expect100Continue = false;
spring.datasource.url=jdbc:mysql://realnet.cdas4e08uugj.us-east-1.rds.amazonaws.com:3306/realnet_CNSBENEW?createDatabaseIfNotExist=true spring.datasource.url=jdbc:mysql://realnet.cdas4e08uugj.us-east-1.rds.amazonaws.com:3306/realnet_CNSBENEW?createDatabaseIfNotExist=true
spring.datasource.username=cnsdev spring.datasource.username=cnsdev
spring.datasource.password=cnsdev1234 spring.datasource.password=cnsdev7304
spring.datasource.driverClassName = com.mysql.cj.jdbc.Driver spring.datasource.driverClassName = com.mysql.cj.jdbc.Driver