Skip to content
OnlyProjects
B.Tech / B.E. · Computer Science & EngineeringFor educational purposes only
Code included

Fair-Price Shop Stock, Entitlement & Distribution Register for a PDS Outlet (Java Servlets/JSP + MySQL)

Monthly entitlements, godown receipts, daily issue register and stock reconciliation for a ration shop — one ledger instead of four

Mapped to your syllabusAKTU NEP scheme (3rd yr 2024-25, 4th yr 2025-26) · BCS753 Project-I · Semester 7

Overview

1 min read

Fair-Price Shop Stock, Entitlement & Distribution Register (FPSR) is a web application for the fair-price (ration) shop that most Indian neighbourhoods depend on under the Targeted Public Distribution System. In a typical urban outlet serving 900–1,500 ration-card households, the dealer still runs the month on paper: a godown receipt book, an issue register signed per family, a wastage note and a stock book reconciled by hand at month end — with mismatches discovered only when supplies run out mid-month.

The system gives the shop two roles — the dealer (admin) and the sales clerk — one shared register built on Java Servlets, JSP and MySQL, exactly the stack the AKTU NEP syllabus teaches (BCS552 Web Technology Lab: Servlet/JSP, HTML/CSS/JS; BCS551 DBMS Lab: MySQL). Cardholders are recorded with an internal registry code and a category (Antyodaya AAY or Priority Household PHH); monthly per-person entitlements for wheat, rice, sugar and other commodities are configured per category as per NFSA norms. The clerk records daily issues against a cardholder's remaining entitlement; the system refuses any issue that would exceed the month's cap or the available stock, inside a single database transaction. Godown receipts and wastage adjustments keep the stock ledger current, and a month-end reconciliation report shows opening stock, receipts, issues, adjustments and closing stock per commodity.

It is deliberately scoped for a first major project — mostly CRUD with one real concurrency rule — but every screen defends a genuine operational need, which is what makes it viva-defensible.

Relevant for
Uttar Pradesh
Level
Beginner · 14 weeks · team of 2
Common at
Dr. A.P.J. Abdul Kalam Technical University, Savitribai Phule Pune University, Gujarat Technological University
Updated
Nov 2026

Syllabus alignment

AKTU · NEP scheme (3rd yr 2024-25, 4th yr 2025-26)

BCS753 · Project-I · Semester 7 · 5 credits · 150 sessional

Subjects this project applies
  • BCS551 DBMS Lab (MySQL / PL-SQL)
  • BCS552 Web Technology Lab (Servlet/JSP, HTML, CSS, JavaScript)
  • BCS651 Software Engineering Lab (UML with StarUML, JUnit, GanttProject)
  • Object-Oriented Programming with Java
How it is evaluated

See your department's project guidelines.

Also fits: SPPU 2019 Course (2024 NEP pattern rolling in), GTU 2018-19 pattern (NEP BE0x codes from 2024 admits), MAKAUT 2018 curriculum (mapping effective 2023-24).

What's in the box

11 parts · 5 free · 2 previewed · 4 unlock for ₹2,000

Problem & synopsis

5 min read

Problem statement

A fair-price shop serving over a thousand card households runs on four hand-written ledgers — godown receipts, the daily issue register, wastage notes and the month-end stock book. Because the ledgers are separate, the shop cannot tell at the counter how much of a household's monthly entitlement remains, and it cannot tell how much stock is truly on hand until the books are tallied. Over-issues are discovered late, stock-outs arrive mid-month, variances between the register and the godown invoice are explained on loose sheets, and preparing a report for the inspector means rewriting figures by hand.

There is a need for a single, role-based register that stores entitlement rules per card category, records every receipt, issue and adjustment as a database transaction, refuses any issue that breaks a stock or entitlement rule, and produces a month-end reconciliation and printable reports — built with the Servlets/JSP and MySQL skills the curriculum already teaches.

Synopsis

Abstract

Fair-price shops distribute subsidised foodgrains to ration-card households every day, yet the shop's own records are mostly hand-written. This project builds FPSR, a three-tier web application using Java Servlets, JSP and MySQL that maintains the shop's stock ledger, per-category monthly entitlements and the daily distribution register in one normalised database, with month-end reconciliation and CSV reports.

Introduction

