Skip to content

About

Automated CSV Data Generator and Data Processing Engine for academic records & exports

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

5 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📊 CSV Viewer & Report Generation System

Java Tomcat MySQL License

ℹ️ About Project

The CSV Viewer & Report Generation System is an enterprise-grade Java web application created to simplify the management, ingestion, visualization, and reporting of large CSV datasets. Developed using a 3-tier architecture with Java Servlets, JSP, HikariCP, and MySQL, the system provides real-time asynchronous background report generation, dynamic status monitoring, in-browser dataset exploration, and direct exports to formatted CSV and Excel (.xlsx) workbooks.


🚀 Features

  • 📁 Folder & File Management: Create, organize, and search CSV datasets categorized into distinct folders.
  • ⚡ Asynchronous CSV Processing: Non-blocking background thread execution for multi-thousand row files (GenerateServlet).
  • 🔄 Real-Time Progress Monitoring: Dynamic AJAX polling tracking processing progress from 0% to 100% (ProgressServlet).
  • 🔍 Interactive Data Viewer: Tabular data visualization featuring row/column statistics and live client-side record searching.
  • 📥 Multi-Format Export: One-click downloading of generated datasets as formatted .csv or .xlsx files.
  • 🛡️ High Availability & Fault Tolerance: Built-in StatusStore in-memory fallback and HikariCP connection pool circuit breakers ensuring zero downtime even during database fluctuations.

🏗️ Architecture

The system follows a classic Three-Tier Architecture:

graph TD
    subgraph Presentation Layer
        UI[User / Admin Dashboard - JSP & JS]
    end

    subgraph Application Layer
        Servlet1[FileListServlet]
        Servlet2[FolderCsvServlet]
        Servlet3[GenerateServlet - Async Thread]
        Servlet4[ProgressServlet - Status Polling]
        Servlet5[ViewCsvServlet]
        Servlet6[DownloadServlet]
    end

    subgraph Data Layer
        DB[(MySQL Database)]
        Cache[StatusStore Memory Fallback]
        FS[Server File Storage]
    end

    UI <--> Servlet1
    UI <--> Servlet2
    UI <--> Servlet3
    UI <--> Servlet4
    UI <--> Servlet5
    UI <--> Servlet6

    Servlet3 <--> Cache
    Servlet4 <--> Cache
    Servlet3 <--> FS
    Servlet5 <--> FS
    Servlet6 <--> FS
    Servlet1 <--> DB
    Servlet3 <--> DB
    Servlet4 <--> DB
Loading

📦 Servlets & Components

Component Type Description
FileListServlet.java Backend Scans disk folders and aggregates generated report counts for the dashboard.
FolderCsvServlet.java Backend Lists CSV files within a folder and overlays generation statuses.
GenerateServlet.java Backend Reads CSV datasets asynchronously in background threads and updates progress.
ProgressServlet.java Backend Exposes real-time progress percentages via JSON endpoints.
ViewCsvServlet.java Backend Parses CSV files into structured JSON for tabular visualization.
DownloadServlet.java Backend Streams CSV and Excel (.xlsx) files securely to client browsers.
StatusStore.java Cache In-memory thread-safe status store for 100% uptime fallback.
DbConnection.java Service Shared HikariCP connection pool manager with fast fail-over.

🛠️ Setup & Installation

1. Prerequisites

  • JDK: Java 11 or higher
  • Server: Apache Tomcat 9.0+
  • Database: MySQL 8.0+

2. Database Configuration

Configure database connection parameters in src/main/resources/db.properties:

db.url=jdbc:mysql://localhost:3306/csvgenerator_db?useSSL=false&serverTimezone=UTC
db.username=root
db.password=your_password
db.pool.size=10

Note

Environment variables DB_URL, DB_USERNAME, and DB_PASSWORD will override db.properties automatically if present.

3. Deploy & Run

  1. Deploy the compiled web application to Tomcat's webapps or wtpwebapps directory.
  2. Start Apache Tomcat.
  3. Access the dashboard:
    http://localhost:8080/apps/apps/csvgenerator/fileListServlet
    

📄 License

Distributed under the MIT License.

About

Automated CSV Data Generator and Data Processing Engine for academic records & exports

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages