This repository contains the source code for the DataPulse project, including the Backend (Spring Boot), Frontend (Vite/React), and Database (TimescaleDB/PostgreSQL).
The entire application is containerized and configured to be easily launched in any environment using Docker.
- Frontend: Single Page Application built with Vite and TypeScript (Exposed port:
5173). - Backend: REST API developed with Spring Boot 4 and Java 17 (Exposed port:
8080). - Database: TimescaleDB based on PostgreSQL 15, optimized for time-series data (Exposed port:
5432).
To run the application, you need to have the following installed on your machine:
- Docker Desktop (or Docker Engine)
- Docker Compose
The entire ecosystem is orchestrated using Docker Compose. To start the project, follow these steps:
- Clone the repository to your local machine and open a terminal in the root folder of the project (where the
docker-compose.ymlfile is located). - Execute the following command to build the images and start the containers in the background:
docker compose up -d --buildImportant note on the first startup: During the very first launch, the database will take a few seconds to execute the initialization script (schema.sql) and set up the tables. The Spring Boot backend is configured with a healthcheck and will automatically wait for the database to be fully ready before starting. This prevents any startup crashes or connection errors.
To stop the containers without losing the data saved in the database:
docker compose downTo stop the containers and permanently delete all data from the database (useful if you want to force a complete reset on the next startup):
docker compose down -vOnce all containers are successfully running, you can access the various services via your browser or API testing tools:
| Service | Local URL |
|---|---|
| Web Frontend | http://localhost:5173 |
| API Backend | http://localhost:8080 |
| Database | localhost:5432 |