<?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:itunes="http://www.itunes.com/dtds/podcast-1.0.dtd" xmlns:googleplay="http://www.google.com/schemas/play-podcasts/1.0"><channel><title><![CDATA[Hasan Mahmud Rhidoy]]></title><description><![CDATA[Crafting Cutting-Edge Solutions with Code Wizardry | Driving Innovation in Fintech Solutions]]></description><link>https://rhidoyhasanmahmud.substack.com</link><image><url>https://substackcdn.com/image/fetch/$s_!kNqu!,w_256,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1d7cfbbf-3184-488b-9b89-0cde6acf9c5b_2065x2940.jpeg</url><title>Hasan Mahmud Rhidoy</title><link>https://rhidoyhasanmahmud.substack.com</link></image><generator>Substack</generator><lastBuildDate>Tue, 26 May 2026 03:48:30 GMT</lastBuildDate><atom:link href="https://rhidoyhasanmahmud.substack.com/feed" rel="self" type="application/rss+xml"/><copyright><![CDATA[Hasan Mahmud Rhidoy]]></copyright><language><![CDATA[en]]></language><webMaster><![CDATA[rhidoyhasanmahmud@substack.com]]></webMaster><itunes:owner><itunes:email><![CDATA[rhidoyhasanmahmud@substack.com]]></itunes:email><itunes:name><![CDATA[Hasan Mahmud Rhidoy]]></itunes:name></itunes:owner><itunes:author><![CDATA[Hasan Mahmud Rhidoy]]></itunes:author><googleplay:owner><![CDATA[rhidoyhasanmahmud@substack.com]]></googleplay:owner><googleplay:email><![CDATA[rhidoyhasanmahmud@substack.com]]></googleplay:email><googleplay:author><![CDATA[Hasan Mahmud Rhidoy]]></googleplay:author><itunes:block><![CDATA[Yes]]></itunes:block><item><title><![CDATA[Exploring Brain-Computer Interface (BCI): My First Step into Neurotechnology]]></title><description><![CDATA[[Part - 1]]]></description><link>https://rhidoyhasanmahmud.substack.com/p/exploring-brain-computer-interface</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/exploring-brain-computer-interface</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Fri, 15 May 2026 01:37:38 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/425f5012-9563-4467-9430-cf5b803948fc_858x568.webp" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>&#2438;&#2455;&#2494;&#2478;&#2496;&#2453;&#2494;&#2482;, 15 May 2026, &#2438;&#2478;&#2495; &#2447;&#2453;&#2463;&#2495; Brain-Computer Interface (BCI) workshop-&#2447; &#2437;&#2434;&#2486;&#2455;&#2509;&#2480;&#2489;&#2467; &#2453;&#2480;&#2468;&#2503; &#2479;&#2494;&#2458;&#2509;&#2459;&#2495;, &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; EEG Signal Processing, Neurotechnology, &#2447;&#2476;&#2434; Python-based hands-on analysis &#2472;&#2495;&#2527;&#2503; &#2476;&#2495;&#2477;&#2495;&#2472;&#2509;&#2472; technical session &#2469;&#2494;&#2453;&#2476;&#2503;&#2404;</p><h4>Workshop Details</h4><p>&#128205; Venue: <strong>Xiamen University, Malaysia (</strong>A3-618)<br>&#128197; Event: BCI Workshop 2026<br>&#129504; Main Focus Areas:</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><ul><li><p>EEG Processing</p></li><li><p>Brain-Computer Interface (BCI)</p></li><li><p>Neurotechnology</p></li><li><p>Python-based Analysis</p></li><li><p>Hands-on Learning Session</p></li></ul><p>Workshop-&#2447; &#2437;&#2434;&#2486; &#2472;&#2503;&#2451;&#2527;&#2494;&#2480; &#2438;&#2455;&#2503; topic &#2455;&#2497;&#2482;&#2507; &#2488;&#2478;&#2509;&#2474;&#2480;&#2509;&#2453;&#2503; &#2447;&#2453;&#2463;&#2495; foundational understanding &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2494;&#2480; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2459;&#2495;, &#2479;&#2494;&#2468;&#2503; session-&#2447;&#2480; discussion, live demonstration, research concepts, &#2447;&#2476;&#2434; hands-on activities &#2455;&#2497;&#2482;&#2507; &#2438;&#2480;&#2451; effectively relate &#2451; interpret &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2495;&#2404;</p><p>&#2447;&#2439; document &#2463;&#2495; &#2478;&#2498;&#2482;&#2468; &#2438;&#2478;&#2494;&#2480; pre-workshop learning notes &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2474;&#2509;&#2480;&#2488;&#2509;&#2468;&#2497;&#2468; &#2453;&#2480;&#2494; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404; &#2447;&#2454;&#2494;&#2472;&#2503; BCI ecosystem, EEG fundamentals, signal processing concepts, &#2447;&#2476;&#2434; related technologies &#2488;&#2478;&#2509;&#2474;&#2480;&#2509;&#2453;&#2503; initial understanding &#2451; learning summary &#2488;&#2434;&#2480;&#2453;&#2509;&#2487;&#2467; &#2453;&#2480;&#2494; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404;</p><p>Workshop &#2486;&#2503;&#2487;&#2503; speaker insights, practical demonstrations, hands-on experience, technical observations, &#2447;&#2476;&#2434; personal reflections &#2479;&#2497;&#2453;&#2509;&#2468; &#2453;&#2480;&#2503; &#2447;&#2439; document-&#2447;&#2480; Part&#8211;2 section &#2438;&#2480;&#2451; enrich &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;&#2404;</p><div><hr></div><h1>Brain-Computer Interface (BCI) &#2438;&#2488;&#2482;&#2503; &#2453;&#2496;?</h1><p>Brain-Computer Interface (BCI) &#2489;&#2482;&#2507; &#2447;&#2478;&#2472; &#2447;&#2453;&#2463;&#2495; system &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; human brain activity detect &#2453;&#2480;&#2503; &#2488;&#2503;&#2463;&#2494;&#2453;&#2503; computer &#2476;&#2494; external device-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; communicate &#2453;&#2480;&#2494;&#2472;&#2507; &#2489;&#2527;&#2404;</p><p>&#2478;&#2494;&#2472;&#2503; traditional input device &#2479;&#2503;&#2478;&#2472; keyboard, mouse &#2476;&#2494; touchscreen &#2459;&#2494;&#2524;&#2494;&#2451; brain signal &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; command generate &#2453;&#2480;&#2494;&#2480; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><p>&#2447;&#2439; field-&#2447; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; common technology &#2489;&#2482;&#2507; EEG (Electroencephalography), &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; scalp-&#2447;&#2480; &#2441;&#2474;&#2480; sensor/electrode &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; brain-&#2447;&#2480; electrical activity collect &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!zb51!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!zb51!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 424w, https://substackcdn.com/image/fetch/$s_!zb51!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 848w, https://substackcdn.com/image/fetch/$s_!zb51!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 1272w, https://substackcdn.com/image/fetch/$s_!zb51!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!zb51!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png" width="1456" height="226" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:226,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:35339,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/197785911?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!zb51!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 424w, https://substackcdn.com/image/fetch/$s_!zb51!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 848w, https://substackcdn.com/image/fetch/$s_!zb51!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 1272w, https://substackcdn.com/image/fetch/$s_!zb51!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0c738e0a-1a5c-4a99-9c41-3069bbf3bbd2_1908x296.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>                                                     Figure: BCI simple flow</p><div><hr></div><h1>EEG Signal &#2453;&#2496;?</h1><p>EEG signal &#2478;&#2498;&#2482;&#2468; brain neuron-&#2447;&#2480; tiny electrical activity.</p><p>&#2468;&#2476;&#2503; raw EEG signal &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2437;&#2472;&#2503;&#2453; noisy &#2489;&#2527; &#2453;&#2494;&#2480;&#2467; signal-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; mix &#2489;&#2527;&#2503; &#2479;&#2494;&#2527;:</p><ul><li><p>Eye movement</p></li><li><p>Muscle movement</p></li><li><p>Electrical interference</p></li><li><p>Body movement</p></li></ul><p>&#2468;&#2494;&#2439; raw signal directly &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527; &#2472;&#2494;&#2404; &#2438;&#2455;&#2503; filtering, preprocessing &#2447;&#2476;&#2434; noise reduction &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;&#2404;</p><p>Software engineering perspective &#2469;&#2503;&#2453;&#2503; &#2470;&#2503;&#2454;&#2482;&#2503; &#2476;&#2495;&#2487;&#2527;&#2463;&#2494; &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; noisy streaming data processing-&#2447;&#2480; &#2478;&#2468;&#2507; &#2478;&#2472;&#2503; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404;</p><div><hr></div><h1>&#2453;&#2503;&#2472; Topic &#2463;&#2494; Interesting &#2482;&#2494;&#2455;&#2459;&#2503;</h1><p>BCI field &#2463;&#2494; interesting &#2482;&#2494;&#2455;&#2494;&#2480; &#2476;&#2524; &#2453;&#2494;&#2480;&#2467; &#2489;&#2482;&#2507; &#2447;&#2463;&#2494; multiple domain-&#2447;&#2480; combination:</p><ul><li><p>Artificial Intelligence</p></li><li><p>Signal Processing</p></li><li><p>Healthcare Technology</p></li><li><p>Human-Computer Interaction</p></li><li><p>Real-Time Systems</p></li><li><p>Data Analysis</p></li></ul><p>&#2447;&#2453;&#2460;&#2472; software engineer &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; EEG signal concept &#2463;&#2494;&#2453;&#2503; &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; real-time streaming event data-&#2447;&#2480; &#2478;&#2468;&#2507; &#2478;&#2472;&#2503; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404;</p><p>&#2486;&#2497;&#2471;&#2497; difference &#2489;&#2482;&#2507; - &#2447;&#2454;&#2494;&#2472;&#2503; data source &#2489;&#2458;&#2509;&#2459;&#2503; human brain</p><div><hr></div><h1>EEG Brainwave Bands</h1><p>BCI &#2447;&#2476;&#2434; EEG &#2472;&#2495;&#2527;&#2503; &#2474;&#2524;&#2468;&#2503; &#2455;&#2495;&#2527;&#2503; &#2479;&#2503; &#2460;&#2495;&#2472;&#2495;&#2488;&#2463;&#2494; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; interesting &#2482;&#2503;&#2455;&#2503;&#2459;&#2503;, &#2488;&#2503;&#2463;&#2494; &#2489;&#2482;&#2507; - &#2438;&#2478;&#2494;&#2470;&#2503;&#2480; brain different mental state-&#2447;&#2480; &#2488;&#2478;&#2527; different frequency-&#2447;&#2480; electrical activity generate &#2453;&#2480;&#2503;&#2404;</p><p>&#2447;&#2439; electrical activity-&#2455;&#2497;&#2482;&#2507;&#2453;&#2503;&#2439; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; brainwave &#2476;&#2482;&#2494; &#2489;&#2527;&#2404; EEG device &#2478;&#2498;&#2482;&#2468; &#2447;&#2439; brainwave pattern detect &#2453;&#2480;&#2494;&#2480; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503;&#2404;</p><p>Different frequency band different &#2471;&#2480;&#2472;&#2503;&#2480; mental or physical state represent &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2479;&#2470;&#2495;&#2451; &#2447;&#2463;&#2494; fully deterministic &#2472;&#2494;, &#2468;&#2494;&#2480;&#2474;&#2480;&#2451; researchers &#2437;&#2472;&#2503;&#2453; pattern identify &#2453;&#2480;&#2468;&#2503; &#2474;&#2503;&#2480;&#2503;&#2459;&#2503;&#2472;&#2404;</p><p>&#2472;&#2495;&#2458;&#2503; common EEG brainwave band &#2455;&#2497;&#2482;&#2507;&#2480; basic overview &#2470;&#2503;&#2451;&#2527;&#2494; &#2489;&#2482;&#2507;:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Z5MI!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Z5MI!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 424w, https://substackcdn.com/image/fetch/$s_!Z5MI!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 848w, https://substackcdn.com/image/fetch/$s_!Z5MI!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 1272w, https://substackcdn.com/image/fetch/$s_!Z5MI!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Z5MI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png" width="1456" height="481" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:481,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:113886,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/197785911?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Z5MI!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 424w, https://substackcdn.com/image/fetch/$s_!Z5MI!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 848w, https://substackcdn.com/image/fetch/$s_!Z5MI!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 1272w, https://substackcdn.com/image/fetch/$s_!Z5MI!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb9e9abc8-d37f-455c-aac8-8a43ac62df71_1514x500.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h4>Delta Wave</h4><p>Delta wave &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; deep sleep-&#2447;&#2480; &#2488;&#2478;&#2527; &#2476;&#2503;&#2486;&#2495; &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527;&#2404; &#2447;&#2463;&#2494; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; low-frequency brainwave&#2404;</p><p>&#2479;&#2454;&#2472; &#2478;&#2494;&#2472;&#2497;&#2487; deep restorative sleep-&#2447; &#2469;&#2494;&#2453;&#2503;, &#2468;&#2454;&#2472; Delta activity increase &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; Sleep research &#2447;&#2476;&#2434; medical monitoring-&#2447; &#2447;&#2439; signal &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467;&#2404;</p><h4>Theta Wave</h4><p>Theta wave &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468;:</p><ul><li><p>meditation,</p></li><li><p>drowsiness,</p></li><li><p>relaxed mental state,</p></li><li><p>&#2437;&#2469;&#2476;&#2494; light sleep-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; relate &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p></li></ul><p>&#2437;&#2472;&#2503;&#2453; &#2488;&#2478;&#2527; creative thinking &#2476;&#2494; deep relaxation-&#2447;&#2480; &#2488;&#2478;&#2527;&#2451; Theta activity &#2470;&#2503;&#2454;&#2494; &#2479;&#2503;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><h4>Alpha Wave</h4><p>Alpha wave &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; commonly discussed EEG pattern-&#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; &#2447;&#2453;&#2463;&#2495;&#2404;</p><p>&#2447;&#2463;&#2494; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2468;&#2454;&#2472; increase &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2479;&#2454;&#2472; &#2447;&#2453;&#2460;&#2472; &#2478;&#2494;&#2472;&#2497;&#2487;:</p><ul><li><p>relaxed,</p></li><li><p>calm,</p></li><li><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; fully awake &#2437;&#2476;&#2488;&#2509;&#2469;&#2494;&#2527; &#2469;&#2494;&#2453;&#2503;&#2404;</p></li></ul><p>Example: &#2458;&#2507;&#2454; &#2476;&#2472;&#2509;&#2471; &#2453;&#2480;&#2503; &#2486;&#2494;&#2472;&#2509;&#2468;&#2477;&#2494;&#2476;&#2503; &#2476;&#2488;&#2503; &#2469;&#2494;&#2453;&#2482;&#2503; &#2437;&#2472;&#2503;&#2453; &#2488;&#2478;&#2527; Alpha activity increase &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>BCI research-&#2447; Alpha band &#2474;&#2509;&#2480;&#2494;&#2527;&#2439; attention &#2447;&#2476;&#2434; relaxation analysis-&#2447; &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><h4>Beta Wave</h4><p>Beta wave active thinking &#2447;&#2476;&#2434; concentration-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; relate &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><p>&#2479;&#2454;&#2472;:</p><ul><li><p>problem solving,</p></li><li><p>analytical thinking,</p></li><li><p>focus,</p></li><li><p>mental workload</p></li></ul><p>increase &#2489;&#2527;, &#2468;&#2454;&#2472; Beta activity-&#2451; increase &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>Software engineering perspective &#2469;&#2503;&#2453;&#2503; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2482;&#2503; - debugging &#2476;&#2494; intense coding session-&#2447;&#2480; &#2488;&#2478;&#2527; &#2489;&#2527;&#2468;&#2507; &#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; activity &#2476;&#2503;&#2486;&#2495; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><h4>Gamma Wave</h4><p>Gamma wave comparatively high-frequency activity&#2404;</p><p>&#2447;&#2463;&#2494; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468;:</p><ul><li><p>complex cognitive processing,</p></li><li><p>learning,</p></li><li><p>memory-related activity,</p></li><li><p>information integration</p></li></ul><p>&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; associate &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><p>&#2447;&#2454;&#2472;&#2451; Gamma wave &#2472;&#2495;&#2527;&#2503; &#2437;&#2472;&#2503;&#2453; ongoing research &#2489;&#2458;&#2509;&#2459;&#2503; &#2453;&#2494;&#2480;&#2467; human cognition-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; &#2447;&#2480; relation &#2474;&#2497;&#2480;&#2507;&#2474;&#2497;&#2480;&#2495; clear &#2472;&#2494;&#2404;</p><h3>&#2453;&#2503;&#2472; &#2447;&#2439; Brainwave Band Important?</h3><p>EEG analysis-&#2447;&#2480; &#2476;&#2524; &#2437;&#2434;&#2486;&#2439; &#2438;&#2488;&#2482;&#2503; &#2447;&#2439; frequency pattern analyze &#2453;&#2480;&#2494;&#2480; &#2441;&#2474;&#2480; &#2472;&#2495;&#2480;&#2509;&#2477;&#2480; &#2453;&#2480;&#2503;&#2404;</p><p>Researchers &#2447;&#2476;&#2434; engineers &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503;&#2472;:</p><ul><li><p>&#2453;&#2507;&#2472; frequency band increase &#2489;&#2458;&#2509;&#2459;&#2503;,</p></li><li><p>&#2453;&#2507;&#2472;&#2463;&#2494; decrease &#2489;&#2458;&#2509;&#2459;&#2503;,</p></li><li><p>&#2453;&#2507;&#2472; mental state-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; &#2453;&#2507;&#2472; pattern relate &#2453;&#2480;&#2459;&#2503;,</p></li><li><p>&#2447;&#2476;&#2434; &#2453;&#2496;&#2477;&#2494;&#2476;&#2503; &#2447;&#2439; signal &#2469;&#2503;&#2453;&#2503; meaningful insight &#2476;&#2503;&#2480; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;</p></li></ul><p>&#2447;&#2439; concept &#2455;&#2497;&#2482;&#2507;&#2439; &#2474;&#2480;&#2503;:</p><ul><li><p>attention detection,</p></li><li><p>stress analysis,</p></li><li><p>fatigue monitoring,</p></li><li><p>meditation tracking,</p></li><li><p>&#2447;&#2478;&#2472;&#2453;&#2495; &#2453;&#2495;&#2459;&#2497; BCI control system-&#2447;&#2480; foundation &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2503;&#2404;</p></li></ul><div><hr></div><h1>Real-World Application &#2479;&#2503;&#2455;&#2497;&#2482;&#2507; Interesting &#2482;&#2503;&#2455;&#2503;&#2459;&#2503;</h1><p>BCI &#2447;&#2476;&#2434; EEG technology-&#2447;&#2480; &#2453;&#2495;&#2459;&#2497; interesting real-world use case:</p><ul><li><p>Medical rehabilitation</p></li><li><p>Paralysis support system</p></li><li><p>Driver fatigue detection</p></li><li><p>Attention monitoring</p></li><li><p>Stress analysis</p></li><li><p>Smart prosthetic control</p></li><li><p>Human-machine interaction</p></li><li><p>Mental health monitoring</p></li></ul><p>Healthcare + AI sector &#2477;&#2476;&#2495;&#2487;&#2509;&#2479;&#2468;&#2503; &#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; intelligent monitoring system-&#2447;&#2480; &#2470;&#2495;&#2453;&#2503; &#2438;&#2480;&#2451; move &#2453;&#2480;&#2476;&#2503; &#2476;&#2482;&#2503; &#2478;&#2472;&#2503; &#2489;&#2458;&#2509;&#2459;&#2503;&#2404;</p><div><hr></div><h1>Pre-Workshop Thoughts</h1><p>&#2447;&#2439; &#2478;&#2497;&#2489;&#2498;&#2480;&#2509;&#2468;&#2503; &#2438;&#2478;&#2495; &#2447;&#2454;&#2472;&#2451; BCI &#2488;&#2478;&#2509;&#2474;&#2480;&#2509;&#2453;&#2503; beginner level-&#2447; &#2438;&#2459;&#2495;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; introductory concept &#2455;&#2497;&#2482;&#2507; &#2470;&#2503;&#2454;&#2503;&#2439; &#2476;&#2497;&#2461;&#2494; &#2479;&#2494;&#2458;&#2509;&#2459;&#2503; field &#2463;&#2494; &#2437;&#2472;&#2503;&#2453; interdisciplinary &#2447;&#2476;&#2434; future-focused&#2404;</p><p>&#2476;&#2495;&#2486;&#2503;&#2487; &#2453;&#2480;&#2503; AI, healthcare &#2447;&#2476;&#2434; real-time intelligent systems-&#2447;&#2480; future direction-&#2447;&#2480; &#2488;&#2494;&#2469;&#2503; &#2447;&#2439; domain-&#2447;&#2480; strong connection &#2438;&#2459;&#2503; &#2476;&#2482;&#2503; &#2478;&#2472;&#2503; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404;</p><p>Workshop-&#2447;&#2480; hands-on session &#2447;&#2476;&#2434; speaker discussion &#2469;&#2503;&#2453;&#2503; practical engineering perspective-&#2447; &#2438;&#2480;&#2451; &#2437;&#2472;&#2503;&#2453; &#2453;&#2495;&#2459;&#2497; &#2486;&#2503;&#2454;&#2494;&#2480; &#2438;&#2486;&#2494; &#2453;&#2480;&#2459;&#2495;&#2404;</p><p></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Object Oriented Programming vs Procedural Programming: Understanding the Mindset Difference]]></title><description><![CDATA[[Part-4] How Different Programming Paradigms Shape Software Design]]></description><link>https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-vs-procedural</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-vs-procedural</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Fri, 10 Apr 2026 13:09:16 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/84fe9167-a962-4843-95d5-95403967002e_1920x1080.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Programming paradigm &#2478;&#2498;&#2482;&#2468; &#2447;&#2453;&#2463;&#2495; problem solving approach&#2404; &#2447;&#2463;&#2495; &#2472;&#2495;&#2480;&#2509;&#2471;&#2494;&#2480;&#2467; &#2453;&#2480;&#2503; developer &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; system structure &#2453;&#2480;&#2476;&#2503;, logic organize &#2453;&#2480;&#2476;&#2503; &#2447;&#2476;&#2434; future change handle &#2453;&#2480;&#2476;&#2503;&#2404; Procedural Programming &#2447;&#2476;&#2434; Object Oriented Programming &#2447;&#2439; &#2470;&#2497;&#2439;&#2463;&#2495; widely used paradigm &#2489;&#2482;&#2503;&#2451; &#2447;&#2470;&#2503;&#2480; design philosophy &#2477;&#2495;&#2472;&#2509;&#2472;&#2404;</p><p>Procedural Programming &#2447; system &#2453;&#2503; &#2447;&#2453;&#2463;&#2495; sequence of operations &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2470;&#2503;&#2454;&#2494; &#2489;&#2527; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; functions &#2474;&#2509;&#2480;&#2471;&#2494;&#2472; role &#2474;&#2494;&#2482;&#2472; &#2453;&#2480;&#2503; &#2447;&#2476;&#2434; data &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; shared structure &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2476;&#2509;&#2479;&#2476;&#2489;&#2499;&#2468; &#2489;&#2527;&#2404; &#2447;&#2439; approach simple logic &#2447;&#2476;&#2434; limited scope application &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; &#2453;&#2494;&#2480;&#2509;&#2479;&#2453;&#2480; &#2453;&#2494;&#2480;&#2467; &#2447;&#2468;&#2503; execution flow &#2488;&#2489;&#2460;&#2503; follow &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>&#2437;&#2472;&#2509;&#2479;&#2470;&#2495;&#2453;&#2503; Object Oriented Programming system &#2453;&#2503; real world entity &#2447;&#2480; &#2478;&#2468;&#2507; model &#2453;&#2480;&#2503; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; object &#2472;&#2495;&#2460;&#2503;&#2480; data &#2447;&#2476;&#2434; behaviour &#2447;&#2453;&#2488;&#2494;&#2469;&#2503; manage &#2453;&#2480;&#2503;&#2404; &#2447;&#2468;&#2503; system naturally modular &#2489;&#2527; &#2447;&#2476;&#2434; responsibility clearly distributed &#2469;&#2494;&#2453;&#2503;&#2404;</p><p>&#2447;&#2439; difference &#2486;&#2497;&#2471;&#2497;&#2478;&#2494;&#2468;&#2509;&#2480; coding style &#2447;&#2480; difference &#2472;&#2494; &#2476;&#2480;&#2434; system design &#2453;&#2480;&#2494;&#2480; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494;&#2480; &#2474;&#2494;&#2480;&#2509;&#2469;&#2453;&#2509;&#2479;&#2404;</p><div><hr></div><h3>Key Differences in Design Philosophy</h3><h5>Comparing Structural Thinking Rather Than Syntax</h5><p>Procedural programming &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; execution flow &#2477;&#2495;&#2468;&#2509;&#2468;&#2495;&#2453; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2503;&#2404; &#2437;&#2480;&#2509;&#2469;&#2494;&#2510; &#2453;&#2507;&#2472; step &#2447;&#2480; &#2474;&#2480;&#2503; &#2453;&#2507;&#2472; step execute &#2489;&#2476;&#2503; &#2488;&#2503;&#2463;&#2494;&#2439; primary concern&#2404;</p><p>Object oriented design entity interaction &#2477;&#2495;&#2468;&#2509;&#2468;&#2495;&#2453; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2503;&#2404; &#2447;&#2454;&#2494;&#2472;&#2503; &#2474;&#2509;&#2480;&#2486;&#2509;&#2472; &#2453;&#2480;&#2494; &#2489;&#2527; &#2453;&#2507;&#2472; object &#2453;&#2507;&#2472; responsibility &#2472;&#2503;&#2476;&#2503; &#2447;&#2476;&#2434; object &#2455;&#2497;&#2482;&#2507; &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; interact &#2453;&#2480;&#2476;&#2503;&#2404;</p><p>Procedural approach &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; step sequence optimize &#2453;&#2480;&#2503;, &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; OOP approach system structure optimize &#2453;&#2480;&#2503;&#2404;</p><p>&#2447;&#2439; &#2453;&#2494;&#2480;&#2467;&#2503;&#2439; large scale backend system design &#2453;&#2480;&#2494;&#2480; &#2488;&#2478;&#2527; OOP approach &#2476;&#2503;&#2486;&#2495; &#2476;&#2509;&#2479;&#2476;&#2489;&#2499;&#2468; &#2489;&#2527; &#2453;&#2494;&#2480;&#2467; &#2447;&#2468;&#2503; change isolation &#2447;&#2476;&#2434; modularity naturally &#2474;&#2494;&#2451;&#2527;&#2494; &#2479;&#2494;&#2527;&#2404;</p><div><hr></div><h4>Why Object Oriented Programming Works Better for Evolving Systems</h4><h5>Managing Change in Long Running Software Projects</h5><p>Real world software system static &#2469;&#2494;&#2453;&#2503; &#2472;&#2494;&#2404; &#2488;&#2478;&#2527;&#2503;&#2480; &#2488;&#2494;&#2469;&#2503; requirement change &#2489;&#2527;, integration &#2479;&#2507;&#2455; &#2489;&#2527; &#2447;&#2476;&#2434; business rule evolve &#2453;&#2480;&#2503;&#2404; &#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; environment &#2447; &#2447;&#2478;&#2472; design &#2470;&#2480;&#2453;&#2494;&#2480; &#2479;&#2494; change tolerate &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>Object oriented design &#2447;&#2439; &#2460;&#2494;&#2527;&#2455;&#2494;&#2527; advantage &#2470;&#2503;&#2527; &#2453;&#2494;&#2480;&#2467; encapsulation change impact isolate &#2453;&#2480;&#2503;, abstraction unnecessary complexity hide &#2453;&#2480;&#2503; &#2447;&#2476;&#2434; polymorphism future extension allow &#2453;&#2480;&#2503; without breaking existing structure&#2404;</p><p>&#2447;&#2439; &#2453;&#2494;&#2480;&#2467;&#2503; modern backend ecosystem &#2479;&#2503;&#2478;&#2472; enterprise Java applications, Spring based systems &#2447;&#2476;&#2434; domain driven architectures &#2447; OOP extensively &#2476;&#2509;&#2479;&#2476;&#2489;&#2499;&#2468; &#2489;&#2527;&#2404;</p><p>&#2447;&#2454;&#2494;&#2472;&#2503; &#2478;&#2498;&#2482; benefit performance &#2472;&#2494; &#2476;&#2480;&#2434; maintainability &#2447;&#2476;&#2434; adaptability&#2404;</p><div><hr></div><h3>Choosing the Right Approach Based on System Needs</h3><h5>Understanding When Each Paradigm Is Appropriate</h5><p>&#2447;&#2463;&#2494; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2479;&#2503; procedural programming &#2447;&#2476;&#2434; OOP &#2447;&#2453;&#2503; &#2437;&#2474;&#2480;&#2503;&#2480; competitor &#2472;&#2494; &#2476;&#2480;&#2434; different problem &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; suitable tool&#2404;</p><p>Simple automation script, data processing task &#2476;&#2494; small utility application &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; procedural approach &#2437;&#2472;&#2503;&#2453; &#2488;&#2478;&#2527; &#2476;&#2503;&#2486;&#2495; straightforward&#2404;</p><p>&#2437;&#2472;&#2509;&#2479;&#2470;&#2495;&#2453;&#2503; long running business system, SaaS platform &#2476;&#2494; integration heavy backend system &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; OOP design &#2476;&#2503;&#2486;&#2495; practical &#2453;&#2494;&#2480;&#2467; &#2447;&#2468;&#2503; system naturally modular &#2489;&#2527;&#2404;</p><p>Software engineering &#2447; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; approach choose &#2453;&#2480;&#2494; &#2489;&#2527; problem characteristics &#2437;&#2472;&#2497;&#2479;&#2494;&#2527;&#2496;, &#2453;&#2507;&#2472;&#2507; paradigm &#2453;&#2503; universally superior &#2471;&#2480;&#2503; &#2472;&#2494;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Object Oriented Programming (OOP): From Theory to Real Software Engineering Practice]]></title><description><![CDATA[[Part -3] Common Mistakes Developers Make When Using OOP]]></description><link>https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-oop-from-ea5</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-oop-from-ea5</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Wed, 08 Apr 2026 14:03:38 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/c6195c0a-5a4a-423f-8368-ec22bf86b907_1200x678.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Object Oriented Programming &#2486;&#2503;&#2454;&#2494;&#2480; &#2474;&#2480; &#2437;&#2472;&#2503;&#2453; developer &#2478;&#2472;&#2503; &#2453;&#2480;&#2503; class &#2476;&#2494;&#2472;&#2494;&#2482;&#2503;&#2439; OOP &#2489;&#2527;&#2503; &#2455;&#2503;&#2459;&#2503;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476;&#2503; &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527; &#2476;&#2503;&#2486;&#2495;&#2480;&#2477;&#2494;&#2455; messy enterprise code OOP &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503;&#2439; &#2482;&#2503;&#2454;&#2494; &#2489;&#2527;&#2404; &#2453;&#2494;&#2480;&#2467; concept &#2460;&#2494;&#2472;&#2494; &#2438;&#2480; proper design &#2453;&#2480;&#2494; &#2447;&#2453; &#2460;&#2495;&#2472;&#2495;&#2488; &#2472;&#2494;&#2404;</p><p>Real software engineering &#2447; &#2453;&#2495;&#2459;&#2497; common mistake &#2476;&#2494;&#2480;&#2476;&#2494;&#2480; &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527; &#2479;&#2503;&#2455;&#2497;&#2482;&#2507; system complexity &#2476;&#2494;&#2524;&#2495;&#2527;&#2503; &#2470;&#2503;&#2527; instead of reducing it&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>&#2458;&#2482;&#2497;&#2472; &#2453;&#2495;&#2459;&#2497; practical mistake &#2470;&#2503;&#2454;&#2495; &#2479;&#2503;&#2455;&#2497;&#2482;&#2507; industry experience &#2447; &#2454;&#2497;&#2476; common&#2404;</p><div><hr></div><h3>Mistake 1: Creating Classes Without Clear Responsibility</h3><p>&#2488;&#2476;&#2458;&#2503;&#2527;&#2503; common mistake &#2489;&#2482;&#2507; class &#2476;&#2494;&#2472;&#2494;&#2472;&#2507; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; clear responsibility define &#2472;&#2494; &#2453;&#2480;&#2494;&#2404; &#2437;&#2472;&#2503;&#2453; developer &#2447;&#2453;&#2463;&#2494; class &#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; unrelated functionality &#2466;&#2497;&#2453;&#2495;&#2527;&#2503; &#2470;&#2503;&#2527;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; &#2447;&#2453;&#2463;&#2495; OrderService class &#2438;&#2459;&#2503; &#2447;&#2476;&#2434; &#2488;&#2503;&#2454;&#2494;&#2472;&#2503;:</p><ul><li><p>order create logic</p></li><li><p>payment processing</p></li><li><p>email sending</p></li><li><p>inventory update</p></li><li><p>report generation</p></li></ul><p>&#2488;&#2476; &#2453;&#2495;&#2459;&#2497; &#2466;&#2497;&#2453;&#2494;&#2472;&#2507; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404;</p><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; class &#2453;&#2503; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2476;&#2482;&#2494; &#2489;&#2527; <strong>All In One Class</strong> &#2453;&#2494;&#2480;&#2467; &#2447;&#2463;&#2495; &#2437;&#2472;&#2503;&#2453; &#2476;&#2503;&#2486;&#2495; responsibility &#2472;&#2495;&#2527;&#2503; &#2475;&#2503;&#2482;&#2503;&#2404;</p><p>&#2447;&#2439; design maintain &#2453;&#2480;&#2494; &#2453;&#2464;&#2495;&#2472; &#2489;&#2527;&#2503; &#2479;&#2494;&#2527; &#2453;&#2494;&#2480;&#2467; &#2447;&#2453;&#2463;&#2495; small change &#2453;&#2480;&#2482;&#2503;&#2451; unexpected side effect &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><h5>Better approach &#2489;&#2482;&#2507; responsibility &#2438;&#2482;&#2494;&#2470;&#2494; &#2453;&#2480;&#2494;:</h5><ul><li><p>OrderService &#8594; order lifecycle manage &#2453;&#2480;&#2476;&#2503;</p></li><li><p>PaymentService &#8594; payment handle &#2453;&#2480;&#2476;&#2503;</p></li><li><p>InventoryService &#8594; stock manage &#2453;&#2480;&#2476;&#2503;</p></li><li><p>NotificationService &#8594; email/SMS handle &#2453;&#2480;&#2476;&#2503;</p></li></ul><h5>&#2447;&#2463;&#2494;&#2453;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527; <strong>Single Responsibility mindset</strong>, &#2479;&#2494; clean OOP design &#2447;&#2480; core&#2404;</h5><p>Senior engineers &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2474;&#2509;&#2480;&#2469;&#2478;&#2503;&#2439; &#2474;&#2509;&#2480;&#2486;&#2509;&#2472; &#2453;&#2480;&#2503;: <em>&#8220;&#2447;&#2439; class &#2447;&#2480; &#2447;&#2453;&#2463;&#2494;&#2439; clear responsibility &#2438;&#2459;&#2503; &#2453;&#2495;?&#8221;  </em>&#2479;&#2470;&#2495; answer &#2472;&#2494; &#2489;&#2527;, &#2468;&#2494;&#2489;&#2482;&#2503; design improve &#2453;&#2480;&#2494; &#2470;&#2480;&#2453;&#2494;&#2480;&#2404;</p><h3>Mistake 2: Overusing Inheritance Instead of Composition</h3><p>&#2437;&#2472;&#2503;&#2453; developer &#2478;&#2472;&#2503; &#2453;&#2480;&#2503; inheritance &#2479;&#2468; &#2476;&#2503;&#2486;&#2495; use &#2453;&#2480;&#2494; &#2479;&#2494;&#2476;&#2503; &#2468;&#2468; design &#2477;&#2494;&#2482;&#2507; &#2489;&#2476;&#2503;&#2404; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476;&#2503; excessive inheritance system rigid &#2453;&#2480;&#2503; &#2470;&#2503;&#2527;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; developer design &#2453;&#2480;&#2482;&#2507;:</p><p>User</p><ul><li><p>PremiumUser</p></li><li><p>PremiumUserWithDiscount</p></li><li><p>PremiumUserWithSpecialDiscount</p></li></ul><p>&#2447;&#2439; hierarchy quickly messy &#2489;&#2527;&#2503; &#2479;&#2494;&#2527;&#2404; </p><p>Industry &#2447; better approach &#2489;&#2482;&#2507;: <strong>Composition over inheritance</strong></p><p>So nstead of using PremiumUser extends User, it better user has DiscountPolicy.</p><p>&#2447;&#2454;&#2472; DiscountPolicy &#2438;&#2482;&#2494;&#2470;&#2494; &#2453;&#2480;&#2503; change &#2453;&#2480;&#2494; &#2479;&#2494;&#2476;&#2503;&#2404; &#2447;&#2439; design &#2476;&#2503;&#2486;&#2495; flexible &#2453;&#2494;&#2480;&#2467; behaviour dynamically change &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404; &#2447;&#2439; principle clean architecture &#2447;&#2476;&#2434; domain driven design &#2447; &#2454;&#2497;&#2476; common&#2404;</p><h3>Mistake 3: Breaking Encapsulation with Public Fields</h3><p>&#2437;&#2472;&#2503;&#2453; junior developer &#2488;&#2476; field public &#2453;&#2480;&#2503; &#2470;&#2503;&#2527; convenience &#2447;&#2480; &#2460;&#2472;&#2509;&#2479;&#2404; &#2447;&#2468;&#2503; encapsulation completely break &#2489;&#2527;&#2503; &#2479;&#2494;&#2527;&#2404;</p><p>Example bad thinking: <strong>&#8220;Getter setter &#2482;&#2495;&#2454;&#2468;&#2503; &#2488;&#2478;&#2527; &#2482;&#2494;&#2455;&#2503; &#2468;&#2494;&#2439; public &#2480;&#2494;&#2454;&#2495;&#8221;</strong></p><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2447;&#2480; &#2475;&#2482;&#2503; future validation impossible &#2489;&#2527;&#2503; &#2479;&#2494;&#2527;&#2404;</p><p>Professional design &#2447; data expose &#2453;&#2480;&#2494; &#2489;&#2527; controlled way &#2468;&#2503;&#2404; &#2453;&#2494;&#2480;&#2467; future &#2447; business rule change &#2489;&#2476;&#2503;&#2439;&#2404;</p><p>&#2447;&#2453;&#2463;&#2494; &#2477;&#2494;&#2482;&#2507; design &#2488;&#2476;&#2488;&#2478;&#2527; future change &#2478;&#2494;&#2469;&#2494;&#2527; &#2480;&#2503;&#2454;&#2503; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><h3>Mistake 4: Ignoring Domain Modelling</h3><p>&#2437;&#2472;&#2503;&#2453; developer code &#2453;&#2503; technical structure &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2470;&#2503;&#2454;&#2503; instead of business model &#2489;&#2495;&#2488;&#2503;&#2476;&#2503;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; system &#2447; Order &#2438;&#2459;&#2503; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; developer &#2488;&#2503;&#2463;&#2494;&#2453;&#2503; &#2486;&#2497;&#2471;&#2497; DTO &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2459;&#2503;&#2404; &#2453;&#2507;&#2472;&#2507; behaviour &#2472;&#2503;&#2439;&#2404;</p><p>Better thinking:</p><ul><li><p>Order &#2486;&#2497;&#2471;&#2497; data container &#2472;&#2494;&#2404;</p></li><li><p>Order &#2447;&#2453;&#2463;&#2495; domain object&#2404;</p></li></ul><p>Order &#2460;&#2494;&#2472;&#2476;&#2503;:</p><ul><li><p>it can be cancelled &#2453;&#2495;&#2472;&#2494;</p></li><li><p>it can be refunded &#2453;&#2495;&#2472;&#2494;</p></li><li><p>status change rule &#2453;&#2495;</p></li></ul><p>&#2447;&#2463;&#2494;&#2453;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527; <strong>Rich Domain Model thinking</strong>&#2404; &#2447;&#2439; mindset Domain Driven Design &#2447;&#2480; foundation&#2404;</p><h3>Mistake 5: Writing OOP Code with Procedural Mindset</h3><p>&#2447;&#2439;&#2463;&#2494; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; subtle mistake&#2404; &#2437;&#2472;&#2503;&#2453; developer class &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; design procedural &#2480;&#2494;&#2454;&#2503;&#2404;</p><p>Example:</p><ul><li><p>OrderService.processOrder(order)</p></li></ul><p>&#2447;&#2439; design &#2447; Order &#2486;&#2497;&#2471;&#2497; data carrier&#2404;</p><p>Better:</p><ul><li><p>order.process()</p></li></ul><p>&#2447;&#2454;&#2472; Order behaviour own &#2453;&#2480;&#2459;&#2503;&#2404; &#2447;&#2463;&#2494; procedural &#2469;&#2503;&#2453;&#2503; OOP transition&#2404;</p><p>Senior engineers &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503; behaviour object &#2447;&#2480; &#2453;&#2494;&#2459;&#2503; &#2480;&#2494;&#2454;&#2468;&#2503;&#2404;</p><p>&#2447;&#2439; principle &#2453;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527;:</p><p><strong>Tell the object what to do, don&#8217;t ask for data and do it yourself.</strong></p><p>&#2447;&#2463;&#2494; object oriented thinking &#2447;&#2480; mature level&#2404;</p><div><hr></div><p>Good OOP design &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2447;&#2439; characteristics follow &#2453;&#2480;&#2503;:</p><ul><li><p>Classes small &#2447;&#2476;&#2434; focused &#2489;&#2527;</p></li><li><p>Responsibility clear &#2469;&#2494;&#2453;&#2503;</p></li><li><p>Dependency minimal &#2469;&#2494;&#2453;&#2503;</p></li><li><p>Behaviour logically placed &#2469;&#2494;&#2453;&#2503;</p></li><li><p>Future change isolated &#2469;&#2494;&#2453;&#2503;</p></li></ul><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; design naturally testable &#2489;&#2527; &#2447;&#2476;&#2434; long term maintainable &#2489;&#2527;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Object Oriented Programming (OOP): From Theory to Real Software Engineering Practice]]></title><description><![CDATA[[Part-2] The Four Pillars of OOP Explained with a Real Software Example]]></description><link>https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-oop-from</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-oop-from</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sun, 05 Apr 2026 14:06:55 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/29e7814d-d0bd-4f7d-81e2-53d99413326b_600x300.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Object Oriented Programming &#2447;&#2480; foundation &#2470;&#2494;&#2433;&#2524;&#2495;&#2527;&#2503; &#2438;&#2459;&#2503; &#2458;&#2494;&#2480;&#2463;&#2495; &#2478;&#2498;&#2482; &#2471;&#2494;&#2480;&#2467;&#2494;&#2480; &#2441;&#2474;&#2480;&#2404; &#2447;&#2455;&#2497;&#2482;&#2507; &#2486;&#2497;&#2471;&#2497; theory &#2472;&#2494;, &#2476;&#2480;&#2434; large scale software maintain &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; essential engineering principles&#2404;</p><p><strong>&#2447;&#2439; &#2458;&#2494;&#2480;&#2463;&#2495; pillar &#2489;&#2482;&#2507;:</strong></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><ul><li><p>Encapsulation</p></li><li><p>Abstraction</p></li><li><p>Inheritance</p></li><li><p>Polymorphism</p></li></ul><p>&#2447;&#2455;&#2497;&#2482;&#2507; &#2438;&#2482;&#2494;&#2470;&#2494; &#2438;&#2482;&#2494;&#2470;&#2494; concept &#2478;&#2472;&#2503; &#2489;&#2482;&#2503;&#2451; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476;&#2503; &#2447;&#2455;&#2497;&#2482;&#2507; &#2447;&#2453;&#2488;&#2494;&#2469;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2503; system &#2453;&#2503; clean &#2447;&#2476;&#2434; maintainable &#2480;&#2494;&#2454;&#2468;&#2503;&#2404;</p><div><hr></div><h3>1. Encapsulation &#8211; Data protection &#2447;&#2480; engineering approach</h3><p>Encapsulation &#2453;&#2503; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2477;&#2494;&#2476;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527; data hiding&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; industry perspective &#2447; &#2447;&#2463;&#2494; &#2438;&#2488;&#2482;&#2503; <strong>controlled access design</strong>&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; &#2438;&#2478;&#2494;&#2470;&#2503;&#2480; Product class &#2438;&#2459;&#2503; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; price &#2447;&#2476;&#2434; stock &#2438;&#2459;&#2503;&#2404; &#2479;&#2470;&#2495; system &#2447;&#2480; &#2479;&#2503;&#2453;&#2507;&#2472;&#2507; &#2460;&#2494;&#2527;&#2455;&#2494; &#2469;&#2503;&#2453;&#2503; price change &#2453;&#2480;&#2494; &#2479;&#2494;&#2527; &#2468;&#2494;&#2489;&#2482;&#2503; huge problem &#2489;&#2476;&#2503;&#2404; &#2453;&#2507;&#2472;&#2507; developer &#2477;&#2497;&#2482; &#2453;&#2480;&#2503; negative price set &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2476;&#2494; stock zero &#2489;&#2451;&#2527;&#2494;&#2480; &#2474;&#2480;&#2503;&#2451; order allow &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2447;&#2439; risk avoid &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; senior engineers direct data access allow &#2453;&#2480;&#2503; &#2472;&#2494;&#2404;</p><p>Instead &#2468;&#2494;&#2480;&#2494; &#2476;&#2482;&#2503;:</p><ul><li><p>Product &#2472;&#2495;&#2460;&#2503;&#2480; data &#2472;&#2495;&#2460;&#2503;&#2439; control &#2453;&#2480;&#2476;&#2503;&#2404;</p></li></ul><p><strong>Conceptually example:</strong></p><p>Product &#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; price &#2469;&#2494;&#2453;&#2476;&#2503; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; external system &#2488;&#2480;&#2494;&#2488;&#2480;&#2495; change &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2476;&#2503; &#2472;&#2494;&#2404; Price update &#2453;&#2480;&#2468;&#2503; &#2489;&#2482;&#2503; Product &#2447;&#2480; method call &#2453;&#2480;&#2468;&#2503; &#2489;&#2476;&#2503;&#2404;</p><p>Example &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2497;&#2472;:</p><pre><code>Product.updatePrice(newPrice)</code></pre><h5>&#2447;&#2454;&#2472; Product internally validation &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;:</h5><ul><li><p>price negative &#2453;&#2495;&#2472;&#2494;</p></li><li><p>discount rule violate &#2453;&#2480;&#2459;&#2503; &#2453;&#2495;&#2472;&#2494;</p></li><li><p>audit log &#2482;&#2494;&#2455;&#2476;&#2503; &#2453;&#2495;&#2472;&#2494;</p></li></ul><p>&#2447;&#2439; design &#2447;&#2480; &#2453;&#2494;&#2480;&#2467;&#2503; system safer &#2489;&#2527;&#2404; &#2447;&#2463;&#2494;&#2439; encapsulation &#2447;&#2480; real value&#2404;</p><p>&#2447;&#2463;&#2494; &#2486;&#2497;&#2471;&#2497; data hide &#2453;&#2480;&#2494; &#2472;&#2494;, &#2447;&#2463;&#2494; <strong>business rule protection</strong>&#2404;</p><div><hr></div><h3>2. Abstraction &#8211; Complexity hide &#2453;&#2480;&#2494;&#2480; engineering strategy</h3><p>Large system &#2447; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; &#2476;&#2524; problem &#2489;&#2482;&#2507; complexity overload&#2404; &#2479;&#2470;&#2495; developer &#2453;&#2503; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; internal step &#2460;&#2494;&#2472;&#2468;&#2503; &#2489;&#2527; &#2468;&#2494;&#2489;&#2482;&#2503; system use &#2453;&#2480;&#2494; impossible &#2489;&#2527;&#2503; &#2479;&#2494;&#2476;&#2503;&#2404;</p><p>Abstraction &#2447;&#2439; problem solve &#2453;&#2480;&#2503;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; Order place &#2453;&#2480;&#2494;&#2480; process &#2438;&#2459;&#2503;:</p><ul><li><p>Stock check</p></li><li><p>Payment validation</p></li><li><p>Discount calculation</p></li><li><p>Tax calculation</p></li><li><p>Order persistence</p></li><li><p>Notification send</p></li></ul><p>User &#2453;&#2495; &#2447;&#2488;&#2476; &#2460;&#2494;&#2472;&#2503;? &#2472;&#2494;&#2404;</p><p>User &#2486;&#2497;&#2471;&#2497; click &#2453;&#2480;&#2503;: <strong>Place Order</strong></p><p>Software internally &#2488;&#2476; &#2453;&#2480;&#2503;&#2404; &#2447;&#2439; design &#2453;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527; abstraction&#2404;</p><h5>Software engineering &#2447; abstraction &#2478;&#2494;&#2472;&#2503;: <strong>What happens &#2460;&#2494;&#2472;&#2494; &#2470;&#2480;&#2453;&#2494;&#2480;, How happens &#2460;&#2494;&#2472;&#2494; &#2470;&#2480;&#2453;&#2494;&#2480; &#2472;&#2494;&#2404;</strong></h5><pre><code>order.placeOrder()</code></pre><p>&#2447;&#2439; &#2447;&#2453;&#2463;&#2494;&#2439; call &#2447;&#2480; &#2477;&#2495;&#2468;&#2480;&#2503; &#2489;&#2527;&#2468;&#2507; &#2536;&#2534;&#2463;&#2494; operation &#2489;&#2458;&#2509;&#2459;&#2503;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; external system &#2460;&#2494;&#2472;&#2503; &#2472;&#2494; &#2447;&#2476;&#2434; &#2460;&#2494;&#2472;&#2494;&#2480; &#2470;&#2480;&#2453;&#2494;&#2480;&#2451; &#2472;&#2503;&#2439;&#2404;</p><p>&#2447;&#2439; design developer productivity massively improve &#2453;&#2480;&#2503;&#2404; &#2447;&#2463;&#2494;&#2439; reason modern frameworks abstraction heavy&#2404;</p><p>Spring Boot example &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2497;&#2472;, &#2438;&#2474;&#2472;&#2495; &#2486;&#2497;&#2471;&#2497; &#2482;&#2495;&#2454;&#2503;&#2472;:</p><pre><code>repository.save(order)</code></pre><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2477;&#2495;&#2468;&#2480;&#2503;:</p><ul><li><p>connection open</p></li><li><p>transaction start</p></li><li><p>sql generate</p></li><li><p>execute</p></li><li><p>commit</p></li><li><p>close</p></li></ul><p>&#2447;&#2463;&#2494;&#2439; abstraction power&#2404;</p><div><hr></div><h3>3. Inheritance &#8211; Code reuse &#2447;&#2480; structured approach</h3><p>Large software &#2447; &#2437;&#2472;&#2503;&#2453; class &#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; common behaviour &#2469;&#2494;&#2453;&#2503;&#2404; &#2479;&#2470;&#2495; &#2474;&#2509;&#2480;&#2468;&#2495;&#2476;&#2494;&#2480; copy paste &#2453;&#2480;&#2494; &#2489;&#2527; &#2468;&#2494;&#2489;&#2482;&#2503; maintenance nightmare &#2489;&#2527;&#2503; &#2479;&#2494;&#2527;&#2404;</p><p>Inheritance &#2447;&#2439; problem solve &#2453;&#2480;&#2503;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; E-commerce system &#2447; multiple user type &#2438;&#2459;&#2503;:</p><ul><li><p>Customer</p></li><li><p>Seller</p></li><li><p>Admin</p></li></ul><p>&#2488;&#2476;&#2494;&#2439; User&#2404; &#2488;&#2476;&#2494;&#2439; login &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2488;&#2476;&#2494;&#2439; profile update &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2468;&#2494;&#2489;&#2482;&#2503; common behaviour User class &#2447; &#2480;&#2494;&#2454;&#2494; &#2479;&#2494;&#2527;&#2404;</p><p>User:</p><ul><li><p>name</p></li><li><p>email</p></li><li><p>password</p></li><li><p>login()</p></li><li><p>logout()</p></li><li><p>updateProfile()</p></li></ul><p>&#2468;&#2494;&#2480;&#2474;&#2480;:</p><ul><li><p>Customer extends User</p></li><li><p>Seller extends User</p></li><li><p>Admin extends User</p></li></ul><p>&#2447;&#2454;&#2472; Customer &#2447;&#2480; extra behaviour &#2469;&#2494;&#2453;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;:</p><ul><li><p>placeOrder()</p></li><li><p>viewOrderHistory()</p></li></ul><p>Seller &#2447;&#2480;:</p><ul><li><p>addProduct()</p></li><li><p>updateInventory()</p></li></ul><p>Admin &#2447;&#2480;:</p><ul><li><p>blockUser()</p></li><li><p>generateReport()</p></li></ul><p>&#2447;&#2468;&#2503; code duplication &#2453;&#2478;&#2503; &#2479;&#2494;&#2527; &#2447;&#2476;&#2434; hierarchy clear &#2489;&#2527;&#2404; &#2447;&#2463;&#2494; &#2486;&#2497;&#2471;&#2497; reuse &#2472;&#2494;, &#2447;&#2463;&#2494; <strong>domain modelling clarity</strong> &#2470;&#2503;&#2527;&#2404;</p><div><hr></div><h3>4. Polymorphism &#8211; Flexible behaviour design</h3><p>Polymorphism &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; misunderstood concept&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2447;&#2463;&#2494; extensible system design &#2447;&#2480; core&#2404;</p><p>Real meaning:</p><p><strong>Same interface, different behaviour</strong></p><p>&#2471;&#2480;&#2503;&#2472; system &#2447; payment &#2438;&#2459;&#2503;:</p><ol><li><p>Credit Card</p></li><li><p>Bank Transfer</p></li><li><p>Wallet</p></li></ol><p>&#2488;&#2476; payment &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; process &#2453;&#2480;&#2468;&#2503; &#2489;&#2476;&#2503;&#2404;</p><p>Without polymorphism developer &#2489;&#2527;&#2468;&#2507; &#2482;&#2495;&#2454;&#2468;&#2507;:</p><pre><code>if paymentType == CARD
processCard()

