<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Madhu</title>
    <description>The latest articles on DEV Community by Madhu (@madhukashyap).</description>
    <link>https://dev.to/madhukashyap</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3556973%2Ff023a321-697e-466d-b2d2-bda1e4c3dfec.jpeg</url>
      <title>DEV Community: Madhu</title>
      <link>https://dev.to/madhukashyap</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/madhukashyap"/>
    <language>en</language>
    <item>
      <title>💔 Love in the Time of Microservices.</title>
      <dc:creator>Madhu</dc:creator>
      <pubDate>Fri, 24 Oct 2025 14:46:16 +0000</pubDate>
      <link>https://dev.to/madhukashyap/love-in-the-time-of-microservices-3c2n</link>
      <guid>https://dev.to/madhukashyap/love-in-the-time-of-microservices-3c2n</guid>
      <description>&lt;p&gt;Microservices were supposed to be independent. They were supposed to scale on their own. They were supposed to fail gracefully.&lt;/p&gt;

&lt;p&gt;But then came… tight coupling — the forbidden love story of distributed systems.&lt;/p&gt;

&lt;h3&gt;
  
  
  ❤️ Act 1: “You Complete Me()”
&lt;/h3&gt;

&lt;p&gt;“I can’t function without your API.”&lt;/p&gt;

&lt;p&gt;Everything was beautiful at first.&lt;br&gt;
Order Service couldn’t do a thing without Payment Service — and Payment Service was always there to respond. They called each other constantly. They shared secrets (and DTOs). Then one day, Payment Service went down. Order Service panicked. The circuit breaker blew. It was chaos.&lt;br&gt;
And that’s when we realized: “This isn’t love. This is synchronous dependency.” 😭&lt;/p&gt;

&lt;h3&gt;
  
  
  💌 Act 2: “Let’s Take a Break()”
&lt;/h3&gt;

&lt;p&gt;“Maybe we should go asynchronous.”&lt;/p&gt;

&lt;p&gt;The architect intervened. “Listen,” he said. “You two need some space.” So they moved to event-driven communication.&lt;br&gt;
Now, Order just emits an event, and waits. If Payment responds later, great. If not, life goes on. No more late-night blocking calls. No more waiting for ACKs that never come.&lt;/p&gt;

&lt;h3&gt;
  
  
  💔 Act 3: “You Changed Your Schema… Again.”
&lt;/h3&gt;

&lt;p&gt;“We said we’d always be backward compatible!”&lt;/p&gt;

&lt;p&gt;One day, Payment updated its API. New JSON field. Slightly different response shape. No warning.&lt;br&gt;
Suddenly, Order Service couldn’t parse half its responses.&lt;br&gt;
Deployments failed. Rollbacks started. Monitoring alerts screamed.&lt;/p&gt;

&lt;h3&gt;
  
  
  😤 Act 4: “I Need My Own Space (Database)”
&lt;/h3&gt;

&lt;p&gt;“We can’t share the same DB forever.”&lt;/p&gt;

&lt;p&gt;They tried to be modern, but deep down they still shared the same monolithic database. It was convenient… until it wasn’t.&lt;br&gt;
Deadlocks, foreign keys, and cascading deletes tore them apart.&lt;br&gt;
Sharing a schema isn’t romance — it’s co-dependency.&lt;br&gt;
They finally split up. Each took their own DB and started publishing events like healthy adults.&lt;br&gt;
“We’re still connected,” said Order,“just eventually consistent.” 💔&lt;/p&gt;

</description>
      <category>springboot</category>
      <category>funny</category>
      <category>jokes</category>
      <category>programming</category>
    </item>
    <item>
      <title>🐶Spring Boot, but Every Exception Is a Dog Breed</title>
      <dc:creator>Madhu</dc:creator>
      <pubDate>Wed, 15 Oct 2025 07:05:58 +0000</pubDate>
      <link>https://dev.to/madhukashyap/spring-boot-but-every-exception-is-a-dog-breed-4lja</link>
      <guid>https://dev.to/madhukashyap/spring-boot-but-every-exception-is-a-dog-breed-4lja</guid>
      <description>&lt;p&gt;You know how every Spring Boot exception has its own personality?&lt;br&gt;