A fair-price shop receives its monthly allocation from the FCI godown against an invoice, then issues fixed per-person quantities to AAY and Priority Household cardholders across the month. The dealer must answer three questions at any moment: how much stock is on hand, how much of a household's monthly entitlement has been used, and whether the two ledgers still agree. With paper registers, each answer needs manual arithmetic across four books, and a mid-month stock-out or an over-issue is found only after the damage.

Existing System

  • Godown receipts are pasted into a notebook; issues are entered in a register that each family signs.
  • Entitlement quantities for the month circulate on a notice or a messaging group and are applied from memory.
  • The stock book is tallied by hand at month end; variances are explained on a separate sheet.
  • Limitations: no single source of truth, arithmetic errors carried silently forward, no per-household usage history, no early warning before a stock-out, and no report the dealer can show an inspector without an evening of writing.

Proposed System

  • A normalised MySQL database for users, card categories, commodities, entitlements, cardholders, receipts, adjustments, distributions and month-end closings.
  • Issue transactions that atomically verify (a) the commodity's current stock and (b) the household's remaining monthly entitlement before inserting the issue.
  • A monthly entitlement matrix per category that the dealer edits when government norms change — no code change.
  • Month-end reconciliation (opening + receipts − issues − adjustments = closing) with a variance flag, and CSV exports for the inspector's visit.
  • Role-based access: dealer (admin) and clerk, with an application-level audit log of every insert and edit.

Feasibility Study

  • Technical: Servlets/JSP on Tomcat and MySQL are open-source, run on any laptop with 4 GB RAM, and are the exact tools of BCS552/BCS551, so the team already knows them. The only non-trivial logic — transactional issue checks — is well documented in the Connector/J manual.
  • Economic: zero licence cost; hosting is unnecessary because the shop's register is a local machine with a backup.
  • Operational: the issue screen is a single form (registry code → remaining entitlements → tick quantities → save) designed for a counter that serves a household in under two minutes. The dealer needs one 30-minute walkthrough.

