The application is deployed and running at: https://online-store-49w9.onrender.com/
This is an Online Store web application built using Java and the Spring Framework. The application provides functionality for customers, shopkeepers, and delivery personnel to interact with the system. It follows a layered architecture with controllers, services, DAOs, and entities. The frontend is implemented using JSP, while the backend leverages Spring MVC and Hibernate. The database is hosted on Aiven PostgreSQL for reliable cloud-based storage.
-
Clone the repository:
git clone git@github.com:Nadim-Mahmud/online-store.git cd online-store -
Build the project using Gradle:
gradle clean build
-
Start the application using Docker (Tomcat container):
docker compose up tomcat
-
Access the application at:
http://localhost:8080
- Can create and manage all user accounts (Admin, Shopkeeper, Deliveryman, User).
- Can add categories, tags, and items to the store.
- Has full control over store configuration.
- Can view orders placed by users.
- Approves orders if they are valid and items are available.
- Cancels orders if they cannot be processed.
- Views orders approved by Shopkeepers.
- Updates delivery status by delivering items or canceling delivery if necessary.
- Can browse available items by category, tag, or search.
- Places orders for desired items.
- Tracks the status of their orders (Pending, Approved, Delivered, Canceled).
The application comes with pre-configured users for testing:
- Admin:
ndm@gmail.com/ndm123 - User:
us@gmail.com/ndm123 - Shopkeeper (example):
sk@gmail.com/ndm123 - Deliveryman (example):
dm@gmail.com/ndm123
Note: Multiple Shopkeepers and Deliverymen can be created by the Admin.
- Secure login and registration system.
- Role-based authentication for customers, shopkeepers, and delivery personnel.
- Profile management with password updates and personal details.
- Shopkeepers can add, update, and remove products.
- Products can be categorized for easy navigation.
- Customers can browse and filter products by category and tags.
- Customers can place orders and provide delivery details.
- Shopkeepers can process and manage incoming orders.
- Delivery personnel can track and update order statuses.
- Customers can add items to the cart before proceeding to checkout.
- Order summary is displayed before final confirmation.
- Secure payment processing integration (future scope).
- Input validation for user registration, order details, and form submissions.
- Custom exception handling for better error management.
- Secure password storage using encryption.
- Protection against common web vulnerabilities (e.g., SQL injection, CSRF, XSS).
- Role-based access control to prevent unauthorized actions.
- Backend: Java, Spring MVC, Hibernate
- Frontend: JSP, JavaScript, CSS
- Database: PostgreSQL hosted on Aiven
- Build Tool: Gradle
- Containerization: Docker, Tomcat
- Security: Encryption utilities, authentication filters
.
├── README.md
├── build.gradle
├── settings.gradle
├── db-migration (Database migration scripts)
│ ├── dml.sql
│ └── pre-ddl.sql
├── src
│ ├── main
│ │ ├── java
│ │ │ └── net.therap.onlinestore
│ │ │ ├── controller (Handles HTTP requests)
│ │ │ ├── entity (Database entities)
│ │ │ ├── service (Business logic implementation)
│ │ │ ├── exception (Custom exception handling)
│ │ │ ├── filter (Authentication and request filters)
│ │ │ ├── helper (Utility classes for various functions)
│ │ │ ├── validator (Input validation rules)
│ │ ├── resources
│ │ │ ├── application.properties (Configuration settings)
│ │ │ ├── log4j.properties (Logging configuration)
│ │ │ ├── messages.properties (Internationalization support)
│ │ │ ├── META-INF/persistence.xml (Database configuration)
│ │ ├── webapp
│ │ ├── WEB-INF (Spring MVC and JSP configuration)
│ │ ├── assets (CSS, JavaScript, and images)