Some are calm, some bark all day, and some will destroy your entire project because you missed one annotation 😩&lt;br&gt;
So I decided to imagine what each of them would be — if they were dog breeds. Because if I can’t fix my exceptions, I might as well give them personalities. &lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 1. NullPointerException: The Labrador
&lt;/h3&gt;

&lt;p&gt;Always excited, always running, and then — BAM 💥 — crashes into the wall because something wasn’t initialized..&lt;/p&gt;

&lt;p&gt;Description: Friendly and everywhere, but if you forget to check for null… it’ll take the whole app down.&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 2. BeanCreationException: The German Shepherd
&lt;/h3&gt;

&lt;p&gt;Super loyal, but very strict about rules. If even one bean is missing or misconfigured, it’ll bark at you like:&lt;/p&gt;

&lt;p&gt;“WHO REGISTERED THIS CLASS WITHOUT @Component?”&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 3. HttpMessageNotReadableException: The Chihuahua
&lt;/h3&gt;

&lt;p&gt;Loud, angry, and usually triggered by something tiny — like an extra comma in your JSON.&lt;/p&gt;

&lt;p&gt;Mood: “I can’t read this! What is this malformed request body you’ve sent me?!”&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 4. DataIntegrityViolationException: The Bulldog
&lt;/h3&gt;

&lt;p&gt;Doesn’t move. Doesn’t care. Will not let you insert duplicate values into that column no matter how nicely you ask.&lt;/p&gt;

&lt;p&gt;Vibe: “Primary key means ONE, hooman. ONE.”&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 5. CircularDependencyException: The Husky
&lt;/h3&gt;

&lt;p&gt;Loves running in circles. You can fix it ten times, and it’ll still find another way to chase its own tail.&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 6. ApplicationContextException: The Dalmatian
&lt;/h3&gt;

&lt;p&gt;You think you’ve seen them all, but every one looks slightly different.&lt;/p&gt;

&lt;p&gt;Always appears right before you deploy something important. Spots everywhere (logs, stack traces, everything).&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 7. LazyInitializationException: The Beagle
&lt;/h3&gt;

&lt;p&gt;Shows up late to the party, starts sniffing around the database long after the session is closed.&lt;/p&gt;

&lt;p&gt;Quote: “Wait, where’s the EntityManager? I just wanted to fetch the relationships!”&lt;/p&gt;

&lt;h3&gt;
  
  
  🐕 8. ResourceNotFoundException: The Golden Retriever
&lt;/h3&gt;

&lt;p&gt;Tries its best, runs the fetch query, comes back with nothing… still happy though.&lt;br&gt;
Message: “Couldn’t find it, but I love you anyway ❤️”&lt;/p&gt;

&lt;p&gt;Which one do you think should be here in the list? 😀&lt;/p&gt;

</description>
      <category>java</category>
      <category>springboot</category>
      <category>jokes</category>
    </item>
    <item>
      <title>☕ Is Java Dead? Nope — It’s Just Too Busy Running the World</title>
      <dc:creator>Madhu</dc:creator>
      <pubDate>Fri, 10 Oct 2025 07:25:57 +0000</pubDate>
      <link>https://dev.to/madhukashyap/is-java-dead-nope-its-just-too-busy-running-the-world-2e77</link>
      <guid>https://dev.to/madhukashyap/is-java-dead-nope-its-just-too-busy-running-the-world-2e77</guid>
      <description>&lt;p&gt;Every year, someone on Reddit or Twitter confidently announces:&lt;br&gt;
“Java is dead” and every year, millions of Java applications keep running the internet.&lt;br&gt;
Let’s be honest — Java’s been around since 1995.&lt;br&gt;
It’s not flashy like Go or Rust, and it doesn’t come with hype-driven frameworks every six months. People look at the syntax and say, “Eww, semicolons and classes everywhere.”&lt;/p&gt;

&lt;p&gt;🌍Is java really dead in the modern era?&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;90% of enterprise systems? ✅ Still Java.&lt;/li&gt;
&lt;li&gt;Billions of Android apps? ✅ Java roots.&lt;/li&gt;
&lt;li&gt;Trading systems in banks? ✅ Mostly Java.&lt;/li&gt;
&lt;li&gt;Even Netflix, Amazon, and LinkedIn run critical parts of their systems on Java.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Java isn’t dead — it’s just not screaming for attention on social media, it’s too busy getting work done quietly in production. 😎&lt;/p&gt;

