Concurrent Strategies using MDBs
1. Introduction Message Driven Beans, also known as “MDB”, handle message processing in an asynchronous context. We can learn the basics of MDB in this article. This tutorial will discuss some...
View ArticleSet the Time Zone of a Date in Java
1. Overview In this quick tutorial, we’ll see how to set the time zone of a date using Java 7, Java 8 and the Joda-Time library. 2. Using Java 8 Java 8 introduced a new Date-Time API for working with...
View ArticleWhy String is Immutable in Java?
1. Introduction In Java, Strings are immutable. An obvious question that is quite prevalent in interviews is “Why Strings are designed as immutable in Java?” James Gosling, the creator of Java, was...
View ArticleRunning JUnit Tests Programmatically, from a Java Application
1. Overview In this tutorial, we’ll show how to run JUnit tests directly from Java code – there are scenarios where this option comes in handy. If you are new to JUnit, or if you want to upgrade to...
View ArticleDefault Password Encoder in Spring Security 5
1. Overview In Spring Security 4, it was possible to store passwords in plain text using in-memory authentication. A major overhaul of the password management process in version 5 has introduced more...
View ArticleExtracting Principal and Authorities using Spring Security OAuth
1. Overview In this tutorial, we’ll illustrate how to create an application that delegates user authentication to a third party, as well as to a custom authorization server, using Spring Boot and...
View ArticleServer-Sent Events (SSE) In JAX-RS
1. Overview Server-Sent Events (SSE) is an HTTP based specification that provides a way to establish a long-running and mono-channel connection from the server to the client. The client initiates the...
View ArticleJersey MVC Support
1. Overview Jersey is an open-source framework for developing RESTFul Web Services. As well as serving as the JAX-RS reference implementation it also includes a number of extensions to further...
View ArticleIntroduction to Hazelcast Jet
1. Introduction In this tutorial, we’ll learn about Hazelcast Jet. It’s a distributed data processing engine provided by Hazelcast, Inc. and is built on top of Hazelcast IMDG If you want to learn...
View ArticleHow to Configure Spring Boot Tomcat
1. Overview Spring Boot web applications include a pre-configured, embedded web server by default. In some situations though, we’d like to modify the default configuration to meet custom requirements....
View ArticleSpring Data Web Support
1. Overview Spring MVC and Spring Data each do a great job simplifying application development in their own right. But, what if we put them together? In this tutorial, we’ll take a look at Spring...
View ArticleAnonymous Classes in Java
1. Introduction In this tutorial, we’ll consider anonymous classes in Java. We’ll describe how we can declare and create instances of them. We’ll also briefly discuss their properties and limitations....
View ArticlePersisting Maps with Hibernate
1. Introduction In Hibernate, we can represent one-to-many relationships in our Java beans by having one of our fields be a List. In this quick tutorial, we’ll explore various ways of doing this with a...
View ArticleTypes of SQL Joins
1. Introduction In this tutorial, we’ll show different types of SQL joins and how they can be easily implemented in Java. 2. Defining the Model Let’s start by creating two simple tables: CREATE TABLE...
View ArticleSpring Data JPA Repository Populators
1. Introduction In this quick article, we’ll explore Spring JPA Repository Populators with a quick example. The Spring Data JPA repository populator is a great alternative for data.sql script. Spring...
View ArticleGroovy def Keyword
1. Overview In this quick tutorial, we’ll explore the concept of the def keyword in Groovy. It provides an optional typing feature to this dynamic JVM language. 2. Meaning of the def Keyword The def...
View ArticleGeneric Constructors in Java
1. Overview We previously discussed the basics of Java Generics. In this tutorial, we’ll have a look at Generic Constructors in Java. A generic constructor is a constructor that has at least one...
View ArticleSpring Data JPA Delete and Relationships
1. Overview In this tutorial, we’ll have a look at how deleting is done in Spring Data JPA. 2. Sample Entity As we know from the Spring Data JPA reference documentation, repository interfaces provide...
View ArticleGuide to Google Tink
1. Introduction Nowadays, many developers use cryptographic techniques to protect user data. In cryptography, small implementation errors can have serious consequences, and understanding how to...
View ArticleSet Operations in Java
1. Introduction A set is a handy way to represent a unique collection of items. In this tutorial, we’ll learn more about what that means and how we can use one in Java. 2. A Bit of Set Theory 2.1. What...
View Article