DropWizard demo application
This is an example application of a small ReST service using DropWizard. The user can manage to-do items. A simple test UI is included.
NB: This is only an example. The intent is to demonstrate the technical stack, but not to provide a full-fledged application. No real authentication is required.
Features
The following techniques are demonstrated:
- Serving static content (the test UI) via the embedded Jetty web server,
- Validation of DTOs and API endpoints,
- Declarative data access with JDBI3,
- Custom row mapper for JDBC results,
- Schema migrations with LiquiBase,
- Annotation-based JAX-RS response postprocessing,
- Basic authentication and access control,
- A simple health check,
- Unit and integration testing,
- Docker packaging.
How to start the application
- Maven and Java SE 8 are required.
- Run
mvn clean install
to build the application, - Start it with
java -jar target/todo-kt-0.0.1-SNAPSHOT.jar server h2-config.yml
, - Try the test UI at
http://localhost:8080
, log as any user with the reversed user name as password.