Season 01
18 article(s) in this season
-
29 Jul 2025
💊 #18: Optimising your code with WebFlux, p. 2 – the share method
The .share() method turns a cold Flux into a hot one: the source runs only once and concurrent subscribers receive the same stream.
-
21 Jul 2025
💊 #17: Optimising your code with WebFlux, p. 1 – the cache method
Flux's .cache() method stores the values emitted on the first subscription and reuses them for the following ones, avoiding recomputation on the source.
-
12 Jul 2025
💊 #16: ArgumentCaptor – gotta test 'em all!
Mockito ArgumentCaptor: beyond a plain verify(), inspecting the arguments actually passed to a mocked method to test side-effects too.
-
03 Jul 2025
💊 #15: Orchestrator + Strategy = fallback with style!
Combining the orchestrator pattern and the strategy pattern to handle dynamic fallbacks (e.g. audio transcription): decoupled, extensible and testable code.
-
21 Jun 2025
💊 #14: Is Mono a lazybones? It depends!
Mono.just() evaluates its argument immediately (eager), Mono.fromCallable() defers execution until subscription (lazy): handy for potentially blocking operations.
-
17 Jun 2025
💊 #13: Where does the Mono run?
A Mono's execution thread changes when you use subscribeOn(): by default it's the subscriber's thread, with boundedElastic() it moves to the pool dedicated to blocking I/O operations.
-
24 Mar 2025
💊 #12: The zip methods with a combinator
Using the combinator variants of Mono.zip, zipWith and zipWhen to get a well-typed object directly instead of a Tuple2, plus a custom helper for the N-Mono case (with N > 2).
-
04 Mar 2025
💊 #11: Agile Git Flow with hierarchical merging
A variant of Git Flow hybridised with Trunk-Based Development for agile teams: 4 branch levels (master/develop/sprint/feature), squash merges from child to parent and a clean history.
-
16 Feb 2025
💊 #10: Migrating a BE architecture to a new data model
Horizontal refactoring of the repositories, vertical refactoring of services and converters, ~100 integration tests, over 500 unit tests, and a 4-branch git strategy to migrate the data model without blocking ongoing development.
-
12 Feb 2025
💊 #9: Solving development problems with AI – from prompt to code
Delegating a Java list-aggregation problem to ChatGPT: an abstract prompt (no domain leak) + a solution with Collectors.groupingBy and flatMap.