if paymentType == BANK
processBank()

if paymentType == WALLET
processWallet()</code></pre><p>&#2447;&#2463;&#2494; scalable &#2472;&#2494;&#2404;</p><p>Better design - Payment interface:</p><pre><code>processPayment()</code></pre><p>&#2468;&#2494;&#2480;&#2474;&#2480;:</p><ul><li><p>CardPayment implements Payment</p></li><li><p>BankPayment implements Payment</p></li><li><p>WalletPayment implements Payment</p></li></ul><p>&#2447;&#2454;&#2472; Order &#2486;&#2497;&#2471;&#2497; &#2460;&#2494;&#2472;&#2503;:</p><pre><code>payment.processPayment()</code></pre><p>Payment type &#2460;&#2494;&#2472;&#2494;&#2480; &#2470;&#2480;&#2453;&#2494;&#2480; &#2472;&#2503;&#2439;&#2404; &#2447;&#2439; design future proof&#2404; Tomorrow crypto payment &#2438;&#2488;&#2482;&#2503;&#2451; Order change &#2482;&#2494;&#2455;&#2476;&#2503; &#2472;&#2494;&#2404; &#2486;&#2497;&#2471;&#2497; new class add &#2489;&#2476;&#2503;&#2404; </p><p>&#2447;&#2463;&#2494;&#2439; polymorphism &#2447;&#2480; real engineering value&#2404; &#2447;&#2463;&#2494; extensibility &#2470;&#2503;&#2527; without breaking existing code&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Object-Oriented Programming (OOP): A Practical Guide with Real Software Engineering Examples]]></title><description><![CDATA[Part 1: Why Was Object-Oriented Programming Created? Understanding the Real Problem It Solves]]></description><link>https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-oop-a</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/object-oriented-programming-oop-a</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sun, 05 Apr 2026 12:56:22 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/df956865-c80f-4be6-bb02-3ef1b8bcd07a_1280x640.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Programming &#2447;&#2480; &#2486;&#2497;&#2480;&#2497;&#2468;&#2503; &#2476;&#2503;&#2486;&#2495;&#2480;&#2477;&#2494;&#2455; software procedural style &#2447; &#2482;&#2503;&#2454;&#2494; &#2489;&#2468;&#2507;&#2404; &#2437;&#2480;&#2509;&#2469;&#2494;&#2510; developer &#2480;&#2494; mainly function &#2447;&#2476;&#2434; data &#2438;&#2482;&#2494;&#2470;&#2494; &#2477;&#2494;&#2476;&#2503; manage &#2453;&#2480;&#2468;&#2507;&#2404; &#2459;&#2507;&#2463; project &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; &#2447;&#2439; approach &#2453;&#2494;&#2460; &#2453;&#2480;&#2482;&#2503;&#2451; system &#2476;&#2524; &#2489;&#2468;&#2503; &#2486;&#2497;&#2480;&#2497; &#2453;&#2480;&#2482;&#2503; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494; &#2470;&#2503;&#2454;&#2494; &#2470;&#2495;&#2468;&#2503; &#2469;&#2494;&#2453;&#2503;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; &#2438;&#2474;&#2472;&#2495; &#2447;&#2453;&#2463;&#2495; <strong>E-commerce system</strong> develop &#2453;&#2480;&#2459;&#2503;&#2472; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; customer account, product catalogue, order processing &#2447;&#2476;&#2434; payment handling &#2438;&#2459;&#2503;&#2404; &#2486;&#2497;&#2480;&#2497;&#2468;&#2503; system &#2459;&#2507;&#2463; &#2469;&#2494;&#2453;&#2482;&#2503; &#2438;&#2474;&#2472;&#2495; &#2489;&#2527;&#2468;&#2507; &#2438;&#2482;&#2494;&#2470;&#2494; &#2438;&#2482;&#2494;&#2470;&#2494; function &#2482;&#2495;&#2454;&#2482;&#2503;&#2472; &#2479;&#2503;&#2478;&#2472; <code>createOrder(), updateProduct(), calculatePrice()</code> &#2439;&#2468;&#2509;&#2479;&#2494;&#2470;&#2495; &#2447;&#2476;&#2434; data &#2455;&#2497;&#2482;&#2507; global structure &#2476;&#2494; simple table mapping &#2470;&#2495;&#2527;&#2503; manage &#2453;&#2480;&#2482;&#2503;&#2472;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; system grow &#2453;&#2480;&#2494; &#2486;&#2497;&#2480;&#2497; &#2453;&#2480;&#2482;&#2503; complexity &#2476;&#2494;&#2524;&#2468;&#2503; &#2469;&#2494;&#2453;&#2503;&#2404; Customer &#2447;&#2480; discount logic &#2479;&#2507;&#2455; &#2489;&#2527;, product inventory sync &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;, order status tracking &#2482;&#2494;&#2455;&#2503;, payment retry mechanism &#2482;&#2494;&#2455;&#2503;&#2404; &#2468;&#2454;&#2472; &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527; &#2447;&#2453;&#2463;&#2495; module change &#2453;&#2480;&#2482;&#2503; &#2437;&#2472;&#2509;&#2479; module unexpected &#2477;&#2494;&#2476;&#2503; break &#2453;&#2480;&#2503;&#2404; &#2453;&#2494;&#2480;&#2467; data &#2447;&#2476;&#2434; behaviour &#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; clear boundary &#2469;&#2494;&#2453;&#2503; &#2472;&#2494;&#2404;</p><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; uncontrolled dependency system &#2453;&#2503; fragile &#2453;&#2480;&#2503; &#2470;&#2503;&#2527;&#2404; Engineering perspective &#2469;&#2503;&#2453;&#2503; &#2447;&#2463;&#2494;&#2453;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527; <strong>tight coupling problem</strong>&#2404;</p><p>&#2447;&#2439; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494; solve &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; engineers &#2472;&#2468;&#2497;&#2472; &#2447;&#2453;&#2463;&#2494; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2503; - &#2479;&#2470;&#2495; software &#2453;&#2503; real world &#2447;&#2480; &#2478;&#2468;&#2507; model &#2453;&#2480;&#2494; &#2479;&#2494;&#2527; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; entity &#2472;&#2495;&#2460;&#2503;&#2480; data &#2447;&#2476;&#2434; behaviour &#2472;&#2495;&#2460;&#2503;&#2439; manage &#2453;&#2480;&#2503;, &#2468;&#2494;&#2489;&#2482;&#2503; complexity control &#2453;&#2480;&#2494; &#2488;&#2489;&#2460; &#2489;&#2476;&#2503;&#2404; &#2447;&#2439; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2469;&#2503;&#2453;&#2503;&#2439; Object Oriented Programming &#2447;&#2480; &#2460;&#2472;&#2509;&#2478;&#2404;</p><div><hr></div><h3>Object Oriented Programming &#2438;&#2488;&#2482;&#2503; &#2453;&#2495;?</h3><p>&#2488;&#2489;&#2460;&#2477;&#2494;&#2476;&#2503; &#2476;&#2482;&#2482;&#2503; Object Oriented Programming &#2489;&#2482;&#2507; &#2447;&#2478;&#2472; &#2447;&#2453;&#2463;&#2495; programming approach &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; system &#2453;&#2503; real world &#2447;&#2480; objects &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; model &#2453;&#2480;&#2494; &#2489;&#2527;&#2404; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; object &#2472;&#2495;&#2460;&#2503;&#2480; state (data) &#2447;&#2476;&#2434; behaviour (methods) &#2472;&#2495;&#2527;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2503;&#2404;</p><p>&#2471;&#2480;&#2503;&#2472; &#2447;&#2453;&#2463;&#2495; E-commerce system &#2447; &#2447;&#2453;&#2463;&#2495; <strong>Product</strong> &#2438;&#2459;&#2503;&#2404; Product &#2447;&#2480; &#2453;&#2495;&#2459;&#2497; information &#2469;&#2494;&#2453;&#2503; &#2479;&#2503;&#2478;&#2472; name, price, stock quantity&#2404; &#2438;&#2476;&#2494;&#2480; &#2453;&#2495;&#2459;&#2497; behaviour &#2469;&#2494;&#2453;&#2503; &#2479;&#2503;&#2478;&#2472; price update &#2453;&#2480;&#2494;, stock reduce &#2453;&#2480;&#2494;, availability check &#2453;&#2480;&#2494;&#2404;</p><p>Procedural approach &#2447; &#2489;&#2527;&#2468;&#2507; &#2438;&#2474;&#2472;&#2495; price change &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; external function &#2482;&#2495;&#2454;&#2468;&#2503;&#2472;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; OOP approach &#2447; Product &#2472;&#2495;&#2460;&#2503;&#2439; &#2472;&#2495;&#2460;&#2503;&#2480; price manage &#2453;&#2480;&#2476;&#2503;&#2404; &#2447;&#2468;&#2503; system &#2437;&#2472;&#2503;&#2453; &#2476;&#2503;&#2486;&#2495; organized &#2489;&#2527; &#2453;&#2494;&#2480;&#2467; responsibility clearly defined &#2469;&#2494;&#2453;&#2503;&#2404;</p><p>&#2447;&#2439; approach &#2447;&#2480; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; &#2476;&#2524; &#2488;&#2497;&#2476;&#2495;&#2471;&#2494; &#2489;&#2482;&#2507; system &#2453;&#2503; logical building block &#2447; &#2477;&#2494;&#2455; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;, &#2479;&#2503;&#2463;&#2494; large scale backend development &#2447; &#2437;&#2468;&#2509;&#2479;&#2472;&#2509;&#2468; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467;&#2404;</p><div><hr></div><h3>Real software example &#2470;&#2495;&#2527;&#2503; &#2476;&#2497;&#2461;&#2495;</h3><p>&#2471;&#2480;&#2503;&#2472; &#2438;&#2478;&#2480;&#2494; &#2447;&#2453;&#2463;&#2495; simple online shop system design &#2453;&#2480;&#2459;&#2495;&#2404;</p><p>&#2447;&#2454;&#2494;&#2472;&#2503; &#2468;&#2495;&#2472;&#2463;&#2495; main entity &#2438;&#2459;&#2503;:</p><ol><li><p>Customer</p></li><li><p>Product</p></li><li><p>Order</p></li></ol><p>&#2447;&#2453;&#2460;&#2472; Customer multiple Order &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2447;&#2453;&#2463;&#2495; Order &#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; multiple Product &#2469;&#2494;&#2453;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2447;&#2454;&#2472; &#2479;&#2470;&#2495; OOP mindset &#2447; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2495; &#2468;&#2494;&#2489;&#2482;&#2503; &#2438;&#2478;&#2480;&#2494; naturally &#2477;&#2494;&#2476;&#2476;&#2507;:</p><ul><li><p>Customer &#2472;&#2495;&#2460;&#2503;&#2480; profile manage &#2453;&#2480;&#2476;&#2503;</p></li><li><p>Product &#2472;&#2495;&#2460;&#2503;&#2480; inventory manage &#2453;&#2480;&#2476;&#2503;</p></li><li><p>Order &#2472;&#2495;&#2460;&#2503;&#2480; lifecycle manage &#2453;&#2480;&#2476;&#2503;</p></li></ul><h5>Example &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2497;&#2472; conceptual level &#2447;:</h5><h5><strong>Customer object &#2469;&#2494;&#2453;&#2476;&#2503; &#2479;&#2494;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; &#2469;&#2494;&#2453;&#2476;&#2503;:</strong></h5><ul><li><p>customerId</p></li><li><p>name</p></li><li><p>email</p></li><li><p>address</p></li></ul><p>&#2447;&#2476;&#2434; behaviour:</p><ul><li><p>updateProfile()</p></li><li><p>changeAddress()</p></li><li><p>viewOrders()</p></li></ul><h5><strong>Product object &#2469;&#2494;&#2453;&#2476;&#2503;:</strong></h5><ul><li><p>productId</p></li><li><p>name</p></li><li><p>price</p></li><li><p>availableStock</p></li></ul><p>&#2447;&#2476;&#2434; behaviour:</p><ul><li><p>updatePrice()</p></li><li><p>reduceStock()</p></li><li><p>checkAvailability()</p></li></ul><h5><strong>Order object &#2469;&#2494;&#2453;&#2476;&#2503;:</strong></h5><ul><li><p>orderId</p></li><li><p>customer</p></li><li><p>productList</p></li><li><p>totalAmount</p></li><li><p>orderStatus</p></li></ul><p>&#2447;&#2476;&#2434; behaviour:</p><ul><li><p>calculateTotal()</p></li><li><p>placeOrder()</p></li><li><p>cancelOrder()</p></li><li><p>updateStatus()</p></li></ul><p>&#2447;&#2454;&#2472; &#2482;&#2453;&#2509;&#2487;&#2509;&#2479; &#2453;&#2480;&#2482;&#2503; &#2470;&#2503;&#2454;&#2476;&#2503;&#2472; system naturally organized &#2489;&#2527;&#2503; &#2455;&#2503;&#2459;&#2503;&#2404; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; object &#2472;&#2495;&#2460;&#2503;&#2480; responsibility handle &#2453;&#2480;&#2459;&#2503;&#2404; &#2447;&#2463;&#2494;&#2453;&#2503; &#2476;&#2482;&#2494; &#2489;&#2527; <strong>responsibility driven design</strong>, &#2479;&#2494; clean architecture &#2447;&#2480; fundamental concept&#2404;</p><div><hr></div><h3>Industry &#2447;&#2454;&#2472;&#2507; OOP &#2453;&#2503;&#2472; &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503;?</h3><p>&#2437;&#2472;&#2503;&#2453;&#2503;&#2439; &#2477;&#2494;&#2476;&#2503; OOP &#2486;&#2497;&#2471;&#2497; academic concept&#2404; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476;&#2503; &#2447;&#2463;&#2494; &#2477;&#2497;&#2482;&#2404; Modern backend frameworks &#2479;&#2503;&#2478;&#2472; Spring Boot, .NET, Django ORM &#8212; &#2488;&#2476;&#2439; OOP concept &#2447;&#2480; &#2441;&#2474;&#2480; built&#2404;</p><p>&#2453;&#2494;&#2480;&#2467; enterprise system &#2447; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; &#2476;&#2524; challenge coding &#2472;&#2494;, &#2476;&#2480;&#2434; <strong>change manage &#2453;&#2480;&#2494;</strong>&#2404;</p><p>Real production system &#2447; requirement change &#2489;&#2476;&#2503;&#2439;&#2404; &#2472;&#2468;&#2497;&#2472; feature &#2438;&#2488;&#2476;&#2503;, old logic modify &#2489;&#2476;&#2503;, integration change &#2489;&#2476;&#2503;&#2404; &#2479;&#2470;&#2495; system structured &#2472;&#2494; &#2489;&#2527; &#2468;&#2494;&#2489;&#2482;&#2503; small change &#2453;&#2480;&#2468;&#2503; &#2455;&#2495;&#2527;&#2503;&#2451; huge regression risk &#2468;&#2504;&#2480;&#2495; &#2489;&#2527;&#2404;</p><h5><strong>OOP &#2447;&#2439; &#2460;&#2494;&#2527;&#2455;&#2494;&#2527; &#2488;&#2494;&#2489;&#2494;&#2479;&#2509;&#2479; &#2453;&#2480;&#2503; &#2453;&#2494;&#2480;&#2467;:</strong></h5><ol><li><p>Encapsulation change isolate &#2453;&#2480;&#2503;</p></li><li><p>Abstraction complexity hide &#2453;&#2480;&#2503;</p></li><li><p>Inheritance reuse &#2476;&#2494;&#2524;&#2494;&#2527;</p></li><li><p>Polymorphism extensibility &#2470;&#2503;&#2527;</p></li></ol><p>&#2447;&#2439; &#2453;&#2494;&#2480;&#2467;&#2503;&#2439; large scale SaaS platform, banking software, logistics system - &#2488;&#2476; &#2460;&#2494;&#2527;&#2455;&#2494;&#2527; OOP heavily used&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[How OpenClaw Works: Understanding AI Agent Architecture in a Simple Way]]></title><description><![CDATA[OpenClaw AI Engineering Bootcamp &#8211; Part 2]]></description><link>https://rhidoyhasanmahmud.substack.com/p/how-openclaw-works-understanding</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/how-openclaw-works-understanding</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sat, 28 Mar 2026 11:10:17 GMT</pubDate><enclosure url="https://substackcdn.com/image/fetch/$s_!ChIL!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><a href="https://rhidoyhasanmahmud.substack.com/p/openclaw-ai-agent">Part-1 &#2447; &#2438;&#2478;&#2480;&#2494; AI Agent &#2453;&#2495; &#2447;&#2476;&#2434; &#2453;&#2503;&#2472; &#2447;&#2439; concept &#2447;&#2454;&#2472; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2489;&#2527;&#2503; &#2441;&#2464;&#2459;&#2503; &#2468;&#2494; &#2472;&#2495;&#2527;&#2503; &#2438;&#2482;&#2507;&#2458;&#2472;&#2494; &#2453;&#2480;&#2503;&#2459;&#2495;</a>&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2447;&#2453;&#2460;&#2472; learner &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2447;&#2454;&#2494;&#2472;&#2503; &#2447;&#2453;&#2463;&#2495; &#2454;&#2497;&#2476; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2474;&#2509;&#2480;&#2486;&#2509;&#2472; &#2438;&#2488;&#2503; - &#2479;&#2454;&#2472; &#2447;&#2453;&#2463;&#2495; AI agent run &#2453;&#2480;&#2503; &#2468;&#2454;&#2472; &#2438;&#2488;&#2482;&#2503; &#2477;&#2495;&#2468;&#2480;&#2503; &#2453;&#2495; &#2456;&#2463;&#2503;?</p><p>&#2438;&#2478;&#2480;&#2494; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; AI &#2453;&#2503; &#2447;&#2453;&#2463;&#2495; black box &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; &#2470;&#2503;&#2454;&#2495;&#2404; &#2438;&#2478;&#2480;&#2494; &#2447;&#2453;&#2463;&#2495; instruction &#2470;&#2495;&#2439;, &#2453;&#2495;&#2459;&#2497;&#2453;&#2509;&#2487;&#2467; &#2474;&#2480;&#2503; AI &#2447;&#2453;&#2463;&#2495; answer &#2470;&#2503;&#2527;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476;&#2503; &#2447;&#2439; process &#2447;&#2480; &#2477;&#2495;&#2468;&#2480;&#2503; &#2476;&#2503;&#2486; &#2453;&#2495;&#2459;&#2497; component &#2447;&#2453;&#2488;&#2494;&#2469;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2503;&#2404; &#2447;&#2439; structure &#2476;&#2507;&#2461;&#2494; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2453;&#2494;&#2480;&#2467; &#2438;&#2474;&#2472;&#2495; &#2479;&#2470;&#2495; &#2477;&#2476;&#2495;&#2487;&#2509;&#2479;&#2468;&#2503; AI system build &#2453;&#2480;&#2468;&#2503; &#2458;&#2494;&#2472;, &#2468;&#2494;&#2489;&#2482;&#2503; &#2486;&#2497;&#2471;&#2497; AI &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2460;&#2494;&#2472;&#2482;&#2503;&#2439; &#2489;&#2476;&#2503; &#2472;&#2494;, &#2476;&#2480;&#2434; system &#2447;&#2480; &#2477;&#2495;&#2468;&#2480;&#2503;&#2480; logic &#2476;&#2497;&#2461;&#2468;&#2503;&#2451; &#2489;&#2476;&#2503;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>&#2447;&#2453;&#2463;&#2495; &#2488;&#2489;&#2460; analogy &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2482;&#2503; &#2476;&#2495;&#2487;&#2527;&#2463;&#2495; &#2438;&#2480;&#2451; &#2474;&#2480;&#2495;&#2487;&#2509;&#2453;&#2494;&#2480; &#2489;&#2476;&#2503;&#2404;</p><p>&#2471;&#2480;&#2497;&#2472; &#2447;&#2453;&#2463;&#2495; office environment &#2453;&#2482;&#2509;&#2474;&#2472;&#2494; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; &#2447;&#2453;&#2460;&#2472; manager task receive &#2453;&#2480;&#2503;&#2472;, &#2453;&#2527;&#2503;&#2453;&#2460;&#2472; employee &#2453;&#2494;&#2460; &#2453;&#2480;&#2503;&#2472;, &#2447;&#2453;&#2463;&#2495; document storage &#2438;&#2459;&#2503; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472;&#2496;&#2527; information &#2480;&#2494;&#2454;&#2494; &#2469;&#2494;&#2453;&#2503; &#2447;&#2476;&#2434; &#2453;&#2495;&#2459;&#2497; tools &#2469;&#2494;&#2453;&#2503; &#2479;&#2503;&#2455;&#2497;&#2482;&#2507; &#2470;&#2495;&#2527;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404; </p><p>&#2447;&#2454;&#2472; &#2479;&#2470;&#2495; manager &#2447;&#2453;&#2463;&#2495; task &#2474;&#2494;&#2472;, &#2468;&#2495;&#2472;&#2495; &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; task &#2476;&#2497;&#2461;&#2503;&#2472;, &#2468;&#2494;&#2480;&#2474;&#2480; plan &#2453;&#2480;&#2503;&#2472;, decide &#2453;&#2480;&#2503;&#2472; &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; &#2453;&#2494;&#2460;&#2463;&#2495; &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;, &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472; &#2489;&#2482;&#2503; tools &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503;&#2472; &#2447;&#2476;&#2434; &#2486;&#2503;&#2487;&#2503; result &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2503;&#2472;&#2404;</p><p>&#2447;&#2453;&#2463;&#2495; AI agent system &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; &#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; structure follow &#2453;&#2480;&#2503;&#2404; &#2447;&#2454;&#2494;&#2472;&#2503; &#2453;&#2527;&#2503;&#2453;&#2463;&#2495; main component &#2447;&#2453;&#2488;&#2494;&#2469;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2503; &#2447;&#2453;&#2463;&#2495; task complete &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479;&#2404; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2477;&#2494;&#2476;&#2503; &#2447;&#2453;&#2463;&#2495; AI agent architecture &#2476;&#2497;&#2461;&#2468;&#2503; &#2489;&#2482;&#2503; &#2438;&#2478;&#2480;&#2494; &#2474;&#2494;&#2433;&#2458;&#2463;&#2495; core component &#2447;&#2480; &#2453;&#2469;&#2494; &#2476;&#2482;&#2468;&#2503; &#2474;&#2494;&#2480;&#2495;:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!ChIL!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!ChIL!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 424w, https://substackcdn.com/image/fetch/$s_!ChIL!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 848w, https://substackcdn.com/image/fetch/$s_!ChIL!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 1272w, https://substackcdn.com/image/fetch/$s_!ChIL!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!ChIL!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png" width="1252" height="706" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:706,&quot;width&quot;:1252,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:190732,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:false,&quot;topImage&quot;:true,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/192391727?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!ChIL!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 424w, https://substackcdn.com/image/fetch/$s_!ChIL!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 848w, https://substackcdn.com/image/fetch/$s_!ChIL!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 1272w, https://substackcdn.com/image/fetch/$s_!ChIL!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb1ae78b4-3eab-469a-9653-1d1d90c9242c_1252x706.png 1456w" sizes="100vw" fetchpriority="high"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>&#2447;&#2439; &#2474;&#2494;&#2433;&#2458;&#2463;&#2495; &#2460;&#2495;&#2472;&#2495;&#2488; &#2476;&#2497;&#2461;&#2468;&#2503; &#2474;&#2494;&#2480;&#2482;&#2503; basic architecture &#2488;&#2478;&#2509;&#2474;&#2480;&#2509;&#2453;&#2503; &#2447;&#2453;&#2463;&#2495; &#2474;&#2480;&#2495;&#2487;&#2509;&#2453;&#2494;&#2480; &#2471;&#2494;&#2480;&#2467;&#2494; &#2468;&#2504;&#2480;&#2495; &#2489;&#2527;&#2404;</p><h3><em>Agent - system &#2447;&#2480; decision maker</em></h3><p>Agent &#2453;&#2503; system &#2447;&#2480; decision making component &#2476;&#2482;&#2494; &#2479;&#2494;&#2527;&#2404; &#2479;&#2454;&#2472; &#2447;&#2453;&#2463;&#2495; user instruction &#2470;&#2503;&#2527;, agent &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503; instruction &#2447;&#2480; meaning &#2476;&#2497;&#2461;&#2468;&#2503;&#2404; &#2437;&#2480;&#2509;&#2469;&#2494;&#2510; user &#2453;&#2495; &#2458;&#2494;&#2458;&#2509;&#2459;&#2503;, &#2453;&#2495; &#2471;&#2480;&#2472;&#2503;&#2480; information &#2470;&#2480;&#2453;&#2494;&#2480; &#2447;&#2476;&#2434; &#2453;&#2495; &#2471;&#2480;&#2472;&#2503;&#2480; action &#2472;&#2503;&#2451;&#2527;&#2494; &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472;&#2404;</p><p>&#2447;&#2439; process &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; &#2447;&#2453;&#2460;&#2472; software engineer &#2447;&#2480; &#2478;&#2468;&#2507;, &#2479;&#2495;&#2472;&#2495; requirement &#2486;&#2497;&#2472;&#2503; decide &#2453;&#2480;&#2503;&#2472; solution &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; design &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;&#2404; Agent &#2447;&#2480; &#2453;&#2494;&#2460; &#2478;&#2498;&#2482;&#2468; reasoning &#2453;&#2480;&#2494; &#2447;&#2476;&#2434; next step determine &#2453;&#2480;&#2494;&#2404;</p><p>&#2488;&#2489;&#2460;&#2477;&#2494;&#2476;&#2503; &#2476;&#2482;&#2482;&#2503; agent &#2447;&#2480; &#2470;&#2494;&#2527;&#2495;&#2468;&#2509;&#2476; &#2468;&#2495;&#2472;&#2463;&#2495; &#2460;&#2495;&#2472;&#2495;&#2488;&#2503;&#2480; &#2441;&#2474;&#2480; &#2472;&#2495;&#2480;&#2509;&#2477;&#2480; &#2453;&#2480;&#2503;:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!ixvu!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!ixvu!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 424w, https://substackcdn.com/image/fetch/$s_!ixvu!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 848w, https://substackcdn.com/image/fetch/$s_!ixvu!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 1272w, https://substackcdn.com/image/fetch/$s_!ixvu!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!ixvu!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png" width="830" height="688" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:688,&quot;width&quot;:830,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:104961,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/192391727?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!ixvu!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 424w, https://substackcdn.com/image/fetch/$s_!ixvu!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 848w, https://substackcdn.com/image/fetch/$s_!ixvu!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 1272w, https://substackcdn.com/image/fetch/$s_!ixvu!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1793c3a1-fa10-4869-9f4a-95ae94dacd45_830x688.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><strong>&#2447;&#2439; &#2453;&#2494;&#2480;&#2467;&#2503;&#2439; agent &#2453;&#2503; &#2437;&#2472;&#2503;&#2453; &#2488;&#2478;&#2527; system &#2447;&#2480; brain &#2476;&#2482;&#2494; &#2489;&#2527;&#2404;</strong></p><h3><em>Memory - AI system &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; context &#2478;&#2472;&#2503; &#2480;&#2494;&#2454;&#2503;</em></h3><p>Memory component AI system &#2453;&#2503; context &#2471;&#2480;&#2503; &#2480;&#2494;&#2454;&#2468;&#2503; &#2488;&#2494;&#2489;&#2494;&#2479;&#2509;&#2479; &#2453;&#2480;&#2503;&#2404; &#2479;&#2470;&#2495; memory &#2472;&#2494; &#2469;&#2494;&#2453;&#2503; &#2468;&#2494;&#2489;&#2482;&#2503; AI &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; instruction &#2453;&#2503; completely new &#2489;&#2495;&#2488;&#2503;&#2476;&#2503; treat &#2453;&#2480;&#2476;&#2503;&#2404;</p><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2474;&#2472;&#2495; &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; &#2476;&#2482;&#2482;&#2503;&#2472;, <em>&#8220;&#2438;&#2478;&#2495; &#2447;&#2453;&#2463;&#2495; ecommerce project &#2476;&#2494;&#2472;&#2494;&#2458;&#2509;&#2459;&#2495;&#2404;&#8221;</em> &#2447;&#2480;&#2474;&#2480; &#2453;&#2495;&#2459;&#2497;&#2453;&#2509;&#2487;&#2467; &#2474;&#2480;&#2503; &#2476;&#2482;&#2482;&#2503;&#2472;, <em>&#8220;&#2447;&#2463;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; &#2453;&#2507;&#2472; database &#2477;&#2494;&#2482;&#2507; &#2489;&#2476;&#2503;?&#8221;</em> &#2479;&#2470;&#2495; system memory &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; &#2468;&#2494;&#2489;&#2482;&#2503; &#2488;&#2503; &#2476;&#2497;&#2461;&#2468;&#2503; &#2474;&#2494;&#2480;&#2476;&#2503; &#2438;&#2474;&#2472;&#2495; ecommerce project &#2447;&#2480; &#2453;&#2469;&#2494;&#2439; &#2476;&#2482;&#2459;&#2503;&#2472;&#2404;</p><p><strong>Memory &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2470;&#2497;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;</strong>&#2404; &#2447;&#2453;&#2463;&#2495; &#2489;&#2482;&#2507; <strong>short-term memory</strong> &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; current interaction &#2447;&#2480; information &#2469;&#2494;&#2453;&#2503;&#2404; &#2437;&#2472;&#2509;&#2479;&#2463;&#2495; &#2489;&#2482;&#2507; <strong>long-term memory</strong> &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; important knowledge store &#2453;&#2480;&#2494; &#2469;&#2494;&#2453;&#2503; &#2479;&#2494; future interaction &#2447; &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><p>&#2447;&#2439; concept &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; &#2478;&#2494;&#2472;&#2497;&#2487;&#2503;&#2480; brain &#2447;&#2480; &#2478;&#2468;&#2507;&#2404; &#2438;&#2478;&#2480;&#2494; &#2453;&#2495;&#2459;&#2497; information temporary &#2478;&#2472;&#2503; &#2480;&#2494;&#2454;&#2495;, &#2438;&#2476;&#2494;&#2480; &#2453;&#2495;&#2459;&#2497; information &#2470;&#2496;&#2480;&#2509;&#2456; &#2488;&#2478;&#2527; &#2471;&#2480;&#2503; &#2478;&#2472;&#2503; &#2480;&#2494;&#2454;&#2495;&#2404;</p><h3><em>Tools - AI &#2453;&#2503; practical capability &#2470;&#2503;&#2527;</em></h3><p>AI &#2479;&#2470;&#2495; &#2486;&#2497;&#2471;&#2497; text generate &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2468;&#2494;&#2489;&#2482;&#2503; &#2468;&#2494;&#2480; capability &#2488;&#2496;&#2478;&#2495;&#2468; &#2469;&#2494;&#2453;&#2503;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2479;&#2454;&#2472; AI &#2453;&#2503; tools &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494;&#2480; &#2488;&#2497;&#2479;&#2507;&#2455; &#2470;&#2503;&#2451;&#2527;&#2494; &#2489;&#2527; &#2468;&#2454;&#2472; &#2488;&#2503; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476; &#2453;&#2494;&#2460; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2447;&#2439; tools &#2476;&#2495;&#2477;&#2495;&#2472;&#2509;&#2472; &#2471;&#2480;&#2472;&#2503;&#2480; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2479;&#2503;&#2478;&#2472; web search, database access, API integration, file reading &#2437;&#2469;&#2476;&#2494; code execution environment&#2404; &#2479;&#2454;&#2472; AI &#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; tools &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2468;&#2454;&#2472; &#2488;&#2503; &#2486;&#2497;&#2471;&#2497; theoretical answer &#2472;&#2494; &#2470;&#2495;&#2527;&#2503; &#2476;&#2494;&#2488;&#2509;&#2468;&#2476; data &#2472;&#2495;&#2527;&#2503; &#2453;&#2494;&#2460; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2474;&#2472;&#2495; &#2447;&#2453;&#2463;&#2495; AI system &#2453;&#2503; &#2476;&#2482;&#2482;&#2503;&#2472;, <em><strong>&#8220;Latest AI trends &#2472;&#2495;&#2527;&#2503; &#2447;&#2453;&#2463;&#2495; summary &#2470;&#2495;&#2472;&#2404;&#8221;</strong></em> &#2479;&#2470;&#2495; system &#2447;&#2480; &#2453;&#2494;&#2459;&#2503; web search capability &#2469;&#2494;&#2453;&#2503; &#2468;&#2494;&#2489;&#2482;&#2503; &#2488;&#2503; internet &#2469;&#2503;&#2453;&#2503; data collect &#2453;&#2480;&#2503; &#2447;&#2453;&#2463;&#2495; updated answer &#2470;&#2495;&#2468;&#2503; &#2474;&#2494;&#2480;&#2476;&#2503;&#2404;</p><p>&#2447;&#2439; &#2460;&#2494;&#2527;&#2455;&#2494;&#2463;&#2494;&#2468;&#2503; &#2447;&#2453;&#2463;&#2495; simple rule &#2478;&#2472;&#2503; &#2480;&#2494;&#2454;&#2494; &#2479;&#2494;&#2527;: <strong>Tools &#2459;&#2494;&#2524;&#2494; AI explain &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;, tools &#2469;&#2494;&#2453;&#2482;&#2503; AI execute &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</strong></p><h3>Workflow - task execution &#2447;&#2480; roadmap</h3><p>Workflow define &#2453;&#2480;&#2503; &#2447;&#2453;&#2463;&#2495; task &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; complete &#2489;&#2476;&#2503;&#2404; &#2447;&#2463;&#2495; &#2438;&#2488;&#2482;&#2503; execution &#2447;&#2480; roadmap&#2404;</p><p>&#2471;&#2480;&#2497;&#2472; &#2447;&#2453;&#2463;&#2495; AI research assistant &#2447;&#2480; workflow &#2447;&#2478;&#2472; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;: &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; user query receive &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;, &#2468;&#2494;&#2480;&#2474;&#2480; topic identify &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;, &#2447;&#2480;&#2474;&#2480; relevant information collect &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;, &#2468;&#2494;&#2480;&#2474;&#2480; important data filter &#2453;&#2480;&#2494; &#2489;&#2476;&#2503; &#2447;&#2476;&#2434; &#2486;&#2503;&#2487;&#2503; &#2447;&#2453;&#2463;&#2495; structured answer &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;&#2404;</p><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; step sequence define &#2453;&#2480;&#2494;&#2453;&#2503; workflow design &#2476;&#2482;&#2494; &#2479;&#2494;&#2527;&#2404; &#2447;&#2463;&#2495; actually &#2447;&#2453;&#2463;&#2495; engineering skill &#2453;&#2494;&#2480;&#2467; &#2447;&#2454;&#2494;&#2472;&#2503; logical order maintain &#2453;&#2480;&#2494; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467;&#2404;</p><p><strong>&#2447;&#2453;&#2463;&#2495; typical AI workflow &#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2458;&#2494;&#2480;&#2463;&#2495; stage &#2469;&#2494;&#2453;&#2503;:</strong></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!kM-T!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!kM-T!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 424w, https://substackcdn.com/image/fetch/$s_!kM-T!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 848w, https://substackcdn.com/image/fetch/$s_!kM-T!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 1272w, https://substackcdn.com/image/fetch/$s_!kM-T!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!kM-T!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png" width="1198" height="706" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/d848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:706,&quot;width&quot;:1198,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:104731,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/192391727?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!kM-T!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 424w, https://substackcdn.com/image/fetch/$s_!kM-T!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 848w, https://substackcdn.com/image/fetch/$s_!kM-T!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 1272w, https://substackcdn.com/image/fetch/$s_!kM-T!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd848f71e-d3fb-4c6b-a0f0-5f08c4cbde48_1198x706.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>&#2447;&#2439; flow &#2474;&#2509;&#2480;&#2494;&#2527; &#2488;&#2476; AI agent system &#2447; &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527;&#2404;</p><h3><em>&#2447;&#2453;&#2463;&#2495; request &#2447;&#2480; &#2477;&#2495;&#2468;&#2480;&#2503; &#2453;&#2495; &#2456;&#2463;&#2503;?</em></h3><p>&#2447;&#2454;&#2472; &#2447;&#2453;&#2463;&#2495; simple example &#2470;&#2495;&#2527;&#2503; &#2474;&#2497;&#2480;&#2507; process &#2463;&#2494; &#2476;&#2507;&#2461;&#2494; &#2479;&#2494;&#2453;&#2404;</p><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2474;&#2472;&#2495; &#2447;&#2453;&#2463;&#2495; AI system &#2453;&#2503; &#2476;&#2482;&#2482;&#2503;&#2472;, <em><strong>&#8220;Microservices architecture &#2488;&#2489;&#2460;&#2477;&#2494;&#2476;&#2503; explain &#2453;&#2480;&#2497;&#2472;&#2404;&#8221;</strong></em></p><p>System internally &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2453;&#2527;&#2503;&#2453;&#2463;&#2495; &#2471;&#2494;&#2474; follow &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; agent query analyse &#2453;&#2480;&#2476;&#2503;&#2404; &#2447;&#2480;&#2474;&#2480; memory check &#2453;&#2480;&#2476;&#2503; relevant context &#2438;&#2459;&#2503; &#2453;&#2495;&#2472;&#2494;&#2404; &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472; &#2489;&#2482;&#2503; tools &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; additional information collect &#2453;&#2480;&#2476;&#2503;&#2404; &#2468;&#2494;&#2480;&#2474;&#2480; &#2447;&#2453;&#2463;&#2495; structured explanation generate &#2453;&#2480;&#2476;&#2503; &#2447;&#2476;&#2434; &#2486;&#2503;&#2487;&#2503; response return &#2453;&#2480;&#2476;&#2503;&#2404;</p><p>User perspective &#2469;&#2503;&#2453;&#2503; &#2447;&#2463;&#2494; simple &#2478;&#2472;&#2503; &#2489;&#2482;&#2503;&#2451;, &#2477;&#2495;&#2468;&#2480;&#2503; &#2447;&#2453;&#2463;&#2495; structured process &#2453;&#2494;&#2460; &#2453;&#2480;&#2503;&#2404;</p><h3><em>Infrastructure - system &#2453;&#2507;&#2469;&#2494;&#2527; run &#2453;&#2480;&#2503;?</em></h3><p>AI system &#2486;&#2497;&#2471;&#2497; software &#2472;&#2494;, &#2447;&#2463;&#2495; infrastructure &#2447;&#2480; &#2441;&#2474;&#2480; run &#2453;&#2480;&#2503;&#2404; &#2447;&#2453;&#2463;&#2495; AI agent local computer, virtual machine, VPS server &#2476;&#2494; cloud environment &#2447; run &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p><strong>Infrastructure decision &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2468;&#2495;&#2472;&#2463;&#2495; &#2476;&#2495;&#2487;&#2527;&#2503;&#2480; &#2441;&#2474;&#2480; depend &#2453;&#2480;&#2503;:</strong></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!sfy-!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!sfy-!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 424w, https://substackcdn.com/image/fetch/$s_!sfy-!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 848w, https://substackcdn.com/image/fetch/$s_!sfy-!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 1272w, https://substackcdn.com/image/fetch/$s_!sfy-!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!sfy-!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png" width="796" height="394" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/c25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:394,&quot;width&quot;:796,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:35147,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/192391727?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!sfy-!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 424w, https://substackcdn.com/image/fetch/$s_!sfy-!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 848w, https://substackcdn.com/image/fetch/$s_!sfy-!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 1272w, https://substackcdn.com/image/fetch/$s_!sfy-!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc25f81a3-4f14-4efa-838c-46e29ece660b_796x394.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Learning phase &#2447; local machine &#2479;&#2469;&#2503;&#2487;&#2509;&#2463; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; Small deployment &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; VPS &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404; Production level system &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; cloud infrastructure &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; infrastructure thinking AI engineering &#2447;&#2480; &#2447;&#2453;&#2463;&#2495; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2437;&#2434;&#2486;&#2404;</p><h3><em>Architecture &#2476;&#2497;&#2461;&#2494; &#2453;&#2503;&#2472; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467;?</em></h3><p>&#2437;&#2472;&#2503;&#2453;&#2503; &#2486;&#2497;&#2471;&#2497; AI &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2468;&#2503; &#2458;&#2494;&#2472;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2479;&#2494;&#2480;&#2494; AI system build &#2453;&#2480;&#2468;&#2503; &#2458;&#2494;&#2472; &#2468;&#2494;&#2470;&#2503;&#2480; &#2460;&#2472;&#2509;&#2479; architecture &#2476;&#2507;&#2461;&#2494; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467;&#2404;</p><p>&#2453;&#2494;&#2480;&#2467; architecture &#2476;&#2497;&#2461;&#2482;&#2503; system behaviour predict &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404; Problem troubleshoot &#2453;&#2480;&#2494; &#2488;&#2489;&#2460; &#2489;&#2527;&#2404; Performance bottleneck identify &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404; Security risk &#2476;&#2507;&#2461;&#2494; &#2479;&#2494;&#2527;&#2404;</p><p>&#2488;&#2476;&#2458;&#2503;&#2527;&#2503; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2476;&#2495;&#2487;&#2527; &#2489;&#2482;&#2507; - architecture &#2476;&#2497;&#2461;&#2482;&#2503; &#2438;&#2474;&#2472;&#2495; &#2476;&#2497;&#2461;&#2468;&#2503; &#2474;&#2494;&#2480;&#2476;&#2503;&#2472; system &#2447;&#2480; limitation &#2453;&#2507;&#2469;&#2494;&#2527;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[What is OpenClaw? Understanding AI Agents and Why They Matter Today]]></title><description><![CDATA[OpenClaw AI Engineering Bootcamp &#8211; Part 1]]></description><link>https://rhidoyhasanmahmud.substack.com/p/openclaw-ai-agent</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/openclaw-ai-agent</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sat, 28 Mar 2026 09:02:01 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/cfb20d26-ef2e-486a-a73c-041799b022a0_2400x1350.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h3><em>AI &#2447;&#2454;&#2472; &#2486;&#2497;&#2471;&#2497; &#2441;&#2468;&#2509;&#2468;&#2480; &#2470;&#2503;&#2527; &#2472;&#2494;, &#2453;&#2494;&#2460;&#2451; &#2453;&#2480;&#2503;</em></h3><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2474;&#2472;&#2494;&#2480; &#2447;&#2478;&#2472; &#2447;&#2453;&#2463;&#2495; assistant &#2438;&#2459;&#2503; &#2479;&#2494;&#2453;&#2503; &#2438;&#2474;&#2472;&#2495; &#2486;&#2497;&#2471;&#2497; &#2474;&#2509;&#2480;&#2486;&#2509;&#2472;&#2439; &#2453;&#2480;&#2503;&#2472; &#2472;&#2494;, &#2476;&#2480;&#2434; &#2453;&#2494;&#2460; &#2470;&#2503;&#2472;&#2404; &#2438;&#2474;&#2472;&#2495; &#2479;&#2470;&#2495; &#2468;&#2494;&#2453;&#2503; &#2476;&#2482;&#2503;&#2472;, <em>&#8220;<strong>&#2447;&#2439; topic &#2472;&#2495;&#2527;&#2503; research &#2453;&#2480;&#2503; &#2438;&#2478;&#2494;&#2453;&#2503; &#2488;&#2489;&#2460;&#2477;&#2494;&#2476;&#2503; &#2476;&#2497;&#2461;&#2495;&#2527;&#2503; &#2470;&#2495;&#2472;,&#8221;</strong></em> &#2488;&#2503; &#2486;&#2497;&#2471;&#2497; &#2453;&#2495;&#2459;&#2497; &#2468;&#2469;&#2509;&#2479; &#2470;&#2495;&#2527;&#2503; &#2469;&#2503;&#2478;&#2503; &#2469;&#2494;&#2453;&#2503; &#2472;&#2494;&#2404; &#2488;&#2503; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503; &#2476;&#2495;&#2477;&#2495;&#2472;&#2509;&#2472; &#2460;&#2494;&#2527;&#2455;&#2494; &#2469;&#2503;&#2453;&#2503; &#2468;&#2469;&#2509;&#2479; &#2488;&#2434;&#2455;&#2509;&#2480;&#2489; &#2453;&#2480;&#2468;&#2503;, &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; &#2437;&#2434;&#2486; &#2438;&#2482;&#2494;&#2470;&#2494; &#2453;&#2480;&#2468;&#2503; &#2447;&#2476;&#2434; &#2447;&#2478;&#2472;&#2477;&#2494;&#2476;&#2503; &#2488;&#2494;&#2460;&#2494;&#2468;&#2503; &#2479;&#2494;&#2468;&#2503; &#2438;&#2474;&#2472;&#2495; &#2488;&#2503;&#2463;&#2494;&#2453;&#2503; &#2488;&#2489;&#2460;&#2503; &#2476;&#2497;&#2461;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2472;&#2404;</p><p>&#2447;&#2480;&#2474;&#2480; &#2479;&#2470;&#2495; &#2438;&#2474;&#2472;&#2495; &#2476;&#2482;&#2503;&#2472;, <em><strong>&#8220;&#2447;&#2439; summary &#2469;&#2503;&#2453;&#2503; &#2447;&#2453;&#2463;&#2495; presentation &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2468;&#2503; &#2488;&#2494;&#2489;&#2494;&#2479;&#2509;&#2479; &#2453;&#2480;&#2497;&#2472;,&#8221;</strong></em> &#2468;&#2454;&#2472; &#2488;&#2503; presentation &#2447;&#2480; structure &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2438;&#2476;&#2494;&#2480; &#2479;&#2470;&#2495; &#2476;&#2482;&#2503;&#2472;, <em><strong>&#8220;&#2447;&#2439; presentation &#2447;&#2480; &#2460;&#2472;&#2509;&#2479; speaking notes &#2482;&#2495;&#2454;&#2503; &#2470;&#2495;&#2472;,&#8221;</strong></em> &#2488;&#2503;&#2463;&#2494;&#2451; &#2453;&#2480;&#2503; &#2470;&#2495;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2447;&#2454;&#2494;&#2472;&#2503; &#2476;&#2495;&#2487;&#2527;&#2463;&#2494; &#2486;&#2497;&#2471;&#2497; information &#2470;&#2503;&#2451;&#2527;&#2494; &#2472;&#2494;, &#2476;&#2480;&#2434; &#2453;&#2494;&#2460;&#2503;&#2480; &#2471;&#2494;&#2474;&#2455;&#2497;&#2482;&#2507; execute &#2453;&#2480;&#2494;&#2480; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2494;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>&#2447;&#2439; &#2460;&#2494;&#2527;&#2455;&#2494;&#2463;&#2494;&#2468;&#2503;&#2439; AI &#2447;&#2480; &#2476;&#2524; &#2474;&#2480;&#2495;&#2476;&#2480;&#2509;&#2468;&#2472; &#2489;&#2527;&#2503;&#2459;&#2503;&#2404; &#2438;&#2455;&#2503; AI &#2476;&#2482;&#2468;&#2503; &#2438;&#2478;&#2480;&#2494; &#2476;&#2497;&#2461;&#2468;&#2494;&#2478; question answering system&#2404; &#2447;&#2454;&#2472; AI &#2471;&#2496;&#2480;&#2503; &#2471;&#2496;&#2480;&#2503; execution system &#2489;&#2527;&#2503; &#2479;&#2494;&#2458;&#2509;&#2459;&#2503;&#2404;</p><h3><em>AI Agent &#2438;&#2488;&#2482;&#2503; &#2453;&#2495;?</em></h3><p>AI Agent &#2453;&#2503; &#2454;&#2497;&#2476; &#2488;&#2489;&#2460;&#2477;&#2494;&#2476;&#2503; &#2476;&#2507;&#2461;&#2494;&#2468;&#2503; &#2458;&#2494;&#2439;&#2482;&#2503; &#2476;&#2482;&#2494; &#2479;&#2494;&#2527;, &#2447;&#2463;&#2495; &#2447;&#2478;&#2472; &#2447;&#2453;&#2463;&#2495; software system &#2479;&#2494;&#2453;&#2503; &#2438;&#2474;&#2472;&#2495; &#2447;&#2453;&#2463;&#2495; goal &#2470;&#2495;&#2482;&#2503; &#2488;&#2503; &#2488;&#2503;&#2439; goal achieve &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472;&#2496;&#2527; &#2471;&#2494;&#2474;&#2455;&#2497;&#2482;&#2507; &#2472;&#2495;&#2480;&#2509;&#2471;&#2494;&#2480;&#2467; &#2453;&#2480;&#2494;&#2480; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503;&#2404; &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; &#2447;&#2478;&#2472; &#2447;&#2453;&#2460;&#2472; assistant &#2447;&#2480; &#2478;&#2468;&#2507; &#2479;&#2494;&#2453;&#2503; &#2438;&#2474;&#2472;&#2495; &#2476;&#2482;&#2503;&#2472;, <em><strong>&#8220;&#2447;&#2439; &#2453;&#2494;&#2460;&#2463;&#2494; &#2453;&#2480;&#2503; &#2470;&#2495;&#2472;,&#8221;</strong></em> &#2447;&#2476;&#2434; &#2488;&#2503; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503; &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; &#2453;&#2494;&#2460;&#2463;&#2495; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527; &#2468;&#2494; &#2476;&#2503;&#2480; &#2453;&#2480;&#2468;&#2503;&#2404;</p><p>&#2447;&#2453;&#2463;&#2495; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467; AI tool &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; calculator &#2447;&#2480; &#2478;&#2468;&#2507;&#2404; &#2438;&#2474;&#2472;&#2495; input &#2470;&#2495;&#2482;&#2503; output &#2470;&#2503;&#2527;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; AI agent &#2437;&#2472;&#2503;&#2453;&#2463;&#2494; personal assistant &#2447;&#2480; &#2478;&#2468;&#2507;&#2404; &#2438;&#2474;&#2472;&#2495; &#2468;&#2494;&#2453;&#2503; &#2447;&#2453;&#2463;&#2495; &#2482;&#2453;&#2509;&#2487;&#2509;&#2479; &#2470;&#2503;&#2472; &#2447;&#2476;&#2434; &#2488;&#2503; &#2488;&#2503;&#2439; &#2482;&#2453;&#2509;&#2487;&#2509;&#2479; &#2474;&#2498;&#2480;&#2467; &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; plan &#2453;&#2480;&#2494;&#2480; &#2458;&#2503;&#2487;&#2509;&#2463;&#2494; &#2453;&#2480;&#2503;&#2404;</p><h3><em>&#2453;&#2503;&#2472; &#2447;&#2454;&#2472; AI Agent platform &#2455;&#2497;&#2482;&#2507; &#2460;&#2472;&#2474;&#2509;&#2480;&#2495;&#2527; &#2489;&#2458;&#2509;&#2459;&#2503;?</em></h3><p>&#2476;&#2480;&#2509;&#2468;&#2478;&#2494;&#2472; software industry &#2468;&#2503; &#2447;&#2453;&#2463;&#2495; &#2476;&#2524; &#2474;&#2480;&#2495;&#2476;&#2480;&#2509;&#2468;&#2472; &#2489;&#2458;&#2509;&#2459;&#2503; - companies &#2447;&#2454;&#2472; automation &#2447;&#2480; &#2470;&#2495;&#2453;&#2503; &#2479;&#2494;&#2458;&#2509;&#2459;&#2503;&#2404; &#2468;&#2494;&#2480;&#2494; repetitive &#2453;&#2494;&#2460; &#2453;&#2478;&#2494;&#2468;&#2503; &#2458;&#2494;&#2527;, human effort optimize &#2453;&#2480;&#2468;&#2503; &#2458;&#2494;&#2527; &#2447;&#2476;&#2434; operational efficiency &#2476;&#2494;&#2524;&#2494;&#2468;&#2503; &#2458;&#2494;&#2527;&#2404;</p><p>AI agent &#2447;&#2439; &#2460;&#2494;&#2527;&#2455;&#2494;&#2463;&#2494;&#2468;&#2503;&#2439; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; &#2476;&#2503;&#2486;&#2495; &#2488;&#2494;&#2489;&#2494;&#2479;&#2509;&#2479; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2447;&#2453;&#2463;&#2495; practical &#2441;&#2470;&#2494;&#2489;&#2480;&#2467; &#2458;&#2495;&#2472;&#2509;&#2468;&#2494; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404; &#2471;&#2480;&#2497;&#2472; &#2447;&#2453;&#2463;&#2495; company &#2468;&#2503; &#2474;&#2509;&#2480;&#2468;&#2495;&#2470;&#2495;&#2472; &#2437;&#2472;&#2503;&#2453; support email &#2438;&#2488;&#2503;&#2404; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2477;&#2494;&#2476;&#2503; &#2447;&#2455;&#2497;&#2482;&#2507; manually check &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;, categorize &#2453;&#2480;&#2468;&#2503; &#2489;&#2527; &#2447;&#2476;&#2434; reply &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;&#2404; &#2447;&#2468;&#2503; &#2488;&#2478;&#2527; &#2482;&#2494;&#2455;&#2503; &#2447;&#2476;&#2434; &#2447;&#2453;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; &#2453;&#2494;&#2460; &#2476;&#2494;&#2480;&#2476;&#2494;&#2480; &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2447;&#2453;&#2463;&#2495; AI agent incoming email analyse &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;, category &#2472;&#2495;&#2480;&#2509;&#2471;&#2494;&#2480;&#2467; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2447;&#2476;&#2434; suggested reply generate &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><h3><em>OpenClaw &#2447;&#2454;&#2494;&#2472;&#2503; &#2453;&#2495; &#2477;&#2498;&#2478;&#2495;&#2453;&#2494; &#2480;&#2494;&#2454;&#2503;?</em></h3><p>OpenClaw &#2489;&#2482;&#2507; &#2447;&#2478;&#2472; &#2447;&#2453;&#2463;&#2495; platform &#2479;&#2503;&#2463;&#2494; AI agent system &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2494;, manage &#2453;&#2480;&#2494; &#2447;&#2476;&#2434; deploy &#2453;&#2480;&#2494; &#2488;&#2489;&#2460; &#2453;&#2480;&#2503; &#2470;&#2503;&#2527;&#2404; &#2447;&#2480; &#2478;&#2494;&#2472;&#2503; &#2489;&#2458;&#2509;&#2459;&#2503; &#2438;&#2474;&#2472;&#2494;&#2453;&#2503; &#2488;&#2476;&#2453;&#2495;&#2459;&#2497; &#2486;&#2497;&#2480;&#2497; &#2469;&#2503;&#2453;&#2503; &#2476;&#2494;&#2472;&#2494;&#2468;&#2503; &#2489;&#2476;&#2503; &#2472;&#2494;, &#2476;&#2480;&#2434; &#2438;&#2474;&#2472;&#2495; &#2447;&#2453;&#2463;&#2495; structured environment &#2474;&#2494;&#2476;&#2503;&#2472; &#2479;&#2503;&#2454;&#2494;&#2472;&#2503; AI workflow organize &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><p>OpenClaw &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; theoretically &#2476;&#2495;&#2477;&#2495;&#2472;&#2509;&#2472; &#2471;&#2480;&#2472;&#2503;&#2480; intelligent system &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2494; &#2488;&#2478;&#2509;&#2477;&#2476;&#2404; &#2479;&#2503;&#2478;&#2472; AI research assistant, AI support system, personal AI knowledge base &#2476;&#2494; automation agent&#2404;</p><h3><em>&#2447;&#2439; Bootcamp series &#2447; &#2438;&#2474;&#2472;&#2495; &#2453;&#2495; &#2486;&#2495;&#2454;&#2476;&#2503;&#2472;?</em></h3><p>&#2447;&#2439; OpenClaw AI Engineering Bootcamp series &#2447; &#2438;&#2478;&#2494;&#2470;&#2503;&#2480; &#2482;&#2453;&#2509;&#2487;&#2509;&#2479; &#2489;&#2476;&#2503; &#2454;&#2497;&#2476; basic level &#2469;&#2503;&#2453;&#2503; &#2486;&#2497;&#2480;&#2497; &#2453;&#2480;&#2494; &#2447;&#2476;&#2434; &#2471;&#2496;&#2480;&#2503; &#2471;&#2496;&#2480;&#2503; practical understanding &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2494;&#2404; &#2438;&#2478;&#2480;&#2494; &#2486;&#2497;&#2471;&#2497; concept explain &#2453;&#2480;&#2476;&#2507; &#2472;&#2494;, &#2476;&#2480;&#2434; &#2470;&#2503;&#2454;&#2476;&#2507; &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; &#2447;&#2453;&#2463;&#2495; AI system &#2476;&#2494;&#2488;&#2509;&#2468;&#2476;&#2503; setup &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;, &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; AI agent &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2494; &#2479;&#2494;&#2527; &#2447;&#2476;&#2434; &#2453;&#2495;&#2477;&#2494;&#2476;&#2503; deploy &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><p>&#2438;&#2478;&#2494;&#2470;&#2503;&#2480; goal simple - &#2447;&#2439; series &#2486;&#2503;&#2487; &#2489;&#2451;&#2527;&#2494;&#2480; &#2474;&#2480;&#2503; &#2438;&#2474;&#2472;&#2495; &#2479;&#2503;&#2472; &#2486;&#2497;&#2471;&#2497; AI &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480;&#2453;&#2494;&#2480;&#2496; &#2472;&#2494;, &#2476;&#2480;&#2434; &#2447;&#2453;&#2463;&#2495; basic AI system setup &#2453;&#2480;&#2468;&#2503; &#2488;&#2453;&#2509;&#2487;&#2478; &#2489;&#2472;&#2404;</p><p></p><p></p><p></p><p></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Reliable Event Processing in Distributed Systems]]></title><description><![CDATA[Designing Kafka Producers and Consumers with Outbox, Retry Topics, and DLQ]]></description><link>https://rhidoyhasanmahmud.substack.com/p/reliable-event-processing-in-distributed</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/reliable-event-processing-in-distributed</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Tue, 10 Mar 2026 14:10:56 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/3f16df30-b9a2-4e87-a4c3-718fd172cf0b_2400x1256.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Modern microservice architecture-&#2447; <strong>event-driven communication</strong> &#2454;&#2497;&#2476; common &#2489;&#2527;&#2503; &#2455;&#2503;&#2459;&#2503;&#2404; Kafka, RabbitMQ, SQS &#2439;&#2468;&#2509;&#2479;&#2494;&#2470;&#2495; message broker &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; service &#2455;&#2497;&#2482;&#2507; asynchronous communication &#2453;&#2480;&#2503;&#2404;</p><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; &#2447;&#2454;&#2494;&#2472;&#2503; &#2447;&#2453;&#2463;&#2495; &#2476;&#2524; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494; &#2438;&#2459;&#2503;:</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><blockquote><p><strong>Message loss &#2447;&#2476;&#2434; failure handling</strong></p></blockquote><p>&#2479;&#2470;&#2495; message publish fail &#2453;&#2480;&#2503; &#2476;&#2494; consumer processing fail &#2453;&#2480;&#2503;, &#2468;&#2494;&#2489;&#2482;&#2503; system inconsistent &#2489;&#2527;&#2503; &#2479;&#2503;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>&#2447;&#2439; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494;&#2480; &#2488;&#2478;&#2494;&#2471;&#2494;&#2472;&#2503; production system-&#2447; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2468;&#2495;&#2472;&#2463;&#2495; pattern &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2489;&#2527;:</p><ul><li><p><strong>Transactional Outbox Pattern</strong></p></li><li><p><strong>Retry Pattern</strong></p></li><li><p><strong>Dead Letter Queue (DLQ)</strong></p></li></ul><p>&#2447;&#2439; blog-&#2447; &#2438;&#2478;&#2480;&#2494; &#2470;&#2503;&#2454;&#2476;&#2507; &#2453;&#2496;&#2477;&#2494;&#2476;&#2503; &#2447;&#2439; &#2468;&#2495;&#2472;&#2463;&#2495; &#2447;&#2453;&#2488;&#2494;&#2469;&#2503; &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; &#2447;&#2453;&#2463;&#2495; <strong>reliable event processing system</strong> design &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><h3><code>Problem: Database Update + Event Publish</code></h3><p>&#2471;&#2480;&#2507; &#2447;&#2453;&#2463;&#2495; Order Service &#2438;&#2459;&#2503;&#2404;</p><p>&#2479;&#2454;&#2472; &#2472;&#2468;&#2497;&#2472; order create &#2489;&#2527;:</p><ol><li><p>Database-&#2447; order save &#2453;&#2480;&#2494; &#2489;&#2527;</p></li><li><p>Kafka-&#2468;&#2503; <code>order-created</code> event publish &#2453;&#2480;&#2494; &#2489;&#2527;</p></li></ol><p>Simple implementation:</p><pre><code>orderRepository.save(order);
kafkaTemplate.send(&#8221;order-created&#8221;, event);</code></pre><p>&#2447;&#2454;&#2494;&#2472;&#2503; &#2447;&#2453;&#2463;&#2495; &#2476;&#2524; risk &#2438;&#2459;&#2503;&#2404;</p><p><strong>Possible scenarios:</strong></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!DwPz!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!DwPz!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 424w, https://substackcdn.com/image/fetch/$s_!DwPz!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 848w, https://substackcdn.com/image/fetch/$s_!DwPz!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 1272w, https://substackcdn.com/image/fetch/$s_!DwPz!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!DwPz!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png" width="568" height="328.35068493150686" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:422,&quot;width&quot;:730,&quot;resizeWidth&quot;:568,&quot;bytes&quot;:50675,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!DwPz!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 424w, https://substackcdn.com/image/fetch/$s_!DwPz!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 848w, https://substackcdn.com/image/fetch/$s_!DwPz!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 1272w, https://substackcdn.com/image/fetch/$s_!DwPz!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1875eab1-232c-4958-9e71-7b2ff9b3c233_730x422.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Example:</p><ul><li><p>Order database-&#2447; save &#2489;&#2527;&#2503;&#2459;&#2503;</p></li><li><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; event publish fail &#2453;&#2480;&#2503;&#2459;&#2503;</p></li></ul><p>&#2468;&#2494;&#2489;&#2482;&#2503; &#2437;&#2472;&#2509;&#2479; services (inventory, payment) order &#2488;&#2478;&#2509;&#2474;&#2480;&#2509;&#2453;&#2503; &#2460;&#2494;&#2472;&#2468;&#2503;&#2439; &#2474;&#2494;&#2480;&#2476;&#2503; &#2472;&#2494;&#2404; &#2447;&#2439; problem solve &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; <strong>Transactional Outbox Pattern</strong> &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><h3><code>Transactional Outbox Pattern &#2453;&#2496;?</code></h3><p>Outbox pattern-&#2447;&#2480; &#2478;&#2498;&#2482; &#2471;&#2494;&#2480;&#2467;&#2494; &#2489;&#2482;&#2507;:</p><blockquote><p>Kafka-&#2468;&#2503; &#2488;&#2480;&#2494;&#2488;&#2480;&#2495; event publish &#2472;&#2494; &#2453;&#2480;&#2503;, event &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; database-&#2447;&#2480; &#2447;&#2453;&#2463;&#2495; <strong>outbox table</strong>-&#2447; store &#2453;&#2480;&#2494; &#2489;&#2476;&#2503;&#2404;</p></blockquote><p>&#2468;&#2494;&#2480;&#2474;&#2480; &#2447;&#2453;&#2463;&#2495; background process &#2488;&#2503;&#2439; event Kafka-&#2468;&#2503; publish &#2453;&#2480;&#2476;&#2503;&#2404;</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!JdmO!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!JdmO!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 424w, https://substackcdn.com/image/fetch/$s_!JdmO!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 848w, https://substackcdn.com/image/fetch/$s_!JdmO!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 1272w, https://substackcdn.com/image/fetch/$s_!JdmO!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!JdmO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png" width="975" height="211" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/79990f12-48c1-453b-854f-695c4ed728dd_975x211.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:211,&quot;width&quot;:975,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:37694,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!JdmO!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 424w, https://substackcdn.com/image/fetch/$s_!JdmO!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 848w, https://substackcdn.com/image/fetch/$s_!JdmO!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 1272w, https://substackcdn.com/image/fetch/$s_!JdmO!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F79990f12-48c1-453b-854f-695c4ed728dd_975x211.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><h3><code>Outbox Pattern Flow</code></h3><h4><code>Step 1: Business Transaction</code></h4><p>Order create &#2453;&#2480;&#2494;&#2480; &#2488;&#2478;&#2527; database transaction-&#2447;&#2480; &#2478;&#2471;&#2509;&#2479;&#2503; &#2470;&#2497;&#2463;&#2495; &#2453;&#2494;&#2460; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><pre><code>Save Order
Insert Outbox Event
Commit Transaction</code></pre><p>Example Outbox Table:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">| id | event_type    | payload | status  |
| -- | ------------- | ------- | ------- |
| 1  | ORDER_CREATED | {...}   | PENDING |</code></pre></div><h4><code>Step 2: Outbox Publisher</code></h4><p>&#2447;&#2453;&#2463;&#2495; background worker outbox table &#2469;&#2503;&#2453;&#2503; event &#2474;&#2524;&#2503; Kafka-&#2468;&#2503; publish &#2453;&#2480;&#2503;&#2404;</p><p><strong>Flow:</strong></p><pre><code>Outbox Table
     &#8595;
Outbox Publisher
     &#8595;
Kafka Topic</code></pre><p><strong>Example pseudo code:</strong></p><pre><code>List&lt;OutboxEvent&gt; events = repository.findPending();

for (OutboxEvent e : events) {
    kafkaTemplate.send(e.getTopic(), e.getPayload());
}</code></pre><p>Kafka publish success &#2489;&#2482;&#2503; status update &#2453;&#2480;&#2494; &#2489;&#2527;:</p><pre><code>PENDING &#8594; SENT</code></pre><h4><code>Kafka Down &#2489;&#2482;&#2503; &#2453;&#2496; &#2489;&#2476;&#2503;?</code></h4><p>Kafka unavailable &#2469;&#2494;&#2453;&#2482;&#2503; publisher retry &#2453;&#2480;&#2476;&#2503;&#2404;</p><pre><code>Outbox Event &#8594; PENDING
Publisher Retry &#8594; Kafka publish later</code></pre><p>&#2447;&#2468;&#2503; message loss &#2489;&#2476;&#2503; &#2472;&#2494;&#2404;</p><h3><code>Consumer Failure Handling</code></h3><p>Producer successfully Kafka-&#2468;&#2503; message publish &#2453;&#2480;&#2494;&#2480; &#2474;&#2480; message processing-&#2447;&#2480; &#2470;&#2494;&#2527;&#2495;&#2468;&#2509;&#2476; &#2469;&#2494;&#2453;&#2503; <strong>consumer service-&#2447;&#2480; &#2441;&#2474;&#2480;</strong>&#2404; &#2453;&#2495;&#2472;&#2509;&#2468;&#2497; distributed system-&#2447; message processing &#2488;&#2476;&#2488;&#2478;&#2527; &#2488;&#2475;&#2482; &#2472;&#2494;&#2451; &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>Consumer side-&#2447; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2468;&#2495;&#2472; &#2471;&#2480;&#2472;&#2503;&#2480; situation &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527;:</p><ol><li><p>Temporary failure</p></li><li><p>Permanent failure</p></li><li><p>Poison message</p></li></ol><p>&#2447;&#2439; &#2468;&#2495;&#2472;&#2463;&#2495; case handle &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; production system-&#2447; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; <strong>Retry Topics &#2447;&#2476;&#2434; Dead Letter Queue (DLQ)</strong> &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><h5><code>1. Temporary Failure (Retry Required)</code></h5><p>&#2453;&#2495;&#2459;&#2497; error temporary &#2489;&#2527; &#2447;&#2476;&#2434; &#2453;&#2495;&#2459;&#2497; &#2488;&#2478;&#2527; &#2474;&#2480;&#2503; retry &#2453;&#2480;&#2482;&#2503; success &#2489;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404;</p><p>Example:</p><ul><li><p>Database temporarily unavailable</p></li><li><p>External API timeout</p></li><li><p>Network issue</p></li><li><p>Redis connection issue</p></li></ul><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; error &#2489;&#2482;&#2503; message <strong>retry topic</strong>-&#2447; publish &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><p>Example Kafka topics:</p><pre><code>order-created
order-created.retry.1
order-created.retry.2
order-created.retry.3</code></pre><p>Processing flow:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!21VU!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!21VU!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 424w, https://substackcdn.com/image/fetch/$s_!21VU!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 848w, https://substackcdn.com/image/fetch/$s_!21VU!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 1272w, https://substackcdn.com/image/fetch/$s_!21VU!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!21VU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png" width="376" height="766" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:766,&quot;width&quot;:376,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:46105,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!21VU!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 424w, https://substackcdn.com/image/fetch/$s_!21VU!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 848w, https://substackcdn.com/image/fetch/$s_!21VU!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 1272w, https://substackcdn.com/image/fetch/$s_!21VU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e2a0fb2-56b1-488e-b537-536ca06b84ae_376x766.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>&#2447;&#2468;&#2503; system automatically retry &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2447;&#2476;&#2434; temporary failure recover &#2489;&#2527;&#2404;</p><h5>2. Permanent Failure (Direct DLQ)</h5><p>&#2453;&#2495;&#2459;&#2497; error retry &#2453;&#2480;&#2482;&#2503;&#2451; success &#2489;&#2476;&#2503; &#2472;&#2494;&#2404; &#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; error &#2453;&#2503; <strong>non-retryable error</strong> &#2476;&#2482;&#2494; &#2489;&#2527;&#2404;</p><p>Example:</p><ul><li><p>Invalid payload format</p></li><li><p>JSON parsing error</p></li><li><p>Required field missing</p></li><li><p>Business validation failure</p></li></ul><p>&#2447;&#2439; &#2471;&#2480;&#2472;&#2503;&#2480; message retry &#2472;&#2494; &#2453;&#2480;&#2503; &#2488;&#2480;&#2494;&#2488;&#2480;&#2495; <strong>DLQ topic</strong>-&#2447; &#2474;&#2494;&#2464;&#2494;&#2472;&#2507; &#2489;&#2527;&#2404;</p><p>Example:</p><pre><code>order-created.dlq</code></pre><p>Flow:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!cm_6!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!cm_6!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 424w, https://substackcdn.com/image/fetch/$s_!cm_6!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 848w, https://substackcdn.com/image/fetch/$s_!cm_6!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 1272w, https://substackcdn.com/image/fetch/$s_!cm_6!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!cm_6!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png" width="340" height="686" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/c9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:686,&quot;width&quot;:340,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:43694,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!cm_6!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 424w, https://substackcdn.com/image/fetch/$s_!cm_6!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 848w, https://substackcdn.com/image/fetch/$s_!cm_6!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 1272w, https://substackcdn.com/image/fetch/$s_!cm_6!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fc9ad4f6e-d9bc-4450-ab54-d9b9b1a92f55_340x686.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>DLQ-&#2468;&#2503; &#2469;&#2494;&#2453;&#2494; message &#2474;&#2480;&#2503; investigation &#2476;&#2494; replay &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><h5>3. Poison Message Problem</h5><p>&#2453;&#2495;&#2459;&#2497; message &#2476;&#2494;&#2480;&#2476;&#2494;&#2480; fail &#2453;&#2480;&#2503; &#2447;&#2476;&#2434; &#2447;&#2453;&#2439; partition block &#2453;&#2480;&#2503; &#2480;&#2494;&#2454;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503;&#2404; &#2447;&#2453;&#2503; <strong>poison message</strong> &#2476;&#2482;&#2494; &#2489;&#2527;&#2404;</p><p>Example:</p><ul><li><p>Invalid schema message</p></li><li><p>Corrupted data</p></li><li><p>Unexpected payload structure</p></li></ul><p>Retry limit exceed &#2453;&#2480;&#2482;&#2503; message automatically DLQ-&#2468;&#2503; move &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><p><strong>Example flow:</strong></p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!tDQ_!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!tDQ_!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 424w, https://substackcdn.com/image/fetch/$s_!tDQ_!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 848w, https://substackcdn.com/image/fetch/$s_!tDQ_!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 1272w, https://substackcdn.com/image/fetch/$s_!tDQ_!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!tDQ_!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png" width="520" height="538" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:538,&quot;width&quot;:520,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:36696,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!tDQ_!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 424w, https://substackcdn.com/image/fetch/$s_!tDQ_!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 848w, https://substackcdn.com/image/fetch/$s_!tDQ_!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 1272w, https://substackcdn.com/image/fetch/$s_!tDQ_!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F55be9cee-a10e-49ce-936e-8f9d0c6c706c_520x538.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>&#2447;&#2468;&#2503; poison message system block &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2503; &#2472;&#2494;&#2404;</p><h4><code>Complete Consumer Failure Flow</code></h4><p>Production system-&#2447; consumer failure handling &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2447;&#2478;&#2472; &#2489;&#2527;:</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!6-Qt!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!6-Qt!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 424w, https://substackcdn.com/image/fetch/$s_!6-Qt!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 848w, https://substackcdn.com/image/fetch/$s_!6-Qt!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 1272w, https://substackcdn.com/image/fetch/$s_!6-Qt!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!6-Qt!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png" width="840" height="78" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:78,&quot;width&quot;:840,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:12582,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!6-Qt!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 424w, https://substackcdn.com/image/fetch/$s_!6-Qt!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 848w, https://substackcdn.com/image/fetch/$s_!6-Qt!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 1272w, https://substackcdn.com/image/fetch/$s_!6-Qt!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F0cf0b389-d63c-4898-8b31-9ee15d498494_840x78.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>Retry topic temporary failure recover &#2453;&#2480;&#2494;&#2480; &#2488;&#2497;&#2479;&#2507;&#2455; &#2470;&#2503;&#2527; &#2447;&#2476;&#2434; DLQ permanent failure isolate &#2453;&#2480;&#2503;&#2404;</p><h4><code>DLQ Message Management</code></h4><p>DLQ-&#2468;&#2503; &#2469;&#2494;&#2453;&#2494; message discard &#2453;&#2480;&#2494; &#2489;&#2527; &#2472;&#2494;&#2404; &#2447;&#2455;&#2497;&#2482;&#2507; &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468;:</p><ul><li><p>investigation &#2453;&#2480;&#2494; &#2489;&#2527;</p></li><li><p>dashboard-&#2447; monitor &#2453;&#2480;&#2494; &#2489;&#2527;</p></li><li><p>manual replay &#2453;&#2480;&#2494; &#2489;&#2527;</p></li></ul><p>Example replay flow:</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!GRSb!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!GRSb!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 424w, https://substackcdn.com/image/fetch/$s_!GRSb!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 848w, https://substackcdn.com/image/fetch/$s_!GRSb!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 1272w, https://substackcdn.com/image/fetch/$s_!GRSb!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!GRSb!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png" width="471" height="81" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:81,&quot;width&quot;:471,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:12179,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!GRSb!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 424w, https://substackcdn.com/image/fetch/$s_!GRSb!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 848w, https://substackcdn.com/image/fetch/$s_!GRSb!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 1272w, https://substackcdn.com/image/fetch/$s_!GRSb!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb0be7ab4-bb3f-4d8f-8e1e-b613869a168c_471x81.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>Root cause fix &#2453;&#2480;&#2494;&#2480; &#2474;&#2480; message &#2474;&#2497;&#2472;&#2480;&#2494;&#2527; process &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;&#2404;</p><h5>DLQ Key Benefits</h5><p>Consumer side-&#2447; retry &#2447;&#2476;&#2434; DLQ &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2482;&#2503;:</p><ul><li><p>message loss prevent &#2489;&#2527;</p></li><li><p>poison message isolate &#2453;&#2480;&#2494; &#2479;&#2494;&#2527;</p></li><li><p>system stable &#2469;&#2494;&#2453;&#2503;</p></li><li><p>debugging &#2488;&#2489;&#2460; &#2489;&#2527;</p></li></ul><div><hr></div><p>Consumer failure handling strategy &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2447;&#2439;&#2477;&#2494;&#2476;&#2503; implement &#2453;&#2480;&#2494; &#2489;&#2527;:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!-uHe!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!-uHe!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 424w, https://substackcdn.com/image/fetch/$s_!-uHe!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 848w, https://substackcdn.com/image/fetch/$s_!-uHe!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 1272w, https://substackcdn.com/image/fetch/$s_!-uHe!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!-uHe!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png" width="398" height="556" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:556,&quot;width&quot;:398,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:46231,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190500037?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!-uHe!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 424w, https://substackcdn.com/image/fetch/$s_!-uHe!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 848w, https://substackcdn.com/image/fetch/$s_!-uHe!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 1272w, https://substackcdn.com/image/fetch/$s_!-uHe!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F95d77e5b-ac56-40a0-afdb-87eb859ebe72_398x556.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>&#2447;&#2439; architecture &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2482;&#2503; event-driven system &#2437;&#2472;&#2503;&#2453; &#2476;&#2503;&#2486;&#2495; <strong>resilient &#2447;&#2476;&#2434; reliable</strong> &#2489;&#2527;&#2404;</p><h4>Reference</h4><ol><li><p><a href="https://newsletter.systemdesignclassroom.com/p/dead-letter-queues-are-not-your-safety-net">Dead Letter Queues Are Not Your Safety Net</a></p></li><li><p><a href="https://ctaverna.github.io/dead-letters/">Design for failure by using Dead Letter Queues (DLQ)</a></p></li><li><p><a href="https://aws.amazon.com/what-is/dead-letter-queue/">What is a Dead-Letter Queue (DLQ)?</a></p></li><li><p><a href="https://medium.com/@danthelion/dead-letter-queues-what-they-are-and-when-to-use-them-252c33fb4ced">Dead Letter Queues: What They Are and When to Use Them</a></p></li><li><p><a href="https://www.linkedin.com/pulse/mastering-dead-letter-queues-dlq-system-design-patterns-munish-gupta-5iqmc/">Mastering Dead Letter Queues (DLQ) in System Design: Patterns, Trade-offs, and Why Kafka Shines for Event Streaming</a></p></li></ol><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Top 5 Caching Strategies Every Backend Engineer Should Know: Performance & Scalability Guide]]></title><description><![CDATA[Modern backend systems-&#2447; performance, scalability &#2447;&#2476;&#2434; reliability &#2476;&#2460;&#2494;&#2527; &#2480;&#2494;&#2454;&#2468;&#2503; Caching &#2447;&#2453;&#2463;&#2495; fundamental technique]]></description><link>https://rhidoyhasanmahmud.substack.com/p/top-5-caching-strategies-every-backend</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/top-5-caching-strategies-every-backend</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Mon, 09 Mar 2026 13:12:55 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/07fae7ea-6583-4a29-a1a1-9b91cb2798ec_800x448.webp" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>&#2479;&#2454;&#2472; &#2447;&#2453;&#2463;&#2495; application-&#2447; &#2489;&#2494;&#2460;&#2494;&#2480; &#2476;&#2494; &#2482;&#2494;&#2454; user request &#2438;&#2488;&#2503;, &#2468;&#2454;&#2472; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; request &#2479;&#2470;&#2495; &#2488;&#2480;&#2494;&#2488;&#2480;&#2495; database-&#2447; &#2479;&#2494;&#2527;, &#2468;&#2494;&#2489;&#2482;&#2503; &#2453;&#2527;&#2503;&#2453;&#2463;&#2495; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494; &#2489;&#2527;:</p><ul><li><p>Database bottleneck &#2468;&#2504;&#2480;&#2495; &#2489;&#2527;</p></li><li><p>Query latency &#2476;&#2503;&#2524;&#2503; &#2479;&#2494;&#2527;</p></li><li><p>Infrastructure cost &#2476;&#2494;&#2524;&#2503;</p></li><li><p>System scalability &#2453;&#2478;&#2503; &#2479;&#2494;&#2527;</p></li></ul><p>&#2447;&#2439; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494; &#2488;&#2478;&#2494;&#2471;&#2494;&#2472;&#2503;&#2480; &#2460;&#2472;&#2509;&#2479;&#2439; <strong>Caching layer</strong> &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2489;&#2527;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>Caching &#2478;&#2498;&#2482;&#2468; <strong>frequently accessed data memory-based storage (&#2479;&#2503;&#2478;&#2472; Redis, Memcached)-&#2447; &#2480;&#2494;&#2454;&#2494;</strong>, &#2479;&#2494;&#2468;&#2503; database query &#2453;&#2478; &#2489;&#2527; &#2447;&#2476;&#2434; response time &#2470;&#2509;&#2480;&#2497;&#2468; &#2489;&#2527;&#2404;</p><p>&#2468;&#2476;&#2503; caching &#2486;&#2497;&#2471;&#2497; data store &#2453;&#2480;&#2494;&#2439; &#2472;&#2494; - <strong>data synchronization, consistency, invalidation &#2447;&#2476;&#2434; write behaviour</strong> &#2472;&#2495;&#2527;&#2503;&#2451; &#2437;&#2472;&#2503;&#2453; architecture decision &#2469;&#2494;&#2453;&#2503;&#2404;</p><p>&#2447;&#2439; &#2476;&#2509;&#2482;&#2455;&#2503; &#2438;&#2478;&#2480;&#2494; <strong>&#2539;&#2463;&#2495; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467; caching strategy</strong> &#2476;&#2495;&#2488;&#2509;&#2468;&#2494;&#2480;&#2495;&#2468;&#2477;&#2494;&#2476;&#2503; &#2438;&#2482;&#2507;&#2458;&#2472;&#2494; &#2453;&#2480;&#2476;&#2507;&#2404;</p><h3>1. Read Through Caching</h3><p>Read Through caching-&#2447; application &#2488;&#2480;&#2494;&#2488;&#2480;&#2495; database access &#2453;&#2480;&#2503; &#2472;&#2494;&#2404; Application &#2488;&#2476;&#2488;&#2478;&#2527; cache layer-&#2447;&#2480; &#2478;&#2494;&#2471;&#2509;&#2479;&#2478;&#2503; data request &#2453;&#2480;&#2503;&#2404;</p><p>&#2479;&#2470;&#2495; cache-&#2447; data &#2469;&#2494;&#2453;&#2503; &#8594; cache return &#2453;&#2480;&#2476;&#2503;<br>&#2479;&#2470;&#2495; cache miss &#2489;&#2527; &#8594; cache &#2472;&#2495;&#2460;&#2503;&#2439; database &#2469;&#2503;&#2453;&#2503; data fetch &#2453;&#2480;&#2503; &#2447;&#2476;&#2434; cache-&#2447; store &#2453;&#2480;&#2503;&#2404;</p><h5><code>Architecture Flow</code></h5><pre><code>Application
     &#8595;
   Cache
     &#8595;
 Database</code></pre><h5><code>Step-by-step Flow</code></h5><ul><li><p>Client request &#2438;&#2488;&#2503;</p></li><li><p>Application cache-&#2447; request &#2453;&#2480;&#2503;</p></li><li><p>Cache miss &#2489;&#2482;&#2503; cache DB query &#2453;&#2480;&#2503;</p></li><li><p>DB data cache-&#2447; store &#2489;&#2527;</p></li><li><p>Response application-&#2447; &#2475;&#2495;&#2480;&#2503; &#2479;&#2494;&#2527;</p></li></ul><h5>Read Through Caching-&#2447;&#2480; &#2488;&#2497;&#2476;&#2495;&#2471;&#2494; &#2447;&#2476;&#2434; &#2437;&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</h5><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Dyju!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Dyju!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 424w, https://substackcdn.com/image/fetch/$s_!Dyju!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 848w, https://substackcdn.com/image/fetch/$s_!Dyju!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 1272w, https://substackcdn.com/image/fetch/$s_!Dyju!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Dyju!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png" width="1416" height="998" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:998,&quot;width&quot;:1416,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:212152,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190383218?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Dyju!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 424w, https://substackcdn.com/image/fetch/$s_!Dyju!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 848w, https://substackcdn.com/image/fetch/$s_!Dyju!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 1272w, https://substackcdn.com/image/fetch/$s_!Dyju!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2ef4b8d9-c690-41ab-b37e-04c535ee889f_1416x998.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h5><code>Use Cases</code></h5><ul><li><p>CDN systems</p></li><li><p>Content delivery platforms</p></li><li><p>Social media feeds</p></li><li><p>Product catalog systems</p></li></ul><h5><code>Example</code></h5><p>&#2471;&#2480;&#2497;&#2472; &#2447;&#2453;&#2463;&#2495; <strong>news website</strong>&#2404; &#2447;&#2453;&#2463;&#2495; article &#2489;&#2494;&#2460;&#2494;&#2480; user &#2474;&#2524;&#2459;&#2503;&#2404;</p><p>&#2474;&#2509;&#2480;&#2469;&#2478; request &#8594; DB<br>&#2474;&#2480;&#2476;&#2480;&#2509;&#2468;&#2496; request &#8594; cache</p><p>&#2447;&#2468;&#2503; database load dramatically &#2453;&#2478;&#2503;&#2404;</p><div><hr></div><h1>2. Write Through Caching</h1><p>Write Through strategy-&#2468;&#2503; &#2479;&#2454;&#2472; application data write &#2453;&#2480;&#2503;, &#2468;&#2454;&#2472; <strong>cache &#2447;&#2476;&#2434; database &#2447;&#2453;&#2439; &#2488;&#2494;&#2469;&#2503; update &#2489;&#2527;</strong>&#2404;</p><p>&#2437;&#2480;&#2509;&#2469;&#2494;&#2510; write operation cache-&#2447;&#2480; &#2478;&#2494;&#2471;&#2509;&#2479;&#2478;&#2503; database-&#2447; &#2479;&#2494;&#2527;&#2404;</p><h5><code>Architecture Flow</code></h5><pre><code>Application
     &#8595;
   Cache
     &#8595;
 Database</code></pre><h5>Step-by-step Flow</h5><ol><li><p>Application write request &#2474;&#2494;&#2464;&#2494;&#2527;</p></li><li><p>Cache update &#2489;&#2527;</p></li><li><p>Cache database update &#2453;&#2480;&#2503;</p></li><li><p>Operation complete</p></li></ol><h5>Write Through Caching-&#2447;&#2480; &#2488;&#2497;&#2476;&#2495;&#2471;&#2494; &#2447;&#2476;&#2434; &#2437;&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</h5><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!zJsU!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!zJsU!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 424w, https://substackcdn.com/image/fetch/$s_!zJsU!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 848w, https://substackcdn.com/image/fetch/$s_!zJsU!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 1272w, https://substackcdn.com/image/fetch/$s_!zJsU!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!zJsU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png" width="1398" height="948" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:948,&quot;width&quot;:1398,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:196960,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190383218?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!zJsU!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 424w, https://substackcdn.com/image/fetch/$s_!zJsU!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 848w, https://substackcdn.com/image/fetch/$s_!zJsU!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 1272w, https://substackcdn.com/image/fetch/$s_!zJsU!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F8c3b61de-ca85-4a02-9937-e4379e23c911_1398x948.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h5>Use Cases</h5><ul><li><p>Banking systems</p></li><li><p>Payment processing systems</p></li><li><p>Inventory systems</p></li><li><p>Financial applications</p></li></ul><h5><code>Example</code></h5><p>&#2447;&#2453;&#2463;&#2495; <strong>bank account system</strong>&#2404;</p><p>User balance update &#2453;&#2480;&#2482;&#2503;:</p><pre><code>Update balance
     &#8595;
Cache update
     &#8595;
Database update</code></pre><p>&#2447;&#2468;&#2503; cache-&#2447; &#2453;&#2454;&#2472;&#2451; outdated balance &#2469;&#2494;&#2453;&#2503; &#2472;&#2494;&#2404;</p><div><hr></div><h1>3. Cache Aside (Lazy Loading)</h1><p>Cache Aside caching &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; widely used pattern&#2404;</p><p>&#2447;&#2454;&#2494;&#2472;&#2503; application &#2472;&#2495;&#2460;&#2503;&#2439; cache management control &#2453;&#2480;&#2503;&#2404;</p><h5><code>Architecture Flow</code></h5><pre><code>Application
 &#8595;        &#8593;
Cache    Database</code></pre><h5>Step-by-step Flow</h5><ol><li><p>Application cache check &#2453;&#2480;&#2503;</p></li><li><p>Cache hit &#2489;&#2482;&#2503; &#8594; cache data return</p></li><li><p>Cache miss &#2489;&#2482;&#2503; &#8594; DB query</p></li><li><p>Data cache-&#2447; store &#2489;&#2527;</p></li></ol><h5>Example Flow</h5><pre><code>GET /users/101</code></pre><h5>Steps:</h5><ol><li><p>Redis cache check</p></li><li><p>Cache miss</p></li><li><p>Database query</p></li><li><p>Cache update</p></li><li><p>Response return</p></li></ol><h5>Cache Aside-&#2447;&#2480; &#2488;&#2497;&#2476;&#2495;&#2471;&#2494; &#2447;&#2476;&#2434; &#2437;&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</h5><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!dOmg!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!dOmg!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 424w, https://substackcdn.com/image/fetch/$s_!dOmg!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 848w, https://substackcdn.com/image/fetch/$s_!dOmg!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 1272w, https://substackcdn.com/image/fetch/$s_!dOmg!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!dOmg!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png" width="1404" height="936" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:936,&quot;width&quot;:1404,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:197763,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190383218?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!dOmg!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 424w, https://substackcdn.com/image/fetch/$s_!dOmg!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 848w, https://substackcdn.com/image/fetch/$s_!dOmg!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 1272w, https://substackcdn.com/image/fetch/$s_!dOmg!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F09855aa3-fd07-43af-9425-67630ba83f97_1404x936.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h5>Use Cases</h5><ul><li><p>Microservices architecture</p></li><li><p>API caching</p></li><li><p>Product service</p></li><li><p>User profile service</p></li></ul><div><hr></div><h1>4. Write Around Caching</h1><p>Write Around strategy-&#2468;&#2503; write operation <strong>cache bypass &#2453;&#2480;&#2503; &#2488;&#2480;&#2494;&#2488;&#2480;&#2495; database-&#2447; &#2479;&#2494;&#2527;</strong>&#2404;</p><p>Cache update &#2489;&#2527; &#2472;&#2494;&#2404;</p><p>Cache populate &#2489;&#2527; &#2486;&#2497;&#2471;&#2497;&#2478;&#2494;&#2468;&#2509;&#2480; read request &#2489;&#2482;&#2503;&#2404;</p><h5><code>Architecture Flow</code></h5><p>Write:</p><pre><code>Application &#8594; Database</code></pre><p>Read:</p><pre><code>Application &#8594; Cache &#8594; Database</code></pre><h5>Write Around Caching -&#2447;&#2480; &#2488;&#2497;&#2476;&#2495;&#2471;&#2494; &#2447;&#2476;&#2434; &#2437;&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</h5><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Qd7t!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Qd7t!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 424w, https://substackcdn.com/image/fetch/$s_!Qd7t!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 848w, https://substackcdn.com/image/fetch/$s_!Qd7t!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 1272w, https://substackcdn.com/image/fetch/$s_!Qd7t!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Qd7t!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png" width="1390" height="1020" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:1020,&quot;width&quot;:1390,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:345227,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190383218?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Qd7t!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 424w, https://substackcdn.com/image/fetch/$s_!Qd7t!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 848w, https://substackcdn.com/image/fetch/$s_!Qd7t!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 1272w, https://substackcdn.com/image/fetch/$s_!Qd7t!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F9ed14374-4ea2-447c-a0f1-6f3d0a972f16_1390x1020.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h5><code>Use Cases</code></h5><ul><li><p>Logging systems</p></li><li><p>Analytics pipelines</p></li><li><p>Big data ingestion systems</p></li></ul><h5>Example</h5><p>&#2447;&#2453;&#2463;&#2495; <strong>log processing system</strong>&#2404;</p><p>&#2474;&#2509;&#2480;&#2468;&#2495; &#2488;&#2503;&#2453;&#2503;&#2472;&#2509;&#2465;&#2503; &#2482;&#2494;&#2454; &#2482;&#2494;&#2454; log write &#2489;&#2458;&#2509;&#2459;&#2503;&#2404;</p><p>&#2479;&#2470;&#2495; &#2488;&#2476; cache-&#2447; &#2480;&#2494;&#2454;&#2495; &#8594; memory waste &#2489;&#2476;&#2503;&#2404;</p><p>&#2468;&#2494;&#2439;:</p><pre><code>Write &#8594; DB
Read &#8594; Cache</code></pre><div><hr></div><h1>5. Write Back (Write Behind)</h1><p>Write Back caching-&#2447; write operation &#2474;&#2509;&#2480;&#2469;&#2478;&#2503; cache-&#2447; &#2489;&#2527; &#2447;&#2476;&#2434; &#2474;&#2480;&#2503; asynchronously database-&#2447; persist &#2489;&#2527;&#2404;</p><h5><code>Architecture Flow</code></h5><pre><code>Application
     &#8595;
   Cache
     &#8595;
Async Write
     &#8595;
 Database</code></pre><h5><code>Step-by-step Flow</code></h5><ol><li><p>Application write request &#2474;&#2494;&#2464;&#2494;&#2527;</p></li><li><p>Cache update &#2489;&#2527;</p></li><li><p>Background worker DB update &#2453;&#2480;&#2503;</p></li></ol><h5>Write Back-&#2447;&#2480; &#2488;&#2497;&#2476;&#2495;&#2471;&#2494; &#2447;&#2476;&#2434; &#2437;&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</h5><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!yoqc!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!yoqc!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 424w, https://substackcdn.com/image/fetch/$s_!yoqc!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 848w, https://substackcdn.com/image/fetch/$s_!yoqc!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 1272w, https://substackcdn.com/image/fetch/$s_!yoqc!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!yoqc!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png" width="1396" height="956" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:956,&quot;width&quot;:1396,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:306918,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190383218?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!yoqc!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 424w, https://substackcdn.com/image/fetch/$s_!yoqc!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 848w, https://substackcdn.com/image/fetch/$s_!yoqc!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 1272w, https://substackcdn.com/image/fetch/$s_!yoqc!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F78bc7ba3-7675-41c9-8a52-4b39deb8919e_1396x956.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h5><code>&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</code></h5><ul><li><p>Very low write latency</p></li><li><p>High throughput</p></li><li><p>Database load &#2453;&#2478;</p></li></ul><h5><code>&#2437;&#2488;&#2497;&#2476;&#2495;&#2471;&#2494;</code></h5><ul><li><p>Crash &#2489;&#2482;&#2503; data loss risk</p></li><li><p>Complex implementation</p></li></ul><h5><code>Use Cases</code></h5><ul><li><p>Gaming platforms</p></li><li><p>Real-time analytics</p></li><li><p>High-throughput systems</p></li></ul><h5><code>Example</code></h5><p>&#2447;&#2453;&#2463;&#2495; <strong>gaming leaderboard system</strong>&#2404;</p><p>Player score update:</p><pre><code>Player score &#8594; Cache
Background worker &#8594; DB</code></pre><p>&#2447;&#2468;&#2503; game performance fast &#2469;&#2494;&#2453;&#2503;&#2404;</p><div><hr></div><h1>Strategy Comparison</h1><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Pzf9!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Pzf9!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 424w, https://substackcdn.com/image/fetch/$s_!Pzf9!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 848w, https://substackcdn.com/image/fetch/$s_!Pzf9!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 1272w, https://substackcdn.com/image/fetch/$s_!Pzf9!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Pzf9!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png" width="1456" height="399" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/43523763-0475-475d-8535-047129f4cf6b_1460x400.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:399,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:94095,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/190383218?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Pzf9!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 424w, https://substackcdn.com/image/fetch/$s_!Pzf9!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 848w, https://substackcdn.com/image/fetch/$s_!Pzf9!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 1272w, https://substackcdn.com/image/fetch/$s_!Pzf9!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F43523763-0475-475d-8535-047129f4cf6b_1460x400.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><strong>Caching strategy &#2472;&#2495;&#2480;&#2509;&#2476;&#2494;&#2458;&#2472; &#2453;&#2480;&#2494;&#2480; &#2488;&#2478;&#2527; &#2453;&#2527;&#2503;&#2453;&#2463;&#2495; &#2476;&#2495;&#2487;&#2527; &#2455;&#2497;&#2480;&#2497;&#2468;&#2509;&#2476;&#2474;&#2498;&#2480;&#2509;&#2467;:</strong></p><ol><li><p>System read heavy &#2472;&#2494;&#2453;&#2495; write heavy</p></li><li><p>Data consistency requirement</p></li><li><p>System latency requirement</p></li><li><p>Infrastructure capability</p></li></ol><p><strong>&#2488;&#2464;&#2495;&#2453; caching architecture &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2482;&#2503;:</strong></p><ul><li><p>Database load 80&#8211;90% &#2474;&#2480;&#2509;&#2479;&#2472;&#2509;&#2468; &#2453;&#2478;&#2494;&#2472;&#2507; &#2479;&#2494;&#2527;</p></li><li><p>Response time dramatically improve &#2489;&#2527;</p></li><li><p>System scalability &#2476;&#2499;&#2470;&#2509;&#2471;&#2495; &#2474;&#2494;&#2527;</p></li></ul><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Spring Cloud Config দিয়ে Microservice Configuration Centralize করা - Auto Refresh সহ Complete Guide]]></title><description><![CDATA[Centralized configuration, runtime refresh &#2447;&#2476;&#2434; production-ready architecture implement &#2453;&#2480;&#2494;&#2480; practical guide]]></description><link>https://rhidoyhasanmahmud.substack.com/p/spring-cloud-config-microservice</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/spring-cloud-config-microservice</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sat, 07 Mar 2026 15:14:38 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/7c1b7824-bd31-4879-ba1b-3f11b98245c8_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Microservice architecture &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2482;&#2503; &#2488;&#2476;&#2458;&#2503;&#2527;&#2503; &#2476;&#2524; operational challenge &#2455;&#2497;&#2482;&#2507;&#2480; &#2447;&#2453;&#2463;&#2495; &#2489;&#2482;&#2507; <strong>configuration management</strong>&#2404;</p><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2474;&#2472;&#2494;&#2480; system &#2447; &#2453;&#2527;&#2503;&#2453;&#2463;&#2495; service &#2438;&#2459;&#2503;:</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><pre><code>product-service
order-service
payment-service</code></pre><p>&#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; service &#2479;&#2470;&#2495; &#2472;&#2495;&#2460;&#2503;&#2480; <code>application.yml</code> maintain &#2453;&#2480;&#2503;, &#2468;&#2494;&#2489;&#2482;&#2503; configuration management &#2454;&#2497;&#2476; &#2470;&#2509;&#2480;&#2497;&#2468; complex &#2489;&#2527;&#2503; &#2479;&#2494;&#2527;&#2404;</p><p>&#2441;&#2470;&#2494;&#2489;&#2480;&#2467;:</p><pre><code>product-service/application.yml
order-service/application.yml
payment-service/application.yml</code></pre><p>&#2447;&#2454;&#2494;&#2472;&#2503; &#2453;&#2527;&#2503;&#2453;&#2463;&#2495; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494; &#2470;&#2503;&#2454;&#2494; &#2479;&#2494;&#2527;:</p><ul><li><p>configuration duplication</p></li><li><p>environment management &#2453;&#2464;&#2495;&#2472;</p></li><li><p>production configuration maintain &#2453;&#2480;&#2494; &#2461;&#2494;&#2478;&#2503;&#2482;&#2494;&#2474;&#2498;&#2480;&#2509;&#2467;</p></li><li><p>config change &#2453;&#2480;&#2482;&#2503; service restart &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;</p></li></ul><p>&#2447;&#2439; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494;&#2455;&#2497;&#2482;&#2507;&#2480; elegant solution &#2489;&#2482;&#2507; <strong>Spring Cloud Config</strong>&#2404;</p><h3>Microservice Architecture &#2447; Configuration Problem</h3><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2474;&#2472;&#2494;&#2480; &#2535;&#2534;&#2463;&#2495; microservice &#2438;&#2459;&#2503;&#2404;</p><p>&#2447;&#2453;&#2463;&#2495; common configuration &#2438;&#2459;&#2503;:</p><pre><code>database connection
api timeout
feature flags
external service URL</code></pre><p>&#2479;&#2470;&#2495; &#2474;&#2509;&#2480;&#2468;&#2495;&#2463;&#2495; service &#2447; manually update &#2453;&#2480;&#2468;&#2503; &#2489;&#2527;, &#2468;&#2494;&#2489;&#2482;&#2503;:</p><ul><li><p>deployment overhead &#2476;&#2494;&#2524;&#2503;</p></li><li><p>configuration mismatch &#2489;&#2527;</p></li><li><p>production incidents &#2489;&#2451;&#2527;&#2494;&#2480; &#2488;&#2478;&#2509;&#2477;&#2494;&#2476;&#2472;&#2494; &#2476;&#2494;&#2524;&#2503;</p></li></ul><p>&#2447;&#2439; &#2460;&#2494;&#2527;&#2455;&#2494;&#2527; centralized configuration system &#2474;&#2509;&#2480;&#2527;&#2507;&#2460;&#2472;&#2404;</p><h3>Spring Cloud Config &#2453;&#2495;?</h3><p><strong>Spring Cloud Config</strong> &#2489;&#2482;&#2507; &#2447;&#2453;&#2463;&#2495; centralized configuration management system&#2404;</p><p>&#2447;&#2463;&#2495; configuration &#2455;&#2497;&#2482;&#2507;&#2453;&#2503; &#2447;&#2453;&#2463;&#2495; central repository (usually Git) &#2447; store &#2453;&#2480;&#2503; &#2447;&#2476;&#2434; runtime &#2447; microservices &#2455;&#2497;&#2482;&#2507; &#2488;&#2503;&#2439; configuration load &#2453;&#2480;&#2503;&#2404;</p><p>Architecture:</p><pre><code>            Git Repository
                  &#9474;
                  &#9660;
        Spring Cloud Config Server
                  &#9474;
                  &#9660;
              Microservices</code></pre><p>&#2447;&#2454;&#2494;&#2472;&#2503;:</p><ul><li><p>Git &#8594; configuration storage</p></li><li><p>Config Server &#8594; configuration provider</p></li><li><p>Microservices &#8594; configuration consumer</p></li></ul><h3>Config Repository Structure</h3><p>Config repository &#2488;&#2494;&#2471;&#2494;&#2480;&#2467;&#2468; &#2447;&#2439;&#2477;&#2494;&#2476;&#2503; organize &#2453;&#2480;&#2494; &#2489;&#2527;:</p><pre><code>config-repo
 &#9500;&#9472;&#9472; application.yml
 &#9500;&#9472;&#9472; product-service.yml
 &#9500;&#9472;&#9472; product-service-dev.yml
 &#9492;&#9472;&#9472; order-service-dev.yml</code></pre><p>Example:</p><pre><code>server:
  port: 8081

product:
  message: Product service configuration loaded from Config Server</code></pre><p>&#2447;&#2454;&#2494;&#2472;&#2503; <code>product-service-dev.yml</code> &#2486;&#2497;&#2471;&#2497;&#2478;&#2494;&#2468;&#2509;&#2480; <strong>dev environment</strong> &#2447;&#2480; &#2460;&#2472;&#2509;&#2479;&#2404;</p><h3>Spring Cloud Config Server Setup</h3><p>&#2474;&#2509;&#2480;&#2469;&#2478;&#2503; &#2447;&#2453;&#2463;&#2495; Config Server &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2468;&#2503; &#2489;&#2476;&#2503;&#2404;</p><p>Dependency:</p><pre><code>&lt;dependency&gt;
 &lt;groupId&gt;org.springframework.cloud&lt;/groupId&gt;
 &lt;artifactId&gt;spring-cloud-config-server&lt;/artifactId&gt;
&lt;/dependency&gt;</code></pre><p>Main class:</p><pre><code>@EnableConfigServer
@SpringBootApplication
public class ConfigServerApplication {
}</code></pre><p>application.yml:</p><pre><code>server:
  port: 8888

spring:
  cloud:
    config:
      server:
        git:
          uri: https://github.com/username/config-repo</code></pre><p>&#2447;&#2454;&#2472; config server Git repository &#2469;&#2503;&#2453;&#2503; configuration serve &#2453;&#2480;&#2476;&#2503;&#2404;</p><h3>Microservice Configuration</h3><p>Microservice &#2447; config server connect &#2453;&#2480;&#2468;&#2503; &#2489;&#2476;&#2503;&#2404;</p><pre><code>spring:
  config:
    import: configserver:http://localhost:8888</code></pre><p>Example controller:</p><pre><code>@RestController
@RefreshScope
public class ProductController {

    @Value(&#8221;${product.message}&#8221;)
    private String message;

}</code></pre><p><code>@RefreshScope</code> runtime configuration reload enable &#2453;&#2480;&#2503;&#2404;</p><h3>Problem: Config Change &#2453;&#2480;&#2482;&#2503; Service Update &#2489;&#2527; &#2472;&#2494;</h3><p>&#2471;&#2480;&#2497;&#2472; &#2438;&#2478;&#2480;&#2494; Git repo &#2468;&#2503; config update &#2453;&#2480;&#2482;&#2494;&#2478;:</p><pre><code>product.message=Updated value</code></pre><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; service automatically update &#2489;&#2476;&#2503; &#2472;&#2494;&#2404;</p><p>&#2453;&#2494;&#2480;&#2467; Spring Boot runtime &#2447; configuration reload &#2453;&#2480;&#2503; &#2472;&#2494;&#2404;</p><h3>Manual Refresh</h3><p>Spring Boot &#2447; &#2447;&#2453;&#2463;&#2495; actuator endpoint &#2438;&#2459;&#2503;:</p><pre><code>POST /actuator/refresh</code></pre><p>&#2453;&#2495;&#2472;&#2509;&#2468;&#2497; multiple microservice &#2469;&#2494;&#2453;&#2482;&#2503; &#2447;&#2463;&#2495; scalable &#2472;&#2494;&#2404;</p><h3>Spring Cloud Bus</h3><p>&#2447;&#2439; &#2488;&#2478;&#2488;&#2509;&#2479;&#2494;&#2480; elegant solution &#2489;&#2482;&#2507; <strong>Spring Cloud Bus</strong>&#2404;</p><p>Spring Cloud Bus &#2447;&#2453;&#2463;&#2495; distributed event system &#2479;&#2494; Kafka &#2476;&#2494; RabbitMQ &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; configuration refresh event broadcast &#2453;&#2480;&#2503;&#2404;</p><p>Architecture:</p><pre><code>          Config Server
                &#9474;
                &#9660;
         Spring Cloud Bus
                &#9474;
                &#9660;
               Kafka
                &#9474;
      &#9484;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9524;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9488;
      &#9660;                   &#9660;
 product-service      order-service</code></pre><h3>Configuration Refresh</h3><p>&#2447;&#2454;&#2472; config update &#2489;&#2482;&#2503;:</p><pre><code>POST /actuator/busrefresh</code></pre><p>&#2447;&#2439; endpoint Kafka &#2447;&#2480; &#2478;&#2494;&#2471;&#2509;&#2479;&#2478;&#2503; &#2488;&#2476; service &#2453;&#2503; notify &#2453;&#2480;&#2476;&#2503;&#2404;</p><p>&#2475;&#2482;&#2494;&#2475;&#2482;:</p><pre><code>All services refresh configuration automatically</code></pre><h3>Fully Automated Configuration Refresh</h3><p>Manual API call avoid &#2453;&#2480;&#2494;&#2480; &#2460;&#2472;&#2509;&#2479; &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2494; &#2489;&#2527;:</p><p><strong>Git Webhook + Config Monitor</strong></p><p>Flow:</p><pre><code>Git Push
   &#9474;
   &#9660;
GitHub Webhook
   &#9474;
   &#9660;
Config Server (/monitor)
   &#9474;
   &#9660;
Spring Cloud Bus
   &#9474;
   &#9660;
Kafka
   &#9474;
   &#9660;
All Services Refresh</code></pre><p>&#2447;&#2454;&#2472; config change &#2453;&#2480;&#2482;&#2503; &#2486;&#2497;&#2471;&#2497;:</p><pre><code>git push</code></pre><p>&#2453;&#2480;&#2482;&#2503;&#2439; &#2488;&#2476; service automatically refresh &#2489;&#2476;&#2503;&#2404;</p><h3>Production Architecture</h3><p>&#2447;&#2453;&#2463;&#2495; typical production architecture &#2470;&#2503;&#2454;&#2468;&#2503; &#2447;&#2478;&#2472; &#2489;&#2527;:</p><pre><code>            Git Config Repo
                  &#9474;
                  &#9660;
          Spring Cloud Config Server
                  &#9474;
                  &#9660;
            Spring Cloud Bus
                  &#9474;
                  &#9660;
                 Kafka
                  &#9474;
       &#9484;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9524;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9472;&#9488;
       &#9660;                     &#9660;
  product-service       order-service</code></pre><h1>Benefits</h1><p>Spring Cloud Config &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2482;&#2503; &#2474;&#2494;&#2451;&#2527;&#2494; &#2479;&#2494;&#2527;:</p><ul><li><p>centralized configuration</p></li><li><p>environment specific config</p></li><li><p>runtime refresh</p></li><li><p>microservice friendly architecture</p></li><li><p>Git based version control</p></li><li><p>production ready configuration management</p></li></ul><div><hr></div><p>Microservice architecture &#2447; configuration management &#2447;&#2453;&#2463;&#2495; critical concern&#2404;</p><p>Spring Cloud Config, Spring Cloud Bus &#2447;&#2476;&#2434; Git Webhook &#2476;&#2509;&#2479;&#2476;&#2489;&#2494;&#2480; &#2453;&#2480;&#2503; &#2438;&#2478;&#2480;&#2494; &#2454;&#2497;&#2476; &#2488;&#2489;&#2460;&#2503;&#2439; &#2447;&#2453;&#2463;&#2495; <strong>fully automated configuration management system</strong> &#2468;&#2504;&#2480;&#2495; &#2453;&#2480;&#2468;&#2503; &#2474;&#2494;&#2480;&#2495;&#2404;</p><p>&#2447;&#2463;&#2495; &#2486;&#2497;&#2471;&#2497; development experience improve &#2453;&#2480;&#2503; &#2472;&#2494;, &#2476;&#2480;&#2434; production reliability &#2451; significantly improve &#2453;&#2480;&#2503;&#2404;</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[From Zero to Understanding SQL Like a Backend Engineer]]></title><description><![CDATA[SQL Mastery Series - Part 1]]></description><link>https://rhidoyhasanmahmud.substack.com/p/from-zero-to-understanding-sql-like</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/from-zero-to-understanding-sql-like</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sat, 21 Feb 2026 06:11:52 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/150cdc0a-46d3-422e-acda-24266b28db73_1298x738.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h4><code>The day everything became slow&#8230;</code></h4><p>A few months ago, one of our APIs suddenly became slow.</p><p>Users were waiting. Requests were piling up.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>CPU was fine. Memory was fine.</p><p>But database latency jumped from:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">20 ms &#8594; 3 seconds</code></pre></div><p>The problem? SQL. Not the database. Not the server. Just one bad query. </p><p>That day reminded me of something important:</p><p><strong>SQL is not optional. It&#8217;s the backbone of every backend system.</strong></p><p>Whether you use:</p><ul><li><p>Spring Boot</p></li><li><p>Django</p></li><li><p>Node.js</p></li><li><p>Go</p></li></ul><p>Everything eventually becomes SQL.</p><h4><code>So what exactly is SQL?</code></h4><p>SQL stands for Structured Query Language.</p><p>In simple words, <strong>SQL is the language your backend uses to talk to the database.</strong></p><p>Example:</p><pre><code><code>SELECT * FROM users;</code></code></pre><p>This means: &#8220;Database, please give me all users.&#8221;</p><p>Your PDF also explains that SQL is used to store, retrieve, update, and delete data.</p><p>But let&#8217;s understand it like engineers.</p><h4><code>Real Backend Flow</code></h4><p>When a user logs in:</p><pre><code><code>User &#8594; Backend &#8594; SQL &#8594; Database &#8594; SQL Response &#8594; Backend &#8594; User</code></code></pre><p>Example:</p><ul><li><p>User enters email:</p></li><li><p>Backend runs:</p></li></ul><pre><code><code>SELECT * FROM users WHERE email = 'hasan@gmail.com';</code></code></pre><p>Database returns the user &#8594; Backend verifies password &#8594; Login successful.</p><p>SQL is happening behind every login, payment, and API call.</p><h4><code>What is a Database?</code></h4><p>Think of database like Excel on steroids.</p><p>Example:</p><p>users table:</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!l6O0!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!l6O0!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 424w, https://substackcdn.com/image/fetch/$s_!l6O0!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 848w, https://substackcdn.com/image/fetch/$s_!l6O0!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 1272w, https://substackcdn.com/image/fetch/$s_!l6O0!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!l6O0!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png" width="592" height="128" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/a3d0db66-3451-443c-a147-264177e97eef_592x128.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:128,&quot;width&quot;:592,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:23353,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/188479791?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!l6O0!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 424w, https://substackcdn.com/image/fetch/$s_!l6O0!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 848w, https://substackcdn.com/image/fetch/$s_!l6O0!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 1272w, https://substackcdn.com/image/fetch/$s_!l6O0!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fa3d0db66-3451-443c-a147-264177e97eef_592x128.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>SQL helps you:</p><ul><li><p>read data</p></li><li><p>write data</p></li><li><p>update data</p></li><li><p>delete data</p></li></ul><h4><code>Primary Key - The Identity Card</code></h4><p>Every table needs a unique identifier.</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;sql&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-sql">CREATE TABLE users (
  id INT PRIMARY KEY,
  name VARCHAR(100)
);</code></pre></div><p>Here:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;sql&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-sql">id = unique identity</code></pre></div><p>No duplicates allowed.</p><p>Real example:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;sql&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-sql">User ID = 1001</code></pre></div><p>Even if two users have same name, ID is always unique.</p><h4><code>Foreign Key - Relationship Between Tables</code></h4><p>Example: users &amp; order table</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!pcwQ!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!pcwQ!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 424w, https://substackcdn.com/image/fetch/$s_!pcwQ!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 848w, https://substackcdn.com/image/fetch/$s_!pcwQ!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 1272w, https://substackcdn.com/image/fetch/$s_!pcwQ!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!pcwQ!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png" width="1052" height="180" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:180,&quot;width&quot;:1052,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:37607,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/188479791?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!pcwQ!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 424w, https://substackcdn.com/image/fetch/$s_!pcwQ!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 848w, https://substackcdn.com/image/fetch/$s_!pcwQ!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 1272w, https://substackcdn.com/image/fetch/$s_!pcwQ!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F4898d1a8-278f-4627-8ed9-a35847440169_1052x180.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><p>Here:</p><pre><code><code>User_Id &#8594; connects order to user</code></code></pre><p>This creates relationship.</p><h4><code>SQL Commands You Use Every Day</code></h4><p>There are only 4 main commands:</p><p>Create data:</p><pre><code><code>INSERT INTO users VALUES (1, 'Hasan');</code></code></pre><p>Read data:</p><pre><code><code>SELECT * FROM users;</code></code></pre><p>Update data:</p><pre><code><code>UPDATE users SET name='Hasan Mahmud';</code></code></pre><p>Delete data:</p><pre><code><code>DELETE FROM users;</code></code></pre><h4><code>Why SQL is critical for backend engineers</code></h4><p>Because every backend eventually depends on database performance.</p><p>Bad SQL:</p><pre><code><code>API = slow</code></code></pre><p>Good SQL:</p><pre><code><code>API = fast</code></code></pre><h4><code>Real example from production</code></h4><p>Bad query:</p><pre><code><code>SELECT * FROM orders;</code></code></pre><p>Good query:</p><pre><code><code>SELECT id, total FROM orders WHERE user_id = 101;</code></code></pre><p>Faster, efficient, and production-ready.</p><h4><code>DELETE vs TRUNCATE vs DROP &#8212; The Mistake That Can Destroy Your Database</code></h4><p><strong>The worst production mistake I&#8217;ve ever seen</strong></p><p>It was a normal deployment day. Everything was working fine.</p><p>Then suddenly&#8230;</p><p>All user data disappeared. Not slow. Not corrupted.</p><p>Just gone. The reason?</p><p>One SQL command.</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">DROP TABLE users;</code></pre></div><p>That&#8217;s it. Years of data deleted in milliseconds.</p><p>No rollback. No recovery. That&#8217;s when I realized: <strong>Understanding DELETE, TRUNCATE, and DROP is not optional. It&#8217;s survival knowledge.</strong></p><h4><code>First, understand this simple table</code></h4><pre><code>Users table

id | name
---------
1  | Hasan
2  | John
3  | Alice</code></pre><p>Now let&#8217;s see what each command actually does.</p><h4><code>DELETE - The Safe Option</code></h4><p>Example:</p><pre><code><code>DELETE FROM users WHERE id = 1;</code></code></pre><p>Result:</p><pre><code><code>id | name
---------
2  | John
3  | Alice</code></code></pre><p>Only one row was deleted. Everything else stays.</p><h4><code>Why DELETE is safe</code></h4><p>Because DELETE works row by row.</p><p>And most importantly:</p><ul><li><p>You can rollback.</p></li></ul><p>Example:</p><pre><code><code>BEGIN;

DELETE FROM users WHERE id = 1;

ROLLBACK;</code></code></pre><ul><li><p>Data comes back.</p></li><li><p>Nothing lost.</p></li></ul><h4><code>Production use case</code></h4><p>Delete one order:</p><pre><code><code>DELETE FROM orders WHERE id = 101;</code></code></pre><p>This is safe.</p><h4><code>TRUNCATE - Fast but Dangerous</code></h4><p>Example:</p><pre><code><code>TRUNCATE TABLE users;</code></code></pre><p>Result:</p><pre><code><code>users table is now empty</code></code></pre><p>All rows gone.</p><h4><code>Why is TRUNCATE faster</code></h4><p>Because the database doesn&#8217;t delete rows one by one.</p><p>It simply resets the table.</p><p>Think like:</p><pre><code><code>DELETE &#8594; remove each book from shelf
TRUNCATE &#8594; replace entire shelf</code></code></pre><p>Much faster.</p><p><strong>But here&#8217;s the danger</strong></p><p>TRUNCATE usually cannot be rolled back. The data is gone permanently.</p><h4><code>DROP - Nuclear Option</code></h4><p>Example:</p><pre><code><code>DROP TABLE users;</code></code></pre><p>Result:</p><pre><code><code>Table deleted
Structure deleted
Everything deleted</code></code></pre><p>Not just data. The table itself is gone.</p><div class="captioned-image-container"><figure><a class="image-link image2" target="_blank" href="https://substackcdn.com/image/fetch/$s_!lPAZ!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!lPAZ!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 424w, https://substackcdn.com/image/fetch/$s_!lPAZ!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 848w, https://substackcdn.com/image/fetch/$s_!lPAZ!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 1272w, https://substackcdn.com/image/fetch/$s_!lPAZ!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!lPAZ!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png" width="846" height="170" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/ee39a291-0590-42c7-b112-deaf92e91f77_846x170.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:170,&quot;width&quot;:846,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:37556,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/188479791?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!lPAZ!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 424w, https://substackcdn.com/image/fetch/$s_!lPAZ!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 848w, https://substackcdn.com/image/fetch/$s_!lPAZ!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 1272w, https://substackcdn.com/image/fetch/$s_!lPAZ!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fee39a291-0590-42c7-b112-deaf92e91f77_846x170.png 1456w" sizes="100vw" loading="lazy"></picture><div></div></div></a></figure></div><h4><code>The biggest mistake beginners make</code></h4><p>Running this:</p><pre><code><code>DELETE FROM users;</code></code></pre><p>Without WHERE.</p><p>Result: All users deleted.</p><p>Always double-check.</p><p><strong>Think like a house analogy:</strong></p><p>DELETE &#8594; Remove one person from the house</p><p>TRUNCATE &#8594; Empty house</p><p>DROP &#8594; Destroy house</p><h4><code>When to use each in real backend systems</code></h4><p>Use DELETE when:</p><ul><li><p>deleting specific rows</p></li><li><p>production systems</p></li><li><p>need rollback</p></li></ul><p>Use TRUNCATE when:</p><ul><li><p>clearing logs</p></li><li><p>resetting test data</p></li></ul><p>Use DROP when:</p><ul><li><p>removing the table permanently</p></li><li><p>migrations</p></li><li><p>removing unused tables</p></li></ul><h4><code>WHERE vs HAVING - The Mistake That Silently Slows Your Queries</code></h4><p>One of our analytics APIs suddenly became slow. The query looked clean.</p><p>No syntax errors. No crashes.</p><p>But execution time jumped from:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">50 ms &#8594; 4 seconds</code></pre></div><p>The issue? A small mistake.</p><p>Using <code>HAVING</code> instead of <code>WHERE</code>. It worked.</p><p>But it was inefficient. <strong>SQL mistakes often don&#8217;t break systems. They silently slow them down.</strong></p><p>First, understand this example table</p><p><strong>orders table:</strong></p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">| id | user_id | amount |
| -- | ------- | ------ |
| 1  | 101     | 100    |
| 2  | 101     | 200    |
| 3  | 102     | 300    |
| 4  | 103     | 150    |</code></pre></div><h4><code>WHERE - Filters BEFORE processing</code></h4><p>Example:</p><pre><code><code>SELECT *
FROM orders
WHERE amount &gt; 150;</code></code></pre><p>Result:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">| id | user_id | amount |
| -- | ------- | ------ |
| 2  | 101     | 200    |
| 3  | 102     | 300    |</code></pre></div><p>Database filters rows immediately, which is fast and efficient.</p><h4><code>HAVING - Filters AFTER processing</code></h4><p>Example:</p><pre><code>SELECT user_id, SUM(amount)
FROM orders
GROUP BY user_id
HAVING SUM(amount) &gt; 200;</code></pre><p>Result:</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">| user_id | sum |
| ------- | --- |
| 101     | 300 |
| 102     | 300 |</code></pre></div><p>Here&#8217;s what happens internally:</p><p>Step 1: Group all users<br>Step 2: Calculate SUM<br>Step 3: Apply the HAVING filter</p><p>More work and Slower.</p><p><strong>WHERE flow:</strong></p><pre><code>Table &#8594; Filter &#8594; Result</code></pre><p><strong>HAVING flow:</strong></p><pre><code>Table &#8594; Group &#8594; Calculate &#8594; Filter &#8594; Result</code></pre><p>HAVING does more processing.</p><h4><code>Real backend example</code></h4><p>Bad query:</p><pre><code>SELECT user_id, COUNT(*)
FROM orders
GROUP BY user_id
HAVING user_id = 101;</code></pre><p>Better query:</p><pre><code>SELECT user_id, COUNT(*)
FROM orders
WHERE user_id = 101
GROUP BY user_id;</code></pre><p>Why?</p><p>WHERE filters first and HAVING filters later.</p><p>Less work = faster query.</p><div><hr></div><p>Imagine:</p><pre><code>orders table = 50 million rows</code></pre><p>Using HAVING incorrectly:</p><p>Database processes all 50 million rows.</p><p>Using WHERE correctly:</p><p>Database processes may be 100 rows.</p><p>Massive difference.</p><div><hr></div><h4><code>When to use WHERE </code></h4><p>Use WHERE when filtering individual rows.</p><p>Example:</p><pre><code>SELECT *
FROM users
WHERE country = &#8216;Malaysia&#8217;;</code></pre><p>It is fast and efficient.</p><h4><code>When to use HAVING</code></h4><p>Use HAVING when filtering aggregated results.</p><p>Example:</p><pre><code>SELECT department, COUNT(*)
FROM employees
GROUP BY department
HAVING COUNT(*) &gt; 10;</code></pre><p>You cannot use WHERE here because COUNT doesn&#8217;t exist before grouping.</p><div><hr></div><p>In Summary:</p><ul><li><p>WHERE = filter people before counting</p></li><li><p>HAVING = count people, then filter groups</p></li></ul><p>Note: Always use WHERE unless aggregation is involved.</p><div class="highlighted_code_block" data-attrs="{&quot;language&quot;:&quot;plaintext&quot;,&quot;nodeId&quot;:null}" data-component-name="HighlightedCodeBlockToDOM"><pre class="shiki"><code class="language-plaintext">Database
  &#8595;
WHERE filters rows
  &#8595;
GROUP BY groups data
  &#8595;
HAVING filters grouped data
  &#8595;
Result</code></pre></div><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Idempotency in Distributed Systems: Why Your API Must Handle Retries Safely]]></title><description><![CDATA[How modern systems prevent duplicate payments, duplicate orders, and data corruption using idempotency]]></description><link>https://rhidoyhasanmahmud.substack.com/p/idempotency-in-distributed-systems</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/idempotency-in-distributed-systems</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Fri, 20 Feb 2026 06:50:20 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/c0185f20-4306-4eec-b3b0-f8cb0af58d23_1400x788.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h3><code>A small incident that can break user trust</code></h3><p>Imagine this. You open a mobile banking app and transfer <strong>$1000</strong>. You click <strong>&#8220;Send.&#8221;</strong></p><p>Nothing happens. No confirmation. No success message.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>You panic and click again. Later, you check your balance. <strong>$2000 is gone.</strong></p><p>You only intended to send $1000.</p><p>From a user perspective, this feels like a disaster.<br>From an engineering perspective, this is a failure of <strong>idempotency</strong>.</p><p>Modern distributed systems must assume failures are normal. <strong>Networks fail. Requests timeout. Clients retry. Load balancers retry. Kafka retries</strong>.</p><p>If your system cannot safely handle retries, it will corrupt data. This is where idempotency becomes essential.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!n6Ak!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!n6Ak!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 424w, https://substackcdn.com/image/fetch/$s_!n6Ak!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 848w, https://substackcdn.com/image/fetch/$s_!n6Ak!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 1272w, https://substackcdn.com/image/fetch/$s_!n6Ak!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!n6Ak!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png" width="958" height="1102" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/edbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:1102,&quot;width&quot;:958,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:163625,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/188585123?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!n6Ak!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 424w, https://substackcdn.com/image/fetch/$s_!n6Ak!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 848w, https://substackcdn.com/image/fetch/$s_!n6Ak!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 1272w, https://substackcdn.com/image/fetch/$s_!n6Ak!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fedbf70dc-5e4d-44a5-97d7-ee21959cc87a_958x1102.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h3><code>What is Idempotency </code></h3><p>Idempotency means:</p><blockquote><p>Performing the same operation multiple times produces the same final result as performing it once.</p></blockquote><p>In simple terms: Retrying the same request should not create duplicate effects.</p><p>Example:</p><pre><code>Send $1000 once &#8594; balance reduced by $1000
Send same request again &#8594; balance should NOT reduce again</code></pre><p>Final state remains correct. This ensures system consistency and protects user data.</p><h3><code>Why retries are normal in distributed systems</code></h3><p>Many developers assume requests execute only once.</p><p>In reality, retries happen constantly.</p><p>Common retry sources:</p><ul><li><p>Network timeout</p></li><li><p>Mobile network instability</p></li><li><p>Load balancer retry</p></li><li><p>API gateway retry</p></li><li><p>Kafka message redelivery</p></li><li><p>Service crash and restart</p></li><li><p>Client retry logic</p></li></ul><p>Your system must be designed assuming every request can happen multiple times.</p><p>Retries are not exceptions. They are expected behavior.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!3h3H!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!3h3H!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 424w, https://substackcdn.com/image/fetch/$s_!3h3H!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 848w, https://substackcdn.com/image/fetch/$s_!3h3H!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 1272w, https://substackcdn.com/image/fetch/$s_!3h3H!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!3h3H!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png" width="1412" height="934" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/b666067e-753a-4738-b45a-fd974be78d94_1412x934.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:934,&quot;width&quot;:1412,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:183419,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/188585123?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!3h3H!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 424w, https://substackcdn.com/image/fetch/$s_!3h3H!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 848w, https://substackcdn.com/image/fetch/$s_!3h3H!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 1272w, https://substackcdn.com/image/fetch/$s_!3h3H!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fb666067e-753a-4738-b45a-fd974be78d94_1412x934.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h3><code>HTTP Methods and Idempotency</code></h3><p>Some HTTP methods are naturally idempotent.</p><p>Idempotent methods:</p><ul><li><p>GET</p></li><li><p>PUT</p></li><li><p>DELETE</p></li></ul><p>Non-idempotent method:</p><ul><li><p>POST</p></li></ul><p>Example:</p><p><strong>GET request:</strong></p><pre><code>GET /users/123</code></pre><p>Running this multiple times produces the same result [Safe].</p><p><strong>PUT request:</strong></p><pre><code>PUT /users/123</code></pre><p>This replaces the resource. Running it multiple times produces the same final state [Safe].</p><p><strong>POST request:</strong></p><pre><code>POST /orders</code></pre><p>Running this multiple times creates multiple orders. Dangerous without protection.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Old5!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Old5!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 424w, https://substackcdn.com/image/fetch/$s_!Old5!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 848w, https://substackcdn.com/image/fetch/$s_!Old5!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 1272w, https://substackcdn.com/image/fetch/$s_!Old5!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Old5!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png" width="802" height="454" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:454,&quot;width&quot;:802,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:62193,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/188585123?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Old5!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 424w, https://substackcdn.com/image/fetch/$s_!Old5!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 848w, https://substackcdn.com/image/fetch/$s_!Old5!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 1272w, https://substackcdn.com/image/fetch/$s_!Old5!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F2b8d986b-029e-4558-96a9-50efaab7c646_802x454.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><h4><code>Real-world example: Payment system</code></h4><p>Let&#8217;s look at a payment API.</p><p>Request:</p><pre><code>POST /payments
{
  &#8220;userId&#8221;: 123,
  &#8220;amount&#8221;: 1000
}</code></pre><p><strong>Without idempotency:</strong></p><ul><li><p>First request &#8594; payment processed</p></li><li><p>Retry request &#8594; payment processed again</p></li></ul><p>User charged twice.</p><p><strong>With idempotency:</strong></p><ul><li><p>First request &#8594; payment processed</p></li><li><p>Retry request &#8594; system detects duplicate &#8594; returns previous result</p></li></ul><p>User is charged once. Correct behavior.</p><h4><code>How modern systems implement idempotency</code></h4><ol><li><p><strong>Idempotency Key</strong></p></li></ol><p>The most common approach is using an Idempotency Key.</p><p>Client sends request with unique key:</p><pre><code>POST /payments
Idempotency-Key: abc123</code></pre><p><strong>Server logic:</strong></p><ul><li><p>If key exists &#8594; return stored result</p></li><li><p>If the key does not exist &#8594; process the request and store the result</p></li></ul><p>This ensures duplicate requests do not create duplicate effects.</p><p>Database example:</p><pre><code>payments table

