<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Muntaaha Rahman on Medium]]></title>
        <description><![CDATA[Stories by Muntaaha Rahman on Medium]]></description>
        <link>https://medium.com/@muntaaha.rahman3001?source=rss-ba06bbf29926------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*msVtPhNCZD_MknV0</url>
            <title>Stories by Muntaaha Rahman on Medium</title>
            <link>https://medium.com/@muntaaha.rahman3001?source=rss-ba06bbf29926------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 22:25:00 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@muntaaha.rahman3001/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[99.999% Available? The Myth Behind the Nines]]></title>
            <link>https://medium.com/@muntaaha.rahman3001/99-999-available-the-myth-behind-the-nines-50e4c8b059fe?source=rss-ba06bbf29926------2</link>
            <guid isPermaLink="false">https://medium.com/p/50e4c8b059fe</guid>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[availability]]></category>
            <category><![CDATA[scalable-applications]]></category>
            <dc:creator><![CDATA[Muntaaha Rahman]]></dc:creator>
            <pubDate>Sun, 27 Jul 2025 22:11:35 GMT</pubDate>
            <atom:updated>2025-07-27T22:11:35.227Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/688/1*-XznMI7adurwoBUkM_Mycg.png" /></figure><p>Your users don’t care about your SLAs. They just want it to work.</p><p>It’s 2:14 AM.<br>Your phone buzzes violently and “Critical: Service Unavailable — 500 Internal Server Error.”</p><p>You rub your eyes.<br>Your heart skips.<br>You open your dashboard.<br>Traffic flatlined. Error rates spiked. A wave of red.</p><p>And somewhere, in another part of the world, someone’s checkout page just failed.<br>A payment didn’t go through.<br>An order wasn’t placed.<br>A user uninstalled your app.</p><p>Every company brags about “uptime” — 99.9%, 99.99%, even 99.999% — like it’s a badge of honor. But here’s the uncomfortable truth, The more nines you add, the harder and more expensive it gets — and the less realistic it becomes.</p><h3>What Does 99.999% Actually Mean?</h3><p>Uptime is the percentage of time your system (website, API, service) is up and running without failure.</p><p>So, 99.9% availability means the system is available and working 99.9% of the total time in a year.</p><p>A year has, 365 days = 8,760 hours = 525,600 minutes</p><p>Now calculate the 0.1% downtime:<br>Downtime per year=0.1%×8760 hours=0.001×8760=87.6 hours/year</p><p><strong>Common Uptime SLA Levels:</strong></p><p>```<br>| Availability % | Max Downtime / Year | / Month | / Week |<br>| — — — — — — — — — — — — | — — — — — — — — — — -| — — — — — — | — — — — — — |<br>| 99% (“two nines”) | ~87.6 hours | ~7.3 hr | ~1.68 hr |<br>| 99.9% (“three nines”) | ~8.76 hours | ~43.8 min | ~10.1 min |<br>| 99.99% (“four nines”) | ~52.6 minutes | ~4.4 min | ~1 min |<br>| 99.999% (“five nines”) | ~5.26 minutes | ~26 sec | ~6 sec |<br>```</p><p>If your system claims 99.9% uptime, it must not be down for more than 8.76 hours per year — which includes outages, maintenance, and crashes.</p><p>For critical systems (e.g., banking, healthcare, real-time platforms), even a few minutes of downtime can be a huge loss, so higher availability targets (like 99.99%) are expected.</p><h3>Is Anyone Actually Achieving Five Nines?</h3><p>“Five nines” isn’t just a technical benchmark, it’s a promise of near perfection. That’s just 5 minutes of downtime per year which can be easily blown by,<br>- A flaky DNS provider<br>- A delayed database failover<br>- A single bad deployment<br>- Or even a misconfigured load balancer</p><p>To truly claim 99.999% availability, it’s not enough for just your database or backend to stay online. The entire system from frontend to backend, API gateways, CDNs, third-party services, and even mobile apps all have to meet that standard to claim true five nines. That’s an incredibly high bar.</p><p>Even companies like Netflix, known for pioneering chaos engineering and maintaining multi-region failovers, experience occasional outages. And they’re better equipped than most.</p><p>Instead of chasing “five nines”, focus on deliberate design, smart processes, and engineering culture that values resilience over perfection.</p><ol><li>Load Balancers &amp; Auto-Healing Systems<br>Combine with tools like Kubernetes, which can automatically restart crashed containers or reschedule workloads. Use load-balancers to distribute traffic and detect dead servers.</li><li>Monitoring, Alerts &amp; Observability<br>Use tools like Prometheus + Grafana to monitor uptime, latency, Error rates, system health etc.</li><li>Chaos Engineering<br>Tools like Gremlin or Netflix’s Chaos Monkey help ensure the system can tolerate real-world chaos.</li><li>Strong DevOps &amp; Incident Response<br>High availability demands more than just good code — it requires a team that can respond fast when things go wrong. Solid DevOps practices ensure you have automated rollbacks, well-defined runbooks, and on-call engineers who know exactly what to do.</li><li>Communication <br>Communicate during downtime with the users to maintain trust and transparency. Often, how we respond matters more than the outage itself.</li></ol><p>The real goal isn’t “five nines.”<br>It’s reliability that users can feel, and a system that fails gracefully, not catastrophically.</p><p>I believe in reliability more than availability but I am always open for discussion.<br>I’d genuinely appreciate your thoughts, experiences, or feedback on this topic.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=50e4c8b059fe" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kill the Bottleneck Before It Kills Your Performance]]></title>
            <link>https://medium.com/@muntaaha.rahman3001/kill-the-bottleneck-before-it-kills-your-performance-5b64ec89083f?source=rss-ba06bbf29926------2</link>
            <guid isPermaLink="false">https://medium.com/p/5b64ec89083f</guid>
            <category><![CDATA[system-design-concepts]]></category>
            <category><![CDATA[bottleneck]]></category>
            <category><![CDATA[error-handling]]></category>
            <dc:creator><![CDATA[Muntaaha Rahman]]></dc:creator>
            <pubDate>Thu, 29 May 2025 18:50:08 GMT</pubDate>
            <atom:updated>2025-05-29T18:50:08.081Z</atom:updated>
            <content:encoded><![CDATA[<p><strong><em>bottlenecks are silent killers</em></strong> — they creep in unnoticed and wreck performance if left unresolved.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/736/1*qQQYgpysoHPjQdv3A_eoww.jpeg" /></figure><p>In Greek mythology, the <strong>Gordian Knot</strong> was an impossibly tangled rope that no one could unravel — until Alexander the Great sliced through it with a sword.</p><p>Modern systems often face their own “Gordian knots”: bottlenecks hidden in layers of code, architecture, or process. Fortunately, we don’t need swords — we have <strong>profilers, monitoring tools, CI/CD pipelines, and scalable architectures</strong> to either untangle or cut right through these constraints.</p><p>Let’s dive deep,</p><p>Bottlenecks show up in unexpected places — from infrastructure to human processes. Here are some real-world scenarios where systems hit their limits.</p><p><strong>Scenario 1: </strong><br>“In one project, our API started lagging under load. Turns out, a single DB call was doing a full-table scan. Added an index — boom, 400ms → 20ms.”</p><p><strong>Scenario 2: </strong><br>“In one project, our CI/CD pipeline was taking over 30 minutes. Every push ran the full test suite sequentially, rebuilt Docker images from scratch, and reinstalled all dependencies. We added test parallelization, cached the Docker layers, and trimmed redundant steps — cut it down to 7 minutes.”</p><p><strong>Scenario 3:</strong><br>“During a flash sale, checkout ground to a halt. We found the inventory update queries were locking rows under heavy load. Switched to optimistic locking with retries — instant relief.”</p><p><strong>Scenario 4:</strong><br>“Our auth service was doing too much — login, token refresh, profile fetch. Under load, it maxed out CPU and dragged everything down. We split the service and added a lightweight token-only path — problem solved.”</p><p><strong>Scenario 5:</strong><br>“One morning, the app slowed to a crawl. Turns out, analysts were running huge ad-hoc joins on the production DB. We moved reporting to a read replica — never happened again.”</p><p>Common Areas to look for bottlenecks with explanation,</p><ul><li><strong>CPU</strong> — High utilization, thread blocking</li><li><strong>Memory</strong> — Leaks, insufficient RAM</li><li><strong>Disk I/O</strong> — Slow reads/writes</li><li><strong>Database</strong> — Slow queries, missing indexes</li><li><strong>Network</strong> — Latency, packet loss</li><li><strong>Code logic</strong> — Poor algorithms, blocking I/O</li></ul><h3><strong>Tools and Tech to Slice the Knot</strong></h3><p>Building resilient systems isn’t just about solving problems — it’s about avoiding them early.<br> <strong>Prevention is the strategy. Fixing is the safety net. Both matter — but the order matters more.</strong></p><p>There are some proven ways to prevent bottlenecks,</p><p><strong>Add Caching (Redis, CDN)</strong><br>Cache frequently used data to avoid redundant computation. Use Redis for server-side caching and CDNs to serve static assets closer to the user.</p><p><strong>Optimize DB Queries and Indexing</strong><br>Slow queries often come down to missing indexes or inefficient joins. Use tools like EXPLAIN ANALYZE to spot performance killers and tune accordingly.</p><p><strong>Use Async/Non-Blocking I/O</strong><br>When dealing with I/O-bound operations (like HTTP requests or file access), async frameworks help you handle more concurrent work without blocking.</p><p><strong>Profile Code for Hotspots</strong><br>Don’t guess — profile. Tools like Py-Spy or flamegraphs show where your code actually spends time, so you can optimize the real bottlenecks.</p><p><strong>Apply Load Balancing</strong><br>Distribute incoming traffic evenly across multiple instances or containers. This prevents any single server from becoming a chokepoint.</p><p><strong>Queue Long-Running Tasks</strong><br>Move slow jobs (like sending emails or generating reports) to background queues using Celery, Sidekiq, or similar tools. Keep your APIs snappy.</p><p><strong>Scale Horizontally or Vertically</strong><br>Vertical scaling = bigger machines. Horizontal = more machines. Pick based on your workload. Use auto-scaling to adapt on the fly.</p><p><strong>Apply Backpressure or Circuit Breakers</strong><br>If a downstream system is failing, stop hammering it. Backpressure slows the flow; circuit breakers cut it off until recovery.</p><p><strong>Use Read Replicas</strong><br>Split read traffic away from your primary DB. This is especially useful for analytics, dashboards, or high-volume public APIs.</p><p><strong>Debounce or Throttle Requests</strong><br>Prevent overload by limiting how often users (or code) can trigger expensive actions. Useful for rate-limiting buttons or API calls.</p><p><strong>Monitor Everything</strong><br>What gets measured gets fixed. Track latency, queue depth, error rates, CPU usage — and get alerted before your users start tweeting.</p><p>Bottlenecks rarely shout — they whisper through metrics, logs, and subtle symptoms. The first step to resolution is spotting <strong>the right signals</strong> early.</p><p><strong>Latency Spikes</strong>: Requests that normally take milliseconds now randomly take seconds. Often points to resource contention, blocking I/O, or scaling lag.</p><p>What to do,</p><ul><li>Move to async or event-driven code</li><li>Add indexes to slow DB queries</li><li>Warm up cold paths during deploys</li><li>Cache heavy operations</li></ul><p><strong>High Retry Rates</strong>: Services or clients retrying too often? Could be a downstream timeout or saturation issue.</p><p>What to do,</p><ul><li>Set proper timeouts and retry limits</li><li>Use circuit breakers to avoid cascading failures</li><li>Load test downstream services to find the real limits</li></ul><p><strong>Queue Buildup</strong>: Tasks piling up in message queues indicate slow consumers or blocked workers.</p><p>What to do,</p><ul><li>Add more workers or increase concurrency</li><li>Offload expensive tasks to separate queues</li><li>Profile tasks for slowness (DB access, network calls, etc.)</li></ul><p><strong>Maxed-Out Metrics</strong>: CPU at 100%, DB connection pool exhausted, thread count maxed — all signs your system is choking.</p><p>What to do,</p><ul><li>Profile and optimize the slowest functions</li><li>Upgrade instance types (vertical scaling)</li><li>Distribute load (horizontal scaling)</li><li>Apply rate limiting and backpressure</li></ul><p><strong>Error Cascades</strong>: A small failure in one part of the system causes widespread failures elsewhere. Classic result of poor isolation.</p><p>What to do,</p><ul><li>Use isolation: one service failing shouldn’t take down the system</li><li>Add timeouts, retries, and fallbacks</li><li>Consider bulkheads (separate threads/resources for critical services)</li></ul><p><strong>User Complaints Without Logs</strong>: The app <em>feels</em> slow, but logs look fine? Time to check frontend rendering or third-party APIs.</p><p>What to do,</p><ul><li>Measure frontend rendering and API timings</li><li>Enable client-side logging</li><li>Compress images, reduce JS bundle size</li><li>Use CDNs and lazy loading</li></ul><p>Below are some handy tools for tackling bottlenecks,</p><p><strong>Performance Monitoring &amp; Tracing</strong></p><ul><li><strong>Datadog, New Relic, AppDynamics</strong> — Full-stack APM to track bottlenecks across services.</li><li><strong>OpenTelemetry + Jaeger</strong> — Distributed tracing and service latency breakdown.</li><li><strong>Prometheus + Grafana</strong> — Real-time metrics and alerting.</li></ul><p><strong>Load Testing &amp; Stress Testing</strong></p><ul><li><strong>k6</strong> — Scriptable, developer-friendly load testing.</li><li><strong>Locust</strong> — Python-based performance testing.</li><li><strong>Apache JMeter</strong> — GUI-based testing for heavy loads.</li></ul><p><strong>Database Profiling &amp; Optimization</strong></p><ul><li><strong>pg_stat_statements / EXPLAIN ANALYZE (PostgreSQL)</strong> — Identify slow queries.</li><li><strong>MongoDB Atlas Profiler</strong> — Query performance monitoring.</li><li><strong>Percona Toolkit</strong> — MySQL performance analysis.</li></ul><p><strong>Caching</strong></p><ul><li><strong>Redis / Memcached</strong> — In-memory cache for fast reads.</li><li><strong>Cloudflare / Fastly / Akamai</strong> — Edge caching via CDN.</li></ul><p><strong>Async Processing &amp; Queues</strong></p><ul><li><strong>Celery / RQ / Dramatiq (Python)</strong> — Background job queues.</li><li><strong>Kafka / RabbitMQ / Redis Streams</strong> — Message brokers for decoupled processing.</li></ul><p><strong>Scaling, Load Balancing &amp; Isolation</strong></p><ul><li><strong>Kubernetes + HPA</strong> — Horizontal Pod Autoscaling.</li><li><strong>NGINX / HAProxy / Traefik</strong> — Load balancing and routing.</li><li><strong>Istio / Linkerd</strong> — Service mesh with rate limiting and circuit breaking.</li></ul><p><strong>Code Profiling</strong></p><ul><li><strong>Py-Spy / cProfile</strong> — CPU profiling for Python.</li><li><strong>Flamegraphs (Brendan Gregg)</strong> — Visualize performance bottlenecks.</li><li><strong>Chrome DevTools</strong> — Frontend JS and rendering performance.</li></ul><p><strong>Frontend Performance</strong></p><ul><li><strong>Lighthouse</strong> — Audit web performance and best practices.</li><li><strong>Sentry / LogRocket</strong> — Monitor frontend errors and user experience.</li></ul><p><em>Got a bottleneck horror story?</em> Share it in the comments!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5b64ec89083f" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>