DInject has moved to avaje.io/http - taking you there now ...


An application can define a @Roles annotation. If the annotation matches the name "Roles" then it is deemed to define application security roles and generates appropriate code in the web route.

List<HelloDto> getAll() {

The generated code includes the Javalin roles check.

// Generated code ...

ApiBuilder.get("/hello", ctx -> {
}, roles(ADMIN));