Posts

Showing posts with the label Quarkus

Build REST CRUD APIs with Quarkus + Hibernate ORM Panache

Image
Hello everyone, today we will learn how to build RESTful CRUD APIs using  QUARKUS  and Hibernate ORM Panache. Quarkus  is a Java framework designed to run within containers. Fixating on expeditious start-up times and low memory utilization makes it more felicitous to run within container orchestration platforms like Kubernetes. Quarkus  supports many industry-standard libraries such as Hibernate, Kubernetes, RESTEasy, Eclipse MicroProfile, and more... More Quarkus Related topics, Build REST CRUD APIs with Quarkus and MyBatis Build Rest CRUD API with MongoDB, Quarkus, and MongoDB Client Build Rest CRUD API with Quarkus and MongoDB Panache Kotlin + Quarkus + MyBatis - Build REST CRUD API example Let's start to build RESTful API with  QUARKUS   Technologies used: Quarkus 2.2.3.Final Hibernate ORM Panache H2 Database Java 11 Project Directory: Maven Dependencies[pom.xml]: <?xml version = "1.0" ?> <project xsi:schemaLocation = "http://maven.apache.org/POM/4.

Custom Exception Handling in Quarkus REST API

Image
Hello everyone, In this article, we will learn how to handle exceptions in the Quarkus REST application using ExceptionMapper interface implementations. ExceptionMapper is a contract for a provider that will map a thrown application exception to a Response object. We will show you custom exception handling with the help of a simple application, Project Directory: application.properties knowledgefactory.custom.error.msg.usernotfound = User not found knowledgefactory.custom.error.msg.badrequest.numeric = User Id must be numeric Create Error Message package org.knf.dev.demo.exception; public class ErrorMessage { private String message; private Boolean status; public String getMessage() { return message; } public void setMessage( String message) { this .message = message; } public Boolean getStatus() { return status; } public void setStatus( Boolean status) { this .status = status; } public Erro