id
amount
idempotency_key (UNIQUE)</code></pre><p><strong>Unique constraint prevents duplicates.</strong></p><ol start="2"><li><p><strong>Event-driven systems</strong></p></li></ol><p>Kafka guarantees at least once delivery. This means the same message can be delivered multiple times.</p><p><strong>Without idempotency:</strong></p><p>Same event processed twice.</p><p><strong>Example</strong>: OrderCreated event processed twice &#8594; duplicate order.</p><p><strong>Solution</strong>: Store processed event ID.</p><p>If the event is already processed &#8594; ignore. This ensures system correctness.</p><ol start="3"><li><p><strong>Using a cache like Redis (High-performance approach)</strong></p></li></ol><p>Redis is commonly used to track idempotency keys.</p><p>Example:</p><pre><code>SET payment:abc123 processed NX EX 3600</code></pre><ul><li><p>NX &#8594; set only if not exist</p></li><li><p>EX &#8594; expire after time</p></li></ul><p>If key already exists &#8594; duplicate request detected.</p><p>Redis provides extremely fast lookup.</p><p><strong>Perfect for high-scale systems.</strong></p><h4><code>Why idempotency is critical for system reliability</code></h4><p><strong>Without idempotency, systems can cause:</strong></p><ul><li><p>Duplicate payments</p></li><li><p>Duplicate orders</p></li><li><p>Duplicate emails</p></li><li><p>Data corruption</p></li><li><p>Financial loss</p></li><li><p>User trust damage</p></li></ul><p><strong>With idempotency, systems become:</strong></p><ul><li><p>Reliable</p></li><li><p>Safe</p></li><li><p>Fault-tolerant</p></li><li><p>Retry-friendly</p></li></ul><p>This is a fundamental requirement for modern backend systems.</p><h4><code>How companies like Stripe, PayPal, and Uber use idempotency</code></h4><p>Every major distributed system uses idempotency.</p><ul><li><p>Stripe &#8594; payment protection</p></li><li><p>Uber &#8594; ride creation safety</p></li><li><p>Amazon &#8594; order creation safety</p></li><li><p>Kafka &#8594; event processing safety</p></li></ul><p>Idempotency is not optional. It is a standard engineering practice.</p><div><hr></div><p>Distributed systems are built assuming failures will happen.</p><p>Retries are inevitable. Idempotency ensures those retries do not break your system.</p><p>If you are building APIs, microservices, payment systems, or Kafka consumers, idempotency is not an advanced feature.</p><p>It is a necessity.</p><div><hr></div><h4><code>References</code></h4><ul><li><p><a href="https://www.rfc-editor.org/rfc/rfc9110.html">HTTP Idempotency - Official RFC</a></p></li><li><p><a href="https://docs.stripe.com/api/idempotent_requests">Stripe Engineering - Idempotency implementation</a></p></li><li><p><a href="https://martinfowler.com/articles/patterns-of-distributed-systems/idempotent-receiver.html">Martin Fowler - Distributed Systems Patterns</a></p></li><li><p><a href="https://microservices.io/patterns/communication-style/idempotent-consumer.html">Microservices.io - Idempotent Consumer Pattern</a></p></li><li><p><a href="https://kafka.apache.org/42/getting-started/introduction/">Kafka Documentation - Message delivery guarantees</a></p></li></ul><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[The Blockchain Scalability Trilemma - Through an IoT Lens]]></title><description><![CDATA[(Part 3 of the series: When Blockchain Meets Real-Time IoT)]]></description><link>https://rhidoyhasanmahmud.substack.com/p/the-blockchain-scalability-trilemma</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/the-blockchain-scalability-trilemma</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Wed, 18 Feb 2026 15:53:15 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/e00eefba-9511-4cf6-91c8-1d2a9b0929dc_1200x630.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h2>The Dream: Fast, Secure, and Decentralized</h2><p>Imagine someone tells you:</p><blockquote><p>&#8220;We built a blockchain that is super fast, fully decentralized, and extremely secure.&#8221;</p></blockquote><p>If you&#8217;ve studied distributed systems long enough, you&#8217;ll pause.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>Because in blockchain design, there&#8217;s a famous idea called:</p><blockquote><p><strong>The Scalability Trilemma</strong></p></blockquote><p>It says you can&#8217;t perfectly optimize all three at the same time:</p><ul><li><p><strong>Decentralization</strong></p></li><li><p><strong>Security</strong></p></li><li><p><strong>Scalability</strong></p></li></ul><p>Improving one usually weakens another.</p><p>And when we bring <strong>IoT</strong> into the picture, the tension becomes even sharper.</p><h2>Understanding the Three Corners</h2><p>Let&#8217;s break it down simply.</p><h3><code>1. Decentralization</code></h3><p>Many independent nodes participate. No central authority controls the system.</p><p>This gives:</p><ul><li><p>Censorship resistance</p></li><li><p>Fault tolerance</p></li><li><p>Trustlessness</p></li></ul><p>But it also means:</p><ul><li><p>More communication</p></li><li><p>Slower agreement</p></li></ul><h3><code>2. Security</code></h3><p>The system resists attacks, manipulation, and data tampering.</p><p>This often requires:</p><ul><li><p>Strong cryptography</p></li><li><p>Redundant verification</p></li><li><p>Multi-round consensus</p></li></ul><p>Security adds protection - but also overhead.</p><h3><code>3. Scalability</code></h3><p>The system handles:</p><ul><li><p>High transaction volume</p></li><li><p>Large user base</p></li><li><p>Growing data</p></li></ul><p>Scalability usually means:</p><ul><li><p>Faster block times</p></li><li><p>Parallel processing</p></li><li><p>Reduced consensus overhead</p></li></ul><p>But these optimizations can reduce decentralization or security.</p><h2>The Trilemma Visualized</h2><p>Most real-world blockchains sit closer to one side than the others.</p><p>For example:</p><ul><li><p>Bitcoin &#8594; Strong decentralization &amp; security, lower scalability</p></li><li><p>Permissioned chains &#8594; Higher scalability, reduced decentralization</p></li></ul><h2>Why IoT Makes the Trilemma Harder</h2><p>IoT systems demand:</p><ul><li><p>Low latency</p></li><li><p>High throughput</p></li><li><p>Predictable performance</p></li></ul><p>This pushes us strongly toward the <strong>scalability corner</strong>.</p><p>But here&#8217;s the problem:</p><p>When we optimize for scalability:</p><ul><li><p>We reduce validator count</p></li><li><p>We simplify consensus</p></li><li><p>We centralize control</p></li></ul><p>And suddenly, decentralization weakens.</p><p>If we try to maintain decentralization:</p><ul><li><p>More nodes join consensus</p></li><li><p>Message complexity increases</p></li><li><p>Latency grows</p></li></ul><p>That breaks real-time IoT guarantees.</p><h2>A Real-World Tension</h2><p>Imagine millions of IoT sensors sending data.</p><p>To scale:</p><ul><li><p>We might reduce validators to 10 trusted nodes.</p></li><li><p>That improves performance.</p></li></ul><p>But now:</p><ul><li><p>It&#8217;s closer to a distributed database than a decentralized blockchain.</p></li></ul><p>Alternatively:</p><ul><li><p>We keep 1,000 validators for decentralization.</p></li><li><p>Now consensus delay increases.</p></li><li><p>Latency spikes.</p></li></ul><p>IoT systems don&#8217;t tolerate that unpredictability.</p><h2>The Hidden Fourth Constraint: Latency</h2><p>The original trilemma focuses on scalability, security, and decentralization.</p><p>But IoT introduces something critical:</p><blockquote><p><strong>Deterministic latency</strong></p></blockquote><p>It&#8217;s not enough to process many transactions.<br>We must process them <strong>within bounded time</strong>.</p><p>So in IoT contexts, the trilemma feels like this:</p><ul><li><p>Decentralization</p></li><li><p>Security</p></li><li><p>Scalability</p></li><li><p>Predictable latency</p></li></ul><p>And balancing all four is extremely challenging.</p><h2>Why &#8220;Just Scale It&#8221; Doesn&#8217;t Work</h2><p>You might think:</p><blockquote><p>&#8220;Can&#8217;t we just increase hardware?&#8221;</p></blockquote><p>In distributed systems, adding nodes doesn&#8217;t reduce communication overhead.<br>It often increases it.</p><p>Consensus protocols:</p><ul><li><p>Require multiple message rounds</p></li><li><p>Grow in complexity with more validators</p></li><li><p>Increase coordination delay</p></li></ul><p>So naive scaling can worsen latency.</p><h2>Where Research Is Heading</h2><p>Instead of trying to fully solve the trilemma, researchers are exploring:</p><ul><li><p><strong>Sharding</strong> &#8594; Split the network into smaller groups</p></li><li><p><strong>Lightweight consensus</strong> &#8594; Reduce communication rounds</p></li><li><p><strong>Edge-assisted architectures</strong> &#8594; Preprocess data before blockchain</p></li><li><p><strong>Hybrid models</strong> &#8594; Combine trust-based and decentralized layers</p></li></ul><p>These approaches don&#8217;t eliminate the trilemma - they <strong>reshape the trade-offs</strong>.</p><h2>The Honest Truth</h2><p>There is no magic blockchain that:</p><ul><li><p>Is fully decentralized</p></li><li><p>Fully secure</p></li><li><p>Infinitely scalable</p></li><li><p>And real-time deterministic</p></li></ul><p>Every system makes compromises.</p><p>The real question becomes:</p><blockquote><p><strong>Which compromise is acceptable for IoT systems?</strong></p></blockquote><p>That question defines your research direction.</p><div><hr></div><blockquote><p>The scalability trilemma isn&#8217;t a bug. It&#8217;s a design reality.</p></blockquote><p>And when IoT systems demand predictable latency, the balancing act becomes even more delicate.</p><p>Understanding this trade-off is the foundation for:</p><ul><li><p>Sharding strategies</p></li><li><p>Lightweight consensus design</p></li><li><p>Real-time blockchain research</p></li></ul><div><hr></div><h2>References</h2><ul><li><p><a href="https://www.coindesk.com/markets/2015/08/07/vitalik-buterin-on-public-and-private-blockchains">Vitalik Buterin: On Public and Private Blockchains</a></p></li><li><p><a href="https://experts.illinois.edu/en/publications/on-scaling-decentralized-blockchains-a-position-paper/">On scaling decentralized blockchains</a></p></li><li><p><a href="https://discovery.ucl.ac.uk/id/eprint/10182347/1/eth-50739-01.pdf">On the Security, Performance, and Privacy of Proof of Work Blockchains</a></p></li><li><p><a href="https://arxiv.org/pdf/1905.06022">When Internet of Things Meets Blockchain: Challenges in Distributed Consensus</a></p></li></ul><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[B-Tree vs B+ Tree in Production Database Systems]]></title><description><![CDATA[[Part-1] Why databases chose one over the other - explained with real thinking and real examples]]></description><link>https://rhidoyhasanmahmud.substack.com/p/b-tree-vs-b-tree-in-production-database</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/b-tree-vs-b-tree-in-production-database</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sun, 08 Feb 2026 17:22:24 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/174a6127-8ae3-48e1-83cb-d3bd74aa532c_1230x622.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>If you&#8217;ve worked with production databases long enough, you&#8217;ve heard this advice many times:</p><blockquote><p>&#8220;Add an index. It will be faster.&#8221;</p></blockquote><p>But here&#8217;s a more interesting question that most people never ask:</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><blockquote><p><strong>Why does the database internally use B+ Tree, when textbooks already taught us B-Tree?</strong></p></blockquote><p>The answer lives somewhere between <strong>disk reality</strong>, <strong>query patterns</strong>, and <strong>engineering trade-offs</strong> - not in theory alone.</p><p>Let&#8217;s walk through it step by step, like a database actually experiences it.</p><h2>1. Production Reality: Databases Live on Disk</h2><p>Let&#8217;s start with a simple table:</p><pre><code>users (
  id BIGINT,
  age INT,
  name TEXT
)</code></pre><p>Now imagine this table has <strong>10 million rows</strong>.</p><p>When you run:</p><pre><code>SELECT * FROM users WHERE age = 35;</code></pre><p><strong>What really happens?</strong></p><p>Without an index, the database:</p><ul><li><p>Reads page after page from disk</p></li><li><p>Checks every row</p></li><li><p>Discards almost everything</p></li></ul><p>This is called a <strong>sequential scan</strong>, and it&#8217;s slow because:</p><blockquote><p><strong>Disk access is thousands of times slower than memory.</strong></p></blockquote><p>So databases are not trying to be clever with algorithms. They are trying to answer one brutal question:</p><blockquote><p><strong>How can I touch the disk as little as possible?</strong></p></blockquote><p>That single question explains the existence of B-Tree and B+ Tree.</p><h2>2. Why Simple Structures Fail in Production</h2><p>At first glance, many structures look attractive - until disk gets involved.</p><h3>Binary Search Tree (BST)</h3><p>In memory, a BST is elegant:</p><pre><code>        50
       /  \
     20    80
    / \    / \
  10 30  70  90</code></pre><p>On disk, this becomes painful:</p><ul><li><p>Each node may live in a different disk location</p></li><li><p>Each pointer jump may cause a disk read</p></li><li><p>Too many <strong>random I/O operations</strong></p></li></ul><p>Production systems hate randomness on disk.</p><h3>Hash Index</h3><p>Hash indexes work well for this:</p><pre><code>WHERE age = 35</code></pre><p>But completely fail for this:</p><pre><code><code>WHERE age BETWEEN 30 AND 40</code></code></pre><p>And real systems are full of:</p><ul><li><p><code>BETWEEN</code></p></li><li><p><code>ORDER BY</code></p></li><li><p>pagination</p></li><li><p>time-based filtering</p></li></ul><p>Hash indexes don&#8217;t survive real workloads.</p><h2>3. The B-Tree Breakthrough: Think in Pages, Not Nodes</h2><p>B-Tree came from a mindset shift:</p><blockquote><p><strong>Stop thinking in nodes. Start thinking in disk pages.</strong></p></blockquote><p>Instead of storing one key per node, B-Tree stores <strong>many keys in a single node</strong>.</p><p>A node might look like this:</p><pre><code>[ 10 | 20 | 30 | 40 | 50 ]</code></pre><p>That entire block:</p><ul><li><p>Fits into one disk page (e.g., 8KB)</p></li><li><p>Is read with <strong>one disk I/O</strong></p></li></ul><p>This creates a <strong>short and wide</strong> tree.</p><p>In production databases, even with millions of rows, a B-Tree often has a height of only <strong>3 or 4</strong>.</p><p>That means:</p><ul><li><p>3&#8211;4 page reads</p></li><li><p>Predictable performance</p></li><li><p>Excellent scalability</p></li></ul><h2>4. How Searching Works in a B-Tree </h2><p>Consider this small B-Tree:</p><pre><code>               [ 30 | 60 ]
              /     |     \
       [10|20]   [40|50]   [70|80|90]</code></pre><p>Search for <code>age = 50</code>:</p><ol><li><p>Read root <code>[30|60]</code></p></li><li><p>Choose middle child</p></li><li><p>Read <code>[40|50]</code></p></li><li><p>Found</p></li></ol><p>Only <strong>two page reads</strong> in this example.</p><p>This is why B-Tree became the foundation of database indexing.</p><h2>5. Insert and Split: The Cost Databases Accept</h2><p>Assume a B-Tree node can hold <strong>3 keys max</strong>.</p><p>Insert keys in order:</p><pre><code><code>10 &#8594; 20 &#8594; 5 &#8594; 6</code></code></pre><p>Steps:</p><ul><li><p><code>[10]</code></p></li><li><p><code>[10|20]</code></p></li><li><p><code>[5|10|20]</code> (node full)</p></li><li><p>Insert <code>6</code> &#8594; overflow &#8594; split</p></li></ul><p>Result:</p><pre><code><code>              [10]
             /    \
        [5|6]    [20]</code></code></pre><p>Splits:</p><ul><li><p>Are expensive</p></li><li><p>Cause extra writes</p></li><li><p>But happen <strong>far less often than reads</strong></p></li></ul><p>Databases accept this trade-off because:</p><blockquote><p>Reads dominate most production workloads.</p></blockquote><h2>6. Where B-Tree Starts Feeling Awkward in Production</h2><p>Now look at a <strong>very common query</strong>:</p><pre><code><code>SELECT * FROM users
