
Learn to access several relational databases with Quarkus, map objects using JPA Panache, and expose data via rest endpoints and HTML while using various Quarkus profiles.
Explore three Quarkus apps with MySQL, MariaDB, and PostgreSQL, mapping POJOs and JPA entities with Panache, modeling books, CDs, artists, and orders, plus REST endpoints and dockerized development.
Watch a demo of a vintage store app built with quarkus, exposing APIs for artists, customers, books, and cds backed by postgres; explore json and html views with panache queries.
Continue building the final application by adding code and ensuring tests pass, while the next lesson defines object-relational mapping, its history, and how JDBC, JPA, Panache, and Quarkus fit together.
Explore the history and internal architecture of object relational mapping, tracing layers from databases to Panache Aurum through JDBC and JPA, and apply Quarkus configuration used in the course.
Understand what an object relational mapping tool is and why it connects Java objects to relational tables, tracing ORM history from Hibernate and JPA to Quarkus and Panache ORM.
Discover how relational databases store data in tables with primary and foreign keys, and how Quarkus uses JDBC, JPA, Hibernate, and Panache to map objects and perform CRUD.
Set up the required tools for the course, follow the provided URLs, bootstrap three Quarkus applications, browse and clean generated code, and run tests before coding begins.
Explore how to bootstrap three quarkus applications with the maven plugin, showcasing object-relational mapping and different databases, including PostgreSQL, MySQL, and MariaDB.
Verify your development environment by installing Java 11, choosing an IDE, and ensuring Maven, Docker, and curl are ready for Quarkus dev services with relational databases.
Verify your development environment for relational databases with Quarkus by checking Java 11, Maven 3.8, Docker, and curl readiness to invoke rest endpoints.
Bootstrap three Quarkus applications with distinct databases: artist with MySQL via JDBC, customer with MariaDB and Hibernate ORM JPA, and vintage store with PostgreSQL and Panache, producing external jars.
Bootstrap three Quarkus applications by generating a multi-module project with artist, customer, and vintage store, configure a parent pom, and streamline structure by removing docker and extraneous files.
Model the artist pojo, customer entity, and publisher entity; persist and query them with jdbc, jpa, and panache across different databases, using PostgreSQL, then compare pojo jpa and panache entities.
Model and query persistence objects across three projects in Quarkus, including a pojo artist on MySQL, a Jpa customer on MariaDB, and a Panache publisher on PostgreSQL.
Model a plain old Java object as a pojo, persist and query it with pure jdbc against a MySQL database, using a repository to insert and find by id.
Create an artist plain old Java object, use a CDI repository with a data source, and implement SQL-based persist and find-by-id tests in Quarkus.
Model a customer as a JPA entity with a persistent identity and map it to a table using annotations, managed by the entity manager for easy persist and find operations.
Model the customer as a JPA entity with a generated id, implement a repository, and use the entity manager for persist and find by id, enabling database creation and tests.
Model a publisher as a Panache entity backed by JPA annotations, with public attributes and an automatically generated ID from the superclass, enabling built-in CRUD and query operations in PostgreSQL.
Build panache entities in the vintage store app by making publisher a panache entity with public fields and built-in repository behavior; test id lookups against PostgreSQL using test containers.
Compare jdbc, jpa, and panache in Quarkus, highlighting how each integrates with entities and repositories. See how panache simplifies pojos and tests with dev services and test containers.
Run three tests in parallel with test containers for MySQL, MariaDB, and Postgres to compare JDBC, JPA, and Panache, enabling faster Maven test execution.
We modeled persistence objects—the artist pojo, the customer entity, and the publisher entity—and prepared to manage them with CRUD operations using the entity manager, Panache repositories, and JPA tricks.
Package customer and artist entities into separate jars, switch the vintage store app to PostgreSQL, and implement panache repositories with orm xml for artists and a panache archive for customers.
Explore how the JPA entity manager orchestrates entity state and lifecycle, enabling persist, remove, find by ID, locking, and query creation; learn how Panache abstracts it for Quarkus apps.
Panache provides two ways to access entities; the active record pattern embeds CRUD methods in the entity by extending Panache entity base, with operations backed by the JPA entity manager.
Explore how Panache repositories provide an abstraction on the entity manager, compare active record and repository patterns, and use repositories for non panache entities to perform CRUD operations.
Install the artist jar with a Maven clean install, add a dependency in pom.xml excluding MySQL, and implement a Panache artist repository as JPA entity for t_artists with transactional tests.
Transform a pojo into a panache entity and manage a customer jpa entity with a repository, using a panache archive marker for entities in separate jars.
Learn to manage JPA entities with Panache repositories in Quarkus, using active record patterns and repository-based approaches.
Explore Quarkus with Panache to map artists, customers, and publishers using annotations and XML, then inherit from Item to books and CDs and define relationships.
Customize entity mappings in Quarkus using annotations and XML, turning artist and customer into Panache entities as books and CDs inherit from item and connect to publisher, tracks, order lines.
Explore object-relational mapping, translating Java objects to sql, map entities to tables and attributes to columns, including mapping to existing tables via annotations or xml.
Customize mapping with annotations or XML to redefine the database structure for panache and JPA entities. Annotate entities, attributes, and relationships to set table names and column details.
Customize mapping with jpa annotations, change table names to t_publishers and t_customers, adjust column lengths and not-null constraints, and generate ddl scripts via Quarkus dev.
Explore customising mapping with XML in Quarkus to map the artist pojo via an XML file, overriding annotations and defining table and column details to generate ddl.
Customize mapping with xml to adapt an external pojo, adjust ddl via orm xml, change column lengths, extend bio to 3000, and set created_date as non-null.
Explore inheritance mapping in Quarkus with single table, join, or table per class strategies, using an item superclass and book and CD subclasses with a discriminator column.
Explore mapping inheritance in Quarkus by enriching a model with item, book, and CD entities, customizing fields like title, description, price, created_date, and language enum as string.
Map purchase orders to customers and order lines using JPA relationship annotations in Quarkus, with join column or join table and cascade persist and remove.
Map relationships between items, artists, books, publishers, and tracks using many-to-one and one-to-many mappings, generate DDL, and validate with tests for purchase orders and order lines.
Explore querying relational data in Quarkus, using Panache's default queries and custom queries with active record and repository patterns, then add data to test 1-to-1, 1-to-many, and many-to-one relationships.
Learn to query existing entities in relational databases with Quarkus by adding repository queries, building on a complete business model, without creating new entities.
Explore SQL, JPQL, and Panache query languages to query relational data as entities and attributes, using the entity manager and APIs to build dynamic, typed, and native queries.
Explore default panache queries from repository and active record bases to count, list, find by id, delete all, and stream entities, with optional results and SQL insight.
Use default Panache queries to count, list all, persist, and delete artists via repository and active record patterns. Enable log SQL in application properties to view generated SQL and mappings.
Learn to craft custom panache queries using JPQL or simplified JPQL, leveraging the list method, parameters, and the sort API across customer, artist, and publisher repositories.
Create custom Panache queries in entities and repositories, implement active pattern queries, and test list and filter methods such as find by name and containing name using optional results.
Expose data with rest endpoints and json, enable transactions for creating new records, and visualize the database using Q templates and bootstrap in html.
Expose data from relational databases with Quarkus by importing customers, purchase orders, books, CDs; use Pojos and JPA entities, export JSON via JAX-RS endpoints, and render HTML with templates.
Expose relational data via rest endpoints using jax-rs and rest-easy in quarkus, producing json with jsonb, and query /api/customers and /api/publishers using http get.
Expose relational data from a Quarkus app by creating rest endpoints for artists and publishers, loading sample data from an import sql, and enabling json responses with resteasy jackson.
Manage data consistency in quarkus by applying jta transactions for http post and delete, using transactional annotations with inherited policies, and testing with swagger ui and open api extension.
Implement transactional create and delete operations for artists and publishers in Quarkus, returning 201 with the new resource URI and enabling Swagger UI for testing.
Learn to render data as HTML using Qute templates in Quarkus, binding objects to templates and exposing REST endpoints that serve dynamic pages with expressions and loops.
Learn to visualize relational data with Quarkus by creating rest endpoints that render Qute templates for books and CDs, including single and list views, with dynamic IDs.
Beautify Qute templates by creating a base template with CSS, JavaScript, and a navigation bar, then include it in other templates and pass parameters, using Twitter Bootstrap.
Refactor four Qute templates into a shared base template, add a dynamic title parameter, and beautify the UI with Twitter Bootstrap's navigation bar, container layout, and table styling.
Mix Qute and Panache to render lists and details. Use Panache queries with pagination and sorting, passing query, sort, page index, and page size to display html.
Mix Qute and Panache queries to fetch books with filtering, sorting, and pagination via a rest endpoint, using query parameters for query, sort, page, and size with defaults.
Explore how to run a Quarkus app under multiple profiles, switching between development with PostgreSQL, test containers, in-memory databases, and production with Docker Compose, while viewing JSON representations.
Learn to execute and test the Quarkus app in modes, switch from Postgres with dev services to H2 in memory database for testing, and deploy production with a Docker image.
Quarkus uses configuration profiles to activate environment-specific settings in application.properties file. Create custom profiles and activate them with mvn quarkus dev or mvn quarkus test, or a runnable jar.
Execute in development mode with quarkus dev to auto-start dev services via test containers for databases like Postgres and MongoDB. Check the dev UI for the port and credentials.
Start dev mode to run a test container PostgreSQL via Quarkus dev services, then fix the port to 5432 in application properties for stable access.
Configure tests to run with an in-memory H2 database for speed, switching from dev services with Postgres; compare performance by enabling the Maven test profile and running tests in memory.
Run mvn test with dev services to see test containers start postgres, then speed up tests by using an in-memory h2 database and adding the h2 jdbc extension to pom.xml.
Execute the application in production mode using a PostgreSQL database via Docker and Docker Compose, configuring the database URL, credentials, and a production SQL load script to seed data.
Review the progress from pojos, JPA entities to repositories, resources, and templates, and confirm test, in-memory, and PostgreSQL production databases.
Revisit the full journey of building Quarkus apps with MySQL, MariaDB, and PostgreSQL, from POJO and JDBC to JPA entity and Panache repositories.
Finish the course by bootstrapping three apps with three databases, moving from JDBC to JPA and Panache, mapping entities, inheritance, and queries, exposing data with REST and cute templates.
Take one more step in the Quarkus world by accessing external references on Quarkus, JPA, and Panache in a short, introductory lesson.
This course is for Quarkus developers who want to discover how Quarkus handles relational databases. It’s a mixture of slides and code so you can “Understand and Practice” at the same time. This way, you learn the theory, and then put it into practice by developing an application step by step.
In this course you will develop a Quarkus applications maps and queries different kind of persistent objects to several relational databases. After introducing JDBC, JPA and Panache ORM, you will make sure your development environment is set up, and you will go from bootstrapping three Quarkus applications, developing and refactoring a rich business model, map and query these objects to a Postgres database. The different steps you’ll go through are:
Understand JDBC, JPA and Panache ORM
Understand SQL, JPQL and Simplified Panache JPQL
Understand the differences between Panache Active Record and Panache Repositories
Check your development environment
Bootstrap three Quarkus applications:
o POJOs and JDBC with MySQL
o JPA Entities with MariaDB
o Panache ORM Entities with PostgresSQL
Test and refactor these applications so they have dependencies between them
Map persistent objects to a relational database (with annotations and XML)
Map inheritance and relationships
Query persistent objects using JPQL and Simplified Panache QL
Expose data in JSON using REST endpoint with JAX-RS and JSON-B
Handle transactions
Visualise data in HTML using Qute templates and Twitter Bootstrap
Use Quarkus profiles to switch between database
Execute the application in dev/test/production mode thanks to DevServices and Docker
At the end of the course you’ll get a good understanding on how to develop a data centric application with Quarkus. You will be able to bootstrap, develop, package and execute an application that accesses a relational database, but most important, take Quarkus to your next project.
Good luck for the course, and please reach out if you need any help or if you have any request: I’m here to help!