Blog

  • My PTE Core Exam Experience and Results

    I took my exam on November 12, 2025 in São Paulo. I knew that results are available within 5 days, but the majority of people receive them within 48 hours, and some people even get them on the same day! So after the exam, I checked every new email immediately to see whether it was…

  • Two Sum – Easy LeetCode Problem

    Let’s take the classic Two Sum problem and move it from slow and clunky to clean and quick. Problem The original problem description from leetcode . We are given: Our task is to find two different elements in nums whose sum equals target, then return their indices as an array. Extra rules: Here is an…

  • Consistency Models and Leader-Follower Replication

    Discover how various consistency models (eventual, causal, sequential, linearizable, and more) can be implemented on top of leader-follower replication. This article demystifies the hidden delays in synchronous replication, how asynchronous replicas can yield out-of-order writes, and what it takes to achieve stronger models like external consistency in real-world systems.

  • Database Replication Streams: From Statement‑Based to WAL

    Introduction In the previous article I wrote about basics of leader-follower replication, its variations and common problems. This article focuses on how exactly the changes on the leader are replicated to followers. Replication Streams: what they are? There are several ways of sending changes (represented with boxes with question marks on the image above) and…

  • Understanding Leader-Follower Replication

    Ever wonder how massive systems like MySQL, MongoDB, or Kafka keep your data safe from node failures while serving millions of users? Leader-Follower Replication is the behind-the-scenes orchestration that makes it work. This article offers a behind-the-curtain look at how one “leader” node handles all writes, how “followers” stay in sync even across different data…

  • Monotoinc Writes: Implementing using Version Vectors

    Explains how to achieve Monotoinc Writes session guarantee (aka client-centric consistency model) effectively using Version Vectors. Apart from this shows why the Implementation is needed, what could be naive implementation which is based on the definition of Monotoinc Writes and an alternative of using sticky sessions and its downsides.

  • Write Follows Read : Implementing using Version Vectors

    Explains how to achieve Write Follows Read session guarantee (aka client-centric consistency model) effectively using Version Vectors. Apart from this shows why the Implementation is needed, what could be naive implementation which is based on the definition of Write Follows Read and an alternative of using sticky sessions and its downsides.

  • Monotonic Reads: Implementing using Version Vectors

    Monotonic Reads: Implementing using Version Vectors

    Explains how to achieve Monotonic-Reads session guarantee (aka client-centric consistency model) effectively using Version Vectors. Apart from this shows why the Implementation is needed, what could be naive implementation which is based on the definition of Monotonic Reads and an alternative of using sticky sessions and its downsides.

  • Read Your Writes: Implementing using Version Vectors

    Read Your Writes: Implementing using Version Vectors

    Explains how to achieve Read-Your-Writes session guarantee (aka client-centric consistency model) effectively using Version Vectors. Apart from this shows why the Implementation is needed, what could be naive implementation which is based on the definition of Read Your Writes and an alternative of using sticky sessions and its downsides.

  • Merge Sort: Top-Down, Bottom-Up, Natural with code in Kotlin

    Merge Sort: Top-Down, Bottom-Up, Natural with code in Kotlin

    Explanation of how different variations of Merge Sort work – Top-Down, Bottom-Up, Natural Merge Sort. Several optimisations of the algorithm is explained. It is shown in understandable manner why the complexity of merge sort is O(NlogN). Optimality of merge sort is explored. Source code in kotlin is available in github repository