WHERE age BETWEEN 30 AND 40
ORDER BY age;</code></code></pre><p>Here&#8217;s the problem with B-Tree in real systems:</p><ul><li><p>Data may exist in <strong>internal nodes and leaf nodes</strong></p></li><li><p>Leaves are not naturally linked</p></li><li><p>Range scans may jump back and forth</p></li></ul><p>This creates unnecessary disk seeks - something disks hate.</p><p>Production databases wanted smoother access patterns.</p><h2>7. The B+ Tree Insight: Separate Navigation from Data</h2><p>B+ Tree didn&#8217;t replace B-Tree. It <strong>refined it</strong>.</p><p>The philosophy became:</p><blockquote><p><strong>Internal nodes are for navigation. Leaf nodes are for data.</strong></p></blockquote><p>So B+ Tree makes one critical decision:</p><ul><li><p>Internal nodes store <strong>keys only</strong></p></li><li><p>All data (or row pointers) live in <strong>leaf nodes</strong></p></li><li><p>Leaf nodes are <strong>linked together</strong></p></li></ul><h2>8. B+ Tree Structure</h2><p>Conceptually:</p><pre><code><code>           [ 30 | 60 ]
          /     |     \
 [10|20|30] -&gt; [40|50|60] -&gt; [70|80|90]</code></code></pre><p>What this achieves:</p><ul><li><p>Internal nodes guide you quickly</p></li><li><p>Leaf nodes let you walk <strong>sequentially</strong></p></li><li><p>Disk access becomes smooth and predictable</p></li></ul><h2>9. Why Range Queries Become a Superpower</h2><p>Revisit the range query:</p><pre><code><code>WHERE age BETWEEN 30 AND 40</code></code></pre><p>In a B+ Tree, the database does this:</p><ol><li><p>Traverse the tree to find the leaf containing <code>30</code></p></li><li><p>Start scanning leaf entries</p></li><li><p>Follow the leaf-to-leaf pointer</p></li><li><p>Stop after <code>40</code></p></li></ol><p>No jumping back to parents. No random disk reads. Just clean, sequential page access.</p><p>This is exactly how disks want to be used.</p><h2>10. How This Looks in a Real Database</h2><p>In PostgreSQL or MySQL (InnoDB):</p><ul><li><p>One B+ Tree node = one disk page (8KB / 16KB)</p></li><li><p>Root and upper levels are often cached</p></li><li><p>Most queries touch only a few pages</p></li></ul><p>Example:</p><pre><code><code>CREATE INDEX idx_users_age ON users(age);</code></code></pre><pre><code><code>EXPLAIN ANALYZE
