This is a Spring Boot-based Expense API project. It includes various filters for request and response validation, uses Undertow as the embedded server.
- Java 17 or higher
- Maven 3.6.0 or higher
- PostgreSQL database
-
Clone the repository:
git clone https://github.com/godevox/godevox-expense-api.git cd godevox-expense-api
-
Configure the database in
src/main/resources/application.properties
:spring.datasource.url=jdbc:postgresql://localhost:5432/expense_db spring.datasource.username=godevox spring.datasource.password=godevox
-
Build the project:
mvn clean install
-
Run the application:
mvn spring-boot:run
- Description: Validates the presence and format of the
X-Request-ID
header. - Order: 1
- URL Pattern:
/*
- Description: Validates the request body size (max 1KB) for POST requests.
- Order: 2
- URL Pattern:
/*
- Description: Adds security headers to the response.
- Order: 3
- URL Pattern:
/*
The application uses Undertow as the embedded server. The configuration is set in src/main/resources/application.properties
:
server.undertow.io-threads=8
server.undertow.worker-threads=32
server.undertow.buffer-size=1024
server.undertow.direct-buffers=true