<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Mikhail Rodionov on Medium]]></title>
        <description><![CDATA[Stories by Mikhail Rodionov on Medium]]></description>
        <link>https://medium.com/@mikerodionov?source=rss-f672ee2ac0ed------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*8_uwFQjmkdRV7mmsSD6glA.png</url>
            <title>Stories by Mikhail Rodionov on Medium</title>
            <link>https://medium.com/@mikerodionov?source=rss-f672ee2ac0ed------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 23 Nov 2026 05:42:05 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@mikerodionov/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Troubleshooting kube-apiserver issues for the CKA exam and beyond]]></title>
            <link>https://mikerodionov.medium.com/troubleshooting-kube-apiserver-issues-for-the-cka-exam-and-beyond-2f68633d0ccd?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/2f68633d0ccd</guid>
            <category><![CDATA[cka]]></category>
            <category><![CDATA[troubleshooting]]></category>
            <category><![CDATA[containers]]></category>
            <category><![CDATA[kubernetes]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sat, 21 Nov 2026 12:09:34 GMT</pubDate>
            <atom:updated>2026-11-21T12:20:39.608Z</atom:updated>
            <content:encoded><![CDATA[<p>For a while I’ve been postponing my CKA certification, and also felt a bit blocked by the need to transition from a test-based to a performance-based certification exam. It took me setting an exam date and starting to practice with Killercoda to really get things going. The thing about the CKA exam is that the theory part is overwhelmingly vast and quite complex, and honestly doesn’t help you that much on a performance exam, where it is all about doing - not selecting the right option, but navigating product help and the CLI. Once I started just working with labs, all the volume of previously learnt theory started clicking and finding its place in practical application to real tasks and operations.</p><p>One of the largest CKA exam domains is Troubleshooting with a 30% weight, and it is also the most interesting one, IMO, as it helps you understand the mechanics of an installed cluster even better than some installation labs, through the use of tools such as crictl and logging. So let’s talk about this.</p><p><strong>crictl (Container Runtime Interface CLI)</strong> is a command-line tool used directly on a Kubernetes node to inspect and debug containers and pods managed by a CRI-compatible runtime (such as containerd or CRI-O). Unlike kubectl, which communicates over the network with kube-apiserver, crictl talks directly to the local container runtime daemon over a Unix socket on that host — making it your primary diagnostic tool whenever the Kubernetes API server is down or unresponsive.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/983/1*0F4KhmYlEXFaPXniv1YG7Q.png" /></figure><p>Similarly to Docker, crictl has ps and ps -a options.</p><p>crictl ps - List Containers on the Local Node</p><p>crictl ps is the CRI equivalent of docker ps, listing containers running on the specific host you are logged into:</p><ul><li><strong>crictl ps</strong>: Shows only currently <strong>running</strong> containers on that node.</li><li><strong>crictl ps -a</strong>: Shows <strong>all</strong> containers, including exited or crashed ones. On the CKA, -a is essential—if a control plane static pod (like kube-apiserver or etcd) has a typo in its manifest, the container crashes immediately and disappears from plain crictl ps.</li></ul><pre># List all running and stopped containers on the node<br>crictl ps -a<br># Filter for a specific control plane component<br>crictl ps -a --name kube-apiserver<br>crictl ps -a | grep etcd</pre><p>crictl logs — Read Container Output Without the API Server</p><p>crictl logs fetches the stdout and stderr streams of a container directly from the host&#39;s container runtime, acting as the local fallback for kubectl logs when the API server is unreachable.</p><ul><li><strong>Requires the Container ID:</strong> Pass the CONTAINER ID obtained from crictl ps -a (not the Kubernetes Pod name).</li></ul><pre># Print full logs for a running or exited container<br>crictl logs &lt;container-id&gt;<br># Print only the last 30 lines (useful for long crash stack traces)<br>crictl logs --tail=30 &lt;container-id&gt;<br># Stream live logs in real time<br>crictl logs -f &lt;container-id&gt;</pre><h4>Typical CKA Troubleshooting Workflow</h4><p>When kubectl fails with The connection to the server &lt;ip&gt;:6443 was refused:</p><ol><li><strong>List exited control plane containers</strong> on the control plane node:</li></ol><pre>crictl ps -a</pre><p><strong>2. Grab the ID of the </strong><strong>Exited container</strong> (for example, kube-apiserver or etcd) and inspect why it crashed:</p><pre>crictl logs &lt;container-id&gt;</pre><p><strong>3. Fix the static pod manifest</strong> in /etc/kubernetes/manifests/ based on the error message (such as an invalid CLI flag or wrong certificate path), after which kubelet automatically restarts the container.</p><p>Just to solidify our understanding, let’s compare kubectl with crictl one more time:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1S8CQBsL6ZBrkH1hxLD1BA.png" /><figcaption>kubectl vs cictl at a Glance</figcaption></figure><p>It is worth mentioning that looking directly at /var/log/pods/ or /var/log/containers/ is not a separate failure layer—it reads the exact same container-level stdout/stderr logs that crictl logs reads.</p><p>When kube-apiserver fails on a control plane node, the diagnostic path splits into <strong>two stages</strong> depending on whether the container process ever managed to start:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*o_kyfDGSLSi_BsimIYbYRw.png" /><figcaption>kubeapi troubleshooting flow</figcaption></figure><p>Now let’s look at troubleshooting process keeping these stages in mind.</p><h4>Stage 1: Pod / Manifest-Level Failure (Container Never Starts)</h4><p>If kubelet cannot parse the static pod manifest or fails to set up the Pod before launching the kube-apiserver binary, <strong>no application container is created</strong>. Because the binary never runs, crictl ps -a shows no kube-apiserver container and /var/log/containers/ has nothing to read.</p><p><strong>Common causes:</strong></p><ul><li>Broken YAML syntax or indentation in /etc/kubernetes/manifests/kube-apiserver.yaml.</li><li>Invalid Pod schema field (e.g., containers misspelled or wrong API version).</li><li>Missing or invalid hostPath mount source on the node (e.g., typo in a volume path on the host).</li><li>Typo in the container image name/tag causing an image pull failure, or kubelet itself is stopped/misconfigured.</li></ul><p><strong>How to diagnose:</strong></p><pre># Check if kubelet itself is running<br>systemctl status kubelet<br># Filter kubelet&#39;s systemd journal for static pod sync or sandbox errors<br>journalctl -u kubelet -e --no-pager | grep -i apiserver</pre><p>(Optional check: run crictl pods to see if the Pod Sandbox pause container was created even though the kube-apiserver container never started.)</p><p><strong>Verification:</strong> After fixing /etc/kubernetes/manifests/kube-apiserver.yaml, journalctl -u kubelet stops emitting sync/validation errors and crictl ps -a lists a kube-apiserver container entry.</p><h4>Stage 2: Container-Level Failure (Container Starts, Then Crashes)</h4><p>Once kubelet and containerd successfully create the Pod sandbox and launch the kube-apiserver process, any failure inside the process itself is a <strong>container-level failure</strong>. The kube-apiserver binary starts, writes its startup error to stderr, and exits immediately (Exited state in crictl ps -a).</p><p><strong>Common causes:</strong></p><ul><li>Typo in a kube-apiserver command-line flag (e.g., --etcd-serveers or --authorization-mode=Invalid).</li><li>Wrong file path <em>inside</em> the container for a TLS certificate or key (e.g., --tls-cert-file=/etc/kubernetes/pki/apiserver.crt pointing to a nonexistent path).</li><li>Unreachable etcd endpoint (wrong port/IP or etcd static pod is down).</li><li>Port 6443 already in use by another process.</li></ul><p><strong>How to diagnose (Method A — via CRI CLI):</strong></p><pre># 1. Find the exited container ID (must include -a)<br>crictl ps -a | grep kube-apiserver<br># 2. Read the crash reason from containerd<br>crictl logs &lt;container-id&gt;</pre><p><strong>How to diagnose (Method B — directly via </strong><strong>/var/log/):</strong></p><pre># Read the last 50 lines directly from the symlinked log file on disk<br>tail -n 50 /var/log/containers/*kube-apiserver*</pre><p><strong>Verification:</strong> After fixing the flag or path in /etc/kubernetes/manifests/kube-apiserver.yaml, wait ~15–20 seconds and confirm crictl ps | grep kube-apiserver shows Running (with an increasing CREATED age rather than restarting every few seconds) and kubectl get nodes responds.</p><h4>Why Look Directly at /var/log/ Instead of crictl logs?</h4><p>On every CRI-based Kubernetes node, kubelet writes container logs to /var/log/pods/&lt;namespace&gt;_&lt;pod-name&gt;_&lt;pod-uid&gt;/&lt;container-name&gt;/&lt;restart-count&gt;.log and creates symlinks inside /var/log/containers/ pointing to them. crictl logs simply fetches that same file through containerd.</p><p>Note on container/pod logs: In Kubernetes (with CRI runtimes like containerd or CRI-O), <strong>/var/log/pods/ holds the actual log files in a nested directory tree</strong>, while <strong>/var/log/containers/ is a flat directory of symlinks</strong> pointing into /var/log/pods/.</p><p>Notice one subtle detail in their naming templates — the order of &lt;pod-name&gt; and &lt;namespace&gt; is <strong>reversed</strong> between the two directories:</p><pre>SYMLINK (flat directory — &lt;pod-name&gt; comes FIRST):<br>/var/log/containers/&lt;pod-name&gt;_&lt;namespace&gt;_&lt;container-name&gt;-&lt;container-id&gt;.log<br><br>points to<br><br>ACTUAL FILE (nested tree - &lt;namespace&gt; comes FIRST):<br>/var/log/pods/&lt;namespace&gt;_&lt;pod-name&gt;_&lt;pod-uid&gt;/&lt;container-name&gt;/&lt;restart-count&gt;.log</pre><p>You go straight to /var/log/pods/ or /var/log/containers/ in three situations:</p><ol><li><strong>Rapid crash-loop rotation:</strong> If kubelet terminates and replaces a crashing container right as you run crictl ps -a, the old &lt;container-id&gt; disappears and crictl logs returns no such container. Meanwhile, /var/log/pods/kube-system_kube-apiserver-.../kube-apiserver/ keeps numbered crash files (0.log, 1.log) on disk so you can still read the previous exit error.</li><li><strong>Broken </strong><strong>crictl socket config:</strong> If /etc/crictl.yaml is missing or points to the wrong runtime socket, crictl commands fail, whereas /var/log/containers/ can always be inspected with tail or cat.</li><li><strong>Speed without looking up IDs:</strong> Running tail -n 50 /var/log/containers/*apiserver* lets you see the crash log in one step without copying a container ID first.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pk8f8zoSYITwuDeaoFDhpA.png" /><figcaption>Quick Diagnostic Decision Matrix</figcaption></figure><p>Knowing these diagnostic layers comes in handy both on the CKA exam and in real-world troubleshooting. Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2f68633d0ccd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[GCP MIG, UIG and NEG]]></title>
            <description><![CDATA[<div class="medium-feed-item"><p class="medium-feed-image"><a href="https://mikerodionov.medium.com/gcp-mig-uig-and-neg-e4221ae26725?source=rss-f672ee2ac0ed------2"><img src="https://cdn-images-1.medium.com/max/2600/1*P_ziotlRM8R6C1k68eddIA.png" width="2603"></a></p><p class="medium-feed-snippet">When I first encountered Unmanaged Instance Groups (UIG) in GCP, my immediate thought was: if this is just a Managed Instance Group (MIG)&#x2026;</p><p class="medium-feed-link"><a href="https://mikerodionov.medium.com/gcp-mig-uig-and-neg-e4221ae26725?source=rss-f672ee2ac0ed------2">Continue reading on Medium »</a></p></div>]]></description>
            <link>https://mikerodionov.medium.com/gcp-mig-uig-and-neg-e4221ae26725?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/e4221ae26725</guid>
            <category><![CDATA[multi-cloud]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[system-architecture]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[google-cloud-platform]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sun, 23 Aug 2026 15:38:41 GMT</pubDate>
            <atom:updated>2026-08-30T19:06:15.916Z</atom:updated>
        </item>
        <item>
            <title><![CDATA[Looking at the AWS Cloud Practitioner Certification from a Different Perspective]]></title>
            <link>https://mikerodionov.medium.com/looking-at-the-aws-cloud-practitioner-certification-from-a-different-perspective-c28de18f64eb?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/c28de18f64eb</guid>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[tech-career]]></category>
            <category><![CDATA[aws-cloud-practitioner]]></category>
            <category><![CDATA[beginners-guide]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sat, 15 Aug 2026 14:11:44 GMT</pubDate>
            <atom:updated>2026-08-16T12:06:03.705Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Y9BLIbwE22PAtoweoaPbqg.png" /></figure><p>So, for me being multi-cloud certified, and with 20 years of IT admin/ops/DevOps experience, the AWS Cloud Practitioner Exam looks like an extremely easy/shallow exam which feels more like a marketing vocabulary quiz than anything technical. But I recently realized that for a newcomer to the industry even after some sort of bootcamp which was covering concepts way beyond this cert, almost to the SysOps/Architect level, it can feel quite different. Someone with experience or motivation to go the extra mile with labs will do fine. But someone who just received relatively good bootcamp training can still feel a bit lost. When I see a question that can be guessed by name or answered based on basic intuition that does not require technical depth, a newbie navigating the word salad gets lost— names not telling anything, concepts and demarcation lines between them not so clear. So I guess I will write this post to highlight some things you do need to know and get it straight in your head beyond doing/watching some training and drilling practice exams — you can still pass this exam on pure memorization, but I talk here about combining both obtaining certification and a sense of really knowing the foundations.<br>So it will be kind of a list.</p><h3>1) <strong>Know the cloud computing definition</strong></h3><p>Try to internalize and really understand <a href="https://nvlpubs.nist.gov/NISTPUBS/LEGACY/SP/NISTSPECIALPUBLICATION800-145.PDF">NIST definition of cloud computing</a> (<strong>essential characteristics</strong>,<strong> service models</strong>, <strong>deployment models</strong>) along with <a href="http://docs.aws.amazon.com/whitepapers/latest/aws-overview/six-advantages-of-cloud-computing.html">AWS Six Advantages of Cloud Computing (part of the AWS Overview whitepaper)</a>— this cert is heavy on essential characteristics and the juxtaposition of those with on-premises data centers.</p><h3>2) <strong>Know Cloud Service Models</strong></h3><p>Based on clear understanding of (1) wrap your head around service models — you should be very clear why EC2 instances (aka VMs) are IaaS, and what the trade-offs are and motivations of moving along the service models continuum from IaaS, to PaaS or SaaS. If you are really serious about your learning and want to go beyond basics you may want to explore how classic service model classifications getting blurry with such services as managed Kubernetes and some others which are a very weird class of PaaS which to some feels as IaaS almost, and sometimes classified as CaaS. Though you can save these discoveries for later as this is where things get messy, and this is not what you want if you are about to take an exam. :)</p><p>When you try to wrap your head around EC2 instances and IAAS, it is a good moment to ensure solid understanding of instance types and auto scaling groups (ASGs) and how this is all linked to those abstract concepts of essential cloud characteristics (think elasticity), horizontal and vertical scaling (think instance sizes and ASGs).</p><h3>3)<strong> Be clear on the Shared Responsibility Model</strong></h3><p>Understanding (1) and (2) should position you perfectly to be clear on what the Shared Responsibility Model is — what the customer and AWS are responsible for and why it is so. You may clearly see that demarcation line or balance of how much you are responsible for vs. how much the provider is responsible for shows linear growth or decrease depending on which direction you are moving along the IaaS to SaaS continuum. Having a clear understanding of what the cloud is (1) and service delivery models (2) you probably won’t even need to resort to Pizza as a Service-alike analogies.</p><h3>4) <strong>Know Cloud Migration Scenarios and Related Design Patterns</strong></h3><p>Spend some time and try to understand the A<a href="https://aws.amazon.com/blogs/enterprise-strategy/6-strategies-for-migrating-applications-to-the-cloud/">WS 6 R’s of cloud migration scenarios</a> (Rehost, Replatform, Repurchase, Refactor, Retire, Retain), motivations behind each of those and also cloud native architecture patterns <strong>(</strong>if you want to go the extra mile here, explore <a href="https://github.com/cncf/toc/blob/main/DEFINITION.md">CNCF definition of cloud-native</a>, maybe watch <a href="https://youtu.be/d_8Vly4_ofo">“What is Cloud Native and Why Should I Care?” video</a>) — why we have message queues, what are monolith and microservices applications and how they compare against each other, and how various types of queues or messaging services enable modernization and monolith to microservices transition.</p><h3>5)<strong> Get a Basic Understanding of Cloud Networking</strong></h3><p>This is the area where even experienced professionals complain a lot that things are difficult to grasp and it is getting complicated. Obviously not at this cert level, but still clearly grasp AWS cloud networking primitives, their raison d’être, and what connects to what/what hosts what:</p><ul><li><strong>VPC (Virtual Private Cloud):</strong> The main boundary. Think of it as the fenced perimeter around your piece of land in the AWS cloud.</li><li><strong>Subnets:</strong> The rooms inside your fence. Public subnets have a door to the outside world; private subnets do not.</li><li><strong>Internet Gateway (IGW):</strong> The actual front door. If a VPC doesn’t have an IGW attached, it has no access to the public internet.</li><li><strong>Route Tables:</strong> The traffic signs. They tell network traffic exactly which path to take to leave a subnet.</li><li><strong>Security Groups vs. NACLs:</strong> Security Groups are the bouncers at the door of your specific server (EC2 instance). NACLs (Network Access Control Lists) are the security guards at the front gate of the entire subnet.</li></ul><p>So if you are an AWS cloud practitioner exam taker whose goal is not simply to pass, but keep growing and building up your understanding, you should go beyond drilling practice tests and try to pick up concepts I mentioned above and do exploration of those — discuss with AI, watch some YouTube explainer and try to reach a level where you can confidently explain those things on your own and separate those in your head to the level when it does not look spaghetti of concepts, even the ability to give not the strictest definition but at least the basic one with clear delineation of what is responsible for what positions you well ahead of the pack of rote memorizers, and levels up your future learning.</p><p>Passing the exam is great, but actually understanding the underlying architecture is what will help you in your first real cloud role. I hope this list helps you bridge that gap. What was the hardest AWS concept for you to wrap your head around when you first started? Let me know in the comments. Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c28de18f64eb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why AWS IAM Doesn’t Support Group Nesting (And Why That’s a Good Thing)]]></title>
            <link>https://mikerodionov.medium.com/why-aws-iam-doesnt-support-group-nesting-and-why-that-s-a-good-thing-3ef304489bfb?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/3ef304489bfb</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[active-directory]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[ami]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sat, 08 Aug 2026 15:05:15 GMT</pubDate>
            <atom:updated>2026-08-08T15:27:53.961Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QhGX8PcuosfqEgJCS0vYSQ.png" /></figure><p>The other day I was helping someone to work on AWS Cloud Practitioner exam preparation. Honestly, I didn’t expect to find anything new for myself. But although this exam is exceptionally light on depth, it is broad enough to remind you about the existence of services or limitations you may have buried deep in your passive memory — or that fell completely off your radar. For example, a service like the AppStream 2.0 application virtualization service was something I had totally forgotten about, whereas the fact that IAM groups do not support nesting was somewhere in my passive memory. When my mentee marked ‘IAM group nesting’ as a correct answer on a practice test, I told them to think twice. But it sparked my curiosity as I noted that both myself and a total newcomer to IT had a basic intuition that nesting should be there. I just remembered that in the case of AWS IAM it is not, but it felt awfully counter-intuitive to me as well. So let’s take a closer look at this.</p><h4><strong>AWS IAM groups do not support nesting</strong></h4><p>You cannot place an IAM group inside another IAM group. An IAM group is strictly a flat container for IAM users.</p><p>This is a very common trap on AWS certification exams, especially if you have a background in Microsoft Active Directory (where nested groups are standard practice).</p><p>If you see an exam option suggesting “put the Developer group inside the All-Employees group,” it is an <strong>automatic distractor (wrong answer)</strong>.</p><p>Here is how AWS expects you to solve complex permission overlaps instead:</p><ul><li><strong>Users in multiple groups:</strong> A single IAM user can be a member of <strong>up to 10 different IAM groups simultaneously </strong>(<a href="https://docs.aws.amazon.com/general/latest/gr/iam-service.html">source</a>). Instead of nesting, you assign the user to both the “Developers” group and the “All-Employees” group.</li><li><strong>Multiple policies per group:</strong> You can <strong>attach multiple distinct IAM policies (up to 10 managed policies) to a single group </strong>(<a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/reference_iam-quotas.html#reference_iam-quotas-entities">source</a>).</li></ul><h4>Why is that?</h4><p>AWS IAM groups do not support nesting, but what about the “why” part of this?</p><p>For a person coming from AD DS / Entra ID, group nesting is an expected feature that has always been around, and it is natural to expect the same functionality in AWS. But if you pause to think about it, AD DS group nesting brings its own share of nightmares. Anyone who has administered a large Windows environment has likely had to write complex PowerShell scripts just to unravel the ‘spaghetti nesting’ and figure out which groups a user actually belongs to. Worse, deep nesting leads directly to Kerberos ‘Token Bloat’ — where a user’s access token becomes so large from recursive group SIDs that authentication to IIS web apps or even logging into Windows starts failing. Not to mention the grueling wait times for Resultant Set of Policy (RSoP) when applying deeply nested Group Policy Objects (GPOs). From my Windows Server administration days, I still remember how this convenient feature was hitting its constraints, forcing us to rely on palliative fixes — like manually hacking the MaxTokenSize registry key across the fleet just to keep users logging in, or waiting for Windows Server 2012 to introduce Kerberos Resource SID Compression just to squeeze more nested groups into the ticket.</p><p>And what if it is all Microsoft stuff, and the “no group nesting” is something normal in the Linux realm? According to some folks, AWS is just a “fancy Linux” if you know what I mean.</p><p>That AWS being “fancy Linux” analogy is quite well grounded in the fact that the entire AWS hypervisor architecture (<strong>AWS Nitro</strong>) is literally built on a highly customized, stripped-down Linux kernel. That philosophical alignment bleeds directly into their identity management.</p><p><strong>The Linux Connection</strong></p><p>If you think about standard <a href="https://en.wikipedia.org/wiki/POSIX">POSIX</a> environments — whether you are configuring remote server workloads or just maintaining a daily driver on Fedora or Ubuntu — system groups are completely flat.</p><p>A user can have a primary group and multiple supplementary groups (like wheel, docker, or libvirt), but you cannot put a group inside another group. AWS IAM took that exact same flat-hierarchy page out of the POSIX playbook.</p><p><strong>Millisecond Math at Cloud Scale</strong></p><p>The decision to keep IAM flat isn’t just a stylistic preference; it is a hard engineering requirement for scale.</p><p>Every single API call made to AWS — from launching an EC2 instance to listing an S3 bucket — triggers an authorization check against the IAM evaluation engine. AWS processes hundreds of millions of these requests per second globally.</p><p><strong>The Nested Problem:</strong> Evaluating deeply nested Entra ID/AD groups requires recursive tree traversal. Figuring out if User A has access to Resource B might mean walking through five layers of nested groups to find the inherited permission. That adds compute time and latency.</p><p><strong>The Flat Solution:</strong> By forcing a flat structure, AWS IAM can compile a user’s permissions instantly. The engine just grabs the user’s attached policies and their direct groups’ policies, and evaluates them in a single, deterministic pass.</p><p><strong>Enterprise scale support</strong></p><p>While flat IAM groups are highly efficient for the AWS evaluation engine, they remove the ability to rely on complex group hierarchies for permissions management. To compensate, the AWS platform offers two specific architectural patterns for enterprise scale:</p><p><strong>1. Attribute-Based Access Control (ABAC)</strong></p><p>Instead of relying entirely on Role-Based Access Control (RBAC) via endless IAM groups, AWS heavily encourages ABAC using resource tags. Instead of creating a highly specific Alpha-Team-EC2-Admins group, you tag your IAM Role with Project: Alpha, and you tag the EC2 instances with Project: Alpha.</p><p>You then write one universal IAM policy using variables: <em>“Allow the </em><em>ec2:StartInstances action ONLY if the Principal&#39;s </em><em>Project tag exactly matches the Resource&#39;s </em><em>Project tag.&quot;</em> This allows permissions to scale dynamically as new resources are tagged, without requiring constant IAM policy updates.</p><p><strong>2. IAM Roles as the Perimeter</strong></p><p>For cross-team or cross-account access, you don’t put external users into local groups. Instead, you create an IAM Role in the target account with specific permissions. A user in Account A uses the sts:AssumeRole API to assume the Role in Account B. When they do, they drop their original permissions and temporarily adopt the Role’s permissions, creating a clean, auditable security boundary.</p><p>I hope this breakdown helps you navigate the shift from traditional Active Directory mindsets to AWS identity management, and gives you some solid talking points for your next architecture review or certification exam. If you’ve run into any unique ABAC edge cases, or if you have your own war stories about Kerberos token bloat, I’d love to hear about them in the comments. Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=3ef304489bfb" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Demystifying Multi-Cloud Policy: An Architect’s Guide to Azure, AWS, and GCP Governance]]></title>
            <link>https://mikerodionov.medium.com/demystifying-multi-cloud-policy-an-architects-guide-to-azure-aws-and-gcp-governance-6dc020cbc746?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/6dc020cbc746</guid>
            <category><![CDATA[azure]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[cloud-computing]]></category>
            <category><![CDATA[cloud-architecture]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sat, 25 Jul 2026 16:20:47 GMT</pubDate>
            <atom:updated>2026-07-25T16:20:47.106Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Fy-IDSPWjYJGM6uRnLzv_w.png" /></figure><p>Managing a sprawling cloud platform comprised of hundreds of Azure subscriptions (or accounts, or projects for AWS and GCP, respectively) clicking around the portal for policy assignments is a perfect recipe for disaster: configuration drift, operational risks… Governance at scale requires treating compliance as an engineering discipline.</p><p>In this blog post, I will break down the architectural mechanics of cloud policy, the operational realities of Azure Enterprise Policy as Code (EPAC) and how Azure’s approach contrasts with AWS and GCP. While discussing these things I will apply lens of respective vendor certifications intended for admins and architects to reflect vendor promoted use cases and operational knowledge requirements.</p><h3>1. Azure Policy Core Architecture (The AZ-104 / AZ-305 Lens)</h3><p>Azure Policy is a unified governance engine that evaluates resource state against business rules at the<strong> Azure Resource Manager (ARM)</strong> layer. Before a resource is created or updated, ARM intercepts the request and evaluates it against your assigned policies.</p><h4><strong>Scope and Inheritance</strong></h4><p>Policy assignments cascade hierarchically: <strong>Management Group (MG) → Subscription → Resource Group (RG) → Resource</strong>. A policy applied at an upper MG inherently governs all hundreds of subscriptions beneath it. Continuous evaluation cycles (typically every 24 hours) ensure that existing resources haven’t drifted out of compliance.</p><h4><strong>Evaluation Modes</strong></h4><p>In the raw JSON of an Azure Policy definition, mode is a single string property. You must choose exactly one: &quot;mode&quot;: &quot;Indexed&quot;, &quot;mode&quot;: &quot;All&quot;, <strong>OR</strong> &quot;mode&quot;: &quot;Microsoft.KeyVault.Data&quot;.</p><ul><li><strong>Indexed:</strong> Evaluates resource types that support standard tags and locations. This is the go-to mode for 90% of structural policies (e.g., enforcing geographic regions or billing tags).</li><li><strong>All:</strong> Evaluates resource groups, subscriptions, and all resource types. Required when targeting properties nested deep within an ARM template or when <strong>governing Resource Groups directly</strong>.</li><li><strong>Resource Provider Modes:</strong> (e.g., Microsoft.Kubernetes.Data, Microsoft.KeyVault.Data) Used to reach beyond ARM and evaluate data-plane configurations inside specific services.</li></ul><p>That Indexed mode definition above is a bit confusing because in reality Indexed mode excludes <strong>Resource Groups</strong> (which <strong>support both tags and locations</strong>) and <strong>Subscriptions</strong> (which <strong>support</strong> <strong>tags</strong>, but not region-bound).</p><p><strong>Azure Policy explicitly excludes Subscriptions and Resource Groups from the </strong><strong>Indexed evaluation mode</strong>.</p><p>In the eyes of the Azure Resource Manager (ARM), Subscriptions and Resource Groups are foundational <strong>“hierarchy nodes” (scopes)</strong>, not standard manageable resources like a Storage Account or a Virtual Machine.</p><p>To prevent a broad Indexed tag or location policy from accidentally blocking the creation of foundational hierarchy structures, Microsoft hardcoded the engine to skip them.</p><p>Having said that, the exact formula for Indexed is:</p><p><em>Indexed = (Resource types that natively support tags AND locations) - (Resource Groups + Subscriptions)</em></p><p>So apart from the subscriptions and resource groups the other skipped resources are:</p><ul><li><strong>Child Resources:</strong> Microsoft.Network/virtualNetworks/subnets (Subnets live inside a VNet; you tag the VNet, not the Subnet).</li><li><strong>Extension Resources:</strong> Microsoft.Authorization/roleAssignments or Microsoft.Authorization/locks (These are applied <em>over</em> a resource; they don&#39;t have a location).</li><li><strong>Certain Global/PaaS Resources:</strong> Various integrations or specific global offerings that don’t take standard ARM tags or locations.</li></ul><p>Because of this hardcoded exemption for subscriptions and resource groups whenever you need to manage them with policy we need:</p><ol><li>Set the evaluation mode to All.</li><li>Specifically target the resource type in your policyRule if block using Microsoft.Resources/subscriptions/resourceGroups or Microsoft.Resources/subscriptions.</li></ol><h4><strong>The Power of Effects</strong></h4><p>Policies are defined by their effects, mapping directly to your security posture:</p><ul><li><em>Detective:</em> Audit, AuditIfNotExists (<strong>AINE</strong>)</li><li><em>Preventive:</em> Deny (Blocks the PUT/PATCH request instantly)</li><li><em>Reactive/Remediation:</em> Modify, Append, DeployIfNotExists (<strong>DINE</strong>)</li></ul><h4>Advanced Details</h4><p><strong>Exclusions vs. Exemptions:</strong> Do not mix these up. <strong>Exclusions</strong> (NotScopes) are defined within the assignment itself to permanently carve out a branch of your hierarchy (e.g., ignoring a sandbox RG). <strong>Exemptions</strong> are separate, tracked Azure resources used for temporary, time-bound waivers (e.g., a 30-day grace period for a specific VM, usually tied to a Jira/ServiceNow ticket).<br>To illustrate these two items, below is an example of a NotScopes array within a policyAssignment object and of policyExemption JSON.</p><pre>{<br>  &quot;type&quot;: &quot;Microsoft.Authorization/policyAssignments&quot;,<br>  &quot;apiVersion&quot;: &quot;2024-04-01&quot;,<br>  &quot;name&quot;: &quot;enforce-cost-center&quot;,<br>  &quot;properties&quot;: {<br>    &quot;displayName&quot;: &quot;Enforce CostCenter Tag&quot;,<br>    &quot;policyDefinitionId&quot;: &quot;/providers/Microsoft.Authorization/policyDefinitions/1e30110a-5ceb-460c-a204-c1c3969c6d62&quot;,<br>    &quot;scope&quot;: &quot;/subscriptions/11111111-2222-3333-4444-555555555555&quot;,<br>    &quot;notScopes&quot;: [<br>      &quot;/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg-sandbox-01&quot;,<br>      &quot;/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg-ephemeral-builds&quot;<br>    ],<br>    &quot;enforcementMode&quot;: &quot;Default&quot;<br>  }<br>}</pre><pre>{<br>  &quot;type&quot;: &quot;Microsoft.Authorization/policyExemptions&quot;,<br>  &quot;apiVersion&quot;: &quot;2022-07-01-preview&quot;,<br>  &quot;name&quot;: &quot;ticket-INC12345-waiver&quot;,<br>  &quot;scope&quot;: &quot;/subscriptions/11111111-2222-3333-4444-555555555555/resourceGroups/rg-prod-app/providers/Microsoft.Compute/virtualMachines/vm-legacy-01&quot;,<br>  &quot;properties&quot;: {<br>    &quot;policyAssignmentId&quot;: &quot;/subscriptions/11111111-2222-3333-4444-555555555555/providers/Microsoft.Authorization/policyAssignments/enforce-cost-center&quot;,<br>    &quot;exemptionCategory&quot;: &quot;Waiver&quot;,<br>    &quot;expiresOn&quot;: &quot;2026-08-25T00:00:00Z&quot;,<br>    &quot;metadata&quot;: {<br>      &quot;ticketRef&quot;: &quot;JIRA-9876&quot;,<br>      &quot;approvedBy&quot;: &quot;Platform SecOps&quot;<br>    }<br>  }<br>}</pre><p>Exclusions (NotScopes) and exemptions have important operational differences:</p><ol><li><strong>Immutability vs. Agility:</strong> To add a notScope, you must run a PUT request to update the core Policy Assignment itself (which triggers a full re-evaluation cycle and carries operational risk). To add an Exemption, you just deploy a net-new independent resource without touching the core assignment.</li><li><strong>Expirations:</strong> notScopes are permanent structural carve-outs. Exemptions support the expiresOn property natively, making them self-cleaning waivers for technical debt.</li></ol><p><strong>DINE and Managed Identities:</strong> A DeployIfNotExists policy doesn&#39;t just evaluate state; it actively triggers an ARM deployment to fix it. To do this, the policy assignment requires a Managed Identity with precise Role-Based Access Control (RBAC) permissions on the target scope.</p><h3>2. EPAC and the Operational Reality</h3><p>Writing complex Azure Policy JSON from scratch is tedious and error-prone. In reality, the community-driven repository <a href="https://www.azadvertizer.net/">azadvertizer.net</a> indexes all out-of-the-box policies. If you cannot find a built-in policy or a community template for your use case, you should question if you are approaching the architecture correctly.</p><h4><strong>Enterprise Policy as Code (EPAC)</strong></h4><p><em>EPAC shifts governance left</em>. It allows you to treat definitions, assignments, and exemptions as version-controlled code deployed via CI/CD pipelines. EPAC automatically calculates delta changes, manages the rollout across environments, and handles the complex role assignments required for DINE identities.</p><h4><strong>Brownfield Rollouts and Blast Radius</strong></h4><p>Enterprise environments are rarely greenfield; they are often messy, with fractured application ownership. Deploying a broad Deny or DINE policy in a brownfield environment is dangerous. The architect&#39;s rollout pattern is:</p><ol><li>Deploy the policy in Audit mode.</li><li>Gather compliance state telemetry over 30 days.</li><li>Engage application owners to remediate resources or document business justification.</li><li>Create targeted Exemptions for approved legacy technical debt.</li><li>Flip the assignment to Deny to stop the bleeding on all <em>new</em> deployments.</li></ol><h3>3. The Multi-Cloud Arena: Azure vs. AWS vs. GCP</h3><h4><strong>The Certification Lens: What Associate vs. Pro Exams Actually Test</strong></h4><p>When preparing for cloud certifications or technical interviews, understanding <em>what</em> each vendor prioritizes in their policy engine is half the battle:</p><ul><li><strong>Azure (AZ-104 / AZ-305):</strong> Associate exams test your knowledge of Effects (especially Audit vs. Deny) and the hard limits of what Indexed evaluates. Architect exams focus heavily on the operationalization of DeployIfNotExists (DINE) with Managed Identities, and how to structure Management Groups to avoid overlapping assignments.</li><li><strong>AWS (SAA / SAP):</strong> The entire focus of AWS policy exams revolves around the intersection of Identity and boundaries. You must master how <strong>Service Control Policies (SCPs)</strong> at the AWS Organization level interact with local IAM policies. The golden rule tested relentlessly: <em>An explicit Deny in an SCP always overrides an Allow in IAM.</em></li><li><strong>GCP (ACE / PCA):</strong> Google exams heavily index on the hierarchical nature of Organization Policies and the difference between boolean constraints (toggles) and list constraints (allowed/denied values), particularly for enforcing data residency and restricting public IPs.</li></ul><p>While all three clouds aim for secure governance, their architectural execution differs vastly.</p><p><strong>AWS SCPs vs. Azure Policy:</strong> AWS Service Control Policies (SCPs) act as a rigid IAM security filter. They do not grant permissions; they set the absolute maximum permissions for an Organizational Unit (OU). An SCP Deny will ruthlessly override any local IAM Allow. Azure Policy evaluates the <em>resource configuration state</em>, whereas an SCP evaluates the <em>identity&#39;s permission boundary</em>.</p><p><strong>The “One Tool vs. Many” Architecture:</strong> Azure Policy centralizes prevention, detection, and remediation in a single engine. AWS splits this responsibility: you use SCPs to prevent actions at the account level, AWS Config to detect misconfigurations, and EventBridge coupled with Lambda/SSM to remediate them.</p><p><strong>GCP Organization Policies:</strong> GCP relies on hierarchical Org Policies that function as simple, powerful constraints (e.g., Boolean toggles like “Disable external IP on VMs” or List constraints). For deeper, complex resource state evaluation, GCP leans on its Security Command Center.</p><p>We can look at the differences by features and their implementation in Azure/AWS/GCP.</p><h4>Primary Mechanism</h4><p>While Azure Policy uses unified ARM-level evaluation, AWS (SCPs + Config) has a split between SCPs (IAM bounds) and Config (state), GCP uses Org Policies (resource hierarchy constraints).</p><h4>Preventive Control</h4><p>Azure Policy Deny effect blocks ARM requests. AWS SCPs block actions at the IAM evaluation layer. GCP Org Policies use boolean/list constraints block API calls.</p><h4>Detective Control</h4><p>Azure Policy uses Audit effect for continuous compliance. AWS Config Rules evaluate resource state. GCP Asset Inventory / Security Command Center (SCC).</p><h4>Reactive Remediation</h4><p>Azure Policy offers native built-in DeployIfNotExists (DINE) / Modify options. AWS Config Rules trigger Systems Manager (SSM) or Lambda. GCP requires Cloud Functions triggered by Eventarc.</p><h4><strong>Attachment Points and Inheritance Behavior by Cloud</strong></h4><p>The physical “hook” where you attach a policy dictates how it cascades down to resources. Each cloud handles this hierarchy slightly differently:</p><p><strong>Azure (Management Groups → Subscriptions → Resource Groups):</strong> Policies are evaluated cumulatively. If a Management Group assigns a Deny for public IPs, a Subscription underneath it cannot override it with an Allow. However, Azure allows you to attach <em>Exemptions</em> directly at the Resource or Resource Group level to bypass the inherited MG policy.</p><p><strong>AWS (Root → Organizational Units (OUs) → Accounts):</strong> SCPs are attached to the Root, OUs, or individual Accounts. AWS inheritance is a strict filtering mechanism. If an OU-level SCP denies the ec2:RunInstances action, no account within that OU can launch a VM, regardless of whether the user has full Administrator IAM privileges.</p><p><strong>GCP (Organization → Folders → Projects):</strong> Org Policies attach to nodes in the Resource Hierarchy. GCP has a <strong>unique inheritance model</strong>: by default, policies merge down the tree. However, unlike AWS SCPs, a GCP Project Administrator <em>can</em> overwrite an inherited list constraint unless the parent Organization explicitly set the policy to prevent overrides.</p><h3>4. Architectural Patterns and Anti-Patterns</h3><p>When managing a large-scale platform with huge number of subscriptions, the theory of governance collides hard with operational reality. Here are the common patterns (and traps) to watch for.</p><p><strong>Pattern: The Management Group Baseline</strong> The undisputed gold standard for Azure governance is attaching structural policies (e.g., allowed regions, mandatory cost-center tags, Defender for Cloud enablement) at the Management Group level via EPAC. This ensures that every new subscription dropped into the MG is instantly compliant without manual intervention.</p><p><strong>Pattern: The Localized Pipeline Override (The RSV Reality)</strong> You might look at a setup where policies are assigned per-subscription or per-region — for example, a backup policy specifically pointing to a Recovery Services Vault (RSV) dedicated to that exact subscription and region — and wonder: <em>Is this an anti-pattern?</em></p><p><strong>No, it is a highly effective operational pattern.</strong> While the purist view says “assign everything at the MG,” the reality of data residency and provider architecture dictates otherwise. Azure Backup RSVs are inherently regional. A global MG policy trying to deploy a backup configuration via DINE would require complex parameter mapping to figure out <em>which</em> regional RSV to use for a VM in West Europe vs. East US. Pushing a targeted policy assignment via your CI/CD pipeline at the subscription/region level to map to the exact local RSV is a pragmatic, scalable solution to overcome cross-region restore complexities.</p><p>NOTE: This RSV example can be challenged/or designed differently nowadays, as although historically, Azure Backup was rigidly bound to the vault’s region and subscription. Over the last two years, Microsoft has significantly decoupled this, turning RSV into a much more flexible disaster recovery mechanism — including Cross Subscription Restore (CSR) within the same tenant, Cross Region Restore (CRR) between paired regions and Cross Zonal Restore (CZR). But even with mentioned RSV improvements approach with RSV per subscription/region wins for large scale environments because of factors such as: blast radius and security, API throttling, and the overall intent of the CSR architecture is special recovery cases (e.g., restoring a compromised prod VM into an isolated forensics subscription) and not for daily operational architecture.</p><p><strong>Anti-Pattern: Subscription-Level Sprawl</strong> While the RSV pipeline deployment is a valid <em>automated</em> pattern, manually clicking around to create ad-hoc policy assignments on individual subscriptions is a massive anti-pattern. It leads to configuration drift, orphaned policies, and makes it impossible to predict the blast radius of a change. If it is not in EPAC or your IaC pipeline, it shouldn’t exist.</p><p><strong>Anti-Pattern: The Brownfield DINE</strong> Never deploy a DeployIfNotExists policy into a brownfield environment without an Audit phase. DINE will aggressively attempt to modify resources to match the desired state. If application owners rely on legacy configurations, an unexpected DINE rollout can break applications at scale and overwhelm your platform team with troubleshooting tickets.</p><h3>5. Final Thoughts/things to remember</h3><p><strong>ADR Integration:</strong> Technical policy assignments should directly reflect your Architecture Decision Records (ADRs). If an ADR dictates “All storage must be encrypted with Customer-Managed Keys,” your EPAC pipeline is the mechanism that translates that business decision into a strict Azure Policy.</p><p><strong>RBAC vs. Policy:</strong> Clearly delineate that RBAC controls <em>who</em> can perform an action, while Policy controls <em>what</em> the configuration of the resource must be. Both are evaluated independently at the ARM layer; a valid RBAC permission will still fail if the deployment violates a Deny policy.</p><p>I hope this breakdown helps you navigate the complexities of multi-cloud governance and gives you some solid talking points for your next architecture review or interview. If you’ve run into any unique policy edge cases, or if you have your own EPAC deployment strategies, I’d love to hear about them in the comments. Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6dc020cbc746" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[From “Fort Knox” to Internet Fallback: The Evolution of Azure Private Endpoint DNS]]></title>
            <link>https://mikerodionov.medium.com/from-fort-knox-to-fallback-the-evolution-of-azure-private-endpoint-dns-58e6bf9978bf?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/58e6bf9978bf</guid>
            <category><![CDATA[dns]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[azure]]></category>
            <category><![CDATA[terraform]]></category>
            <category><![CDATA[cloud-architecture]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Wed, 20 May 2026 19:38:55 GMT</pubDate>
            <atom:updated>2026-05-20T19:48:13.576Z</atom:updated>
            <content:encoded><![CDATA[<p>If you’ve been building enterprise Azure environments for a few years, you remember when PaaS networking was simple: absolutely no public access. If a service supported it, you deployed a Private Endpoint (PE) to secure it.</p><p>We can call this the “Fort Knox” era of Azure networking. The default was brutal but highly secure. While this zero-trust approach was great for compliance, it created massive operational overhead. Why? Because the moment you linked a Private DNS Zone to your Virtual Network (VNet), you effectively hijacked the entire namespace for that service.</p><p>To understand why this happens, we need to cut through the barrage of Microsoft documentation and look at how Private Endpoints actually manipulate DNS.</p><h4>Demystifying the DNS Jargon: How PE Actually Works</h4><p>When reading Microsoft docs, you will frequently see terms like <strong>QNAME</strong> and <strong>CNAME redirection</strong>. Let’s translate that into plain English.</p><p><strong>QNAME (Query Name)</strong> is simply the exact web address your application is asking for. If your app queries mystorage.blob.core.windows.net, that string is the QNAME.</p><p>Here is the exact step-by-step flow of what happens when your app makes that request:</p><ol><li><strong>The Initial Request:</strong> Your application asks Azure’s built-in DNS (168.63.129.16) for mystorage.blob.core.windows.net.</li><li><strong>The CNAME Handover:</strong> Azure’s public DNS intercepts this and says, “I don’t have an IP for that, but here is a CNAME (alias) instead: look for mystorage.privatelink.blob.core.windows.net.&quot;</li><li><strong>The Private Zone Check:</strong> Azure DNS checks if your VNet is linked to a Private DNS Zone named privatelink.blob.core.windows.net.</li><li><strong>The Resolution:</strong></li></ol><ul><li>If Azure <strong>finds</strong> the record (because PE auto-registered it), it returns the private IP (e.g., 10.0.1.5).</li><li>If Azure <strong>does not find</strong> the record, it assumes the resource doesn’t exist and returns a fatal <strong>NXDOMAIN</strong> (Non-Existent Domain) error. It <em>stops looking</em>.</li></ul><h4>The Mixed-Access Nightmare (Split-Brain DNS Trap)</h4><p>This “stop looking” behavior is the root of the problem. Because your Private DNS Zone is authoritative for the privatelink sub-domain, Azure DNS refuses to look anywhere else. In Azure architecture, this is known as a <strong>DNS Override</strong> or the <strong>Split-Brain DNS trap. </strong>Network engineers sometimes also use the slang term <strong>“Zone Shadowing”</strong> or <strong>“DNS Shadowing”</strong> to describe the internal problem where a local DNS zone hides the public Internet zone.</p><p>As architectures evolved, companies started needing “mixed access.” For example, your internal app uses Private Endpoints for corporate data, but it also needs to download a file from a public, cross-tenant vendor storage account.</p><p>Because both use the same .blob.core.windows.net suffix, your VNet routes the vendor&#39;s query into your Private DNS Zone. Since the vendor&#39;s storage account doesn&#39;t have a Private Endpoint in your VNet, the record is missing. The query returns an NXDOMAIN error, and the connection fails.</p><p>For years, the only workaround was manual maintenance: engineers had to find the public IP of the vendor’s storage account and manually hardcode it into the corporate Private DNS Zone.</p><h4>The Fix: Fallback to Internet Resolution</h4><p>Thankfully, Microsoft recognized that strict DNS precedence was breaking modern, multi-tenant architectures. The solution is a native toggle on the Virtual Network Link known programmatically as ResolutionPolicy.</p><p>Available in <strong>API version 2024–06–01 or higher</strong>, you can now set the resolution policy at the virtualNetworkLinks resource level to NxDomainRedirect. In the Azure Portal, this is simply a checkbox labeled <strong>&quot;Enable fallback to internet.&quot;</strong></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bNxnWWnfNDE-JW9O_NYoqQ.png" /><figcaption>The ‘Enable fallback to internet’ property of a VNet link in the Azure Portal.</figcaption></figure><p><strong>How it changes the flow:</strong></p><p>Now, if Azure DNS checks your private zone and doesn’t find a matching Private Endpoint, it doesn’t just give up. It falls back to public recursion using the original QNAME to find the public IP. This single toggle allows enterprises to maintain strict internal PE routing without breaking outbound connectivity to external, public SaaS services.</p><p>Here is what it looks like in Bicep:</p><pre>resource vnetLink &#39;Microsoft.Network/privateDnsZones/virtualNetworkLinks@2024-06-01&#39; = {<br>  name: &#39;link-to-vnet&#39;<br>  parent: privateDnsZone<br>  location: &#39;global&#39;<br>  properties: {<br>    virtualNetwork: {<br>      id: vnetId<br>    }<br>    registrationEnabled: false<br>    resolutionPolicy: &#39;NxDomainRedirect&#39; // Fallback to Azure DNS for unresolved queries<br>  }<br>}</pre><p>And in Terraform, if you prefer multi-cloud gold standard :) :</p><pre>resource &quot;azurerm_private_dns_zone_virtual_network_link&quot; &quot;vnet_link&quot; {<br>  # 1. The Dynamic Naming Convention<br>  name                  = &quot;${azurerm_virtual_network.example.name}-link&quot;<br>  <br>  resource_group_name   = azurerm_resource_group.example.name<br>  private_dns_zone_name = azurerm_private_dns_zone.example.name<br>  virtual_network_id    = azurerm_virtual_network.example.id<br>  <br>  registration_enabled  = false<br>  <br>  # 2. The &quot;Fallback to Internet&quot; Toggle<br>  resolution_policy     = &quot;NxDomainRedirect&quot; <br>}</pre><h4>AMPLS and Centralized DNS: But Wait, There’s More :)</h4><p>While NxDomainRedirect solves the external PaaS problem, large enterprises using a <strong>Hub-and-Spoke topology with centralized DNS forwarders</strong> face a different, much newer Private Link headache: <strong>Azure Monitor Private Link Scope (AMPLS)</strong>.</p><p>If you are routing all your DNS through a central Hub VNet, you must be incredibly careful with AMPLS. Unlike a Storage Account which has a unique URL, Azure Monitor uses <strong>global and regional endpoints</strong> (e.g., api.loganalytics.io).</p><p><strong>The Trap:</strong> If you create a separate AMPLS object for <em>each</em> spoke VNet, they will all try to write records for the exact same global endpoints into your centralized Private DNS Zone. The last AMPLS created will override the DNS entries, mapping the global endpoints to its own private IP range. Every other spoke VNet will suddenly lose monitoring connectivity because their traffic is being blackholed to an IP in a different, unpeered spoke.</p><p><strong>The Solution:</strong> In a Hub-and-Spoke architecture with shared DNS, you must create <strong>only a single AMPLS object</strong> in the Hub network and attach all Azure Monitor resources to it.</p><p>Private Endpoints simplify security, but they demand absolute respect for DNS hierarchy. Whether you are battling NXDOMAIN traps or AMPLS global overrides, the rule remains the same: in Azure, whoever controls the DNS zone, controls the traffic.</p><h4>Further Reading &amp; Official Documentation</h4><p><a href="https://learn.microsoft.com/en-us/azure/dns/private-dns-fallback"><strong>Azure Private DNS fallback to the internet (NxDomainRedirect)</strong></a> - The official Microsoft documentation detailing the `ResolutionPolicy` property.</p><p><a href="https://learn.microsoft.com/en-us/azure/private-link/private-endpoint-dns"><strong>Azure Private Endpoint DNS Integration</strong></a> - The deep dive into how Azure handles QNAME and CNAME redirection across different PaaS services.</p><p><a href="https://learn.microsoft.com/en-us/azure/azure-monitor/logs/private-link-design"><strong>Design Azure Monitor Private Link Setup (AMPLS)</strong></a> - Microsoft’s architectural guidance on using a single AMPLS in Hub-and-Spoke topologies to avoid global endpoint overrides.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=58e6bf9978bf" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Error streams in Linux and beyond]]></title>
            <link>https://mikerodionov.medium.com/error-streams-in-linux-and-beyond-c7bc47d5515e?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/c7bc47d5515e</guid>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[devops]]></category>
            <category><![CDATA[platform-engineering]]></category>
            <category><![CDATA[tech-interview]]></category>
            <category><![CDATA[design-systems]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Tue, 19 May 2026 21:17:17 GMT</pubDate>
            <atom:updated>2026-10-15T18:12:11.850Z</atom:updated>
            <content:encoded><![CDATA[<p>The other day I had an interesting conversation. It wasn’t perfect, but I tend to learn from every conversation I partake in. Although this post focuses on some technical details, the main message probably has nothing to do with them — I will leave that to the reader’s judgement. Let’s talk a little bit about the manifestations of the output stream segmentation concept and look at some examples.</p><h4>1. Unix Standard Streams — The Foundation</h4><p>The official term is standard streams (or standard I/O streams), defined by POSIX. There are exactly three:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/967/1*lv7VSQ0JJTiHv20Pwtt7YQ.png" /><figcaption>Unix Standard Streams</figcaption></figure><p>That’s it — Unix doesn’t have “warning” or “info” streams. It’s a binary split: output vs. diagnostics. The power of this implementation is that they’re independently redirectable (see example below). This comes from <strong>the file descriptor (FD) model</strong> — everything is a file, streams are just FDs 0, 1, 2 opened automatically by the kernel for every process.</p><pre>command &gt; output.txt 2&gt; errors.txt # separate<br>command &gt; all.txt 2&gt;&amp;1             # merge<br>command 2&gt;/dev/null                # suppress errors</pre><p>If you are attentive to details, the usage of spaces around the greater than sign/redirect operator may jump out at you as somewhat inconsistent in theexamples above — but there is a logic to the madness. Or better said, in shell redirection, and it literally boils down to one hard rule: no space between the FD number and &gt;. The 2&gt; is parsed as a single redirection token. If you write 2 &gt;, the shell interprets 2 as a literal argument to the command and &gt; as redirecting stdout (FD 1).</p><h4>2. Was Unix First? — Historical Predecessors</h4><p>No. Unix (1969–71) popularized it, but the concept has roots:</p><ul><li>Fortran (1957) had “logical unit numbers” — numbered I/O channels. Unit 5 = card reader (input), Unit 6 = printer (output). This is arguably the earliest separation of I/O channels in programming.</li><li>Multics (1964–69) — Unix’s direct ancestor — had separate I/O streams and the concept of redirectable I/O. Ken Thompson and Dennis Ritchie explicitly carried this forward.</li><li>IBM mainframes (1960s) had SYSIN, SYSOUT, SYSERR (JCL DD statements) — literally stdin/stdout/stderr by different names, predating Unix.</li></ul><p>So the seminal idea is really from the batch processing era — the need to separate “what the program produces” from “what went wrong” existed as soon as you had unattended jobs where you couldn’t watch the console. Unix’s contribution was making it elegant, composable, and universal via pipes and FDs.</p><h4>3. Windows NT &amp; ETW — The Structured Counter-Revolution</h4><p>If Unix built its world around the philosophy that “everything is a file” and flat text streams, the architects of Windows NT took a radically different, heavily structured approach to OS-level segmentation.</p><p>To understand why, you have to look at the OS’s lineage. Windows NT’s chief architect, Dave Cutler (whose obsessive drive is famously chronicled in <a href="https://www.amazon.es/Showstopper-breakneck-Windows-generation-Microsoft-ebook/dp/B0GD26T869">G. Pascal Zachary’s book <em>Showstopper!</em></a>), came from building the VMS operating system at DEC. He famously viewed Unix as a “junk operating system” with a weak, hacker-centric architecture. He demanded NT be built from the ground up for strict, enterprise-grade reliability.</p><p>Consequently, the NT kernel architecture eventually gave us <strong>Event Tracing for Windows (ETW)</strong>. Instead of piping flat text out to stdout or stderr and leaving the formatting to the user, Windows uses this high-performance, kernel-level tracing facility.</p><p>It separates the logging ecosystem into three distinct roles:</p><ul><li><strong>Providers:</strong> Applications emitting structured binary data.</li><li><strong>Controllers:</strong> Entities starting and stopping the tracing sessions.</li><li><strong>Consumers:</strong> The subscribers reading the formatted data.</li></ul><p>This architecture essentially allowed to implement <strong>zero-blocking binary routing</strong>.</p><p>The geeky brilliance of ETW is that it completely bypasses the limitations of text-stream multiplexing. When an application logs an error via ETW, it isn’t writing a string to a file descriptor. It drops a binary struct directly into non-paged, per-processor memory buffers in the kernel. The application thread can then keep executing in fractions of a microsecond, while a background kernel worker handles flushing that buffer to disk.</p><p>Because it is structured from the ground up, ETW natively segments data using structured manifests — separating error levels, keywords, and channels at the kernel level <em>before</em> the data is ever rendered. Unlike the CI runners we will look at next, which have to hack metadata into stdout using magic text prefixes like ##vso, ETW never relies on text parsing. It relies on a rigorous, out-of-band binary protocol—exactly the kind of engineered structure the original NT team favored over Unix pipes.</p><h4>4. PowerShell — Multiple Named Streams</h4><p>PowerShell expanded the Unix 3-stream model into 6+ numbered streams (as of PS 5.1+):</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*O5I9Ql5ZL_kJwx5HsTHNnA.png" /><figcaption>PowerShell Numbered Streams</figcaption></figure><p>Redirection uses the same &gt; syntax but with stream numbers:</p><pre>command 3&gt; warnings.txt # redirect warnings<br>command *&gt; all.txt      # redirect everything<br>command 4&gt;&amp;1            # merge verbose into output</pre><p>Key design difference from Unix: Stream 1 (Output) carries typed .NET objects, not text. This is fundamental — PowerShell’s pipeline is an object pipeline, so the separation between “data that flows through the pipe” (stream 1) and “everything else” (streams 2–6) is critical. Write-Host originally bypassed all streams (console-only); stream 6 was added in PS 5.0 to fix this.</p><p>The preference variables let you suppress or escalate per-stream, which is essentially a built-in log-level filter — something Unix leaves to the application (via syslog levels).</p><h4>5. Azure DevOps — Logging Commands</h4><p>ADO has the similar idea in the form of the logging commands, and the syntax is:</p><pre>##vso[task.logissue type=warning]This is a warning<br>##vso[task.logissue type=error]This is an error<br>##vso[task.setvariable variable=myVar]value<br>##vso[task.debug]Debug message</pre><p>Why so ugly? Initially I thought it was some kind of C# influence, but actually, it’s a pragmatic in-band signaling hack which has the following reasoning behind it:</p><ul><li>ADO tasks run as child processes. The agent reads their stdout line by line.</li><li>There’s no structured communication channel (no API, no socket, no separate FD).</li><li>So they needed a magic prefix that’s unlikely to appear in normal output: ##vso</li><li>This is essentially the same technique as ANSI escape codes (\e[31m for red) — embedding control instructions in a text stream.</li></ul><p>The ##vso prefix was chosen because ## is a comment in many languages and unlikely to start a real output line, and vso = Visual Studio Online (ADO&#39;s original name from ~2013). It&#39;s ugly because in-band signaling is inherently ugly — you&#39;re overloading one channel to carry both data and metadata. And the bracket-command syntax [command arg=val]message resembles a simplified IRC/chat protocol more than C#.</p><h4>6. GitHub Actions — Workflow Commands</h4><p>GitHub uses the exact same in-band signaling pattern but with a different prefix (no easter egg references to predecessor product here :) ):</p><pre>::error::This is an error<br>::warning::This is a warning  <br>::notice::This is a notice<br>::debug::Debug message<br>::group::Group title<br>::set-output name=result::value # deprecated<br>::error file=app.js,line=10,col=5::Something failed</pre><p>The ::command:: syntax is cleaner than ADO&#39;s ##vso[...] — GitHub clearly learned from ADO&#39;s verbosity. They also support file annotations that map errors to specific lines in PR diffs, which is a nice touch.</p><p>Both ADO and GH use the same fundamental mechanism: stdout is the only reliable channel between a step process and the runner agent, so you encode structured messages as specially-prefixed lines.</p><h4>Common Concept? Differences?</h4><p>All the implementations listed above solve the same core problem:</p><blockquote>Separate structured metadata (errors, warnings, debug info) from primary output data.</blockquote><p>But there are meaningful architectural differences:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8p-9UCp7XI4oseleIb3abQ.png" /><figcaption>Output segmentation techniques comparison</figcaption></figure><p>This is probably the only thing one can miss by over-simplifying: Unix streams are an OS primitive (kernel file descriptors), PowerShell streams are a runtime abstraction (the .NET runtime multiplexes them), and CI logging commands are a text protocol (application-layer encoding). They’re at three different layers of the stack, solving the same human need with very different engineering constraints.</p><p>And also worth noting: syslog severity levels (<a href="https://www.rfc-editor.org/rfc/rfc5424">RFC 5424</a>: Emergency, Alert, Critical, Error, Warning, Notice, Info, Debug) are yet another expression of this idea, standardized for system logging. Most modern logging frameworks (log4j, Python’s logging, Serilog in .NET) adopted these levels independently of Unix streams.</p><p>And now to the important part :)</p><h4>Should You Quiz a Senior Engineer on ADO ##vso Syntax?</h4><p>My answer would be no, because:</p><ul><li>It’s a lookup-level detail. The ##vso[task.logissue type=error] syntax is in the docs, takes 30 seconds to find, and has zero transferable insight. Memorizing it signals nothing about capability.</li><li>What matters is the mental model. A senior engineer who understands “CI runners parse stdout for magic prefixes to extract structured annotations” can use ADO, GitHub Actions, GitLab CI, or any future system — they’ll just look up the specific prefix.</li><li>The quiz reveals flaws in your interviewing process, not their engineering skills. Testing syntax recall selects for “has used this specific tool recently” rather than “can reason about systems.” You’d reject someone who’s deeply skilled but used GitHub Actions instead of ADO, or maybe who used ADO a while ago and way less.</li></ul><p>Where it <em>would</em> make sense to probe: ask interviewee to design a logging/annotation system for a CI runner. If they arrive at something like in-band signaling with a magic prefix, they understand the concept. If they propose a side-channel (Unix socket, separate FD, structured API), that’s <em>also</em> a valid answer and shows they understand the tradeoffs. That’s the conversation worth having.</p><p>When asking a syntax recall question, an honest “I don’t remember” should be followed <strong>by</strong> further probes to really infer whether the candidate has no exposure to the tool or whether the right understanding is in place. Present a slide with code in context — for platform engineers, code out of context rarely makes any sense whatsoever :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c7bc47d5515e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Architecting with Azure Container Apps (ACA)]]></title>
            <link>https://mikerodionov.medium.com/architecting-with-azure-container-apps-aca-4d9658356a78?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/4d9658356a78</guid>
            <category><![CDATA[software-architecture]]></category>
            <category><![CDATA[fastapi]]></category>
            <category><![CDATA[generative-ai-tools]]></category>
            <category><![CDATA[azure-container-apps]]></category>
            <category><![CDATA[azure]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sun, 25 Jan 2026 19:09:04 GMT</pubDate>
            <atom:updated>2026-01-25T19:42:26.703Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*m32HrDdBI05cK5lOnz02UA.jpeg" /></figure><p>Architectural choices are often about following the <a href="https://en.wikipedia.org/wiki/Goldilocks_principle">Goldilocks principle</a>, trying to find a sweet spot between excessive complexity and robust simplicity. When it comes to Azure Compute Services for running applications, for a while our choices were between Azure App Service and AKS:</p><ul><li>Simple monolith app? Use Azure App Service.</li><li>Complex microservices? Build an Azure Kubernetes Service (AKS) cluster and run on top of it.</li></ul><p>But that binary decision tree lacks some kind of middle-ground. What if we need the power of the Kubernetes ecosystem — like event-driven scaling (KEDA) or distributed application runtimes (Dapr), but we absolutely do not want the operational overhead of managing a Kubernetes control plane and node pools?</p><p><strong>Enter Azure Container Apps (ACA).</strong></p><p>From the AZ-305 (Designing Azure Infrastructure Solutions) exam perspective, ACA represents a critical shift towards “serverless containers.” It is the architect’s choice when optimizing for operational simplicity and cost efficiency in microservice scenarios.</p><p>Let’s dive deeper to see how we can use ACA, how it powers modern AI workloads (AI wrappers, mind the term :) ) and how it stacks up against the competition.</p><h4>The AZ-305 view: ACA recommended use cases</h4><p>The AZ-305 exam is heavily focused on matching business requirements to the correct technology while minimizing administrative burden and ACA shines in scenarios where development speed and automated operations take precedence over granular infrastructure control.</p><p>Below you can see the primary use cases where ACA is the recommended architectural choice:</p><ol><li><strong>Event-Driven Microservices (The KEDA Factor)</strong></li></ol><p>If your application needs to scale based on the depth of a Service Bus queue, HTTP traffic spikes, or Kafka messages, ACA is ideal. It has <a href="https://keda.sh/"><strong>KEDA (Kubernetes Event-Driven Autoscaling)</strong></a><strong> </strong>built right into the platform. You don’t install KEDA; you just configure a scaling rule.</p><p>2.<strong> Workloads with Fluctuating Traffic (serverless/scale to zero)</strong></p><p>This is the biggest differentiator for cost optimization. If you have an internal API used only during business hours, or a processing job that runs sporadically, ACA on the Consumption plan can scale down to zero replicas. <strong>When it’s not running, you are not paying.</strong></p><p>3.<strong> Polyglot Microservices needing “Wiring” (The Dapr Factor)</strong></p><p>If you are building a system with a Python service talking to a .NET service, and they both need state management and pub/sub, ACA offers native integration with <a href="https://dapr.io/"><strong>Dapr (Distributed Application Runtime)</strong></a>. Dapr abstracts away the complexity of connecting these moving parts via sidecars, which ACA manages for you.</p><p>4. <strong>Public API Endpoints requiring internal Isolation</strong></p><p>ACA allows you to deploy a container environment into your own Virtual Network (VNet) while easily exposing specific services to the internet via an integrated Envoy proxy. You get robust ingress controls without needing a separate Application Gateway for basic scenarios.</p><h4>Modern Example: Hosting an Internal AI Wrapper</h4><p>Let’s apply this to a real-world scenario very popular in the industry right now: an internal “ChatGPT-like” wrapper which uses Python (FastAPI) and an Azure OpenAI backend.</p><p>Why is ACA perfect for this? Because of traffic patterns.</p><p>An internal AI tool has extremely spiky usage. For example:</p><ul><li><strong>9:00 AM:</strong> Everyone arrives, logs in, asks the AI to summarize emails. Traffic spikes.</li><li><strong>12:00 PM:</strong> Lunchtime. Traffic drops.</li><li><strong>3:00 AM:</strong> Zero usage.</li></ul><p>If we host this on a traditional VM or a standard Kubernetes cluster node, we are paying for compute capacity at 3:00 AM that is doing absolutely nothing.</p><p>With ACA on the Consumption plan configured with an HTTP scaling rule, the application scales down to zero at night. In this case, infrastructure cost becomes directly tied to actual usage, aligning perfectly with the “Cost Optimization” pillar of the Well-Architected Framework.</p><h4>ACA vs AKS debate</h4><p>For an Azure architect, the most common decision point is “should we use ACA or full-blown AKS?”</p><p>It comes down to the trade-off between <strong>Control</strong> versus <strong>Convenience</strong>. Think of it as the difference between driving a car with a manual transmission (AKS) versus an automatic (ACA).</p><p><strong>Azure Kubernetes Service (AKS)</strong></p><p>AKS is “Managed Kubernetes,” but it is still Kubernetes.</p><ul><li><strong>You are responsible for:</strong> Upgrading node pools, managing the cluster autoscaler, installing and patching add-ons like KEDA or Ingress Controllers (Nginx/Traefik), and securing the control plane API.</li><li><strong>Choose AKS when:</strong> You need total control over the cluster configuration, you require specific GPU node SKUs not available in ACA, or you have a massive, steady-state workload where reserving dedicated VMs is cheaper than serverless pricing.</li></ul><p><strong>Azure Container Apps (ACA)</strong></p><p>ACA is “Serverless Containers” built <em>on top</em> of Kubernetes, but it hides the cluster from you.</p><ul><li><strong>Azure is responsible for:</strong> The control plane, the worker nodes, patching KEDA, patching the Envoy ingress proxy, and managing Dapr sidecars.</li><li><strong>Choose ACA when:</strong> You want to deploy containers and focus on code, not cluster maintenance. You need event-driven scaling without the headache of managing the scaler itself.</li></ul><p>With that we can say: whenever a requirement doesn’t explicitly state “We need access to the Kubernetes API server,” start with ACA. It is the path of least resistance.</p><h4>AWS Comparison</h4><p>For architects working in multi-cloud environments, it may be helpful to map ACA to its AWS counterparts. This comparison isn’t 1:1 — it splits based on complexity.</p><ol><li><strong>For Simple Web Apps: AWS App Runner</strong></li></ol><p>If you are using ACA purely to host a simple API or web frontend (Source-to-URL), its closest cousin is <strong>AWS App Runner</strong>.</p><ul><li><strong>Similarity:</strong> Both fully abstract the orchestration layer (no clusters to manage) and handle built-in ingress/TLS automatically.</li><li><strong>Difference:</strong> App Runner is strictly for web traffic. ACA is broader.</li></ul><p><strong>2. For Microservices &amp; Event-Driven Logic: Amazon ECS with Fargate</strong></p><p>If you are using ACA’s advanced features — like <strong>Dapr sidecars</strong>, <strong>KEDA scaling</strong>, or internal microservice discovery — the better comparison is <strong>Amazon ECS with Fargate compute</strong>.</p><ul><li><strong>Similarity:</strong> Both allow you to run “Serverless Containers” with support for sidecars, complex task definitions, and private networking.</li><li><strong>The ACA Edge:</strong> ACA simplifies the scaling logic. With ECS, you must configure CloudWatch Alarms to scale. With ACA, you simply define a KEDA rule (e.g., “Scale if Kafka queue &gt; 10”), and the platform handles the rest instantly.</li></ul><p>If we look at these two, ACA sits comfortably in the middle. It offers the “Developer Experience” of App Runner but retains the “Architectural Power” (Sidecars/KEDA) of ECS Fargate.</p><p><strong>Where does ACA differentiates itself against AWS</strong>?</p><p>ACA’s unique selling proposition is the tight, native integration of open-source ecosystem standards — specifically <strong>KEDA</strong> and <strong>Dapr</strong>. While you can use these tools on AWS, they are rarely as seamlessly integrated into the platform’s native configuration surface as they are in Azure Container Apps.</p><h4><strong>Final Thoughts</strong></h4><p>The cloud isn’t just about choosing between “Monolith” (App Service) and “Orchestrator” (AKS). ACA fills that crucial middle ground. It allows us to build modern, event-driven, and cost-efficient architectures without inheriting the operational debt of a full Kubernetes cluster.</p><p>For your next microservices project — or your next AZ-305 exam question — ask yourself: <em>Do I need to manage the nodes, or do I just need to run the code?</em> If it’s the latter, start with ACA.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4d9658356a78" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Exploring Azure Front Door]]></title>
            <link>https://mikerodionov.medium.com/exploring-azure-front-door-90ce69ad5340?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/90ce69ad5340</guid>
            <category><![CDATA[azure-front-door]]></category>
            <category><![CDATA[azure]]></category>
            <category><![CDATA[genai-infrastructure]]></category>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sat, 17 Jan 2026 15:16:23 GMT</pubDate>
            <atom:updated>2026-01-17T19:38:56.806Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*V5eIVpkChXpVgDBYsHIsFg.png" /></figure><p>Although I’m in the midst of prepping towards <a href="https://docs.aws.amazon.com/aws-certification/latest/examguides/developer-associate-02.html">AWS Developer Associate Exam</a>, I had an excuse that warranted a quick look at <strong>Azure Front Door (AFD) </strong>which led to this post. Since I plan to renew my AZ-305 certification (Designing Microsoft Azure Infrastructure Solutions) right after the DVA exam, writing this is even more beneficial for me as AZ-305 touches on load balancing architectural choices too :).</p><h4><strong>What is Azure Front Door?</strong></h4><p>It is a global, intelligent “reception desk” for web apps.</p><ul><li>Is it a load balancer? Yes, <strong>L7</strong> (HTTP/HTTPS)</li><li>Is it global? Yes, and it is its defining feature. It is placed outside of Azure Regions (<strong>global</strong> <strong>resource</strong>). Although when deploying you select resource group and region once Front Door is deployed it is immediately available in all Azure edge locations worldwide (175 locations as of now as per <a href="https://learn.microsoft.com/en-us/azure/networking/microsoft-global-network">Microsoft global network page</a>).</li></ul><p><strong>Simple/non technical analogy</strong></p><ul><li><strong>Azure Load Balancer </strong>(<strong>L4</strong>) — the <strong>traffic cop </strong>inside of a specific city (region), it directs cars (packets) to different lanes. Sample flow is <strong>User &gt; Region &gt; VM</strong>.</li><li><strong>Azure Front Door </strong>(<strong>L7</strong>) — the global <strong>air traffic controller</strong>, it sees the whole world and directs planes (users) to the closest open airport (region). Sample flow is: <strong>User &gt; Nearest Edge Location (POP) &gt; MSFT backbone &gt; Region &gt; App Service/VM</strong>.</li></ul><h4><strong>Azure Load Balancers “Big 4&quot;</strong></h4><p>When it comes to real world architectures or Azure certification exams (AZ-104, AZ-305) we are supposed to know Azure Load Balancing options to be able to choose the right option based on requirements/use case.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*v_3Knt9teSLA_Ir8vDTkBQ.png" /><figcaption>Azure Load Balancers “Big 4”</figcaption></figure><h4><strong>Architecture/exam tips</strong></h4><ol><li><strong>Traffic acceleration (anycast/split TCP)</strong></li></ol><p>Front Door makes your app faster using <strong>anycast</strong> (L3 routing technology) and <strong>Split TCP</strong> (L4 protocol optimization, one of the <a href="https://en.wikipedia.org/wiki/Performance-enhancing_proxy">performance-enhancing proxy</a> implementations).</p><p><strong>Anycast — routes to the closest Azure POP</strong></p><ul><li><strong>What it is</strong>: Anycast is an L3 routing technology which does the job of guiding traffic from the client to the closest Azure POP instead of main server far away. It basically shortens the distance over the messy public internet.</li><li><strong>Technical details</strong>: Microsoft announces the same IP address (e.g., 20.1.1.1) from every single Azure Edge location globally using BGP that results in many devices sharing the same IP and actual routing decision as to where packet should go is taken based on the distance from the sender (which typically means the lowest number of BGP hops). When a user in Spain types that IP, the internet routers automatically send the packet to the nearest Azure Edge (e.g., Madrid) because it is the shortest path.</li><li><strong>Acceleration</strong>: Instead of your request traveling over the slow, bumpy public internet to the US, it enters Microsoft’s high-speed private fiber network in Madrid.</li><li><strong>Non technical analogy</strong>: Think of normal IP assigned to one device as a coffee-shop, in this case anycast IP is a chain of coffee-shops they provide the same service but you can use Google maps to select the one which is closer to you.</li></ul><p><strong>Split TCP — completes TCP handshake on the closest Azure POP</strong></p><ul><li><strong>What it is</strong>: L4 protocol optimization which acts as a performance-enhancing proxy.</li><li><strong>Technical details</strong>: Once client reaches the closest Azure POP via anycast shortest path split TCP terminates hello/handshake process immediately at that POP without waiting for signal to reach the final destination and getting response from it.</li><li><strong>Acceleration</strong>: It reduces the <strong>wait time</strong> (latency) to establish the connection.</li><li><strong>Non technical analogy</strong>: Once you are in the closest coffee-shop barista greets you and asks you for your order without waiting for any extra confirmations from coffee-shop chain HQ.</li></ul><p><strong>Connection acceleration flow</strong></p><p>Client from Spain connects over Front Door to a back-end hosted in US:</p><p><strong>Anycast activates first</strong>: It routes your packet to the Madrid Edge location.<br>- <strong>Result</strong>: No inefficient routing through public internet.</p><p><strong>Split TCP</strong> <strong>activates second</strong>: The Madrid Edge says “ACK” (Hello) instantly, finishing the handshake in 10ms.<br>- <strong>Result</strong>: No wait for complete round trip to back-end to establish connection.</p><p><strong>Third, we use Azure backbone:</strong> The Madrid Edge then forwards your request to the US backend over Microsoft’s private fiber.<br>- <strong>Result</strong>: Higher and more predictable connection speed.</p><p><strong>2. Origin Groups (not just Azure)</strong></p><p>AFD is backend agnostic. Your backend (origin) does not have to be in Azure.</p><ul><li>It can route to AWS EC2, Google Cloud, or on-premise server.</li><li><strong>Scenario</strong>: “We are migrating from on-prem to Azure.” <strong>Solution</strong>: Put AFD in front, point 90% traffic to on-prem and 10% to Azure. Gradually shift the weights.</li></ul><p><strong>3. Session Affinity (Sticky Sessions)</strong></p><p>Enables <strong>support for legacy stateful backends</strong> (via<strong> affinity cookies</strong>), though modern architectures should prefer externalizing state (Redis/Cosmos DB) to remain stateless.</p><ul><li><strong>The capability</strong>: AFD can route a user to the exact same backend server every time using cookies (<strong>ASLBSA cookie</strong>). This is called <strong>Session Affinity</strong>.</li><li><strong>Cloud native best practice:</strong> You should decouple session state from the backend (put it in <strong>Redis</strong>/<strong>Cosmos DB)</strong>. This allows you to treat servers as disposable (stateless).</li></ul><p><strong>GenAI Context</strong><em>:</em> For ChatGPT-like apps, we usually want <strong>stateless</strong> APIs so we can scale easily.</p><blockquote><strong>Note on ASLBSA cookie</strong>: The <strong>ASLBSA </strong>(<strong>Azure Software Load Balancer Session Affinity</strong>) cookie is a technical <strong>session management cookie used by AFD</strong>. It is strictly a <strong>functional cookie</strong>, not a marketing or tracking cookie. Its primary purpose is to ensure that a user stays connected to the same backend server throughout their browsing session—a feature known as <strong>Session Affinity</strong> (<strong>Sticky Sessions</strong>). It acts as a “<strong>nametag</strong>” that tells the Azure Load Balancer: “This user is already talking to Server #3. Keep sending their requests to Server #3.”</blockquote><p><strong>4. Web Application Firewall (WAF)</strong></p><p>AFD includes <strong>WAF at the Edge</strong>. This means malicious attacks (<a href="https://en.wikipedia.org/wiki/SQL_injection">SQL Injection</a>, <a href="https://en.wikipedia.org/wiki/Cross-site_scripting">XSS</a>) are blocked <em>before</em> they even touch your Virtual Network. This is a massive security selling point.</p><h4><strong>Tips for Azure certification exams</strong></h4><p>When reading a scenario question, look for these specific keywords to choose AFD:</p><ol><li>“Global” + “HTTP/HTTPS”: If you see both words, the answer is 99% Front Door.</li><li>“SSL Offloading” (Global): You want to decrypt the HTTPS traffic at the edge to inspect it, then send it to the backend.</li><li><strong>“Instant Failover”:</strong> Traffic Manager relies on DNS caching (TTL). If a region dies, users might still be cached to the dead region for minutes. <strong>Front Door is instant</strong> because it proxies the traffic.<br>- <strong>Question</strong>: “We need the<strong> fastest possible failover</strong> for a web app.” → <strong>Front Door.<br>- Question</strong>: “We need to route UDP traffic globally.” → <strong>Traffic Manager </strong>(AFD cannot do UDP).</li></ol><h4><strong>Why AFD especially useful for GenAI projects?</strong></h4><ol><li><strong>Global Access</strong>: Employees worldwide need fast access to the GenAI tool.</li><li><strong>Security</strong>: <strong>WAF</strong> used to block SQL injection and XSS attacks through signatures and AFD allows to block those attacks at the edge.<br><strong>Note on prompt injection attacks: </strong>we cannot rely on WAF as it cannot detect this type of attacks. For those we use Azure AI Content Safety Prompt Shields feature (formerly known as Jailbreak Risk Detection). This feature can be added to your infrastructure in different ways:<br>- activated as an option for<strong> Azure AI Foundry</strong> model deployments<br>- via API call from your code to <strong>Azure AI Content Safety API</strong><br>- on APIM placed between AFD and container apps, <strong>APIM GenAI Gateway</strong> policy when activated runs Prompt Shields on every request before it even reaches container apps.</li><li><strong>Private Link</strong>: Front Door Premium can talk to your backend (Container Apps) via <strong>Private Link</strong>, keeping the AI completely off the public internet.</li><li><strong>Solving the GPU scarcity latency problem</strong>: Unlike standard web apps, GenAI backends are often centralized in just one or two regions (e.g., East US) due to GPU shortages or cost. This means global users are far from the backend. AFD acts as a “long-haul accelerator,” carrying the request over Microsoft’s optimized backbone rather than the public internet, making the single backend feel closer to users in Europe or Asia.</li><li><strong>Streaming Responses (Server-Sent Events)</strong>: GenAI applications (like ChatGPT) rely on “token streaming” to show text as it generates. AFD has robust support for <strong>HTTP/2</strong> and<strong> long-lived connections</strong> required for these Server-Sent Events (SSE) to flow smoothly without timing out or breaking mid-sentence.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*eAtWZCkr-oCBk8GZjz-lAA.jpeg" /><figcaption>Using AFD for GenAI Infra</figcaption></figure><h4><strong>Looping back to the AWS Stack</strong></h4><p>For those of us coming from the AWS world, mapping AFD to AWS services can be tricky because it combines features that are usually separate in AWS.</p><p><strong>Azure Front Door ≈ AWS CloudFront + AWS Global Accelerator</strong></p><ul><li><strong>Like CloudFront:</strong> AFD is a CDN. It caches content at the edge, terminates SSL, and blocks attacks using WAF. It speaks HTTP/HTTPS (L7).</li><li><strong>Like Global Accelerator:</strong> AFD uses Anycast protocols and the private fiber backbone to route dynamic traffic faster.</li></ul><p><strong>The Key Difference:</strong> In AWS, you often have to explicitly put <strong>Global Accelerator</strong> <em>in front of</em> your Application Load Balancer to get that “backbone acceleration.” In Azure, Front Door gives you that acceleration out of the box for HTTP traffic.</p><p><strong>Azure/AWS Services mapping</strong></p><ul><li><strong>AFD:</strong> AWS CloudFront (for Caching/WAF) + Global Accelerator (for Routing).</li><li><strong>Azure Traffic Manager</strong>: AWS Route53 (DNS-based routing).</li><li><strong>Azure Load Balancer</strong>: AWS Network Load Balancer (L4).</li><li><strong>Azure Application Gateway</strong>: AWS Application Load Balancer (L7)</li></ul><p>That wraps up my detour into AFD topic. If you’ve worked with both AFD and AWS Global Accelerator, I’d love to hear your take on the differences in the comments. Thanks for reading!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=90ce69ad5340" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kubernetes “Container Runtime,” Decoded: CRI vs. OCI (The Two-Layer Model)]]></title>
            <link>https://mikerodionov.medium.com/kubernetes-container-runtime-decoded-cri-vs-oci-the-two-layer-model-b10de4cc1a97?source=rss-f672ee2ac0ed------2</link>
            <guid isPermaLink="false">https://medium.com/p/b10de4cc1a97</guid>
            <dc:creator><![CDATA[Mikhail Rodionov]]></dc:creator>
            <pubDate>Sat, 23 Aug 2025 19:53:30 GMT</pubDate>
            <atom:updated>2025-08-24T11:00:59.698Z</atom:updated>
            <content:encoded><![CDATA[<p>Sometimes the term container runtime is used in a broad sense but precision matters. I guess whatever we learn, not only technology wise, we should start with knowing exact meaning of terms/basic definitions, next, move to use cases/architecture and only after that to practical details and ramifications of implementation/putting things into practice which tend to be endless. Learning by doing is not always the best thing, when it is neither preceded nor combined with knowing the theory behind the practice. Let&#39;s say that life obliges us to do learning by doing in sub-optimal ways at times.</p><p>Let&#39;s look at the term &#39;container runtime&#39;; it is often used too broadly, sometimes referring to a CRI implementation and sometimes to the OCI runtime, so kind of referring to containerd and runc using the same term. The same is applicable to <a href="https://medium.com/@mikerodionov/why-docker-was-deprecated-in-kubernetes-and-why-your-images-still-work-ce47bb77a5c5">my previous post on Kubernetes&#39; Docker deprecation</a>, which, although rich in historical references, could have benefited greatly from clarifying terminology better. But no worries, we will do it in this post.</p><p>If someone asks you to give examples of Kubernetes runtimes, which ones would you name? What if that question changes to what is the reference implementation of the Open Container Initiative (OCI) runtime specification? If you are crystal clear on the exact terminology, this question from the KCNA test (which I´m preparing for at the moment) is extremely easy to answer. But if you get used to broad and loosely defined usage of container runtime term you may have doubts as to whether it is containerd or runc as both seem to be runtimes. KCNA preparation materials will explain to you that:</p><blockquote>&#39;<strong>runc</strong> is the reference implementation of the Open Container Initiative (OCI) runtime specification. It is a lightweight, portable, and highly performant runtime environment for containers that implements the OCI runtime specification. runc provides a minimalistic and flexible way to run containers, making it an ideal choice as the reference implementation.&#39;</blockquote><p>Remembering that there is only one OCI runtime reference implementation, named <strong>runc</strong>, will help you answer the KCNA exam question; but it is better to understand why &#39;container runtime&#39; is applied to different things that are in fact different components with different names.</p><p>The problem here is that people overload the word runtime instead of dissecting it and using more precise terminology.</p><p>When it comes to Kubernetes, its container runtime is two-layer implementation:</p><ol><li><strong>CRI implementation/daemon</strong> (often called the ‘Kubernetes container runtime’): in containerd this is a <strong>built-in CRI plugin</strong>, while <strong>CRI-O is a standalone daemon</strong>. It talks to an OCI runtime.</li><li><strong>OCI runtime implementation</strong>, often referred to as a &#39;low-level runtime&#39;.</li></ol><p>Strictly speaking, the Kubernetes container runtime is composed of a CRI implementation and an OCI runtime working together to provide container runtime functionality to Kubernetes.</p><p>CRI implementation is what kubelet talks to via CRI gRPC API which manages images, snapshots, lifecycle, shims, and then calls an OCI runtime.</p><p>OCI runtime implements OCI runtime spec and actually spawns the container (namespaces, cgroups, mounts), with the reference implementation being runc, although there are other available.</p><p>As a rule of thumb: if kubelet talks to it, it is a<strong> CRI implementation</strong> (daemon) — containerd, CRI-O, cri-dockerd; if it calls <strong>clone()/setns()</strong> or boots a micro-VM/user-space kernel, it is an <strong>OCI runtime </strong>(often named low-level runtime) — runc, crun, kata-runtime, runsc.</p><p>To keep things straight, it is best to stick to the idea that Kubernetes uses a two-layer design composed of CRI daemon and OCI runtime implementations and avoid calling both layers &#39;runtimes&#39;; for historical reasons the terms often get mixed. This terminology mess comes from the Kubernetes history:</p><p>In early Kubernetes versions (pre-CRI) kubelet talked directly to Docker engine via its API and from Kubernetes´ point of view it was just a runtime with most people referring to it as a &#39;Docker runtime&#39; (which did have layers below).</p><p>In 2016 the CRI arrived and Kubernetes formalized a runtime abstraction — the CRI — shipping dockershim to keep Docker working for a while.</p><p>In 2022 (Kubernetes 1.24) dockershim was removed and Docker Engine remained usable only via the external <strong>cri-dockerd</strong> shim. People still kept saying “runtime” loosely, mixing CRI daemons and OCI runtimes.</p><p>Confusion around Kubernetes Docker deprecation I tried to describe <a href="https://medium.com/@mikerodionov/why-docker-was-deprecated-in-kubernetes-and-why-your-images-still-work-ce47bb77a5c5">in my previous post</a> was largely caused by this terminology mess, which still persists today.</p><p>So to talk cleanly about Kubernetes runtimes today we should distinguish and name things properly:</p><ul><li><strong>CRI implementation (upper layer):</strong> what kubelet talks to — <strong>containerd</strong>, <strong>CRI-O</strong>, <strong>cri-dockerd</strong>.</li><li><strong>OCI runtime (lower layer):</strong> what actually spawns containers — <strong>runc</strong> (reference), <strong>crun</strong>, <strong>kata-runtime</strong>, <strong>runsc</strong> (gVisor), <strong>runhcs</strong> (Windows).</li></ul><p>So it wasn’t truly “single layer” end-to-end in the beginning; it was <strong>single integration from K8s’ perspective</strong>, which is why “runtime” became a catch-all. Sticking to “CRI implementation” vs “OCI runtime” keeps things precise.</p><p>Just to make this post complete I will include CRI daemons and OCI runtimes implementation tables for your reference.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/575/1*xRkH6K533tGrllZnaXtHtw.png" /><figcaption>CRI daemon implementations</figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/579/1*Hf9QGkRDeYzZgSbM7PjBRA.png" /><figcaption>OCI runtime implementations</figcaption></figure><p>As an afterthought I think it is also worth clarifying related standards and specs, as I was focusing on explaining Kubernetes runtime stack components so that we can identify and distinguish them in reality they are just implementations of the two standards:</p><p><strong>OCI (Open Container Initiative) </strong>which is a vendor-neutral and not Kubernetes-specific standard comprised out of 3 specifications:</p><ul><li><strong>Image Spec:</strong> how images are laid out/formatted.</li><li><strong>Runtime Spec:</strong> how a <em>low-level runtime</em> (e.g., runc, crun, runsc, kata-runtime) receives a bundle (config.json + rootfs) and performs create/start/kill/delete.<strong> runc being a reference implementation of this spec</strong>.</li><li><strong>Distribution Spec:</strong> how registries push/pull images.</li></ul><p><strong>CRI (Container Runtime Interface) </strong>a<strong> Kubernetes</strong> <strong>standard </strong>gRPC API for interaction between <strong>kubelet</strong> and a CRI daemon (e.g., <strong>containerd</strong>, <strong>CRI-O</strong>) which defines two services:</p><ul><li><strong>RuntimeService</strong> (pods/containers lifecycle, exec, logs)</li><li><strong>ImageService</strong> (pull/list/remove images)</li></ul><p><strong>CRI </strong>is image- and runtime-format agnostic, but in practice <strong>CRI implementations are built to work with OCI images and registries, and to launch containers via an OCI runtime</strong> — so they <em>interoperate</em> closely with OCI specs even though there’s no hard requirement. CRI itself specifies kubelet ↔ runtime gRPC APIs only (RuntimeService &amp; ImageService) and it says <em>nothing</em> about image format or low-level runtime details. But in practice:</p><ul><li><strong>containerd</strong>’s CRI plugin pulls/pushes OCI images and supports the OCI Image Spec; it then uses an OCI runtime (e.g., runc) to create containers.</li><li><strong>CRI-O</strong> exists <em>specifically</em> to let Kubernetes use <strong>OCI-compatible runtimes</strong> (runc, Kata, etc.).</li><li>Image pulls talk to registries that implement the <strong>OCI Distribution Spec</strong> (derived from Docker Registry HTTP API v2).</li><li>The <strong>OCI Image Spec</strong> defines manifests/config/layers that these runtimes actually store and run.</li></ul><p><strong>Bottom line:</strong> CRI defines <em>how kubelet asks</em> (“pull this image”, “start this container”). The runtime then fulfills those requests using <strong>OCI Image + Distribution</strong> for image handling and an <strong>OCI Runtime</strong> (e.g., runc/crun) for process creation. One<em> could</em> build a CRI runtime around a non-OCI image format, but you’d need your own translation layer; Kubernetes itself wouldn’t care, while the most of the ecosystem assumes OCI.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b10de4cc1a97" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>