SELECT * FROM users WHERE age BETWEEN 30 AND 40;</code></code></pre><p>You&#8217;ll typically see:</p><ul><li><p><code>Index Scan</code> or <code>Bitmap Index Scan</code></p></li><li><p>Massive reduction in execution time</p></li></ul><h2>11. Index Is Not the Data </h2><p>An index entry looks like this:</p><pre><code><code>(age = 35) &#8594; row_id = 892311</code></code></pre><p>Process:</p><ol><li><p>B+ Tree finds matching keys</p></li><li><p>Database fetches actual rows using row IDs</p></li></ol><p>This explains why:</p><ul><li><p>Indexes filter efficiently</p></li><li><p>Fetching many rows can still be expensive</p></li></ul><p>Understanding this prevents many production surprises.</p><h2>12. Why Production Databases Choose B+ Tree</h2><p>Let&#8217;s summarize with reality in mind:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!Ng4p!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!Ng4p!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 424w, https://substackcdn.com/image/fetch/$s_!Ng4p!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 848w, https://substackcdn.com/image/fetch/$s_!Ng4p!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 1272w, https://substackcdn.com/image/fetch/$s_!Ng4p!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!Ng4p!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png" width="1250" height="956" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:956,&quot;width&quot;:1250,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:246482,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/187301948?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!Ng4p!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 424w, https://substackcdn.com/image/fetch/$s_!Ng4p!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 848w, https://substackcdn.com/image/fetch/$s_!Ng4p!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 1272w, https://substackcdn.com/image/fetch/$s_!Ng4p!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F6548e0e1-2249-4aad-afad-6df37df3610e_1250x956.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>That&#8217;s why:</p><ul><li><p>PostgreSQL uses B+ Trees</p></li><li><p>MySQL InnoDB uses B+ Trees</p></li><li><p>Oracle uses B+ Trees</p></li></ul><p>Not because B-Tree is wrong, but because <strong>B+ Tree fits production behavior better</strong>.</p><h2>Final Thought</h2><p>B-Tree was a brilliant idea. B+ Tree was a <strong>production-grade evolution</strong>.</p><p>They are not academic exercises. They are answers to one hard, practical question:</p><blockquote><p><strong>How do we reduce disk I/O while serving real queries at scale?</strong></p></blockquote><p>That&#8217;s the heart of database indexing.</p><div><hr></div><p><strong>Part 2: Inside a B+ Tree Page (8KB reality)</strong></p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Why TPS Is a Lie: Understanding Blockchain Performance for IoT]]></title><description><![CDATA[(Part 2 of the series: When Blockchain Meets Real-Time IoT)]]></description><link>https://rhidoyhasanmahmud.substack.com/p/why-tps-is-a-lie-understanding-blockchain</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/why-tps-is-a-lie-understanding-blockchain</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sun, 08 Feb 2026 16:05:03 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/50c2fa61-0bd9-4c62-8cc5-0f04b306cc9a_1416x1214.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h2>&#8220;Our Blockchain Can Do 10,000 TPS!&#8221;</h2><p>If you&#8217;ve spent any time reading about blockchains, you&#8217;ve probably seen this claim:</p><blockquote><p><strong>&#8220;Our system supports 10,000 transactions per second.&#8221;</strong></p></blockquote><ul><li><p>It sounds impressive.</p></li><li><p>It sounds fast.</p></li><li><p>It sounds like the problem is already solved.</p></li></ul><p>But if you&#8217;re building <strong>IoT systems</strong>, this number can quietly mislead you.</p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><p>Because for IoT, <strong>speed alone is not the goal</strong>. What matters is <strong>when</strong> a single message gets processed.</p><p>Let&#8217;s talk about why.</p><h2>What TPS Actually Tells Us (and What It Hides)</h2><p><strong>TPS (Transactions Per Second)</strong> answers one question only:</p><blockquote><p><em>How many transactions can the system process in one second, on average?</em></p></blockquote><p>That&#8217;s it.</p><p>TPS does <strong>not</strong> tell you:</p><ul><li><p>How long does one transaction wait?</p></li><li><p>Whether a message arrives too late</p></li><li><p>How bad delays get during congestion</p></li></ul><p>For IoT systems, these missing details are often <strong>more important than TPS itself</strong>.</p><h2>A Simple Analogy: Highways and Ambulances </h2><p>Imagine a busy highway.</p><ul><li><p>10,000 cars pass every hour &#8594; <strong>high throughput</strong></p></li><li><p>But an ambulance is stuck in traffic &#8594; <strong>high latency</strong></p></li></ul><p>TPS is like counting cars. IoT systems care about the <strong>ambulance</strong>.</p><p>A fire alert, a health signal, or a control command doesn&#8217;t care how many other messages are flowing. It only cares about <strong>how fast it arrives</strong>.</p><h2>Latency: The Metric IoT Actually Cares About</h2><p><strong>Latency</strong> is simple:</p><blockquote><p><em>How long does it take for one message to be processed and confirmed?</em></p></blockquote><p>In IoT:</p><ul><li><p>A delayed alert can be useless</p></li><li><p>A late command can cause damage</p></li><li><p>A slow response can break trust</p></li></ul><p>But even here, there&#8217;s a trap.</p><h2>Why &#8220;Average Latency&#8221; Can Be Dangerous</h2><p>You&#8217;ll often see claims like:</p><blockquote><p>&#8220;Average latency is 200 ms.&#8221;</p></blockquote><p>Sounds good, right?</p><p>Now imagine this:</p><ul><li><p>90% of messages arrive in 100 ms</p></li><li><p>10% arrive after 5 seconds</p></li></ul><p>The <strong>average still looks fine</strong>.<br>But for real-time systems, those 10% can be catastrophic.</p><p>This is why averages lie.</p><h2>Meet the Metrics That Actually Matter: p95 and p99</h2><p>Instead of averages, engineers look at <strong>percentiles</strong>.</p><ul><li><p><strong>p95 latency</strong> &#8594; 95 out of 100 messages arrive within this time</p></li><li><p><strong>p99 latency</strong> &#8594; 99 out of 100 messages arrive within this time</p></li></ul><p>These numbers answer the real question:</p><blockquote><p><em>&#8220;How bad does it get when the system is under stress?&#8221;</em></p></blockquote><p>For IoT systems, <strong>worst-case behavior defines reliability</strong>, not best-case speed.</p><h2>Blockchain Makes Latency Less Predictable</h2><p>Blockchains add another complication: <strong>finality</strong>.</p><p>A transaction is not really &#8220;done&#8221; when it&#8217;s submitted.<br>It&#8217;s done when it&#8217;s <strong>confirmed and irreversible</strong>.</p><p>This often means:</p><ul><li><p>Waiting for consensus rounds</p></li><li><p>Waiting for additional blocks</p></li><li><p>Waiting &#8220;just in case&#8221;</p></li></ul><p>All of this adds <strong>extra and variable delay</strong>.</p><h2>TPS vs Latency: A Reality Check</h2><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!JuVG!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!JuVG!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 424w, https://substackcdn.com/image/fetch/$s_!JuVG!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 848w, https://substackcdn.com/image/fetch/$s_!JuVG!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 1272w, https://substackcdn.com/image/fetch/$s_!JuVG!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!JuVG!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png" width="1186" height="706" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:706,&quot;width&quot;:1186,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:126394,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/187290936?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!JuVG!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 424w, https://substackcdn.com/image/fetch/$s_!JuVG!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 848w, https://substackcdn.com/image/fetch/$s_!JuVG!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 1272w, https://substackcdn.com/image/fetch/$s_!JuVG!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe9fb75c5-e7d9-4f5f-9499-64ccc119d55c_1186x706.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>A blockchain with <strong>lower TPS but predictable latency </strong>is often a <strong>better choice</strong> for IoT systems.</p><h2>Why IoT Traffic Breaks TPS-Focused Designs</h2><p>IoT traffic is not smooth.</p><p>It is:</p><ul><li><p>Bursty</p></li><li><p>Event-driven</p></li><li><p>Unpredictable</p></li></ul><p>When many sensors trigger at once:</p><ul><li><p>Queues grow</p></li><li><p>Consensus slows</p></li><li><p>Latency spikes</p></li></ul><p>TPS benchmarks are usually measured in <strong>calm, controlled environments</strong> -<br>not during real-world IoT bursts.</p><h2>The Question We Should Be Asking Instead</h2><p>Instead of asking:</p><blockquote><p><em>&#8220;How many transactions per second can this blockchain handle?&#8221;</em></p></blockquote><p>We should ask:</p><blockquote><p><em>&#8220;Can this system guarantee bounded latency when IoT traffic spikes?&#8221;</em></p></blockquote><p>This small change in mindset leads directly to:</p><ul><li><p>Lightweight consensus</p></li><li><p>Sharding</p></li><li><p>Edge-assisted designs</p></li></ul><p>And that&#8217;s where real research begins.</p><h2>Key Takeaway</h2><blockquote><p><strong>TPS tells you how busy a system can be.<br>Latency tells you how reliable it is.</strong></p></blockquote><p>For real-time IoT systems:</p><ul><li><p>Predictability beats raw speed</p></li><li><p>Worst-case latency matters more than averages</p></li><li><p>TPS alone is never enough</p></li></ul><p><strong>References</strong></p><ul><li><p><strong><a href="https://link.springer.com/chapter/10.1007/978-3-662-53357-4_8">On Scaling Decentralized Blockchains</a></strong></p></li><li><p><strong><a href="https://dl.acm.org/doi/10.1145/2976749.2978341">On the Security and Performance of Proof of Work Blockchains</a></strong></p></li><li><p><strong><a href="https://dl.acm.org/doi/10.1016/j.future.2018.05.046">On blockchain and its integration with IoT. Challenges and opportunities</a></strong></p></li><li><p><strong><a href="https://link.springer.com/book/10.1007/978-1-4614-0676-1">Hard Real-Time Computing Systems</a></strong></p></li></ul><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item><item><title><![CDATA[Why Real-Time IoT and Blockchain Don’t Naturally Fit Together]]></title><description><![CDATA[(Part 1 of the series: When Blockchain Meets Real-Time IoT)]]></description><link>https://rhidoyhasanmahmud.substack.com/p/why-real-time-iot-and-blockchain</link><guid isPermaLink="false">https://rhidoyhasanmahmud.substack.com/p/why-real-time-iot-and-blockchain</guid><dc:creator><![CDATA[Hasan Mahmud Rhidoy]]></dc:creator><pubDate>Sun, 08 Feb 2026 06:10:38 GMT</pubDate><enclosure url="https://substack-post-media.s3.amazonaws.com/public/images/6dd1ebfc-4609-4d60-93e3-137d223ecb63_1558x872.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<h2>Introduction: Two Worlds, Two Priorities</h2><p>Modern systems increasingly rely on <strong>machines talking to machines</strong>. </p><p>For Examples: </p><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div><ul><li><p>A temperature sensor detects heat.</p></li><li><p>A heart monitor spots an anomaly.</p></li><li><p>A traffic sensor notices congestion.</p></li></ul><p>These systems are expected to react <strong>immediately</strong>.</p><p>Blockchain, on the other hand, is built for something else entirely: <strong>trust, immutability, and agreement among distributed parties</strong>.</p><p>At first glance, combining IoT and blockchain feels logical:</p><blockquote><p><em>IoT generates data, blockchain secures it.</em></p></blockquote><p>But when engineers actually try to connect them, they quickly realize something important:</p><blockquote><p>Real-time IoT and blockchain are designed with very different assumptions.</p></blockquote><h2>What Does &#8220;Real-Time&#8221; Actually Mean?</h2><p>Many people assume <strong>real-time means very fast</strong>. That&#8217;s a common misunderstanding.</p><p>In computing, <strong>real-time means predictable</strong>.</p><p>A real-time system must:</p><ul><li><p>Respond within a <strong>known time bound</strong></p></li><li><p>Meet deadlines consistently</p></li><li><p>Be considered failed if deadlines are missed</p></li></ul><p>Even if the response arrives later, it may already be useless.</p><h3>Types of Real-Time Systems</h3><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!EHjq!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!EHjq!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 424w, https://substackcdn.com/image/fetch/$s_!EHjq!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 848w, https://substackcdn.com/image/fetch/$s_!EHjq!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 1272w, https://substackcdn.com/image/fetch/$s_!EHjq!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!EHjq!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png" width="1446" height="404" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/e66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:404,&quot;width&quot;:1446,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:109192,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/187261172?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!EHjq!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 424w, https://substackcdn.com/image/fetch/$s_!EHjq!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 848w, https://substackcdn.com/image/fetch/$s_!EHjq!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 1272w, https://substackcdn.com/image/fetch/$s_!EHjq!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fe66b05e3-354c-43eb-abd9-d2eee1ee9b9b_1446x404.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Most IoT systems fall into the categories of <strong>soft or near real-time</strong>, but timing is still critical.</p><h2>Why IoT Systems Are Time-Critical by Nature</h2><p>IoT systems interact directly with the <strong>physical world</strong>. That makes the delay more than just an inconvenience.</p><p>A late fire alert, a delayed health signal, or a slow industrial controller can cause <strong>real damage</strong>.</p><p>On top of that, IoT devices are often:</p><ul><li><p>Resource-constrained</p></li><li><p>Network-dependent</p></li><li><p>Event-driven rather than request-driven</p></li></ul><p>So IoT systems care less about <em>average speed </em>and more about <em>predictable response time</em>.</p><h2>How Blockchain Handles Transactions</h2><p>Let&#8217;s simplify how blockchain processes data:</p><ol><li><p>Transactions are submitted</p></li><li><p>They wait in a pool</p></li><li><p>Validators execute consensus</p></li><li><p>A block is created</p></li><li><p>The block is confirmed and finalized</p></li></ol><p>This process is <strong>secure and fault-tolerant</strong>, but it is <strong>not time-deterministic</strong>.</p><p>Blockchain was originally designed for:</p><ul><li><p>Financial transactions</p></li><li><p>Human-triggered actions</p></li><li><p>Security over immediacy</p></li></ul><p>Not for machines that need millisecond-level guarantees.</p><h2>The Core Mismatch: Predictability vs Agreement</h2><p>Here is where the conflict becomes clear:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!hgh7!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!hgh7!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 424w, https://substackcdn.com/image/fetch/$s_!hgh7!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 848w, https://substackcdn.com/image/fetch/$s_!hgh7!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 1272w, https://substackcdn.com/image/fetch/$s_!hgh7!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!hgh7!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png" width="1456" height="430" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/d3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:430,&quot;width&quot;:1456,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:154428,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/187261172?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!hgh7!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 424w, https://substackcdn.com/image/fetch/$s_!hgh7!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 848w, https://substackcdn.com/image/fetch/$s_!hgh7!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 1272w, https://substackcdn.com/image/fetch/$s_!hgh7!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2Fd3fca377-95f0-472c-b1e2-e491ac8ac68e_1808x534.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>In real-time systems, <strong>&#8220;eventually confirmed&#8221; is not good enough</strong>.</p><h2>From Sensor to Blockchain: Where Delay Builds Up</h2><p>An IoT event doesn&#8217;t go straight to the blockchain.</p><p>It passes through multiple stages:</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!DPaR!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!DPaR!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 424w, https://substackcdn.com/image/fetch/$s_!DPaR!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 848w, https://substackcdn.com/image/fetch/$s_!DPaR!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 1272w, https://substackcdn.com/image/fetch/$s_!DPaR!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!DPaR!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png" width="600" height="621.6346153846154" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:862,&quot;width&quot;:832,&quot;resizeWidth&quot;:600,&quot;bytes&quot;:140893,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/187261172?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!DPaR!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 424w, https://substackcdn.com/image/fetch/$s_!DPaR!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 848w, https://substackcdn.com/image/fetch/$s_!DPaR!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 1272w, https://substackcdn.com/image/fetch/$s_!DPaR!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F40141f7d-3c6b-47ff-9110-68cb49662393_832x862.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p>Each stage adds delay. Each delay adds uncertainty.</p><p>The critical issue is this:</p><blockquote><p><strong>There is no guaranteed upper bound on end-to-end latency.</strong></p></blockquote><p>That alone breaks real-time assumptions.</p><h2>Why Scale Makes the Problem Worse</h2><p>Now imagine thousands or millions of IoT devices.</p><p>More devices mean:</p><ul><li><p>More transactions</p></li><li><p>More consensus messages</p></li><li><p>More network congestion</p></li><li><p>More latency variation</p></li></ul><p>Even a blockchain that works in a small setup can <strong>collapse under IoT-scale load</strong>. This is why scalability and real-time behavior are tightly connected problems.</p><h3>Why This Is a Research Problem (Not a Tuning Problem)</h3><p>This problem cannot be solved simply by:</p><ul><li><p>Increasing block size</p></li><li><p>Reducing block time</p></li><li><p>Adding more nodes</p></li></ul><p>The conflict is <strong>architectural</strong>, not configurable.</p><p>That&#8217;s why modern research explores:</p><ul><li><p>Lightweight consensus mechanisms</p></li><li><p>Sharding</p></li><li><p>Edge-assisted blockchains</p></li><li><p>Hybrid system architectures</p></li></ul><h2>Key Takeaway</h2><p>Blockchain is secure but unpredictable. IoT is fast but time-critical. Bringing them together requires redesign, not reuse.</p><div class="captioned-image-container"><figure><a class="image-link image2 is-viewable-img" target="_blank" href="https://substackcdn.com/image/fetch/$s_!5TmM!,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png" data-component-name="Image2ToDOM"><div class="image2-inset"><picture><source type="image/webp" srcset="https://substackcdn.com/image/fetch/$s_!5TmM!,w_424,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 424w, https://substackcdn.com/image/fetch/$s_!5TmM!,w_848,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 848w, https://substackcdn.com/image/fetch/$s_!5TmM!,w_1272,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 1272w, https://substackcdn.com/image/fetch/$s_!5TmM!,w_1456,c_limit,f_webp,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 1456w" sizes="100vw"><img src="https://substackcdn.com/image/fetch/$s_!5TmM!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png" width="1248" height="596" data-attrs="{&quot;src&quot;:&quot;https://substack-post-media.s3.amazonaws.com/public/images/1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png&quot;,&quot;srcNoWatermark&quot;:null,&quot;fullscreen&quot;:null,&quot;imageSize&quot;:null,&quot;height&quot;:596,&quot;width&quot;:1248,&quot;resizeWidth&quot;:null,&quot;bytes&quot;:75392,&quot;alt&quot;:null,&quot;title&quot;:null,&quot;type&quot;:&quot;image/png&quot;,&quot;href&quot;:null,&quot;belowTheFold&quot;:true,&quot;topImage&quot;:false,&quot;internalRedirect&quot;:&quot;https://rhidoyhasanmahmud.substack.com/i/187261172?img=https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png&quot;,&quot;isProcessing&quot;:false,&quot;align&quot;:null,&quot;offset&quot;:false}" class="sizing-normal" alt="" srcset="https://substackcdn.com/image/fetch/$s_!5TmM!,w_424,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 424w, https://substackcdn.com/image/fetch/$s_!5TmM!,w_848,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 848w, https://substackcdn.com/image/fetch/$s_!5TmM!,w_1272,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 1272w, https://substackcdn.com/image/fetch/$s_!5TmM!,w_1456,c_limit,f_auto,q_auto:good,fl_progressive:steep/https%3A%2F%2Fsubstack-post-media.s3.amazonaws.com%2Fpublic%2Fimages%2F1e6889ad-3b9e-445d-b19b-ff424ee4880f_1248x596.png 1456w" sizes="100vw" loading="lazy"></picture><div class="image-link-expand"><div class="pencraft pc-display-flex pc-gap-8 pc-reset"><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container restack-image"><svg role="img" width="20" height="20" viewBox="0 0 20 20" fill="none" stroke-width="1.5" stroke="var(--color-fg-primary)" stroke-linecap="round" stroke-linejoin="round" xmlns="http://www.w3.org/2000/svg"><g><title></title><path d="M2.53001 7.81595C3.49179 4.73911 6.43281 2.5 9.91173 2.5C13.1684 2.5 15.9537 4.46214 17.0852 7.23684L17.6179 8.67647M17.6179 8.67647L18.5002 4.26471M17.6179 8.67647L13.6473 6.91176M17.4995 12.1841C16.5378 15.2609 13.5967 17.5 10.1178 17.5C6.86118 17.5 4.07589 15.5379 2.94432 12.7632L2.41165 11.3235M2.41165 11.3235L1.5293 15.7353M2.41165 11.3235L6.38224 13.0882"></path></g></svg></button><button tabindex="0" type="button" class="pencraft pc-reset pencraft icon-container view-image"><svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="lucide lucide-maximize2 lucide-maximize-2"><polyline points="15 3 21 3 21 9"></polyline><polyline points="9 21 3 21 3 15"></polyline><line x1="21" x2="14" y1="3" y2="10"></line><line x1="3" x2="10" y1="21" y2="14"></line></svg></button></div></div></div></a></figure></div><p><strong>References</strong></p><ul><li><p><strong>Reyna et al. (2018)</strong> &#8211; <em>On Blockchain and Its Integration with IoT: Challenges and Opportunities. </em>A foundational paper that clearly explains the architectural mismatch between blockchain and IoT systems. <em>(Future Generation Computer Systems)</em></p></li><li><p><strong>Zhang et al. (2019)</strong> &#8211; <em>When Blockchain Meets the Internet of Things: A Survey</em><br>A well-structured survey covering performance, scalability, and latency issues in blockchain-based IoT systems.<br><em>(IEEE Communications Surveys &amp; Tutorials)</em></p></li><li><p><strong>Dorri et al. (2017)</strong> &#8211; <em>Blockchain for IoT Security and Privacy: </em>A practical case study showing why blockchain overhead becomes problematic for time-sensitive IoT environments. <em>(IEEE PerCom Workshops)</em></p></li></ul><div class="subscription-widget-wrap-editor" data-attrs="{&quot;url&quot;:&quot;https://rhidoyhasanmahmud.substack.com/subscribe?&quot;,&quot;text&quot;:&quot;Subscribe&quot;,&quot;language&quot;:&quot;en&quot;}" data-component-name="SubscribeWidgetToDOM"><div class="subscription-widget show-subscribe"><div class="preamble"><p class="cta-caption">Thanks for reading! Subscribe for free to receive new posts and support my work.</p></div><form class="subscription-widget-subscribe"><input type="email" class="email-input" name="email" placeholder="Type your email&#8230;" tabindex="-1"><input type="submit" class="button primary" value="Subscribe"><div class="fake-input-wrapper"><div class="fake-input"></div><div class="fake-button"></div></div></form></div></div>]]></content:encoded></item></channel></rss>