Follow these steps to start all backend services and the frontend application.
- Java 17 or higher
- Node.js and npm
- Maven
- MySQL Server
Ensure your MySQL server is running with the following settings:
- Database:
Training - User:
root - Password:
Root123$
You can create the database using the following SQL command:
CREATE DATABASE IF NOT EXISTS Training;Infrastructure services must be started first for discovery and routing.
- Directory:
oss-backend/eureka-server - Command:
mvn spring-boot:run - Port: 8761
- Directory:
oss-backend/api-gateway - Command:
mvn spring-boot:run - Port: 9090
Run each of these in a separate terminal window.
- Directory:
oss-backend/user-service - Command:
mvn spring-boot:run - Port: 8089
- Directory:
oss-backend/product-catalog - Command:
mvn spring-boot:run - Port: 8082
- Directory:
oss-backend/cart-service - Command:
mvn spring-boot:run - Port: 8085
- Directory:
oss-backend/order-management-master - Command:
mvn spring-boot:run - Port: 8084
- Directory:
oss-backend/payment-processing-service-master - Command:
mvn spring-boot:run - Port: 8765
- Directory:
oss-frontend - Command:
npm start - URL: http://localhost:4200
- Eureka Dashboard: Access http://localhost:8761 to see all services registered and "UP".
- Frontend: Access http://localhost:4200 to start using the application.
If you encounter "Port already in use" errors:
- Linux:
fuser -k <PORT>/tcp - Windows:
taskkill /F /PID $(netstat -ano | findstr :<PORT> | awk '{print $5}')