Blog

Collection of curated blog posts from me.

Building Streaming API with gRPC

In this article, I’ll guide you through implementing streaming APIs using gRPC in Java. We’ll look at various types of streaming. Then, we’ll create a practical example to show real-time flow. Introduction Many developers know about traditional request-response APIs. Yet, modern apps often need real-time data streaming. gRPC provides powerful streaming capabilities that can transform how your services communicate. Whether you’re making chat apps, real-time analytics, or IoT systems, knowing gRPC streaming is key. Let’s create a weather monitoring service. It will stream temperature updates to clients.

Read more →

February 21, 2025

Redis Caching Pattern in Java Applications - From Theory to Practice

Introduction Picture this: your Java application is handling thousands of requests per second, but your database is struggling to keep up. Response times are climbing, and your team is debating whether to throw more hardware at the problem. Sounds familiar? This is where Redis shines. Redis started as a tool for real-time analytics at Twitter (now X). Now, it’s a versatile caching solution. It manages everything from basic key-value storage to advanced message brokering.

Read more →

February 13, 2025

Spring Boot & Resilience4j - Mastering circuit breakers with Prometheus and Grafana

A comprehensive guide to implementing resilient microservices: from basic circuit breaker patterns to advanced monitoring with Prometheus and Grafana Electrical chain Introduction Imagine you’re building a microservice—based application where many services depend on each other. What happens when one service strt failing? Without proper error handling, failures can cascade through your system. They could bring down the entire application. This is where circuit breaker pattern comes in.

Read more →

February 3, 2025

Essential code review practices that actually save time

Code reviews are crucial for software quality, but without proper best practices, they can become a bottleneck. Here are three (of course, it can be more) reviews efficient yet high - quality. I’ll include real examples where they help 1. Review in small batches Don’t wait to review 500+ lines of code at once. Encourage small, focused pull request of 200–300 lines at a maximum. Real situation: Last month, our team had to review a massive pull request that touched our entire authentication system.

Read more →

January 30, 2025

Property-Based Testing with jqwik - A Practical Guide

Introduction As software grows more complex, traditional example-based testing often fails. It can’t find edge cases and unexpected behaviors. Property-based testing (PBT) is a powerful alternative. It generates test cases based on properties that your code should meet without any manual input. This article will explore property-based testing using jqwik. It’s a modern property-based testing library for Java. What is property-based testing? Property-based testing is a method. Instead of writing specific test cases, you define properties. Your code must meet them in all cases. The testing framework then generates many test cases to verify these properties.

Read more →

January 23, 2025

Building Event-Driven Microservices with Spring Cloud Stream and Kafka

Modern applications face increasingly complex challenges in handling data and interactions between services. As our systems grow, traditional request-response patterns often become bottlenecks. This leads to seek more flexible, scalable solutions. This is where event-driven architecture (EDA) comes in. It offers a powerful way to build resilient microservices. Why event-driven architecture? Think of event architecture like a city’s postal system. Instead of calling each other, services send messages (events) through a central messaging system. This approach enables services to operate without relying on one another. It’s like how different postal offices operate without knowing each other’s internal workings. When one service has something important to share, it publishes an event, and any interested services can react to it in their own time.

Read more →

December 19, 2024

Spring Boot with Temporal - Building Resillient Workflow Applications

A guide to building resilient, distributed apps with Spring Boot and Temporal’s orchestration. Introduction Building reliable distributed applications can be challenging. System crash, network fail, and processes can get stuck halfway through execution. This is where Temporal comes in. It is an open-source workflow orchestration platform. When combined with Spring Boot, it helps you build robust apps. These apps can handle real-world challenges. Why should you care about Temporal? If you’ve worked with distributed systems, you’ve likely faced process failures. They can leave your system inconsistent. They processed a payment but didn’t update the order. Or, they sent an email but didn’t update the database. Temporal solve these problems. It provides durable execution, automatic retries, and state management. With Spring Boot, Temporal gives you tools for complex processes. It also keeps familiar Spring ecosystem you know. You get the best of both worlds. You get Spring’s dependency injection and configuration. You also get Temporal’s workflow management features.

Read more →

December 12, 2024

Master Java Release with GitHub Actions and Maven Release plugin

Introduction In software development, automating the release process is key. It ensures efficiency and consistency in a fast-paced field. Many Java developer struggle with manual release. They face issues with version management and Git tagging. This article will show you how to automate your release process using GitHub Actions and the Maven Release plugin Prerequisites Before diving into the implementation, ensure you have

Read more →

December 5, 2024

Build a MatterMost Bot with Java - Practical guide

Introduction Weather info in your team chat can help with office planning and casual chats. This article will build a simple, practical MatterMost bot. It will post daily weather updates using Java, Spring Boot, and weather API. What we will build Spring Boot application that: Connects to MatterMost via webhooks. Fetches weather data from OpenWeatherMap API. Posts daily weather updates at 9:00 AM. Prerequisites Java 17 Maven or Gradle Docker Implementation Let’s start bot development using the MatterMost server on our local environment. Create a docker-compose file with the following content.

Read more →

November 28, 2024

Pulumi for Java Developer - Getting started with IaC

Introduction In today’s cloud-native world, managing infrastructure by hand is no longer practical. Infrastructure as Code (IaC) has emerged as the de facto standard for managing cloud resources. Terraform has dominated this space with its domain-specific language. Pulumi takes a different approach, which benefits Java Developers. What is Pulumi? Pulumi is a modern Infrastructure as Code platform. It lets developers use familiar programming languages instead of domain specific one like HCL or YAML. For Java developers, this means using their knowledge of Java, strong typing, and OOP. They must use the whole Java ecosystem to manage cloud infrastructure.

Read more →

November 21, 2024