Objectives

  1. 01Design a normalised (3NF) MySQL schema for card categories, commodities, entitlements, cardholders, receipts, adjustments, distributions and month-end closings.
  2. 02Implement dealer and clerk roles with salted-bcrypt passwords, an HttpSession-based login and a servlet filter that enforces role-based access on every URL.
  3. 03Enforce monthly per-person entitlements per category through an editable entitlement matrix that needs no code change when norms change.
  4. 04Make every distribution an atomic transaction that re-checks current stock and remaining monthly entitlement before committing the issue.
  5. 05Maintain the stock ledger from godown receipts and wastage adjustments, and compute month-end closing stock with a variance flag.
  6. 06Provide dashboards (stock position, today's issues, households served) and CSV exports for inspections.
  7. 07Write JUnit tests for the entitlement and reconciliation arithmetic and a black-box test-case table for every screen.

Scope

In scope

  • One fair-price shop with about 1,200 cardholders in two NFSA categories (AAY, Priority Household).
  • Four to eight commodities (wheat, rice, sugar, pulses, etc.) with unit and subsidised unit price.
  • Roles: Dealer (administrator) and Sales Clerk; every write audited.
  • Cardholder registry with internal registry code, category, member count and status; monthly entitlement matrix per category per commodity; receipt, wastage and issue entry; month-end reconciliation and variance report; CSV exports.
  • Demo data for two full months of receipts and issues.

Out of scope (v1)

  • Biometric/ePoS device integration or OTP-based beneficiary authentication.
  • Storage of any government identity numbers — the design deliberately uses an internal registry code instead of Aadhaar or ration-card numbers.
  • Multi-shop (ward- or district-level) deployment and godown-side stock transfer between shops.
  • Online payments or pricing beyond the subsidised unit price.
  • SMS/WhatsApp notifications to cardholders.

Methodology

The project follows the Incremental SDLC model: the register is built in three working increments, each passing through design, coding and testing, so a demonstrable version exists from week 5 onward — important because BCS753 sessional reviews happen mid-semester.

PhaseWeeksActivitiesDeliverable
Requirement analysis1–2Interview the dealer of a local fair-price shop, study the four ledgers, list functional and non-functional requirementsSRS v1.0
System design3ER diagram, DFD level 0/1, use-case and class diagrams (StarUML), database schema, UI wireframes, Gantt chartDesign document
Increment 14–6Schema, JDBC/DAO layer, authentication, roles, audit log, cardholder registryLogin + registry demo
Increment 27–9Entitlement matrix, stock receipts, wastage, distribution counter with transactional checksWorking issue counter
Increment 310–11Month-end reconciliation, dashboards, CSV reportsReconciliation report
Testing12–13JUnit suites, black-box test cases, dry run with two months of demo dataTest report
Documentation & deployment14Final report, PPT, deployment runbook for the shop's laptopBCS753 submission

Testing approach: JUnit 5 for the arithmetic core (entitlement remaining, reconciliation, variance flag) and DAO methods against a dedicated test database; black-box test cases (ID, input, expected, actual, status) for each screen, including the double-clerk concurrency case; and a two-month simulated month with seeded data whose totals are hand-computed first.

Architecture & tech stack

4 diagrams · 7 technologies · 3 min read

  • Java 17
  • Jakarta Servlets / JSP on Tomcat 10.1
  • MySQL 8
  • JDBC (MySQL Connector/J)
  • JSP Standard Tag Library (JSTL)
  • HTML/CSS/JavaScript
  • JUnit 5

FPSR follows the classic MVC three-tier architecture that BCS552 teaches, made concrete:

  1. Presentation (View) — JSP pages with JSTL and Expression Language render every screen; no business logic lives in JSPs. Plain HTML/CSS with a little JavaScript for form pre-checks keeps it phone-friendly.
  2. Controller — Jakarta Servlets map one URL pattern per use case (e.g. /issue, /receipts, /reconciliation). An AuthFilter runs before protected paths, checks the session and role, and forwards to login when absent.
  3. Model — a DAO layer over JDBC PreparedStatements performs all SQL, including the transactional issue check, so SQL never leaks into servlets or JSPs.
  4. Database — MySQL 8 with InnoDB tables and foreign keys; the issue transaction relies on InnoDB row locking to survive two clerks working at once.
flowchart TD
  B["Browser (JSP + JSTL views)"] -->|HTTP GET/POST| F["AuthFilter: session & role check"]
  F --> S["Servlet controllers (jakarta.servlet)"]
  S --> V["Form validation & business rules"]
  V --> DAO["DAO layer: JDBC PreparedStatement"]
  DAO --> DB[("MySQL 8: fps_ration")]
  S --> J["JSP views (JSTL, EL)"]
  J --> B
  DAO --> A[("audit_log table")]

ER diagram

erDiagram
  USER ||--o{ DISTRIBUTION : records
  CARD_CATEGORY ||--o{ CARDHOLDER : classifies
  CARD_CATEGORY ||--o{ ENTITLEMENT : "sets monthly limits for"
  COMMODITY ||--o{ ENTITLEMENT : "is limited by"
  CARDHOLDER ||--o{ DISTRIBUTION : receives
  DISTRIBUTION ||--|{ DISTRIBUTION_ITEM : contains
  COMMODITY ||--o{ DISTRIBUTION_ITEM : "is issued as"
  COMMODITY ||--o{ STOCK_RECEIPT : "is received as"
  COMMODITY ||--o{ STOCK_ADJUSTMENT : "is adjusted in"
  COMMODITY ||--o{ MONTH_CLOSING : "is reconciled in"
  USER ||--o{ AUDIT_LOG : writes

  USER {
    int id PK
    string username UK
    string password_hash
    string role
  }
  CARD_CATEGORY {
    string code PK
    string description
  }
  COMMODITY {
    int id PK
    string name
    string unit
    decimal unit_price
  }
  ENTITLEMENT {
    int id PK
    string category_code FK
    int commodity_id FK
    decimal qty_per_person_per_month
  }
  CARDHOLDER {
    int id PK
    string registry_code UK
    string category_code FK
    string head_of_household
    int members_count
    string address_note
    string status
  }
  STOCK_RECEIPT {
    int id PK
    int commodity_id FK
    decimal qty_received
    date received_on
    string invoice_ref
  }
  STOCK_ADJUSTMENT {
    int id PK
    int commodity_id FK
    decimal qty
    string reason
    date adjusted_on
  }
  DISTRIBUTION {
    int id PK
    int cardholder_id FK
    int issued_by FK
    datetime issued_at
  }
  DISTRIBUTION_ITEM {
    int id PK
    int distribution_id FK
    int commodity_id FK
    decimal qty_issued
  }
  MONTH_CLOSING {
    int id PK
    string month
    int commodity_id FK
    decimal opening
    decimal received
    decimal issued
    decimal adjusted
    decimal closing
  }
  AUDIT_LOG {
    int id PK
    int user_id FK
    string action
    datetime acted_at
  }

DFD — Level 0 (context diagram)

flowchart LR
  D([Dealer]) -- "entitlement rules, godown receipts, wastage" --> SYS(("Fair-Price Shop<br/>Register (FPSR)"))
  SYS -- "reconciliation, variance & stock reports" --> D
  C([Clerk]) -- "daily issue requests against cards" --> SYS
  SYS -- "remaining entitlement & stock position" --> C

Use-case diagram

flowchart LR
  D([Dealer])
  C([Clerk])
  subgraph FPSR["Fair-Price Shop Register"]
    UC1(Login)
    UC2(Manage cardholders & entitlements)
    UC3(Record godown receipts)
    UC4(Record wastage / adjustment)
    UC5(Issue commodities to a cardholder)
    UC6(View month-end reconciliation)
    UC7(Export CSV reports)
    UC8(View audit log)
  end
  D --- UC1 & UC2 & UC3 & UC4 & UC6 & UC7 & UC8
  C --- UC1 & UC5 & UC7

Modules

6 modules

  1. Module 01

    Module 1 — Authentication, Roles & Audit Log (Member 1)

    Login servlet with salted-bcrypt password verification, HttpSession with a 30-minute timeout, and an AuthFilter that guards /dealer/* and /clerk/* URL spaces by role. Every insert, update and delete writes a row to audit_log (user, action, entity, timestamp) so the dealer can answer 'who changed this?' — a question the paper register never answered.

  2. Module 02

    Module 2 — Cardholder Registry & Entitlement Matrix (Member 1)

    CRUD for cardholders (internal registry code, category, head of household, member count, active/suspended status) with server-side validation and pagination. The dealer maintains the entitlement matrix — quantity per person per month for each category–commodity pair — with an 'effective from month' column so a norms change applies from the next month without touching history.

  3. Module 03

    Module 3 — Stock Receipts & Adjustment Ledger (Member 2)

    Godown receipts are entered with invoice reference, commodity, quantity and date; wastage and other adjustments are entered with a reason code. Each entry updates the running stock view, and the module refuses receipts that would make any ledger total negative. A monthly stock-position screen shows on-hand quantity per commodity at any date.

  4. Module 04

    Module 4 — Daily Distribution (Issue) Counter (Member 2)

    The clerk enters a registry code, sees the household's remaining entitlement for the month side by side with available stock, ticks quantities and saves. The save runs in one InnoDB transaction: re-read stock, re-compute this month's issued total, and insert the distribution and its items only if every quantity fits both caps — otherwise roll back with a specific message ('exceeds monthly entitlement by 2 kg').

  5. Module 05

    Module 5 — Month-End Reconciliation, Dashboards & Reports (Member 1)

    A scheduled month-end job computes per commodity: opening stock, receipts, issues, adjustments and closing stock, flags any mismatch beyond a rounding tolerance as a variance, and snapshots it into month_closing. Dashboards show stock position, today's issues and households served; every report exports to CSV for the inspector's visit.

  6. Module 06

    Module 6 — Testing, Deployment & Documentation (Member 2)

    JUnit 5 suites for entitlement arithmetic, reconciliation and DAO methods against a test database; a black-box test-case table per screen including the two-clerk concurrency case; a deployment runbook (MySQL schema, WAR deployment on Tomcat 10.1); and the report chapters for implementation and testing.

Slides

12 slides · titles free · bullets, notes and the .pptx unlock

  1. Slide 1

    Fair-Price Shop Stock, Entitlement & Distribution Register

  2. Slide 2

    Motivation & Context

  3. Slide 3

    Problem Statement

  4. Slide 4

    Existing vs Proposed System

  5. Slide 5

    Objectives

  6. Slide 6

    Technology Stack & Justification

  7. Slide 7

    System Architecture (MVC)

  8. Slide 8

    Database Design

  9. Slide 9

    The Issue Transaction (core logic)

  10. Slide 10

    Demo

  11. Slide 11

    Testing

  12. Slide 12

    Conclusion & Future Scope

Bullets, speaker notes and the .pptx · ₹2,000

The titles above are the real outline. The rest is what you present from.

Unlock for ₹2,000

Viva questions & answers

3 of 17 answered free · 14 unlock

Read each answer, close it, and say it in your own words. Your viva will ask. Now you'll know.

  1. 01Concept

    Why did you build this with Servlets/JSP rather than Spring Boot?

    Servlets and JSP are what AKTU's BCS552 Web Technology Lab teaches, and at this scope they are enough: every request is a form post handled by one servlet, so we preferred a stack we can explain line by line in the viva over a framework that hides the request lifecycle. Spring Boot is a natural next step once the fundamentals are proven.

  2. 02Concept

    What is the difference between a Servlet and a JSP?

    A Servlet is a Java class that receives the request, runs logic and writes the response; a JSP is an HTML template that is itself compiled into a servlet and is meant for presentation. In our project the IssueServlet validates input and runs the transaction, then forwards to issue-receipt.jsp, which renders the result with JSTL tags.

  3. 03Concept

    Where is MVC in your project?

    The model is the DAO layer plus the MySQL schema, the view is the set of JSP/JSTL pages, and the controllers are the servlets plus the AuthFilter. Business rules like the stock and entitlement checks live only in the model layer, so the JSPs never touch SQL and the same DAO can be reused by a future REST API.

+14 more questions, with answers

Try the free ones out loud first. Your examiner will not accept “it's in the PPT”.

Source code & how to run

6 steps · complete source code · unlocks with the project

Unlocks with the project · ₹2,000

6 steps · source code zip

Prerequisites, install, seed data and tests, written for demo day. Plus the complete source.

Unlock for ₹2,000

READMEFIRST

269 words · unlocks with the project

What to change before it goes anywhere near a submission. Skipping it is how the demo fails live.

Unlocks with the project · ₹2,000

269 words · ~1 min read

The checklist of things to rename, re-seed and re-think so the project reads as yours.

Unlock for ₹2,000

Instructions

287 words · unlocks with the project

How to study it, adapt it and walk your examiner through it, step by step.

Unlocks with the project · ₹2,000

287 words · ~1 min read

Report structure, formatting rules and the submission checklist your department will grade.

Unlock for ₹2,000

References

10 sources

  1. Apache Tomcat 10.1 Documentation (Servlet 6.0 / JSP 3.1 container)
  2. Jakarta Servlet 6.0 Specification (Jakarta EE 10)
  3. MySQL Connector/J Developer Guide (JDBC driver)
  4. MySQL 8.0 Reference Manual
  5. OWASP SQL Injection Prevention Cheat Sheet
  6. National Food Security Act, 2013 — Coverage and Entitlements (Department of Food & Public Distribution, Government of India)
  7. JUnit 5 User Guide
  8. Bryan Basham, Kathy Sierra & Bert Bates, Head First Servlets and JSP, 2nd ed., O'Reilly
  9. Ramez Elmasri & Shamkant B. Navathe, Fundamentals of Database Systems, 7th ed., Pearson
  10. Ian Sommerville, Software Engineering, 10th ed., Pearson

Cite this bundle

OnlyProjects. (2026). Fair-Price Shop Stock, Entitlement & Distribution Register for a PDS Outlet (Java Servlets/JSP + MySQL): B.Tech / B.E. Computer Science & Engineering project bundle [Educational resource]. https://onlyprojects.online/projects/btech-cse-fair-price-shop-ration-register

Future scope

1 min read

  • ePoS-style counter: offline-first issue screen with an OTP-based beneficiary acknowledgement, so the register matches how state ePoS devices behave without storing any identity number.
  • SMS/WhatsApp notices to cardholders when their category's entitlement changes or stock arrives.
  • Multi-shop mode: ward- or district-level deployment where the district supply office sees stock positions across shops and reallocates before a stock-out.
  • Hindi/Devanagari interface with a toggle, since counter staff and cardholders often prefer it.
  • Consumption analytics: monthly off-take per category and commodity to forecast next month's godown indents.
  • Mobile app for the dealer to approve adjustments and view stock from outside the shop.

Keep browsing

Same degree, same syllabus slot, different idea. Pick the one your guide will actually approve.

B.Tech / B.E.Code included

Aerospace / Aeronautical

Low-Speed Open-Circuit Wind Tunnel with Force Balance for Aerofoil Lift-Drag Measurement

Build a subsonic test tunnel on a student budget, then trace lift and drag on a 3D-printed NACA 0012 against theory

  • C / Arduino Uno (industry-standard extra) — HX711 load-cell and serial logging firmware
  • Python (NumPy, Matplotlib) — calibration, force coefficients and plots
  • MATLAB / Scilab — thin-airfoil theory overlay and regression
  • +4

intermediate14 wk4 students