O'Reilly logo
live online training icon Live Online training

Serverless Java with Quarkus

Web Platform

Rapid and flexible Cloud Native Java development

Pratik Patel

Quarkus is a new framework, based on existing open standards, for building cloud native Java applications. Built on the premise of “developer joy”, it brings the fun back into building Java applications: make a change in your code, save the source file, and like magic you can test those changes without restarting the server! Quarkus brings together concepts like Reactive and Convention over Configuration to modernize the Java development experience.

Quarkus is built for cloud native applications; with fast startup times, low overhead, and is built on the Java standards that you’re already building applications with! We’ll incorporate Serverless technology into the hands-on labs, like Cloud Functions and Kubernetes. As a developer, learning Quarkus will get you on the fast-track to building cloud native Java applications. In this course, we’ll do reactive programming, database access with JPA, dependency injection with CDI, and more.

What you'll learn-and how you can apply it

By the end of this live, hands-on, online course, you’ll understand:

  • Serverless basics
  • In-depth app development with Quarkus
  • Deploying and managing Cloud Functions

And you’ll be able to:

  • Learn how to build REST applications
  • Integrate a database using JPA to store our REST endpoint’s data
  • Build cloud native applications that startup fast for Cloud Function environments
  • Build high performance reactive architecture applications

This training course is for you because...

  • You’re either a junior or senior developer looking to build cloud native serverless apps
  • You work with Java and Cloud, or are looking to learn how Java works on the Cloud
  • You want to understand the architecture of moving from a monolith to microservices & cloud functions

Prerequisites

Recommended preparation:

  • Have Java 8 installed, with Maven also setup
  • Have an IDE for working with Java code

About your instructor

  • Pratik Patel is a Java Champion and developer advocate at IBM. He wrote the first book on 'enterprise Java' in 1996, "Java Database Programming with JDBC." An all around software and hardware enthusiast with experience in  the healthcare, telecom, financial services, and startup sectors. Helps to organize the Atlanta Java User Group and North Atlanta JavaScript meetup, frequent speaker at tech events, and master builder of nachos.

Schedule

The timeframes are only estimates and may vary according to how the class is progressing

Intro to serverless computing & cloud native (40 minutes)

  • Presentation: 30
    • Discussion on Cloud Native Architectures
    • Comparison of Monolith vs Microservice/Serverless Architecture
    • Serverless and Cloud Functions discussion
    • How Java fits into the landscape
    • Challenges with Java for Cloud Native and Serverless
  • Discussion & QA: 10

Getting to know Quarkus (20 minutes)

  • Presentation: 15
    • Overview of Quarkus
    • Live coding of a basic Quarkus app
    • Building a runnable Jar and Graal Binary, comparison
  • Key concepts:
    • CDI
    • JPA/Panache
    • Vert.x
    • Limitations of Quarkus
  • Q&A: 5
  • BREAK (5)

First steps with Quarkus – Build a REST application (40 minutes)

  • Discussion on REST helpers in Quarkus: 10 mins
  • Exercise: 30
    • Use CDI to create a BlogPost Service
    • Use Annotations to create RESTful endpoints
    • Connect the two
    • How to compile
    • How to run
    • Explore fast reloading feature
  • Q&A
  • BREAK (5)

Quarkus Database Access with Panache (30 minutes)

  • Discussion on Panache for DB access: 10 mins
  • Exercise: 20
    • Configure Postgres DB to hold our BlogPost data
    • Build a Panache service and create our BlogPost entity JPA object
    • Integrate with our BlogPostService for CRUD operations
  • Q&A

Quarkus makes testing code easy (30 minutes)

  • Discussion on testing in Quarkus: 10 mins
  • Exercise: 20
    • Configure Postgres DB to hold our BlogPost data
    • Build a Panache service and create our BlogPost entity JPA object
    • Integrate with our BlogPostService for CRUD operations
  • Q&A
  • BREAK (5)

Deploying Quarkus to a Cloud Function provider (30 minutes)

  • Discussion on Cloud Functions: 5 mins
  • Exercise: 25
    • CLI for Cloud Function deployment and testing
    • Package up Quarkus app for Cloud function
    • Deploy and test using CLI
    • Web-enable Cloud function, test using curl
  • Q&A

Quarkus Reactive (30 minutes)

  • Discussion: what does it mean to be Reactive? 10 mins
  • Exercise: 20
    • SImple Reactive demos in Quarkus
    • Using the Reactive Postgres Client
  • Q&A

Wrap up (15 minutes)

  • Exercise: 30
  • Q&A