Hibernate ORM with Panache¶
The rest-classic module combines RESTEasy Classic with Hibernate ORM and
Panache. Use it to compare imperative JPA persistence and classic JAX-RS
resources with the reactive REST samples.
Sample structure¶
The module's POM includes quarkus-resteasy, quarkus-resteasy-jsonb,
quarkus-hibernate-orm-panache, and quarkus-jdbc-postgresql.
PostRepository
and CommentRepository use Panache repository APIs;
PostService
contains application operations, and JAX-RS resources expose the HTTP API.
The module supports PostgreSQL for production configuration and uses H2 in its
test profile. Inspect application.properties and
src/test/resources before choosing a database.
Run the sample¶
From the rest-classic directory, run:
./mvnw quarkus:dev
On Windows, run mvnw.cmd quarkus:dev. Run ./mvnw test to use the module's
tests and test configuration.
What's next¶
- Compare with Hibernate Reactive and Panache.
- See JSON-B customization for this module's customizer.
- See OpenAPI and Swagger UI for the API documentation in
rest-classic.