A Java console application integrated with PostgreSQL for managing restaurants, customers, delivery personnel, products, and orders.
- Overview
- Features
- Project Requirements
- Technologies
- Repository Structure
- Project Architecture
- Database
- Documentation
- How to Run
- Usage
- Future Improvements
- License
- About Me
The Restaurant Delivery Management System is a Java console application designed to manage the core operations of a food delivery service. The project integrates Java with PostgreSQL through JDBC, applying object-oriented programming principles alongside relational database design.
The system models a real-world delivery environment with the following main actors:
- Customers can register, manage their personal information, and place orders from participating restaurants.
- Restaurants can manage their products, monitor incoming orders, and maintain their business information.
- Delivery Personnel are responsible for delivering orders and can be assigned to deliveries based on their availability.
The project follows a layered architecture that separates the application into distinct packages for business logic, database access, entities, user interface, and application execution. It also includes comprehensive database documentation, UML diagrams, and SQL scripts for database creation, sample data insertion, and analytical queries.
- Create and manage customer accounts
- Update personal information
- Register delivery addresses
- Browse restaurant products
- Place orders from a single restaurant
- View order history and order status
- Manage restaurant information
- Add, update, and remove products
- Manage product inventory and pricing
- View and update customer orders
- Add, update, and remove delivery personnel
- Assign available delivery personnel to orders
- View assigned deliveries
- Update delivery status
The objective of this project is to develop a food delivery management system using Java and PostgreSQL, integrating object-oriented programming concepts with a relational database.
- Manage customers, restaurants, products, delivery personnel, and orders.
- Perform full CRUD operations for all system entities.
- Associate products with restaurants.
- Allow customers to place orders containing multiple products.
- Assign available delivery personnel to orders.
- Track order status through the delivery process.
- Store and retrieve all application data using PostgreSQL.
- Developed using Java following object-oriented programming principles.
- Uses PostgreSQL as the relational database.
- Connects to the database through JDBC.
- Implements relational modeling with one-to-many and many-to-many relationships.
- Includes SQL queries using JOIN, aggregation functions, and window functions.
- Provides complete project documentation, including architecture, class, and database diagrams.
When assigning a delivery person to an order, the system verifies whether the delivery person is available. If available, the order is assigned and the delivery person's status is updated accordingly.
| Category | Technologies |
|---|---|
| Programming Language | Java |
| Database | PostgreSQL |
| Database Connectivity | JDBC |
| Development Tools | Eclipse IDE, Visual Studio Code |
| Database Management | pgAdmin |
| Documentation & Diagrams | Draw.io, Dia |
| Version Control | Git, GitHub |
The repository follows this structure:
restaurant_ordering_system/
βββ database/ # Database scripts
β βββ analysis_queries/ # SQL queries for reports and data analysis
β βββ archive/ # Archived script versions
β βββ 01_init_database.sql # Database creation script
β βββ 02_create_database_tables.sql # Table definitions and constraints
β βββ 03_insert_sample_data.sql # Sample data for testing
β
βββ docs/ # Project documentation
β βββ application/
β β βββ class_diagram/ # UML class diagrams
β β βββ images/ # Usage images
β β βββ old_system_overview_prototype/ # Legacy project references
β β βββ package_architecture/ # Application architecture diagrams
β β βββ naming_conventions.md # Java naming conventions
β β
β βββ database/
β βββ entity_relationship_diagram/ # Database ER diagrams
β βββ data_dictionary.md # Database data dictionary
β βββ naming_conventions.md # Database naming conventions
β
βββ java/
β βββ DeliveryManagementSystem/
β βββ lib/ # External libraries
β βββ src/
β βββ application/
β βββ database/
β βββ entities/
β βββ services/
β βββ ui/
β βββ view/
β
βββ .gitignore # Git ignore rules
βββ LICENSE # Project license
βββ README.md # Project overview and setup guide
The application follows a layered architecture that separates responsibilities into distinct packages, improving code organization, maintainability, and scalability.
Each layer is responsible for a specific part of the system, including application startup, database access, business logic, domain entities, and user interaction.
This separation of concerns promotes a modular design and simplifies future development and maintenance.
The system uses PostgreSQL as its relational database management system. The database was designed to represent the core entities of a food delivery platform, including customers, restaurants, products, delivery personnel, and orders.
The database follows a normalized relational model with one-to-many and many-to-many relationships to ensure data consistency and avoid redundancy. It includes tables for managing business data, customer information, product availability, order details, and delivery assignments.
The project also includes SQL scripts for database creation, table definitions, sample data insertion, and analytical queries using joins, aggregations, and other SQL features.
This repository includes detailed documentation covering the system design, database structure, and development decisions.
Available documentation:
-
Application Architecture
Overview of the system layers, package organization, and application structure. -
UML Class Diagrams
Diagrams representing the application's classes, attributes, methods, and relationships. -
Entity Relationship Diagram (ERD)
Visual representation of the database entities, relationships, and constraints. -
Data Dictionary
Detailed description of database tables, columns, data types, and relationships.
Before running the application, make sure the following tools are installed:
- Java JDK 8+
- PostgreSQL
- pgAdmin (optional, for database management)
- Eclipse IDE or another Java IDE
- Create the PostgreSQL database using the script:
database/01_init_database.sql
- Create the required tables:
database/02_create_database_tables.sql
- Insert sample data (optional):
database/03_insert_sample_data.sql
- Verify that the database is running correctly.
- Clone this repository:
git clone https://github.com/Rodrigo3441/restaurant_ordering_system.git- Open the Java project located in:
java/DeliveryManagementSystem/
-
Configure the PostgreSQL connection settings in the
DatabaseConnectionclass inside database package. -
Make sure the PostgreSQL JDBC driver is available in the project libraries.
- Open the project in your Java IDE.
- Build the project.
- Run the main application class:
application.Main
The application will start through the console interface and allow interaction with the restaurant delivery system.
-
After starting the application, users can interact with the system through a console-based menu interface.
-
The application communicates with PostgreSQL through JDBC to store and retrieve all system data.
Possible improvements and future expansions for this project include:
- Implement a complete authentication system with secure password encryption.
- Develop a graphical user interface (GUI) or a web-based version of the application.
- Expand product management by adding product categories and advanced filtering options.
- Improve the order tracking system with more detailed delivery progress updates.
- Enhance exception handling and validation throughout the application.
- Add automated testing to improve reliability and maintainability.
This project is licensed under the MIT License. You are free to use, modify, and share this project with proper attribution.
Hi! i'm Rodrigo, a data engineer student that is learning new things every day.