&lt;h3&gt;
  
  
  ⚡ The Evolution of Java
&lt;/h3&gt;

&lt;p&gt;Java isn’t that stiff — it’s been hitting the gym 💪.&lt;/p&gt;

&lt;p&gt;🧩 Java 8 (2014) — The Big Revolution&lt;/p&gt;

&lt;p&gt;Java 8 completely changed how developers wrote Java. It made code functional, cleaner, and modern.&lt;br&gt;
Major Features:&lt;/p&gt;

&lt;p&gt;➡️ Lambda Expressions — bring functional programming to Java.&lt;br&gt;
➡️ Stream API — process collections elegantly (map(), filter(), reduce() 🔥).&lt;br&gt;
➡️ Default &amp;amp; Static Methods in Interfaces — evolution of interfaces.&lt;br&gt;
➡️ java.time API — finally, modern date &amp;amp; time handling.&lt;br&gt;
➡️ Optional — avoid those nasty NullPointerExceptions.&lt;br&gt;
➡️ Nashorn JavaScript Engine — run JS code inside Java.&lt;/p&gt;

&lt;p&gt;⚙️ Java 11 (2018) — The Polished Performer&lt;/p&gt;

&lt;p&gt;Java 11 focused on productivity, simplicity, and cleanup — fewer old APIs, more modern tools.Major Features:&lt;/p&gt;

&lt;p&gt;➡️ Local Variable Type Inference (var) — cleaner variable declarations.&lt;br&gt;
➡️ HTTP Client API (standardized) — replace old HttpURLConnection.&lt;br&gt;
➡️ String Utility Methods — lines(), isBlank(), strip(), repeat().&lt;br&gt;
➡️ File Handling Simplified — Files.readString() &amp;amp; writeString().&lt;br&gt;
➡️ Removed Java EE and CORBA modules — lighter runtime.&lt;br&gt;
➡️ Z Garbage Collector (ZGC) — super low latency GC.&lt;/p&gt;

&lt;p&gt;🚀 Java 17 (2021) — The LTS Game-Changer&lt;/p&gt;

&lt;p&gt;Java 17 brought performance, syntax upgrades, and security — the go-to choice for enterprise apps today.&lt;br&gt;
Major Features:&lt;/p&gt;

