Fashion Vista is an e-commerce web application designed to provide a seamless shopping experience for users. This project includes services for managing products, user accounts, carts, orders, and wishlists, all secured with JWT authentication.
The frontend of the application is developed using:
- ReactJS: For building the user interface with reusable components.
- Redux: For state management across the application.
- Axios: For making HTTP requests to interact with the backend services.
- React Router: For handling routing and navigation within the application.
The backend is designed with a microservices architecture and includes the following components:
-
Product Service
- Database: MongoDB
- Responsibilities: Manages product data, including CRUD operations on products.
-
User Service
- Database: MySQL
- Responsibilities: Handles user registration, login, and authentication.
-
Wishlist Service
- Database: MySQL
- Responsibilities: Manages user wishlists.
-
Cart Service
- Database: MySQL
- Responsibilities: Manages cart operations.
-
Order Service
- Database: MySQL
- Responsibilities: Handles order creation and retrieval.
- Port: 8090
- Responsibilities: Acts as a single entry point for all client requests, routing them to the appropriate microservices. Ensures centralized management of cross-cutting concerns such as security, logging, and routing.
- Netflix Eureka: Used for service discovery and registration, allowing services to locate and communicate with each other dynamically.
-
FeignClient:
- User Service: FeignClient is used to make RESTful calls to the Product Service to fetch product details, ensuring the User Service can access up-to-date product information.
- Cart Service: FeignClient is also used to post orders to the Order Service, facilitating the creation of new orders based on the cart's contents.
-
DTO Architecture: Data Transfer Objects (DTOs) are used to transfer data between layers and services, ensuring a clear separation of concerns and reducing data coupling.
- Java 11 or later
- Node.js and npm
- MongoDB
- MySQL
- Spring Boot
- Eureka Server
- Spring Cloud Gateway
-
Clone the repository
git clone https://github.com/kothakokila/fashion-vista.git cd fashion-vista
-
Backend Setup
- Navigate to each microservice directory and install dependencies:
cd CartService mvn clean install cd ../OrderService mvn clean install cd ../ProductService mvn clean install cd ../UserService mvn clean install cd ../WishlistService mvn clean install cd ../Service_Registry mvn clean install cd ../FashionVistaGateway mvn clean install
-
Frontend Setup
- Navigate to the frontend directory and install dependencies:
cd user_interface npm install
-
Start the Eureka Server
cd Service_Registry mvn spring-boot:run
-
Start the Gateway
cd ../FashionVistaGateway mvn spring-boot:run
-
Start the Microservices
cd ../CartService mvn spring-boot:run cd ../OrderService mvn spring-boot:run cd ../ProductService mvn spring-boot:run cd ../UserService mvn spring-boot:run cd ../WishlistService mvn spring-boot:run
-
Start the Frontend
cd ../frontend npm start
Detailed API documentation can be found [here]):
- Backend: Java, Spring Boot, Spring Cloud, Spring Security, JWT
- Database: MongoDB, MySQL
- Frontend: React, Redux, Axios
- Other: Eureka Server, Spring Cloud Gateway