Mid-January, I held a talk at Kotlin.amsterdam based on my post Migrating from Imperative to Reactive (a Spring Boot application). Because it was a Kotlin meetup, I demoed Kotlin code, and I added a step by migrating the codebase to coroutines. During Q&A, somebody asked whether coroutines implemented backpressure. I admit I was not sure of the answer, so I did a bit of research.
Back pressure (or backpressure) is a resistance or force opposing the desired flow of fluid through…
A couple of weeks ago, I gave my talk on Zero Downtime on Kubernetes. A demo is included in the talk, as with most of my presentations. While rehearsing in the morning, the demo worked, albeit slowly. Two days before that, I had another demo that also uses Kubernetes and it was already slow. But I didn’t take the hint.
During the demo, everything was slow: the of scheduling pods, of course…
Gone are the times when developers’ jobs ended with the release of the application. Nowadays, developers care more and more about the operational side of IT: perhaps they operate applications themselves, but more probably, their organization fosters increased collaboration between Dev and Ops.
I started to become interested in the Ops side of software when I was still a consultant. When Spring Boot released the Actuator, I became excited. Via its convention-other-configuration nature, it was possible to add monitoring endpoints with just an additional dependency.
Since then, other frameworks have popped up. They also provide monitoring capabilities. …
When your application goes beyond a dozen of lines of code, you should probably split the code into multiple classes. At this point, the question is how to distribute them. In Java, the classical format is the Java ARchive, better known as the JAR. But real-world applications probably depend on other JARs.
This post aims to describe ways to create self-contained executable JARs, also known as uber-JARs or fat JARs.
A JAR is just a collection of class files. To be executable, its
META-INF/MANIFEST.MF file should point to the class that implements the
main() method. You do this with the…
Collectors methods fit most use-cases. They allow returning either a
Collection or a scalar. For the former, you use one of the
toXXX() method, for the latter, one of the
Let’s imagine an e-commerce platform that implements a shopping cart. The cart is modeled as the following:
This week’s post is pretty short. I’ve already written about overengineering, but this adds a personal touch.
I had to rewrite my Jet Train demo to use another data provider, switching from a Swiss one to a Bay Area one. One of the main components of the demo is a streaming pipeline. The pipeline:
Most of the transform steps in #2 enrich the data. Each of them requires an implementation of a
These implementations all follow the same pattern:
Kotlin offers many exciting features. In general, developers tend to cite null safety as their favorite. For me, it’s function extensions. But delegation comes a close second.
The delegation pattern is described in the GoF book:
Delegation is a way to make composition as powerful for reuse as inheritance [Lie86, JZ91]. In delegation, two objects are involved in handling a request: a receiving object delegates operations to its delegate. This is analogous to subclasses deferring requests to parent classes. But with inheritance, an inherited operation can always refer to the receiving object through the
thismember variable in C++ and…
Frameworks promise to speed up one’s development pace provided one follows the mainstream path. The path may be more or less narrow. I’m a big fan of the Spring ecosystem because its design is extensible and customizable at different abstraction levels: thus, the path is as large as you need it to be.
Functional Programming is becoming more and more popular. Spring provides a couple of DSLs for the Kotlin language. For example, the Beans DSL and the Routes DSL allow for a more functional approach toward Spring configuration. …
A couple of years ago, I attended a talk of my former colleague (but still friend) Volker Simonis. It gave me the idea to dig a bit into the subject of how to secure the JVM. From the material, I created a series of blog posts as well as a talk.
From that point on, I submitted the talk at meetups and conferences, where it was well-received. Because I like to explore different areas, I stopped to submit other proposals. Still, the talk is in my portfolio, and it was requested again in 2021. …
Dev Advocate @Hazelcast . Former developer and architect. Still teaching, learning and blogging.