Idiomatic concurrency: flatMap() vs. parallel() – RxJava FAQ

Simple, effective and safe concurrency was one of the design principles of RxJava. Yet, ironically, it’s probably one of the most misunderstood aspects of this library. Let’s take a simple example: imagine we have a bunch of UUIDs and for each one of them we must perform a set of tasks. The first problem is to perform I/O intensive operation per ...

Read More »

Java Message System Introduction

java-interview-questions-answers

Java Message System In this article, I will talk about Message Orientated Middleware (MOM) and how it is implemented in Enterprise Java by JMS. Also, I will discuss the typical use cases which suit the use of JMS and different terminology used to talk about messaging solutions such as Publisher/Sender, Destination/Topic/Queue and Subscriber/Receiver. I will introduce the two types of ...

Read More »

Lombok – you should definitely give it a try

spring-interview-questions-answers

Lombok is not a new thing in a Java ecosystem, but I must admit I always underestimated its value until I tried it or I was “convienced” to try it. I did not see much value in adding a library that generates code that can be easily generated by any modern IDE these days. So I ignored the library and ...

Read More »

JSP, JSF and EL Introduction

JavaServer Pages, JavaServer Faces, and Expression Language In this article, I am going to take a look at JavaServer Pages (JSP) and Expression Language (EL) and then relate it to JavaServer Faces (JSF).  I will talk about how to access HTTP objects directly in the JSP and JSF code and you will see some examples of the syntactic difference between ...

Read More »

Detecting and testing stalled streams – RxJava FAQ

Imagine you have a stream that publishes events with unpredictable frequency. Sometimes you can expect dozens of messages per second, but occasionally no events can be seen for several seconds. This can be an issue if your stream is transmitted over web socket, SSE or any other network protocol. Silent period taking too long (stall) can be interpreted as network ...

Read More »

Logging in Style: log4j 2, Contextuality, Auto-cleanup… All with No Strings Attached!

Logging—maintaining a temporal trace of operations—is vital for any mission-critical system, no matter how big or small. Same was the case with our Project-X framework, which is why we wanted to get it right, right from the beginning. Contextual logging—where each log line automatically records its originating logical context, such as whether it came from a specific unit or from ...

Read More »

Gracefully Shutting Down Java in Containers: Why You Should Double-Check!

Gracefulness is not only an admirable human quality: it is also a must-have for any application program, especially when it is heaving the burden of mission-critical domains. UltraESB has had a good history of maintaining gracefulness throughout its runtime, including shutdown. The new UltraESB-X honoured the tradition and implemented graceful shutdown in its 17.07 release. When we composed the ips-worker ...

Read More »