<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>English on Ayoub's Blog</title><link>https://ayoubmah.github.io/tags/english/</link><description>Recent content in English on Ayoub's Blog</description><generator>Hugo</generator><language>en-us</language><copyright>&lt;a href="https://creativecommons.org/licenses/by-nc/4.0/" target="_blank" rel="noopener"&gt;CC BY-NC 4.0&lt;/a&gt;</copyright><lastBuildDate>Thu, 19 Mar 2026 23:33:57 +0100</lastBuildDate><atom:link href="https://ayoubmah.github.io/tags/english/index.xml" rel="self" type="application/rss+xml"/><item><title>Day 0 - linux primitives that make k8s possible</title><link>https://ayoubmah.github.io/posts/day-0---linux-primitives-that-make-k8s-possible/</link><pubDate>Thu, 19 Mar 2026 23:33:57 +0100</pubDate><guid>https://ayoubmah.github.io/posts/day-0---linux-primitives-that-make-k8s-possible/</guid><description>&lt;h2 id="so-what-what-happen-when-we-install-k8s-"&gt;so what what happen when we install k8s ?&lt;/h2&gt;
&lt;p&gt;when we install k8s actually we get this processes
we can separate them logically (they are not separated physically like not namespaces or something)
they are just have a different roles :&lt;/p&gt;
&lt;pre tabindex="0"&gt;&lt;code&gt;Our Physical Machine (or VM)
│
├── Control plan processes ← just Linux processes
│ ├── etcd (a process)
│ ├── kube-apiserver (a process)
│ ├── kube-scheduler (a process)
│ └── kube-controller-manager (a process)
│
└── Worker Node processes ← also just Linux processes
 ├── kubelet (a process)
 ├── kube-proxy (a process)
 └── containerd (a process)
&lt;/code&gt;&lt;/pre&gt;&lt;h2 id="so-what-is-a-node-"&gt;so what is a node ?&lt;/h2&gt;
&lt;p&gt;a node it&amp;rsquo;s just a machine (VM/ cloud instance) that k8s know about it and can schedule a work onto it&lt;/p&gt;</description></item><item><title>etcd</title><link>https://ayoubmah.github.io/posts/day-1---etcd/</link><pubDate>Thu, 19 Mar 2026 23:31:51 +0100</pubDate><guid>https://ayoubmah.github.io/posts/day-1---etcd/</guid><description>&lt;h1 id="setup"&gt;setup&lt;/h1&gt;
&lt;p&gt;i have 3 VMs: vm1, vm2 and vm3&lt;/p&gt;
&lt;table&gt;
 &lt;thead&gt;
 &lt;tr&gt;
 &lt;th&gt;Node&lt;/th&gt;
 &lt;th&gt;IP Address&lt;/th&gt;
 &lt;/tr&gt;
 &lt;/thead&gt;
 &lt;tbody&gt;
 &lt;tr&gt;
 &lt;td&gt;node1&lt;/td&gt;
 &lt;td&gt;172.31.253.147&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;node2&lt;/td&gt;
 &lt;td&gt;172.31.250.205&lt;/td&gt;
 &lt;/tr&gt;
 &lt;tr&gt;
 &lt;td&gt;node3&lt;/td&gt;
 &lt;td&gt;172.31.253.194&lt;/td&gt;
 &lt;/tr&gt;
 &lt;/tbody&gt;
