Securing Quarkus with Elytron Database Realm

Quarkus security includes several extensions from Elytron. In this tutorial we will learn how to use the Database Realm Authentication with a simple REST Service. Our project will perform authentication against the H2 in-memory database. In order to bootstrap our project we will need the following extensions mvn io.quarkus:quarkus-maven-plugin:1.0.0.CR1:create \ -DprojectGroupId=com.mastertheboss \ -DprojectArtifactId=quarkus-jdbc-realm \ -DclassName=”com.mastertheboss.SecuredResource” … Read more

Using Servlet Context in Quarkus

Quarkus includes the undertow extension, therefore it’s fully capable of delivering Servlet applications. In this example, we will show how to use the ServletContext in a REST Application. One challenge is that you cannot @Inject the ServletContext directly as you would do it in a Jave EE environment. Nevertheless you can count on the JAX-RS … Read more

Scheduling periodic Tasks in Quarkus

Quarkus does not provide support for EJB therefore you cannot rely on EJB Timers to schedule simple tasks. However, thanks to the extension quarkus-scheduler it is very simple to add this functionality. Let’s create a simple project with Quarkus Maven plugin: mvn io.quarkus:quarkus-maven-plugin:0.19.1:create \ -DprojectGroupId=com.sample \ -DprojectArtifactId=demo-scheduler \ -DclassName=”com.sample.CountEndpoint” \ -Dpath=”/count” \ -Dextensions=”scheduler” By the … Read more

Creating an Ajax front-end to a Quarkus REST application

In this article we will check out how query a REST Service running with Quarkus with a minimal Ajax and jQuery client. Quarkus applications can be quickly bootstrapped using the Maven or Gradle plugin available. The plugin will generate a minimal project structure with a sample REST Endpoint and the Quarkus’s Maven dependencies included in … Read more