ZeroHunger
Project Overview & Feature Specification
ZeroHunger is a full-stack web application designed to bridge the gap between excess food
and those in need. Built entirely on the Java MVC (Model-View-Controller) architecture, the
platform connects Food Donors (individuals and corporations) with NGOs. It provides a secure,
real-time ecosystem where donors can post available food, and NGOs can claim and manage
the logistics of picking up those donations before they expire.
Technical Stack
• Frontend (View): JSP (JavaServer Pages), HTML5, CSS3 (Custom Minimalist #002630
Theme).
• Backend (Controller & Model): Advanced Java (Servlets, POJOs), HTTP Session
Management.
• Database (Data Layer): MySQL, connected via JDBC using Data Access Objects (DAOs).
• Server Deployment: Apache Tomcat v10.1.
Core System Features
1. Secure Authentication & Session Management
• Role-Based Registration: Users must register as a specific entity type (DONOR or NGO).
• Smart Login Routing: The system authenticates credentials against the MySQL database and
generates a secure HTTP Session. It automatically routes Donors to their donation history and
NGOs to the live food board.
• Session Protection: Secure pages (dashboards, posting forms) cannot be accessed via direct
URL manipulation without an active, validated session.
2. Synchronized Multi-Table Database Engine
• Complex Transactions: System actions automatically sync across multiple database tables.
(e.g., When an NGO updates a delivery status, the Java backend simultaneously updates the
Claims table for the NGO and the Food_Posts table for the Donor).
Donor Features (Creation & Tracking)
1. Seamless Food Posting
• Donors can quickly submit a food donation form specifying the food type (Veg, Non-Veg, Dry
Ration), quantity, prepared time, and expiry time.
• Includes a strict 150-character "Description" field to ensure NGOs receive concise, precise
details regarding the food's contents.
2. Real-Time Donor Dashboard
• A dedicated command center where donors can view a history of all their posted food.
• Live Status Tracking: Donors can watch the status of their food transition in real-time from
OPEN to CLAIMED, to PICKED_UP, and finally COMPLETED as the NGO processes the delivery.
NGO Features (Discovery & Logistics)
1. Urgent-First Food Board
• A live, dynamic dashboard displaying all OPEN food donations across the city.
• Smart Sorting: The backend automatically executes SQL sorting to push food with the nearest
expiry time to the very top of the list, ensuring urgent donations are seen and claimed first.
2. One-Click Claim System
• NGOs can claim a food post with a single click.
• Concurrency Protection: The moment a food item is claimed, it is instantly removed from the
public Food Board for all other NGOs, completely preventing double-booking or
miscommunication.
3. Delivery Logistics Dashboard
• A private dashboard where the logged-in NGO can track all the food they have successfully
claimed.
• Lifecycle Management: NGOs can click action buttons to update the physical status of the
food. Changing a status to PICKED_UP or COMPLETED instantly reflects on the respective
Donor's dashboard to complete the communication loop.