&lt;/table&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260319171638.png" alt="Pasted image 20260319171638"&gt;&lt;/p&gt;
&lt;h1 id="step1-install-etcd-on-all-3-nodes-and-create-the-data-dir"&gt;step1: Install etcd on ALL 3 Nodes and create the data dir&lt;/h1&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260319171828.png" alt="Pasted image 20260319171828"&gt;&lt;/p&gt;
&lt;p&gt;let&amp;rsquo;s verify the version and create the data directory
&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260319171932.png" alt="Pasted image 20260319171932"&gt;&lt;/p&gt;
&lt;h1 id="step2-create-the-etcd-systemd-service"&gt;step2: Create the etcd systemd Service&lt;/h1&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260319172432.png" alt="Pasted image 20260319172432"&gt;&lt;/p&gt;
&lt;p&gt;we do the same thing for other VMs changing just the ip add
for example for node1&lt;/p&gt;</description></item><item><title>Containerd under the hood</title><link>https://ayoubmah.github.io/posts/containerd-under-the-hood/</link><pubDate>Fri, 06 Mar 2026 00:00:47 +0100</pubDate><guid>https://ayoubmah.github.io/posts/containerd-under-the-hood/</guid><description>&lt;h1 id="phase-1-runc-raw--zero-tooling"&gt;Phase 1: runc Raw — Zero Tooling&lt;/h1&gt;
&lt;p&gt;so what we&amp;rsquo;ll do in this phase is exactly what containerd does internally&lt;/p&gt;
&lt;p&gt;me (manually) vs containerd (automatically) ─────────────────────────────────────────────────────────&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Create rootfs → pulls image layers&lt;/li&gt;
&lt;li&gt;Write config.json → generates OCI bundle&lt;/li&gt;
&lt;li&gt;Call runc run → calls runc via shim&lt;/li&gt;
&lt;li&gt;Watch cgroups appear → same thing happens&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;first i installed containerd
&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260305002032.png" alt="Pasted image 20260305002032"&gt;
so it&amp;rsquo;s automatically we can see that we have runc but not crun, (so the default OCI implementation in containerd is runc)&lt;/p&gt;</description></item><item><title>containerd vs OCI, and the k8s architecture</title><link>https://ayoubmah.github.io/ilt/2026/03/04/04-03-26/</link><pubDate>Wed, 04 Mar 2026 00:00:00 +0000</pubDate><guid>https://ayoubmah.github.io/ilt/2026/03/04/04-03-26/</guid><description>&lt;h1 id="what-is-the-different-between-containerd-and-oci-open-container-initiative"&gt;what is the different between containerd and OCI (open container initiative)&lt;/h1&gt;
&lt;p&gt;writing &amp;hellip;&lt;/p&gt;
&lt;h1 id="k8s-architecture"&gt;k8s architecture&lt;/h1&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260304201507.png" alt="Pasted image 20260304201507"&gt;&lt;/p&gt;
&lt;p&gt;thanks @djalal for explications &amp;lt;3
writing &amp;hellip;&lt;/p&gt;</description></item><item><title>Docker runtime stack, build cache and volumes</title><link>https://ayoubmah.github.io/ilt/2026/03/03/03-03-2026/</link><pubDate>Tue, 03 Mar 2026 23:52:59 +0100</pubDate><guid>https://ayoubmah.github.io/ilt/2026/03/03/03-03-2026/</guid><description>&lt;h1 id="docker-runtime-stack"&gt;Docker runtime stack&lt;/h1&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260303123027.png" alt="Pasted image 20260303123027"&gt;&lt;/p&gt;
&lt;h3 id="1--docker-cli"&gt;1- docker cli&lt;/h3&gt;
&lt;p&gt;translate commands to rest api and send it over unix socket&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;docker run ngnix &lt;span style="color:#f92672"&gt;===&lt;/span&gt;&amp;gt; POST /container/create &lt;span style="color:#f92672"&gt;{&lt;/span&gt;&lt;span style="color:#e6db74"&gt;&amp;#34;Image&amp;#34;&lt;/span&gt;:&lt;span style="color:#e6db74"&gt;&amp;#34;nginx:latest&amp;#34;&lt;/span&gt;, ....&lt;span style="color:#f92672"&gt;}&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#f92672"&gt;===&lt;/span&gt;&amp;gt; sent to: /var/run/docker.sock
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;so we can talk to dockerd with it&lt;/p&gt;
&lt;p&gt;like&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;curl --unix-socket /var/run/docker.sock http://localhost/containers/json
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;h3 id="2--dockerd"&gt;2- dockerd&lt;/h3&gt;
&lt;p&gt;it&amp;rsquo;s an orchestrator&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;p&gt;manage images (pull, build)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;manage volume (create net, mount)&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;manage network (bridge creation, port mapping)&lt;/p&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;strong&gt;docker run delegated to containerd not here&lt;/strong&gt; !!&lt;/p&gt;</description></item><item><title>Container Filesystem</title><link>https://ayoubmah.github.io/posts/container-filesystem/</link><pubDate>Sun, 08 Feb 2026 23:56:04 +0100</pubDate><guid>https://ayoubmah.github.io/posts/container-filesystem/</guid><description>&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260209000710.png" alt="Pasted image 20260209000710"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260209000844.png" alt="Pasted image 20260209000844"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260209001058.png" alt="Pasted image 20260209001058"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260209001254.png" alt="Pasted image 20260209001254"&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020260209001457.png" alt="Pasted image 20260209001457"&gt;&lt;/p&gt;</description></item><item><title>Crafting My Own Storage Engine-Part 01: Java I/O Fundamentals</title><link>https://ayoubmah.github.io/posts/crafting-my-own-storage-engine-part-01--java-io-fundamentals/</link><pubDate>Tue, 13 Jan 2026 19:37:47 +0100</pubDate><guid>https://ayoubmah.github.io/posts/crafting-my-own-storage-engine-part-01--java-io-fundamentals/</guid><description>&lt;h1 id="the-page-abstraction"&gt;The &amp;ldquo;Page&amp;rdquo; Abstraction&lt;/h1&gt;
&lt;p&gt;so the &lt;code&gt;ByteBuffer&lt;/code&gt; acts like a staging area where we serialize our Java objects (the &lt;code&gt;Page&lt;/code&gt; object) into raw bytes and keep them in RAM using methods like &lt;code&gt;putInt&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;and after that, we need to persist the data to disk — meaning we write those bytes into a file so the data survives after the program stops&lt;/p&gt;
&lt;p&gt;so we have one large file, and since all pages have a fixed size, if we want to write the data for &lt;code&gt;pageId = 14&lt;/code&gt;, we simply compute the offset &lt;code&gt;4096 * 14&lt;/code&gt; and write the buffer at that position using the &lt;code&gt;write&lt;/code&gt; method&lt;/p&gt;</description></item><item><title>Contains Duplicate (LeetCode 217)</title><link>https://ayoubmah.github.io/ilt/2025/12/11/contains-duplicate-leetcode-217/</link><pubDate>Thu, 11 Dec 2025 00:42:08 +0100</pubDate><guid>https://ayoubmah.github.io/ilt/2025/12/11/contains-duplicate-leetcode-217/</guid><description>&lt;h1 id="contains-duplicate-leetcode-217"&gt;Contains Duplicate (LeetCode 217)&lt;/h1&gt;
&lt;p&gt;the link of the problem &lt;a href="https://leetcode.com/problems/contains-duplicate/description/"&gt;here&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Given an integer array &lt;code&gt;nums&lt;/code&gt;, return &lt;code&gt;true&lt;/code&gt; if any value appears &lt;strong&gt;at least twice&lt;/strong&gt; in the array, and return &lt;code&gt;false&lt;/code&gt; if every element is distinct.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Example 1:&lt;/strong&gt;
&lt;strong&gt;Input:&lt;/strong&gt; nums = [1,2,3,1]
&lt;strong&gt;Output:&lt;/strong&gt; true
&lt;strong&gt;Explanation:&lt;/strong&gt;
The element 1 occurs at the indices 0 and 3.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Example 2:&lt;/strong&gt;
&lt;strong&gt;Input:&lt;/strong&gt; nums = [1,2,3,4]
&lt;strong&gt;Output:&lt;/strong&gt; false
&lt;strong&gt;Explanation:&lt;/strong&gt;
All elements are distinct.
&lt;strong&gt;Example 3:&lt;/strong&gt;
&lt;strong&gt;Input:&lt;/strong&gt; nums = [1,1,1,3,3,4,3,2,4,2]
&lt;strong&gt;Output:&lt;/strong&gt; true&lt;/p&gt;</description></item><item><title>Part 1 - Building a Mini Spring Framework (v0.1)-Dependency Injection Basics</title><link>https://ayoubmah.github.io/posts/part-1---building-a-mini-spring-framework-v0.1-dependency-injection-basics/</link><pubDate>Wed, 10 Dec 2025 23:14:46 +0100</pubDate><guid>https://ayoubmah.github.io/posts/part-1---building-a-mini-spring-framework-v0.1-dependency-injection-basics/</guid><description>&lt;h1 id="the-problem-spring-solves"&gt;The problem Spring solves&lt;/h1&gt;
&lt;p&gt;easy right ?
let&amp;rsquo;s see :)&lt;/p&gt;
&lt;p&gt;imagine you are building an e-commerce backend, and you have OrderService that needs to process payments&lt;/p&gt;
&lt;p&gt;the naive approach is: inside the OrderService you write for example&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;PaymentProcess process &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;new&lt;/span&gt; PaypalService();
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;if your boss comes and says &amp;ldquo;we&amp;rsquo;re switching the contract from PayPal to Stripe&amp;rdquo; what do you have to do to your code?&lt;/p&gt;
&lt;p&gt;The answer is use an interface&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;interface&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;PaymentProcess&lt;/span&gt; {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;	&lt;span style="color:#66d9ef"&gt;void&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;pay&lt;/span&gt;(&lt;span style="color:#66d9ef"&gt;double&lt;/span&gt; amount);
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;and the OrderService looks like&lt;/p&gt;</description></item><item><title>Fixing Flyway Database Connection Errors in Docker</title><link>https://ayoubmah.github.io/posts/fixing-flyway-database-connection-errors-in-docker/</link><pubDate>Thu, 20 Nov 2025 12:19:05 +0100</pubDate><guid>https://ayoubmah.github.io/posts/fixing-flyway-database-connection-errors-in-docker/</guid><description>&lt;p&gt;Before reading this blog i suggest you have a quick look at how &lt;em&gt;Docker Compose starts services&lt;/em&gt; especially how databases take time to initialize before they start accepting connections.&lt;/p&gt;
&lt;p&gt;so basically, when you work with microservices, each service has its own database (in my case: patient-db, doctor-db…). and when Spring Boot starts, Flyway tries to run the migration scripts immediately.&lt;/p&gt;
&lt;p&gt;But there is a problem:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;Flyway is much faster than PostgreSQL.&lt;/em&gt;&lt;br&gt;
PostgreSQL says: “I’m starting…”&lt;br&gt;
Flyway says: “I want to connect now.”&lt;br&gt;
PostgreSQL says: “Wait wait wait hold on…”&lt;br&gt;
Flyway says: “Connection refused.”&lt;/p&gt;</description></item><item><title>COMPUTER NETWORKS AND THE INTERNET</title><link>https://ayoubmah.github.io/ilt/2025/10/14/computer-networks-and-the-internet/</link><pubDate>Tue, 14 Oct 2025 21:59:25 +0200</pubDate><guid>https://ayoubmah.github.io/ilt/2025/10/14/computer-networks-and-the-internet/</guid><description>&lt;ul&gt;
&lt;li&gt;Our devices like PC, smartphones &amp;hellip; in the vocab of computer networks are called &amp;ldquo;hosts&amp;rdquo; or &amp;ldquo;end systems&amp;rdquo;.&lt;/li&gt;
&lt;li&gt;the TCP and IP are the most important protocols in the computer networks that control the sending and receiving of information within the Internet&lt;/li&gt;
&lt;li&gt;TCP: &lt;strong&gt;T&lt;/strong&gt;ransmission &lt;strong&gt;C&lt;/strong&gt;ontrol &lt;strong&gt;P&lt;/strong&gt;rotocol.&lt;/li&gt;
&lt;li&gt;IP: &lt;strong&gt;I&lt;/strong&gt;nternet &lt;strong&gt;P&lt;/strong&gt;rotocol.&lt;/li&gt;
&lt;/ul&gt;</description></item><item><title>Collection Interfece</title><link>https://ayoubmah.github.io/posts/collection-interface/</link><pubDate>Tue, 14 Oct 2025 01:15:28 +0200</pubDate><guid>https://ayoubmah.github.io/posts/collection-interface/</guid><description>&lt;p&gt;the collection interface extends Iterable interface from java.lang
we have a method
&lt;strong&gt;boolean add(E e)&lt;/strong&gt; that return true if the collection changed (the elem e added) and false if not
&lt;strong&gt;boolean addAdd(Collection &amp;lt; ? extends E&amp;gt; c)&lt;/strong&gt; , that take a collection of type E of subtype of E and return true if the collection changed (all elm added)&lt;/p&gt;
&lt;p&gt;So if you have a &lt;code&gt;Collection&amp;lt;Animal&amp;gt;&lt;/code&gt; and another &lt;code&gt;Collection&amp;lt;Dog&amp;gt;&lt;/code&gt;,&lt;br&gt;
you can add the &lt;code&gt;Dog&lt;/code&gt;s into the &lt;code&gt;Animal&lt;/code&gt; collection because &lt;code&gt;Dog&lt;/code&gt; &lt;strong&gt;extends&lt;/strong&gt; &lt;code&gt;Animal&lt;/code&gt;.&lt;/p&gt;</description></item><item><title>Create My Own JCF-week1</title><link>https://ayoubmah.github.io/posts/create-my-own-jcf-week1/</link><pubDate>Sat, 11 Oct 2025 00:59:35 +0200</pubDate><guid>https://ayoubmah.github.io/posts/create-my-own-jcf-week1/</guid><description>&lt;h3 id="jcf-java-collection-framework-hierarchy"&gt;JCF: Java Collection Framework Hierarchy&lt;/h3&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020251014010626.png" alt="Pasted image 20251014010626"&gt;&lt;/p&gt;
&lt;p&gt;_Bfore starting implementing JCF should you know the Iterable&lt;E&gt; interface&lt;/p&gt;
&lt;h1 id="1-iterable"&gt;1. Iterable&lt;/h1&gt;
&lt;ul&gt;
&lt;li&gt;Iterable interface is a builtin interface in java it allow us using &amp;ldquo;for-each&amp;rdquo; loop thanks to Iterator method&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;let&amp;rsquo;s take an example
if you work with arrays in java and suppose you create an new array&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;int&lt;/span&gt;&lt;span style="color:#f92672"&gt;[]&lt;/span&gt; arr &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;new&lt;/span&gt; Interger&lt;span style="color:#f92672"&gt;[]&lt;/span&gt;{1,2,3}
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;and you want to make the forEach loop like this &lt;code&gt;for(int n : arr)&lt;/code&gt; =&amp;gt; this will give you a compiler error&lt;/p&gt;</description></item><item><title>MicroServices With Go and kuber</title><link>https://ayoubmah.github.io/posts/microservices-with-go-and-kuber/</link><pubDate>Wed, 08 Oct 2025 08:45:00 +0200</pubDate><guid>https://ayoubmah.github.io/posts/microservices-with-go-and-kuber/</guid><description>&lt;p&gt;coming soon :)&lt;/p&gt;</description></item><item><title>The OS Manages The Hardware</title><link>https://ayoubmah.github.io/ilt/2025/09/17/the-os-manages-the-hardware/</link><pubDate>Wed, 17 Sep 2025 17:09:33 +0200</pubDate><guid>https://ayoubmah.github.io/ilt/2025/09/17/the-os-manages-the-hardware/</guid><description>&lt;h2 id="1-layered-view-of-a-computer-system"&gt;1) Layered view of a computer system&lt;/h2&gt;
&lt;p&gt;the os is a piece of software that is setting between the applications programs and the hardware&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020250917173342.png" alt="Pasted image 20250917173342"&gt;&lt;/p&gt;
&lt;p&gt;the role of the os is&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Protect the hardware from misuse by runaway the applications&lt;/li&gt;
&lt;li&gt;provide application with simple and uniform mechanisms&lt;/li&gt;
&lt;/ol&gt;
&lt;h2 id="2-abstractions-provided-by-an-operating-system"&gt;2) Abstractions provided by an operating system&lt;/h2&gt;
&lt;p&gt;&lt;strong&gt;files&lt;/strong&gt; are abstraction for I/O devices
&lt;strong&gt;virtual memory&lt;/strong&gt; is an abstraction for the main memory + I/O devices
&lt;strong&gt;Processes&lt;/strong&gt; are abstraction for processor + main memory + I/O devices&lt;/p&gt;</description></item><item><title>Doubly Linked Lists</title><link>https://ayoubmah.github.io/ilt/2025/09/08/doubly-linked-lists/</link><pubDate>Mon, 08 Sep 2025 23:23:40 +0200</pubDate><guid>https://ayoubmah.github.io/ilt/2025/09/08/doubly-linked-lists/</guid><description>&lt;p&gt;In this blog we&amp;rsquo;ll see how we can implementing a doubly linked list
if you haven’t seen the Singly Linked List yet it&amp;rsquo;s better to check it &lt;a href="https://ayoubmah.github.io/ilt/2025/08/12/singly-linked-list/"&gt;here&lt;/a&gt; first, because the concept is almost the same with just a few changes.&lt;/p&gt;
&lt;p&gt;the main difference is in the node itself
this time a node referenced by the &lt;strong&gt;next&lt;/strong&gt; node and the &lt;strong&gt;prev&lt;/strong&gt; node
as you can see in this image&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/dob.jpeg" alt="dob"&gt;&lt;/p&gt;
&lt;p&gt;let&amp;rsquo;s implemented in java&lt;/p&gt;</description></item><item><title>Leet-Code-Day001</title><link>https://ayoubmah.github.io/ilt/2025/09/04/leet-code-day001/</link><pubDate>Thu, 04 Sep 2025 23:34:00 +0200</pubDate><guid>https://ayoubmah.github.io/ilt/2025/09/04/leet-code-day001/</guid><description>&lt;p&gt;you can see the problem here
&lt;a href="https://leetcode.com/problems/merge-two-sorted-lists/"&gt;Merge Two Sorted Lists&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The idea is that we have &lt;strong&gt;two sorted singly linked lists&lt;/strong&gt;
and we want &lt;strong&gt;a single merged linked list containing all the elements from the two original lists in sorted order&lt;/strong&gt; like this:&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/WhatsApp%20Image%202025-09-04%20at%2011.50.26%20PM.jpeg" alt="WhatsApp Image 2025-09-04 at 11.50.26 PM"&gt;&lt;/p&gt;
&lt;p&gt;before looking at the steps of the solution, let&amp;rsquo;s see the implementation of the singly linked list with int value (you can see the generic version here &lt;a href="https://ayoubmah.github.io/ilt/2025/08/12/singly-linked-list/"&gt;Singularly Linked List&lt;/a&gt; )&lt;/p&gt;</description></item><item><title>Circularly Linked List</title><link>https://ayoubmah.github.io/ilt/2025/09/04/circularly-linked-list/</link><pubDate>Thu, 04 Sep 2025 00:02:05 +0200</pubDate><guid>https://ayoubmah.github.io/ilt/2025/09/04/circularly-linked-list/</guid><description>&lt;p&gt;Before to read about circularly linked lists i suggest to go to read bit about &lt;a href="https://ayoubmah.github.io/ilt/2025/08/12/singly-linked-list/"&gt;Singly Linked List&lt;/a&gt;, to better understanding circularly linked lists(CLL)&lt;/p&gt;
&lt;p&gt;so basically a CLL is a Singly linked list and instead of the its tail (last node of the list) point on null its point of the first element of the list (head). like this&lt;/p&gt;
&lt;p&gt;&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020250904001212.png" alt="Pasted image 20250904001212"&gt;&lt;/p&gt;</description></item><item><title>Singly Linked List</title><link>https://ayoubmah.github.io/ilt/2025/08/12/singly-linked-list/</link><pubDate>Tue, 12 Aug 2025 00:00:00 +0000</pubDate><guid>https://ayoubmah.github.io/ilt/2025/08/12/singly-linked-list/</guid><description>&lt;p&gt;Before you read this if you want a deep dive on Singly LinkedList and DSA with java in general please read the &amp;ldquo;Chapter 3. Fundamental Data Structures&amp;rdquo; p.122 by MICHEAL T.GOODRICH&lt;/p&gt;
&lt;h1 id="1-node"&gt;1. Node&lt;/h1&gt;
&lt;p&gt;First let&amp;rsquo;s define a node, so a node it&amp;rsquo;s a data structure that can store an object and point to another node&lt;/p&gt;
&lt;p&gt;like this
&lt;img src="https://ayoubmah.github.io/images/Pasted%20image%2020250812133629.png" alt="Pasted image 20250812133629"&gt;&lt;/p&gt;
&lt;p&gt;we can define it in java like&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-java" data-lang="java"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;class&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;Node&lt;/span&gt;&lt;span style="color:#f92672"&gt;&amp;lt;&lt;/span&gt;E&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;private&lt;/span&gt; E data;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;private&lt;/span&gt; Node&lt;span style="color:#f92672"&gt;&amp;lt;&lt;/span&gt;E&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; next;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;Node&lt;/span&gt;(E data){
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;this&lt;/span&gt;.&lt;span style="color:#a6e22e"&gt;data&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; data;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;this&lt;/span&gt;.&lt;span style="color:#a6e22e"&gt;next&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;null&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; E &lt;span style="color:#a6e22e"&gt;getData&lt;/span&gt;() {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; data;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;void&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;setData&lt;/span&gt;(E data) {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;this&lt;/span&gt;.&lt;span style="color:#a6e22e"&gt;data&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; data;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; Node&lt;span style="color:#f92672"&gt;&amp;lt;&lt;/span&gt;E&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;getNext&lt;/span&gt;() {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; next;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; &lt;span style="color:#66d9ef"&gt;void&lt;/span&gt; &lt;span style="color:#a6e22e"&gt;setNext&lt;/span&gt;(Node&lt;span style="color:#f92672"&gt;&amp;lt;&lt;/span&gt;E&lt;span style="color:#f92672"&gt;&amp;gt;&lt;/span&gt; next) {
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;this&lt;/span&gt;.&lt;span style="color:#a6e22e"&gt;next&lt;/span&gt; &lt;span style="color:#f92672"&gt;=&lt;/span&gt; next;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;public&lt;/span&gt; String &lt;span style="color:#a6e22e"&gt;toString&lt;/span&gt;(){
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; &lt;span style="color:#66d9ef"&gt;return&lt;/span&gt; &lt;span style="color:#e6db74"&gt;&amp;#34;(&amp;#34;&lt;/span&gt;&lt;span style="color:#f92672"&gt;+&lt;/span&gt;data&lt;span style="color:#f92672"&gt;+&lt;/span&gt;&lt;span style="color:#e6db74"&gt;&amp;#34;) =&amp;gt;(null)&amp;#34;&lt;/span&gt;;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt; }
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;}
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;As you can see in the code, the constructor of the Node initializes the next pointer to null, which is what we want.&lt;/p&gt;</description></item><item><title>Obsidian + Hugo + GitHub Pages Blog Setup Guide</title><link>https://ayoubmah.github.io/posts/obsidian-+-hugo-+-github-pages-blog-setup-guide/</link><pubDate>Sun, 10 Aug 2025 00:00:00 +0000</pubDate><guid>https://ayoubmah.github.io/posts/obsidian-+-hugo-+-github-pages-blog-setup-guide/</guid><description>&lt;h2 id="overview"&gt;Overview&lt;/h2&gt;
&lt;p&gt;This setup creates an automated blog workflow where you write in Obsidian, push to GitHub, and GitHub Actions automatically builds and deploys your Hugo site.&lt;/p&gt;
&lt;h2 id="phase-1-local-setup"&gt;Phase 1: Local Setup&lt;/h2&gt;
&lt;h3 id="step-1-install-required-tools"&gt;Step 1: Install Required Tools&lt;/h3&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Install Hugo&lt;/strong&gt;&lt;/p&gt;
&lt;div class="highlight"&gt;&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;"&gt;&lt;code class="language-bash" data-lang="bash"&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# Windows (using Chocolatey)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;choco install hugo-extended
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# macOS (using Homebrew)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;brew install hugo
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;&lt;span style="color:#75715e"&gt;# Linux (using Snap)&lt;/span&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span style="display:flex;"&gt;&lt;span&gt;sudo snap install hugo
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Install Git&lt;/strong&gt; (if not already installed)&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Download from &lt;a href="https://git-scm.com/"&gt;git-scm.com&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;&lt;strong&gt;Install Obsidian&lt;/strong&gt;&lt;/p&gt;</description></item></channel></rss>