twitter mastodon Rust GitHub Actions

Preparing to move away from Twitter

I opened my Twitter account more than 13 years ago, in August 2009. For 12 years, I kept focusing on professional-related content: Java, the JVM, programming, etc. I built my audience, trying to promote good technical content, either my own or stuff that I enjoyed reading. Then, on February 24th, Russia invaded Ukraine. My first visit to Ukraine was in 2014, just after the Maidan revolution. During eight years, I returned there often and made plenty of friends. Of course, I wanted to support

web HTTP cache performance

Web resource caching: Server-side

The subject of Web resource caching is as old as the World Wide Web itself. However, I’d like to offer an as-exhaustive-as-possible catalog of how one can improve performance by caching. Web resource caching can happen in two different places: client-side - on the browser and server side. In the previous post, I explained the former; this post focuses on the latter. While client-side caching works well, it has one central issue: to serve the resource locally, it must first have it in the

web HTTP cache performance

Web resource caching: Client-side

The subject of Web resource caching is as old as the World Wide Web itself. However, I’d like to offer an as-exhaustive-as-possible catalog of how one can improve performance by caching. Web resource caching can happen in two different places: client-side - on the browser and server-side. This post is dedicated to the former; the next post will focus on the latter. Caching 101 The idea behind caching is simple: if a resource is a time- or resource-consuming to compute, do it once and st

API PostgreSQL PostgREST API Gateway Apache APISIX no code MVP

A poor man's API

Creating a full-fledged API requires resources, both time and money. You need to think about the model, the design, the REST principles, etc., without writing a single line of code. Most of the time, you don’t know whether it’s worth it: you’d like to offer a Minimum Viable Product and iterate from there. I want to show how you can achieve it without writing a single line of code. The solution The main requirement of the solution is to use the PostgreSQL database. It’s

Spring Boot architecture microservices

Spring Modulith: have we reached modularity maturity?

One of the main reasons to design microservices is that they enforce strong module boundaries. However, the cons of microservices are so huge that it’s like chopping off your right hand to learn to write with the left one; there are more manageable (and less painful!) ways to achieve the same result. Even since the microservices craze started, some cooler heads have prevailed. In particular, Oliver Drotbohm, a developer on the Spring framework, has been a long-time proponent of the moduli

georouting apisix geoip nginx

Geo-routing with Apache APISIX

Apache APISIX, the Apache-led API Gateway, comes out of the box with many plugins to implement your use case. Sometimes, however, the plugin you’re looking for is not available. While creating your own is always possible, it’s sometimes necessary. Today, I’ll show you how to route users according to their location without writing a single line of Lua code. Why geo-routing? Geo-routing is to forward HTTP requests based on a user’s physical location, inferred from their

API Web API RFC

Structured error messages for HTTP APIs

Ever since I started to work on the Apache APISIX project, I’ve been trying to improve my knowledge and understanding of REST RESTful HTTP APIs. For this, I’m reading and watching the following sources: Books. At the moment, I’m finishing API Design Patterns. Expect a review soon.YouTube. I’d recommend ErikWilde' channel. While some videos are better than others, they all focus on APIs.IETF RFCs. Most RFCs are not about APIs, but a friendly person compiled a list of the o

engineering solution engineering

Discuss the problem, not the solution

As a tech guy, I love to discuss technologies. And as discussions go, it’s generally the comparison kind: JVM vs. Net, Java vs. Kotlin, Go vs. Rust, Maven vs. the unspeakable one, etc. However, it’s too easy to fall into the quagmire of the merits and flaws of our beloved toys, talk about them for hours, and not reach a satisfactory agreement. A couple of years ago, I worked as a 'Solution Architect'. The job has different titles, e.g., Solution Designer, Solution Engineer, but the

exceptions lambdas Streams Apache Commons Vavr Functional Programming

Exceptions in lambdas

Java introduced the concept of checked exceptions. The idea of forcing developers to manage exceptions was revolutionary compared to the earlier approaches. Nowadays, Java remains the only widespread language to offer checked exceptions. For example, every exception in Kotlin is unchecked. Even in Java, new features are at odds with checked exceptions: the signature of Java’s built-in functional interfaces doesn’t use exceptions. It leads to cumbersome code when one integrates leg