This article will teach you how to use a plain Datasource resource in a Quarkus application. We will create a simple REST Endpoint and inject a Datasource in it to extract the java.sql.Connection object. We will also learn how to configure the Datasource pool size.
Quarkus
Quarkus is a Kubernetes native Java framework tuned for OpenJDK HotSpot and GraalVM. Quarkus aims to become the leading Java platform for building Kubernetes and serverless environments. Thanks to its capabilities, developers can leverage unified reactive and imperative programming model to create a wide range of distributed application architectures.
The latest version of Quarkus is 3.9.0.CR2
<dependencies> <dependency> <groupId>io.quarkus</groupId> <artifactId>quarkus-bom</artifactId> <version>3.9.0.CR2</version> <type>pom</type> <scope>import</scope> </dependency> </dependencies>
Learn Quarkus through the following steps:
The Basics
Getting started with QuarkusIO
Development with Quarkus
Creating Quarkus projects using IntelliJ IDEA
How to create Quarkus Command Mode applications
Container and Cloud
Building Container-ready native applications with Quarkus
Deploying Quarkus applications on OpenShift
How to run Quarkus applications on Kubernetes
Persistence
Getting started with Quarkus and Hibernate
Data Persistence with Quarkus and Hibernate Panache
Zero Config Database configuration with Quarkus (DevServices)
Testing
A practical guide for testing Quarkus applications
Web UI
Qute: a template for Quarkus Web applications
Reactive Programming
Reactive REST with Quarkus made easy
Getting started with Hibernate reactive on Quarkus
Quarkus Reactive messaging with Kafka
Quarkus Reactive messaging with AMQ
Monitoring
Monitoring Quarkus with Prometheus
Monitoring Quarkus runtime with DevUI
Are you going for a Quarkus Interview? check this: Quarkus Interview Questions
Getting started with Quarkus and Hibernate
In this article we will learn how to create and run a sample Quarkus 3 application which uses Hibernate ORM and JPA. We will create a sample REST Endpoint to expose the basic CRUD operations against a relational Database such as PostgreSQL.
Quarkus vs WildFly Application Server
This article provides a comparison of the features of two popular Java Enterprise Runtimes: WildFly Application Server and Quarkus framework. While both offer robust support for Java applications, their distinct approaches to development, deployment, and scalability cater to diverse use cases. Comparing Quarkus and WildFly. Fair comparison ? Firslty a disclaimer note: Comparing WildFly, a … Read more
Kafka Streams Tutorial
Kafka Streams is a powerful and lightweight library provided by Apache Kafka for building real-time streaming applications and microservices. In this tutorial we will show a simple Kafka Streams example with Quarkus which shows how to perform stream processing tasks directly within the Kafka ecosystem, leveraging the familiar Kafka infrastructure to process and transform data in real-time.
Redis Integration with Quarkus made simple
This tutorial will guide you through accessing Redis in-memory store from a Quarkus application. We will show which are the key interfaces for storing data structures in Redis and how Quarkus Dev Services greatly simplifies setting up a Dev environment for our Redis application. Redis Overview Redis is an open-source in-memory data structure store which … Read more
Virtual Threads with Quarkus made easy
In this first tutorial about Virtual Threads Mastering Virtual Threads: A Comprehensive Tutorial , we have covered the basics of Virtual Threads. In this article we will learn how Quarkus simplifies the implementation and debugging of Virtual Threads in your application through the @RunOnVirtualThread
annotation.
How to upgrade to Quarkus 3
This article discusses how to upgrade your existing Quarkus 2.x applications to Quarkus 3.x using the Quarkus CLI tool. We will learn at first which is the impact of the upgrade on Quarkus 2 application. Then, we will show how to perform the upgrade with just a single command line!
Addressing CVE-2023-4853 in Quarkus
The CVE-2023-4853 vulnerability in question impacts Quarkus framework’s HTTP Security Policy, . This policy provides access control to various endpoints within an application enabling developers to secure access based on path-based configurations. However, a critical flaw has been identified in how the HTTP Security Policy handles request paths containing multiple adjacent forward-slash characters.
Quarkus CRUD Example with Panache Data
In this tutorial we will learn how to create a REST CRUD application in Quarkus, starting from a Hibernate Panache Entity. We will show two different approaches: in the first one we will create a REST Resources to map the CRUD methods. Then, we will show how to use REST Data Panache to generate automatically a REST Endpoint for an Entity.
Quarkus vs. Micronaut: A Comparative Analysis
In the world of modern Java microservices, developers are faced with a variety of frameworks and tools to choose from. Two popular options in this space are Quarkus and Micronaut. Both of these frameworks offer unique features and advantages, making the choice between them a significant decision for developers. In this article, we’ll delve into … Read more