A Java Client for a WebSockets API
1. Introduction HTTP (Hypertext Transfer Protocol) is a stateless request-response protocol. Its simple design makes it very scalable but unsuitable and inefficient for highly interactive real-time...
View ArticleCyclicBarrier in Java
1. Introduction CyclicBarriers are synchronization constructs that were introduced with Java 5 as a part of the java.util.concurrent package. In this article, we’ll explore this implementation in a...
View ArticleIntroduction to AsciiDoctor in Java
1. Introduction In this article, we’ll make a quick introduction on how to use Ascii Doctor with Java. We’ll demonstrate how to generate HTML5 or PDF from an AsciiDoc document. 2. What is AsciiDoc...
View ArticleA Guide To Cron Expressions
1. Overview Simply put, cron is a basic utility available on Unix-based systems. It enables users to schedule tasks to run periodically at a specified date/time. And, it’s naturally a great tool for...
View ArticleThe HttpMediaTypeNotAcceptableException in Spring MVC
1. Overview In this quick article, we’ll have a look at the HttpMediaTypeNotAcceptableException exception, and understand the cases where we might encounter it. 2. The Problem When implementing an API...
View ArticleHandling Exceptions in Lambda Expression Using Vavr
1. Introduction The Functional Interfaces provided by the JDK are not prepared properly for the handling of checked exceptions. If you want to read more about the problem, check this article. In this...
View ArticleApache Commons Collections SetUtils
1. Overview In this article, we’ll be exploring the SetUtils API of Apache Commons Collections library. Simply put, these utilities can be used to execute certain operations on Set data structures in...
View ArticleIntroduction to Netflix Servo
1. Overview Netflix Servo is a metrics tool for Java applications. Servo is similar to Dropwizard Metrics, yet much simpler. It leverages JMX only to provide a simple interface for exposing and...
View ArticleSpring Cloud Tutorial
Building cloud-ready applications have its own set of challenges. This series explores these challenges and of course guides you through a full microservice implementation using Spring Boot and Spring...
View ArticleSpring Cloud Series – The Gateway Pattern
1. Overview So far, in our cloud application, we’ve used the Gateway Pattern to support two main features. First, we insulated our clients from each service, eliminating the need for cross-origin...
View ArticleApache Commons Collections OrderedMap
1. Overview The Apache Commons Collections library provides useful classes that complement the Java Collections Framework. In this article, we will review the interface OrderedMap, which extends...
View ArticleJava Weekly, Issue 183
Lots of interesting writeups on Java 9 this week. Here we go… 1. Spring and Java >> What’s new in JPA 2.2 – Java 8 Date and Time Types [vladmihalcea.com] JPA 2.2 finally has the support for...
View ArticleIntroduction to Kotlin Coroutines
1. Overview In this article, we’ll be looking at coroutines from the Kotlin language. Simply put, coroutines allow us to create asynchronous programs in a very fluent way, and they’re based on the...
View ArticleIntroduction to Apache Commons Text
1. Overview Simply put, the Apache Commons Text library contains a number of useful utility methods for working with Strings, beyond what the core Java offers. In this quick introduction, we’ll see...
View ArticleBigDecimal and BigInteger in Java
1. Overview This is an introductory article on the BigDecimal & the BigInteger data types in the Java programming language. In this write-up, we’ll show in what scenarios we can use these data...
View ArticleApache Commons BeanUtils
1. Overview Apache Commons BeansUtils contains all tools necessary for working with Java beans. Simply put, a bean is a simple Java classes containing fields, getters/setters, and a no-argument...
View ArticleSpring 5 WebClient
1. Overview In this article, we’re going to show the WebClient – a reactive web client that’s being introduced in Spring 5. We’re going to have a look at the WebTestClient as well – which is a...
View ArticleOAuth2 Remember Me with Refresh Token
1. Overview In this article, we will add a “Remember Me” functionality to an OAuth 2 secured application, by leveraging the OAuth 2 Refresh Token. This article is a continuation of our series on using...
View ArticleSemaphores in Java
1. Overview In this quick tutorial, we’ll explore the basics of semaphores and mutexes in Java. 2. Semaphore We’ll start with java.util.concurrent.Semaphore. We can use semaphores to limit the number...
View ArticleType Erasure in Java
1. Overview In this quick article, we’ll discuss the basics of an important mechanism in Java’s generics known as type erasure. 2. What is Type Erasure? Type erasure can be explained as the process of...
View Article