AirGuard is a professional-grade full-stack DBMS project. It features a futuristic Node.js web interface and a robust MySQL relational backend designed to showcase advanced database concepts.
Your database must be running before the application can connect.
- XAMPP: Open XAMPP Control Panel and click Start on MySQL.
- WAMP: Click the WAMP icon -> MySQL -> Service Administration -> Start Service.
net start MySQL80TIP: Ensure MySQL is RUNNING on port 3306 before starting the app.
Create a .env file in the root directory:
DB_HOST=localhost
DB_USER=root
DB_PASSWORD=your_mysql_password
DB_NAME=airguard
PORT=3000
JWT_SECRET=supersecretkey123Open your terminal in the project folder and run:
- Install Requirements:
npm install - Setup Database:
node db-init.js(Automates table creation & data population) - Start Server:
npm start
View the App: http://localhost:3000
- Frontend: Vanilla JavaScript (ES6+), CSS3 (Glassmorphism), HTML5
- Backend: Node.js, Express.js
- Database: MySQL 8.0+
- Security: JSON Web Tokens (JWT), Bcrypt.js (Password Hashing)
- Data Visualization: Chart.js 4.4
- DevOps: Dotenv (Environment Management)
This project is built to demonstrate intelligence-grade database management:
- Database Normalization (3NF): Found in
additions.sql, featuring a full decomposition demo ofRAW_AIR_DATA. - Transaction Integrity: Implementation of
COMMIT,ROLLBACK, andSAVEPOINTfor secure operations. - Concurrency Control: Demonstrations of Row-level locking and Shared locks to prevent data anomalies.
- Automated Logic: Real-time Triggers, Stored Procedures (with Cursors), and Complex Views.
schema.sql: Core relational structure & diverse sample data.additions.sql: Normalization, Transactions, and Locking demos.review-guide/: Detailed technical documentation for DBMS concepts.public/: Sleek glassmorphism frontend with real-time DB status tracking.
The UI automatically tracks your database connection:
- 🟢 DATABASE Badge: Successfully fetching real atmospheric data from MySQL.
- 🔴 SIMULATED Badge: Database disconnected; showing randomized sensor data for demo safety.
⚠️ Sidebar Status: Displays troubleshooting steps if the connection fails.