&lt;p&gt;➡️ Sealed Classes — control which classes can extend a parent.&lt;br&gt;
➡️ Pattern Matching for instanceof — cleaner type checks.&lt;br&gt;
➡️ Records — simple, immutable data carriers (bye-boilerplate 👋).&lt;br&gt;
➡️ Text Blocks (""") — multiline strings for JSON &amp;amp; SQL.&lt;br&gt;
➡️ New macOS rendering pipeline — better performance on Mac.&lt;br&gt;
➡️ Strong Encapsulation in JDK internals — improved security.&lt;/p&gt;

&lt;p&gt;🧠 Java 21 (2023) — The Future-Ready Java&lt;/p&gt;

&lt;p&gt;Java 21 is where things get exciting — lightweight concurrency, structured tasks, and even simpler syntax.&lt;br&gt;
Major Features:&lt;/p&gt;

&lt;p&gt;➡️ Virtual Threads (Project Loom) — thousands of threads without performance issues 😍.&lt;br&gt;
➡️ Record Patterns — deconstruct records elegantly.&lt;br&gt;
➡️ Pattern Matching for switch — expressive and concise.&lt;br&gt;
➡️ Sequenced Collections API — consistent ordering for lists, sets, maps.&lt;br&gt;
➡️ String Templates (Preview) — inline variable interpolation.&lt;br&gt;
➡️ Scoped Values (Preview) — thread-local data made easy.&lt;/p&gt;

&lt;h3&gt;
  
  
  ☕ Why We Still Use Java (and Probably Will for Years)
&lt;/h3&gt;

&lt;p&gt;🧱 1. It Just Works — and Keeps Working&lt;br&gt;
Java isn’t flashy — it’s reliable. Enterprises love it because systems written 10 years ago still run today with minimal changes.&lt;/p&gt;

&lt;p&gt;🧠 3. The JVM = Secret Superpower&lt;br&gt;
Java isn’t just a language — it’s a platform.&lt;br&gt;
The JVM (Java Virtual Machine) runs not just Java, but also Kotlin, Scala, Groovy, and Clojure. That means: &lt;strong&gt;One runtime, many languages&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;🔥 5. Performance That Competes&lt;/p&gt;

&lt;p&gt;With modern garbage collectors (G1, ZGC, Shenandoah) and JIT compilers, Java’s runtime is fast and predictable.&lt;br&gt;
It may not beat C++ in raw performance, but for web-scale, distributed apps, it’s incredibly efficient.&lt;/p&gt;

&lt;p&gt;💬 What Do You Think?&lt;br&gt;
Is Java still worth learning in 2025?&lt;br&gt;
Or is it time to move on to Kotlin, Go, or Rust?&lt;br&gt;
Drop your thoughts below — I’m ready for the debate!!!&lt;/p&gt;

</description>
      <category>java</category>
      <category>interview</category>
      <category>programming</category>
    </item>
    <item>
      <title>🌀 Let's understand Retries in Spring Boot</title>
      <dc:creator>Madhu</dc:creator>
      <pubDate>Fri, 10 Oct 2025 06:46:37 +0000</pubDate>
      <link>https://dev.to/madhukashyap/understanding-retries-in-spring-boot-1jm7</link>
      <guid>https://dev.to/madhukashyap/understanding-retries-in-spring-boot-1jm7</guid>
      <description>&lt;p&gt;💡 What’s a Retry?&lt;/p&gt;

&lt;p&gt;A retry means trying an operation again if it fails the first time. For example:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Your app calls a weather API.&lt;/li&gt;
&lt;li&gt;It fails because of a slow connection.&lt;/li&gt;
&lt;li&gt;You try again after 1 second — and it works! 🌤️&lt;/li&gt;
&lt;li&gt;Retries help your app become more reliable, especially when dealing with temporary issues.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;⚙️ Doing Retries in Spring Boot (The Simple Way)&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Step 1&lt;/strong&gt;&lt;br&gt;
Spring Boot has a library called Spring Retry that makes this super easy.Let’s add it first.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;&amp;lt;dependency&amp;gt;
    &amp;lt;groupId&amp;gt;org.springframework.retry&amp;lt;/groupId&amp;gt;
    &amp;lt;artifactId&amp;gt;spring-retry&amp;lt;/artifactId&amp;gt;
&amp;lt;/dependency&amp;gt;
&amp;lt;dependency&amp;gt;
    &amp;lt;groupId&amp;gt;org.springframework.boot&amp;lt;/groupId&amp;gt;
    &amp;lt;artifactId&amp;gt;spring-boot-starter-aop&amp;lt;/artifactId&amp;gt;
&amp;lt;/dependency&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Step 2&lt;/strong&gt;&lt;br&gt;
Enable retries in your main class&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@SpringBootApplication
@EnableRetry
public class RetryDemoApplication {
    public static void main(String[] args) {
        SpringApplication.run(RetryDemoApplication.class, args);
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Step 3&lt;/strong&gt; &lt;br&gt;
Use @Retryable, so wherever a method might fail (for example, calling an external API), you can tell Spring to retry automatically.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;@Service
public class WeatherService {

    @Retryable(maxAttempts = 3, backoff = @Backoff(delay = 2000))
    public String callWeatherAPI() {
        System.out.println("Calling weather API...");
        if (Math.random() &amp;lt; 0.7) {
            throw new RuntimeException("API failed!");
        }
        return "Weather is Sunny ☀️";
    }

    @Recover
    public String recover(RuntimeException e) {
        return "Weather service is temporarily unavailable 🌧️";
    }
}
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;🔍 What’s Happening Here&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;@Retryable → Tells Spring to retry this method up to 3 times.&lt;/li&gt;
&lt;li&gt;@Backoff(delay = 2000) → Wait 2 seconds between retries.&lt;/li&gt;
&lt;li&gt;@Recover → If all retries fail, this method is called instead of crashing the app.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Retries are like giving your app a second chance to succeed.&lt;br&gt;
With just two annotations — @Retryable and @Recover — you can make your Spring Boot app much more reliable.&lt;/p&gt;

</description>
      <category>springboot</category>
      <category>circuitbreaker</category>
      <category>backenddevelopment</category>
      <category>beginners</category>
    </item>
  </channel>
</rss>
