Skip to content

m-feliciano/javaee-framework

Repository files navigation

Java Web Framework – Clean Architecture

Jakarta-based framework designed with Clean Architecture principles, focused on performance, security, and a clear structure for modern backend development.

Key Features

  • Custom framework: Servlets, CDI, annotation-based controllers and routing.
  • Advanced security: JWT, refresh/rotate, CSRF, structured auditing.
  • Multi-layer cache: Hibernate L1/L2, Ehcache.
  • Rate limiting (Leaky Bucket).
  • Messaging: JMS/ActiveMQ, SQS.
  • Custom JSR-303 validation.
  • Observability: correlationId, metrics, health checks.
  • DTO mapping via MapStruct.

Stack

  • Java 21, Jakarta, Weld CDI, Hibernate, Ehcache
  • JJWT, Jackson, SLF4J/Logback
  • JUnit 5, Mockito
  • PostgreSQL 16+, OkHttp
  • Maven 3.6+, AWS SDK v2
  • Docker, Kubernetes

Architecture

  • Domain: entities, value objects, business rules
  • Application: use cases, orchestration
  • Web: controllers, routing, HTTP adapters
  • Infrastructure: persistence, messaging, integrations
  • Adapters: implementations for interfaces from other layers

Each layer is independent; infrastructure never leaks into the domain.

Custom MVC: annotation scanning, reflection-based routing, middleware pipeline, and central dispatcher.

Preview

Preview Click here to see more.

Demo

A demo application is available for evaluation.

Pull the demo docker-compose file and start the services:

curl -O https://raw.githubusercontent.com/m-feliciano/javaee-framework/refs/heads/master/docker/demo/docker-compose.demo.yml

IMPORTANT: This demo uses an older version (v2.x.x) of the framework and will not be updated with the latest changes.

The current version of the framework can be found in the master branch.

Run the demo application with Docker Compose:

docker compose -f docker-compose.demo.yml up -d

For local build: mvn clean package -Pdev.

Modern UI available in the demo application. See technical details in PREVIEW.md.

Endpoints

The application exposes some endpoints. Here are examples:

  • GET /api/v1/user/me - Get current user details
  • POST /api/v2/user/upload-photo - Upload user photo (v2 example)
  • POST /api/v1/auth/login - Authenticate with username/password
  • GET /api/v1/health/up - Check application health
  • GET /api/v1/product/list - List products

If you want to see all available endpoints, check the Docs tab in the application UI or refer to the source code.

OpenAPI / Swagger

The demo application includes OpenAPI documentation available at:

View the API documentation online:

License

MIT. See LICENSE.

Contribution

Contributions are welcome. See CONTRIBUTING.md.

Status Badges

Java License Docker Pulls Last Commit OpenAPI

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •