<?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 Gerardo Perrucci on Medium]]></title>
        <description><![CDATA[Stories by Gerardo Perrucci on Medium]]></description>
        <link>https://medium.com/@centrodph?source=rss-9a903221e6d0------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*q9RT8B_gG22CElg7g2LdrQ.png</url>
            <title>Stories by Gerardo Perrucci on Medium</title>
            <link>https://medium.com/@centrodph?source=rss-9a903221e6d0------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 22 Nov 2026 10:38:02 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@centrodph/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[Your rules engine is a liability]]></title>
            <link>https://medium.com/the-software-engineers-path/your-rules-engine-is-a-liability-ade1e3eb24c5?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/ade1e3eb24c5</guid>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[ai]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Tue, 21 Apr 2026 22:51:00 GMT</pubDate>
            <atom:updated>2026-04-21T22:51:00.515Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*zA7ka1TMo2xP6760SFsbog.png" /></figure><p>I have spent over a decade building systems that try to be perfect. In the world of high-scale data ingestion, we often trick ourselves into thinking that more code equals more reliability. We write thousands of lines of validation logic, regex patterns, and nested if-statements to handle every possible edge case in a CSV file or a legacy database.</p><p>The problem is not the logic itself, but the maintenance debt it creates. Every time a client changes a column header or a third party API tweaks a response format, the system breaks. You end up spending sixty percent of your week acting as a glorified translator for data that should have been handled by the machine.</p><p>Read the full, technical deep-dive on my blog here: <a href="https://www.gperrucci.com/blog/ai/the-day-i-stopped-coding-rules-and-started-teaching-machines">https://www.gperrucci.com/blog/ai/the-day-i-stopped-coding-rules-and-started-teaching-machines</a></p><h3>The maintenance trap</h3><p>When I was leading the modernization of a large insurance platform, we faced a massive bottleneck. We were ingesting thousands of disparate datasets from different brokers, and each one had its own dialect. Our solution at the time was a massive rules engine. It felt responsible. It was easy to unit test. But it was also brittle. Whenever a new data source appeared, an engineer had to spend hours mapping fields.</p><p>This is the certainty trap. We were so afraid of a machine making a mistake that we forced humans to do a machine’s job. The total cost of ownership for a rules engine is staggering. You are not just paying for the initial development. You are paying for every future hour spent debugging why a string was not trimmed or why a date format was unexpected. The code grows until it is unmanageable, and the engineering team becomes a support desk for data quality issues.</p><h3>AI as the semantic glue</h3><p>Instead of writing rules, we started teaching the system to understand intent. By using Large Language Models (LLMs) as an abstraction layer for data mapping, we removed the need for hardcoded heuristics. The machine does not need me to tell it that “DOB” and “Date of Birth” are the same thing. It already knows.</p><p>This shift changed my role from a coder to a teacher. I stopped writing logic and started writing constraints. In a recent project involving an AI-driven data mapping engine, we replaced a thousand lines of manual configuration with a single prompt and a few examples. The user onboarding friction dropped significantly because the system could handle messy, real-world data without human intervention. We stopped worrying about the specific syntax of the input and focused on the semantic meaning of the output.</p><h3>The sandwich architecture</h3><p><strong>AI is not a silver bullet</strong>. You cannot use a probabilistic model for financial calculations or security permissions. I have seen teams fall into the trap of using AI where a simple boolean check would suffice. This increases latency and introduces unnecessary risk.</p><p>The goal is to use AI for the fuzzy parts of the system, such as mapping and intent, and keep the core business logic deterministic. I call this the sandwich architecture. You have a deterministic bread layer for safety, but the meat of the processing is handled by the intelligence of the model. This balance allows you to maintain accuracy while still being flexible enough to handle the chaos of external data.</p><ol><li>Focus on the cost of maintenance rather than the cost of tokens.</li><li>Abstract the semantic layer to translate external chaos into internal order.</li><li>Build systems that learn from user corrections.</li><li>If you are writing a tenth case for a switch statement, move it to a model.</li><li>Prioritize developer experience by removing boring mapping code.</li></ol><p>I break down the full strategy with code examples and architectural diagrams on my personal blog. Click here to read the full article: <a href="https://www.gperrucci.com/blog/ai/the-day-i-stopped-coding-rules-and-started-teaching-machines">https://www.gperrucci.com/blog/ai/the-day-i-stopped-coding-rules-and-started-teaching-machines</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ade1e3eb24c5" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/your-rules-engine-is-a-liability-ade1e3eb24c5">Your rules engine is a liability</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Stop treating LLMs like magic and start treating them like technical debt]]></title>
            <link>https://medium.com/@centrodph/stop-treating-llms-like-magic-and-start-treating-them-like-technical-debt-9eee16336a56?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/9eee16336a56</guid>
            <category><![CDATA[tech-debt]]></category>
            <category><![CDATA[llms-in-healthcare]]></category>
            <category><![CDATA[ai-engineering]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Sun, 19 Apr 2026 23:06:23 GMT</pubDate>
            <atom:updated>2026-04-19T23:06:23.607Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*MlQMjrkPKvDizR7V1NdLHA.png" /></figure><p>I have spent the last twelve years watching the industry fall in love with shiny objects. From the early days of PHP monoliths to the current obsession with serverless everything, the pattern is always the same.</p><h4>We find a tool that makes the “doing” easier, and we immediately forget the “thinking” part. Generative AI is the latest and most dangerous iteration of this cycle.</h4><p>Read the full, technical deep-dive on my blog here: <a href="https://www.gperrucci.com/blog/ai/understanding-generative-ai-and-your-path-as-an-engineer">https://www.gperrucci.com/blog/ai/understanding-generative-ai-and-your-path-as-an-engineer</a></p><p>Every week, I see another developer bragging about how they built a complex feature in thirty minutes using a series of prompts. They focus on the speed of output while ignoring the architectural integrity of the system.</p><p>The real cost lies in maintenance, scalability, and the total cost of ownership. If you use an LLM to generate code you do not fully understand, you are not being productive. You are just borrowing time from your future self at a high interest rate.</p><h3>The trap of local efficiency</h3><p>I recently worked on an AI-driven engine to handle large-scale data mapping for a SaaS platform. The goal was to automate the ingestion of massive datasets that previously required manual configuration. It was a classic case where AI could actually solve a friction point. However, the most difficult part was not the AI implementation itself. The difficulty was ensuring the event-driven architecture could handle the unpredictable nature of AI outputs without crashing the rest of the system.</p><p>Most engineers use AI to solve local problems. They want a function that sorts an array or a component that renders a specific chart. AI is great at that. But a system is not just a collection of functions. It is a web of dependencies, state management, and edge cases. When you let an LLM write your business logic, you often lose the thread of why a decision was made.</p><p><em>If you cannot explain why a specific architectural pattern was chosen without saying “the AI suggested it,” are you still the lead engineer?</em></p><h3>AI code is the new legacy code</h3><p>Legacy code is often defined as code without tests or code that nobody understands anymore. By that definition, most AI-generated projects are legacy the moment they are committed. I have seen this fail in high-traffic environments where sub-second accuracy is mandatory. In gaming or banking, a “hallucination” in your logic is not just a bug. It is a potential financial or reputational catastrophe.</p><p>I keep coming back to the idea that our job is changing from “writer” to “editor.” A senior engineer must be able to spot the subtle ways an AI might choose a path that works for ten users but fails for ten thousand. I have led migrations of high-traffic portals where we had to strip out “efficient” code because it lacked the observability needed for enterprise production. AI does not naturally include deep telemetry or error handling unless you explicitly demand it, and even then, it often misses the specific context of your infrastructure.</p><p><em>When was the last time you challenged the architectural assumptions of a generated snippet?</em></p><h3>The path forward is architectural integrity</h3><p>The future of engineering is not about who can write the best prompt. It is about who can design systems that are resilient enough to incorporate AI-generated components safely. I don’t know how to feel about the current “prompt engineer” job titles, but I suspect they will be gone in two years. What will remain is the need for engineers who understand memory management, database optimization, and distributed systems.</p><p>In my work with enterprise design systems, I found that the most valuable thing I could provide was a set of rigid constraints. AI thrives when the boundaries are clear. If your architecture is a mess, AI will only help you produce a bigger mess faster. If you want to use these tools effectively, you need to spend more time on your documentation and your system boundaries than on the prompts themselves.</p><p><em>Are you building a system that can survive an AI-generated bug, or are you just hoping for the best?</em></p><h3>Five insights for the modern lead engineer</h3><ol><li>Use AI for boilerplate and repetitive tasks but keep the core business logic in human hands.</li><li>Prioritize system observability so you can catch AI-generated edge cases in real time.</li><li>Treat every line of generated code as a liability until it passes a manual architectural review.</li><li>Focus on learning system design and trade-offs rather than memorizing syntax.</li><li>Build rigid testing suites that act as the guardrails for your automated workflows.</li></ol><p>I break down the full strategy with code examples and architectural diagrams on my personal blog. Click here to read the full article: <a href="https://www.gperrucci.com/blog/ai/understanding-generative-ai-and-your-path-as-an-engineer">https://www.gperrucci.com/blog/ai/understanding-generative-ai-and-your-path-as-an-engineer</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9eee16336a56" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Beyond the Hype and Your Blueprint for AI Engineering]]></title>
            <link>https://medium.com/@centrodph/beyond-the-hype-and-your-blueprint-for-ai-engineering-cac0ca4196d3?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/cac0ca4196d3</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[ai-engineering]]></category>
            <category><![CDATA[ai-agent]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Sat, 18 Apr 2026 22:43:09 GMT</pubDate>
            <atom:updated>2026-04-18T22:43:09.743Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*RKdeKMZt5L6GlvHe.png" /></figure><p>When I first started looking into neural networks, I felt like I was staring at a black box. The math seemed impenetrable, and the history felt like a collection of dusty dates. But once you realize that AI is less about creating life and more about augmented intelligence, tools that help experts do their jobs better, the path becomes much clearer.</p><p>This is the first piece of your career journey. We’re going to look at where this field came from, what it actually is, and the specific milestones you need to hit to become a professional AI engineer.</p><p><em>Originally published at </em><a href="https://www.gperrucci.com/blog/ai/beyond-the-hype-and-your-blueprint-for-ai-engineering"><em>https://www.gperrucci.com</em></a><em>.</em></p><h3>Understanding the augmented shift</h3><p>There is a distinction that most people miss, and that is the difference between artificial intelligence and augmented intelligence.</p><p>As an engineer, your job isn’t to build a replacement for a doctor or a lawyer. Your job is to build a system that puts evidence-backed information at their fingertips so they can make better decisions. This is Augmented Intelligence. When you approach a project with this mindset, you focus on reliability, interpretability, and data quality. Experts should be encouraged to scale their own capabilities while the machine handles the time-consuming work.</p><p>I think this is why the human side of the tech, psychology and linguistics, is so important. If you don’t understand how a human processes information, you can’t build a tool that effectively augments their capabilities.</p><h3>The digital landscape and why now?</h3><p>You might wonder why we are seeing such an explosion in AI right now. It isn’t just one invention, it is the result of changes in our digital environment.</p><p>The internet changed how we connect, and distributed computing allowed us to scale data processing. Then you have the Internet of Things (IoT), which flooded the world with connected devices. Most of this data, especially from social networking, is unstructured. This data swamp is the reason we need machines to help us make sense of the world. As an engineer, you are the one building the filters and the engines that turn that noise into insight.</p><h3>A legacy of logic and why history matters</h3><p>You might think you don’t need to know about the 1950s to write Python code today, but you’d be wrong. Understanding the AI Winters and the shift from rule-based systems to data-driven systems helps you choose the right tool for the job.</p><p>The formal journey started in the 1950s when Alan Turing proposed his famous test and John McCarthy actually coined the term Artificial Intelligence. From there, it has been a cycle of hype and reality.</p><p>First came the Logic Era between the 1950s and 1970s. Early pioneers thought we could code intelligence through pure logic. Programs like ELIZA in the 1960s or the expert systems of the 1970s were impressive, but they were limited by the rules we could write for them.</p><p>Then we saw the Connectionist Rise in the 1980s and 1990s. This is when we started seeing the surge in machine learning. We stopped trying to give the computer rules and started giving it examples. The 1990s introduced neural networks, which laid the foundation for everything we do today.</p><p>Finally, the 2000s ushered in the Deep Learning Boom. This period marked the ascent of deep learning. Between 2010 and 2020, we saw AI spread across industries through natural language processing (NLP) and computer vision. Today, we are seeing rapid expansion into autonomous systems and healthcare.</p><p>If you’re interested in the why behind these shifts, I highly recommend reading the official PyTorch documentation on Autograd. It’s the modern implementation of the backpropagation ideas that surfaced in the 80s, and seeing the math in code form makes it click in a way a history book never will.</p><h3>The engineer’s toolbox and defining the strength of your build</h3><p>In the industry, we categorize AI based on its strength. As you plan your career, you need to decide which of these you want to master.</p><h3>1. Narrow or weak AI</h3><p>This is where 99% of the jobs are right now. Narrow AI is applied to a specific domain, like language translators, virtual assistants, or recommendation engines. It is weak because it can perform specific tasks but cannot learn new ones on its own. It makes decisions based on programmed algorithms and training data.</p><p>As a career milestone, you should aim to master a specific domain. Learn how to handle computer vision for healthcare or NLP for finance. This is where you’ll build your first production-grade models.</p><h3>2. General or strong AI</h3><p>This is the Holy Grail. A generalized AI can perform a diverse array of unrelated tasks and acquire new skills autonomously to tackle novel challenges. It essentially performs at a human level of intelligence. We aren’t there yet, but researchers at places like OpenAI and DeepMind are pushing closer.</p><h3>3. Super or conscious AI</h3><p>This is the stuff of sci-fi. For an AI to be conscious, it would need to be self-aware and show advanced cognitive abilities. Since we can’t even adequately define what consciousness is, we aren’t building this anytime soon. Super AI would demonstrate capabilities far beyond human intelligence in areas like environmental conservation or robotics, but for now, don’t let the hype distract you from the real engineering work.</p><h3>How machines actually learn and the three pillars</h3><p>To get hired, you need to know more than just how to call an API. You need to understand the three ways machines learn. I like to think of these as different coaching styles.</p><p>Supervised Learning is like teaching with a textbook. You give the machine inputs and the correct answers, often called labels. It learns to associate the two. Most business problems, like prediction or classification, are solved here.</p><p>Unsupervised Learning is where you give the machine data but no answers. It has to find patterns on its own. It’s like giving someone a box of mixed Legos and asking them to sort them by color or shape without telling them what color or shape is.</p><p>Reinforcement Learning (RL) is trial and error. The machine gets a reward for a good move and a penalty for a bad one. If you’ve seen the videos of AI learning to play Hide and Seek, that’s RL in action.</p><h3>Your interdisciplinary map</h3><p>AI is a fusion of many fields. To be a top-tier engineer, you can’t just stay in your code editor. You need to pull from several different areas.</p><p>Mathematics and Statistics determine the viable models and measure performance. You need to understand probability and linear algebra to know why your model is failing.</p><p>Computer Science and Electrical Engineering determine how AI is actually implemented in software and hardware.</p><p>Psychology and Linguistics are essential because AI is often modeled on how we believe the brain works. These fields help you understand how to make AI more effective.</p><p>Philosophy provides the framework for ethical questions. As you build more powerful tools, you will face tough choices. For example, should an autonomous car prioritize the passenger or the pedestrian? These aren’t just thought experiments, they are lines of code you might have to write.</p><h3>Project idea and the augmented personal assistant</h3><p>To wrap up this first part of your journey, I want you to think about a project. <strong>Don’t just build a chatbot. Build an augmented intelligence tool.</strong></p><p>The goal is to create a tool that helps a specific subject matter expert, like a student or a hobbyist, make better decisions.</p><p>For your data, use a specialized dataset from a place like Kaggle or official gov data. For the model, use a supervised learning approach to categorize or predict. Finally, make sure the UI presents evidence alongside its prediction. For example, the tool might say, “I think this is X because of Y and Z in the data.”</p><h3>Where to go from here?</h3><p>The industry moves fast. To stay updated, I don’t look at news sites, I look at the people actually building the stuff. Follow researchers like Sebastian Raschka, who breaks down model architectures with incredible clarity, or François Chollet, whose insights into the nature of intelligence and abstraction will keep you thinking long after you close your laptop.</p><p>You’re not just learning to code, you’re learning to build the future of human capability. It’s a long road, but the milestones are worth it. See you in the next sister article.</p><p><em>Originally published at </em><a href="https://www.gperrucci.com/blog/ai/beyond-the-hype-and-your-blueprint-for-ai-engineering"><em>https://www.gperrucci.com</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cac0ca4196d3" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Architect’s Burden: Why Your Blueprint is Actually a Debt Contract]]></title>
            <link>https://medium.com/@centrodph/the-architects-burden-why-your-blueprint-is-actually-a-debt-contract-5af92b072578?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/5af92b072578</guid>
            <category><![CDATA[software-architecture]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Tue, 14 Apr 2026 11:53:20 GMT</pubDate>
            <atom:updated>2026-04-14T11:53:20.798Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*vzBOUBu53Nh-Kp9W.png" /></figure><p>Every box you draw today is a maintenance ticket you are signing for yourself three years from now. If you get it right, that debt is manageable. If you get it wrong, you are basically taking out a high-interest payday loan on your team’s future productivity.</p><p><em>Originally published at </em><a href="https://www.gperrucci.com/blog/engineering/the-architects-burden"><em>https://www.gperrucci.com</em></a><em>.</em></p><h3>The $2 Million Diagram</h3><p>I joined a team working on a high-traffic monolith. They were struggling with scale, so they did what every “modern” team does: they spent six months designing a distributed microservices architecture. It looked beautiful on paper. It had load balancers, event buses, and dedicated data stores for every domain.</p><p>Six months after the migration, the system was slower, the cloud bill had tripled, and the “blueprint” they were so proud of had become a cage. They had solved for “scalability” but ignored “total cost of ownership.” They built a cathedral when they actually needed a sturdy shed.</p><p>Software architecture is often defined as “the stuff that is hard to change later.” That is a fine academic definition, but it misses the point. Architecture is the art of deciding which mistakes you are willing to live with. It is the blueprint of your constraints.</p><h3>The Anatomy of a Blueprint</h3><p>When we talk about architecture, we are really talking about the organization of a system. It is the fundamental structure that explains how components behave and interact. If you are following the standard Software Development Life Cycle (SDLC), this happens in the design phase.</p><p>Programmers use this architecture as a guide to build the moving parts. It defines the operating environment, the interaction patterns, and the principles that keep the code from turning into a bowl of spaghetti. But the real value of architecture lies in its ability to address “non-functional” requirements. These are the things that don’t show up on a feature list but determine whether your app survives a Friday night surge:</p><ul><li>Scalability: Can it handle 10x the users without falling over?</li><li>Maintainability: Can a new hire understand the code without a week-long therapy session?</li><li>Security: Is the data siloed correctly, or is one SQL injection away from a total leak?</li><li>Interoperability: Can your new fancy Go service actually talk to the legacy Java monster?</li></ul><p>In the design phase, we produce artifacts like the Software Design Document (SDD) and Architectural Diagrams (often using UML). These are supposed to be the “source of truth.” The SDD should list your assumptions, your constraints, and your methodologies. If you don’t document the why behind a decision, the what will eventually be ignored or deleted by someone who thinks they know better.</p><h3>Are You Over-Engineering?</h3><p>I want you to stop and look at your current project. If you had to change your database provider tomorrow, how many services would break?</p><p>Does your architecture exist to solve a business problem, or does it exist because you wanted to put a specific framework on your resume?</p><p>If your lead architect left tomorrow, could the junior engineers explain why the system is partitioned the way it is?</p><h3>Performance vs. DX vs. Maintenance</h3><p>There is no such thing as a “perfect” architecture. There are only trade-offs.</p><p>If you choose a highly decoupled, event-driven architecture, you might get amazing scalability. But you have just destroyed your Developer Experience (DX). Now, instead of running one app locally, your engineers have to orchestrate five containers and a Kafka mock just to test a login button.</p><p>On the flip side, a tight monolith offers incredible DX and low latency. But the moment you need to scale one specific heavy-compute function, you are forced to scale the entire beast, which eats into your margins.</p><p>A well-designed architecture balances these competing needs. It provides a basis for communication among stakeholders. It allows for “agility,” which is a word that has been ruined by marketing but still matters. True architectural agility means that when a requirement changes, you don’t have to rewrite the foundation. You just swap out a component.</p><h3>The Decision Heuristic</h3><p>Here is my rule of thumb for making architectural choices:</p><ul><li>If the domain is unknown, stay monolithic. Don’t partition a system until you know where the seams are.</li><li>If the team is small (under 10 people), avoid microservices. The “coordination tax” will kill your velocity.</li><li>If you are building for “high availability,” the architecture must drive the production environment. You need load balancers and redundant databases from day one. You cannot “bolt on” availability to a design that wasn’t built for it.</li></ul><h3>The SDD Strategy</h3><p>An SDD is not just a PDF that sits in a folder. It should be a living document. Here is a simplified example of how I structure a technical specification for a new component in TypeScript, focusing on the interface and error boundaries rather than just the “happy path.”</p><pre>/**<br> * ARCHITECTURAL ARTIFACT: Service Interface Definition<br> * This defines the contract between the API Layer and the Data Layer.<br> * Goal: Decouple the business logic from the specific database implementation.<br> */<br> <br>export interface UserProfile {<br>  id: string;<br>  email: string;<br>  preferences: Record&lt;string, unknown&gt;;<br>}<br> <br>export interface IUserService {<br>  /**<br>   * Fetches a user by ID.<br>   * IMPLEMENTATION NOTE: This must handle the &#39;NotFound&#39; case explicitly <br>   * to avoid leaking internal database nulls to the UI.<br>   */<br>  getUser(id: string): Promise&lt;UserProfile | Error&gt;;<br>  <br>  /**<br>   * Updates user preferences.<br>   * CONSTRAINT: Must be atomic. If the database update fails, <br>   * the cache must not be invalidated.<br>   */<br>  updatePreferences(id: string, prefs: Partial&lt;UserProfile&gt;): Promise&lt;void | Error&gt;;<br>}<br> <br>/**<br> * Example of an Architectural Boundary.<br> * The &#39;UserService&#39; doesn&#39;t care if we use PostgreSQL or MongoDB.<br> * It only cares that the &#39;repository&#39; adheres to this contract.<br> */<br>export class UserManagement {<br>  constructor(private repository: IUserService) {}<br> <br>  async refreshUser(id: string) {<br>    const result = await this.repository.getUser(id);<br>    if (result instanceof Error) {<br>      // LOGGING: In a real architecture, this would trigger <br>      // an alert if the error is a &#39;ConnectionTimeout&#39;.<br>      console.error(`[Arch-Boundary] Failed to fetch user: ${result.message}`);<br>      return;<br>    }<br>    return result;<br>  }<br>}</pre><p>Architecture is not about finding the “right” answer. It is about documenting the reasons you chose a “wrong” answer that you can actually afford. Stop looking for the silver bullet. Start looking for the blueprint that lets you sleep through the night.</p><p><em>Originally published at </em><a href="https://www.gperrucci.com/blog/engineering/the-architects-burden"><em>https://www.gperrucci.com</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5af92b072578" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The false dichotomy of functions and objects]]></title>
            <link>https://medium.com/the-software-engineers-path/the-false-dichotomy-of-functions-and-objects-f47d9176290a?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/f47d9176290a</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[pure-function]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[oop-concepts]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Sun, 22 Mar 2026 17:46:34 GMT</pubDate>
            <atom:updated>2026-03-22T17:46:52.663Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*IbItr5TPEBrqhDhzYdxp2A.png" /></figure><p>It is common to see high-traffic content delivery pipelines collapse for hours because of a supposedly simple refactor. These failures rarely stem from complex algorithms or hardware glitches. Instead, they often arise from a fundamental misunderstanding of state. A frequent mistake involves wrapping a stateless utility function inside a heavy object that caches data it does not own. When the upstream data changes, the object remains stubborn and stale, serving outdated information to millions of users.</p><p>This failure illustrates the actual stakes of the <strong>“Function vs. Object”</strong> debate. It is rarely about syntax or which paradigm is superior in a vacuum. It is about managing complexity and understanding the hidden costs of where you put your data and how you touch it.</p><p>👉 <strong>Original article:</strong> <a href="https://www.gperrucci.com/blog/engineering/false-dichotomy-of-functions-and-objects">https://www.gperrucci.com/blog/engineering/false-dichotomy-of-functions-and-objects</a></p><h3>The modular mandate: Functions as the atomic unit</h3><p>Functions are the consequence of wanting to sleep at night. Modular programming encourages us to separate a program into components where each performs one specific task. In my twelve years of building systems for banks and gaming giants, I have found that the most resilient codebases treat functions as pure, predictable pipes.</p><p>A function takes data, processes it, and returns a result. It is a standalone, reusable piece of logic. Whether your language calls them subroutines, methods, or procedures, the goal remains the same: take a complex program and divide it into manageable pieces.</p><p>Standard library functions like print() are our baseline, but the real engineering happens when we define our own. We give them a unique name, define the body, and invoke them when needed. In languages like C or C++, we even have to declare them ahead of time to help the compiler manage memory and scope.</p><p>But there is a trap here. People often think that because a function is “reusable,” it is “decoupled.” That is a dangerous assumption.</p><p><em>Every parameter you pass into a function is a point of coupling. If a function needs six arguments to do its job, it is not a modular component; it is a hidden dependency nightmare.</em></p><h3>Objects: Packaging state and behavior</h3><p>While functions focus on the action, object-oriented programming (OOP) focuses on the entity. Understanding objects is the key to understanding modern system architecture.</p><p>In a procedural world, you have data structures on one side and functions on the other. You pass the data into the function, and the function modifies it. In OOP, we package them together. An object contains both data (properties or attributes) and the code that operates on that data (methods).</p><p>Think about a car. It has states: is the engine on? What gear is it in? How much fuel is left? It also has behaviors: accelerate, brake, turn. In programming, a software object is conceptually the same. It can represent a user account in a fintech app, a system folder, or a database table.</p><p>The beauty of the object is encapsulation. The object operates on its own data structure. This should, in theory, prevent other parts of the system from messing with internal state. However, this is where most junior to mid-level architectures fail. They create “God Objects” that try to maintain too many states and perform too many behaviors.</p><p><em>When was the last time you looked at a class and realized it was actually three different concepts masquerading as one?</em></p><h3>Socratic trade-offs</h3><p>Before you commit to a paradigm for your next feature, ask yourself these questions:</p><ul><li>Does this logic need to remember anything from the last time it was called? If the answer is no, why are you using an object?</li><li>If this object dies, does the data it holds survive somewhere else? If the data is stored in a database, your object is just a temporary wrapper. Is that wrapper adding value or just latency?</li><li>How hard is it to test this in isolation? Pure functions are trivial to test. Objects with internal state require “mocking” and “setup,” which are often indicators of architectural friction.</li><li>Are you using inheritance because it is “clean,” or because the languages’ type system forced you into a corner?</li></ul><h3>Engineering trade-offs: Performance vs. DX vs. Maintenance</h3><p>The <strong>Total Cost of Ownership (TCO)</strong> of an abstraction is measured in how many hours it takes a new engineer to understand it six months from now.</p><h3>The cost of pure functions</h3><p>Functions offer the best Developer Experience (DX) for unit testing and debugging. Since they are stateless, you do not have to worry about the “hidden context.” However, in high-scale environments, passing large data structures through deep chains of functions can lead to memory overhead if the language does not support efficient pass-by-reference or structural sharing.</p><h3>The cost of objects</h3><p>Objects provide excellent mental models for complex business logic. Mapping a “Bank Account” to an object is intuitive. But the maintenance cost is high. Objects encourage “mutable state,” and mutable state is the root of almost all concurrency bugs I have ever encountered. If two threads try to change the balance property of the same object at the same time, you are in for a long weekend of debugging.</p><h3>The Decision Heuristic: If X, then Y</h3><p>Use this rule of thumb for your daily PR reviews:</p><ul><li><strong>Use Functions (Functional Programming) when:</strong> You are transforming data, performing calculations, or writing utility logic that does not need to persist. If you can describe the task as “Take A and turn it into B,” write a function.</li><li><strong>Use Objects (OOP) when:</strong> You are modeling a long-lived entity with a complex lifecycle. If you need to track the “status” of something over time (like a user session or a hardware connection), an object is the right tool.</li></ul><h3>Production-ready implementation</h3><p>Here is how I approach this in a modern TypeScript environment, blending the best of both worlds. Note the use of interfaces for state and pure functions for logic, wrapped in a thin object layer only when necessary.</p><pre>// Define the state as a plain data structure<br>interface AccountState {<br>  readonly id: string;<br>  readonly balance: number;<br>  readonly status: &#39;active&#39; | &#39;frozen&#39;;<br>}<br> <br>// Logic is kept as pure functions for testability<br>const calculateInterest = (balance: number, rate: number): number =&gt; {<br>  if (rate &lt; 0) throw new Error(&quot;Rate cannot be negative&quot;);<br>  return balance * rate;<br>};<br> <br>// The Object serves as a controlled interface to the state<br>class BankAccount {<br>  private state: AccountState;<br> <br>  constructor(initialState: AccountState) {<br>    this.state = initialState;<br>  }<br> <br>  // Method acts as a gateway, using the pure logic internally<br>  public applyMonthlyInterest(rate: number): void {<br>    if (this.state.status === &#39;frozen&#39;) {<br>      return; // Early exit is better than nested ifs<br>    }<br> <br>    try {<br>      const interest = calculateInterest(this.state.balance, rate);<br>      this.state = {<br>        ...this.state,<br>        balance: this.state.balance + interest<br>      };<br>    } catch (error) {<br>      // Production-grade error handling<br>      console.error(`Failed to apply interest to account ${this.state.id}:`, error);<br>    }<br>  }<br> <br>  public getBalance(): number {<br>    return this.state.balance;<br>  }<br>}</pre><p>In this example, the logic for interest calculation is a pure function. It does not care about “BankAccounts” or “Status.” It just does math. This makes it incredibly easy to test. The BankAccount class manages the lifecycle and ensures that we do not apply interest to frozen accounts. This is how you build for the long term. You use objects to guard the state and functions to do the work.</p><p>👉 <strong>Original article:</strong> <a href="https://www.gperrucci.com/blog/engineering/false-dichotomy-of-functions-and-objects">https://www.gperrucci.com/blog/engineering/false-dichotomy-of-functions-and-objects</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f47d9176290a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/the-false-dichotomy-of-functions-and-objects-f47d9176290a">The false dichotomy of functions and objects</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Solving the “Zombie Instance” Problem in Distributed Systems]]></title>
            <link>https://medium.com/the-software-engineers-path/solving-the-zombie-instance-problem-in-distributed-systems-c4246f8652c9?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/c4246f8652c9</guid>
            <category><![CDATA[distributed-systems]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Tue, 10 Mar 2026 19:50:36 GMT</pubDate>
            <atom:updated>2026-03-10T19:50:36.764Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*ugn0sMURv3dKTapRC9v4kA.png" /></figure><p>One recurring nightmare in these distributed architectures is the “zombie instance.”</p><p>Imagine a fleet of EC2 instances processing stateful transactions. One instance hits a memory leak or an application-level deadlock. It has not crashed. The process is still technically running. Because the process is alive, the standard Auto Scaling Group (ASG) and Elastic Load Balancer (ELB) checks often see it as “InService.”</p><p>In reality, it is a zombie. It is not doing any work, but it is taking up a slot in your fleet. This leads to data processing gaps and delayed transactions. If you rely on simple TCP or HTTP 200 checks, you are essentially flying blind.</p><p><em>Originally published at </em><a href="https://www.gperrucci.com/blog/aws/architecting-for-resilience-zombie-instance-problem"><em>https://www.gperrucci.com</em></a><em>.</em></p><h3>Why standard checks fail</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*LJIsbk3QqW9n99tpbd7Wrg.png" /></figure><p>Traditional ELB checks usually verify if a port is open or if a static file like health.html is reachable. This is a shallow check. It tells you the web server is up. It does not tell you if the database connection pool is exhausted or if the background worker thread has hung.</p><p>I have seen teams make the mistake of relying solely on EC2 status checks. These only monitor the hardware and hypervisor. They do not see inside your JVM or Node.js runtime. Another common pitfall is writing aggressive “kill-all” scripts that terminate instances based on high CPU. High CPU is often a sign of a healthy node working hard. Killing it just shifts the load to remaining nodes, which can trigger a cascading failure.</p><h3>The strategy for deep health checks</h3><p>To solve this, I advocate for a Layer 7 Deep Health Check. This is a specialized API route, like /health/deep, that performs a circuit check of all dependencies.</p><p>This endpoint should verify:</p><ol><li>Connectivity to the primary database.</li><li>Reachability of critical caches.</li><li>The status of internal thread pools or message consumers.</li></ol><p>If any of these fail, the endpoint should return a non-200 status code. This allows the ASG to identify the instance as truly “unhealthy” rather than just “busy.”</p><h3>Graceful recovery with lifecycle hooks</h3><p>Detecting the zombie is only half the battle. If you simply kill a partially failed instance, you might interrupt a long-running, valid transaction. This is where AWS ASG Lifecycle Hooks become essential.</p><p>When an instance is marked for termination, a lifecycle hook pauses the process. This triggers a Lambda function that manages the “drain” phase. I typically configure this function to signal the application to stop accepting new work while allowing current tasks to finish. Only after the application confirms it is “clean” does the Lambda function signal the ASG to proceed with termination.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sYddBAHKEPBLZjf30bpCfg.png" /></figure><p>As Werner Vogels, CTO of Amazon, famously said, Everything fails, all the time. Our job is not to prevent failure but to build systems that recover from it automatically and gracefully. — Werner Vogels</p><h3>The Heuristic: The 30-Second Rule</h3><p>If your health check takes longer than 30 seconds to execute, it is no longer a health check. It is a performance bottleneck. Always wrap dependency checks in strict timeouts. A health check that hangs because the database is slow only makes the problem worse.</p><h3>Calculating the cost of resilience</h3><p>I often hear concerns that adding these layers is too expensive. In reality, the “Health Layer” for a mid-sized fleet usually costs less than $15 per month.</p><p>You pay for CloudWatch Custom Metrics (around $0.30 per metric) and a few cents for the Lambda executions during termination. When you compare this to the cost of a data inconsistency error or a three-hour outage, the investment is negligible.</p><h3>References</h3><ul><li><a href="https://docs.aws.amazon.com/autoscaling/ec2/userguide/health-checks-overview.html">AWS Documentation: Health checks for Auto Scaling groups</a></li><li><a href="https://docs.aws.apple.com/autoscaling/ec2/userguide/gracefully-handle-instance-termination.html">AWS Best Practices: Graceful instance termination</a></li><li><a href="https://aws.amazon.com/route53/application-recovery-controller/">Amazon Route 53 Application Recovery Controller (ARC)</a></li></ul><p>This <a href="https://www.youtube.com/watch?v=LNlwqXb87H8">guide on Route 53 health checks</a> provides a great visual breakdown of how DNS-level failover integrates with the health monitoring strategies discussed above.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c4246f8652c9" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/solving-the-zombie-instance-problem-in-distributed-systems-c4246f8652c9">Solving the “Zombie Instance” Problem in Distributed Systems</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Sticky Sessions are a Lie: How I Solved the Stateful Scaling Crisis]]></title>
            <link>https://medium.com/the-software-engineers-path/sticky-sessions-are-a-lie-how-i-solved-the-stateful-scaling-crisis-46eca356c10f?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/46eca356c10f</guid>
            <category><![CDATA[sessions]]></category>
            <category><![CDATA[redis]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Sat, 07 Mar 2026 19:23:13 GMT</pubDate>
            <atom:updated>2026-03-07T19:23:13.689Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KhUNX_xQgKk4tJzx7_sGlw.png" /></figure><p><strong>The “Sticky Session” trap</strong></p><p>Enabling Application Load Balancer (ALB) stickiness feels like an easy win, but it is a false economy. It breaks true elasticity. If one instance gets slammed, the load balancer keeps sending “stuck” users to that same dying node instead of spreading the wealth.</p><p><em>I break down the full architectural strategy, including best practices and Multi-AZ failover, in the </em><a href="https://www.gperrucci.com/blog/engineering/stateful-scaling-crisis"><em>original post </em></a><em>on my personal blog.</em></p><p><strong>Decoupling compute from state</strong></p><p>To scale properly, you have to make your application nodes stateless. In a recent project for a high-traffic system, I moved session storage from local RAM to a centralized Amazon ElastiCache for Redis cluster.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*1TnSgiBj0iUP324uNVofUg.png" /></figure><p><strong>The Failover Factor</strong></p><p>By externalizing state, the ALB can use a “least requests” algorithm. Any instance in your fleet can pick up any request because they all fetch data from the same global cache. If an instance fails, no one loses their progress.</p><p><strong>Security and Cost</strong></p><p>Using IAM Authentication for Redis is much cleaner than managing static passwords. For about $75 a month, you can run a high-availability Primary/Replica setup that prevents localized outagesand saves you from a mountain of support tickets.</p><p><em>I break down the full architectural strategy, including best practices and Multi-AZ failover, in the </em><a href="https://www.gperrucci.com/blog/engineering/stateful-scaling-crisis"><em>original post </em></a><em>on my personal blog.</em></p><h3>References and resources</h3><p><a href="https://docs.aws.amazon.com/elasticache/">Amazon ElastiCache for Redis Documentation</a></p><p><a href="https://aws.amazon.com/blogs/database/best-practices-valkey-redis-oss-clients-and-amazon-elasticache/">Best Practices for Valkey and Redis OSS Clients and Amazon ElastiCache</a></p><p><a href="https://aws.amazon.com/elasticache/pricing/">ElastiCache Pricing Guide</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=46eca356c10f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/sticky-sessions-are-a-lie-how-i-solved-the-stateful-scaling-crisis-46eca356c10f">Sticky Sessions are a Lie: How I Solved the Stateful Scaling Crisis</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why I moved from native AWS SQS to BullMQ for high traffic systems]]></title>
            <link>https://medium.com/the-software-engineers-path/why-i-moved-from-native-aws-sqs-to-bullmq-for-high-traffic-systems-94c5e263c739?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/94c5e263c739</guid>
            <category><![CDATA[bullmq]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[redis]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Fri, 06 Mar 2026 07:38:27 GMT</pubDate>
            <atom:updated>2026-03-06T07:38:27.146Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*NVBUsYsMe5KCOGBhpeZ82g.png" /></figure><blockquote>Are you actually scaling your background processing, or are you just adding managed services to hide the bottlenecks? In my experience, throwing more infrastructure at a queue problem often results in higher bills rather than better performance.</blockquote><p>Building a high performance architecture for async tasks requires more than just a queue. It requires a deep understanding of how your workers interact with your data store and your infrastructure.</p><p>Here are the core lessons I have learned while building systems for a large platform.</p><ul><li><strong>Redis is your engine.</strong> BullMQ relies entirely on Redis performance. While AWS offers many managed options, I always lean toward ElastiCache. Avoid serverless Redis if you need predictable latency during sudden spikes. In my previous work, the overhead of serverless cold starts was a constant pain point.</li><li><strong>Concurrency requires a scalpel.</strong> You cannot just set a high concurrency number and hope for the best. If you set it too high, you will choke your CPU. If you set it too low, you are leaving money on the table. I start by matching the core count of the worker instance. Then, I adjust based on the time spent waiting for I/O operations.</li><li><strong>Horizontal scaling is the only way forward.</strong> I treat workers as independent units of scale. By deploying them in separate containers, we can ramp up processing power without impacting the main API. This isolation also ensures that a single heavy job cannot take down the entire system.</li><li><strong>Don’t ignore stalled jobs.</strong> Network blips happen. In high traffic environments, these blips lead to stalled jobs. BullMQ has an excellent lock mechanism. However, you must tune the lock duration to match your heaviest task. If the lock expires too early, you end up with duplicate processing. If it is too long, a crashed worker will block that job for far too long.</li></ul><p>As the official BullMQ documentation notes, the library is designed for “Exactly once queue semantics” and is “Easy to scale horizontally.” This simplicity is exactly why I prefer it over more complex enterprise brokers.</p><p><em>“This is just the tip of the iceberg. I break down the full strategy with examples in the original post on my personal blog. </em><a href="https://www.gperrucci.com/blog/aws/scaling-async-workloads-bullmq-aws"><em>Click here to read the full article</em></a><em>”</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=94c5e263c739" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/why-i-moved-from-native-aws-sqs-to-bullmq-for-high-traffic-systems-94c5e263c739">Why I moved from native AWS SQS to BullMQ for high traffic systems</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Stop Confusing Libraries with Frameworks (It’s Ruining Your Architecture)]]></title>
            <link>https://medium.com/the-software-engineers-path/stop-confusing-libraries-with-frameworks-its-ruining-your-architecture-2a072025ca06?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/2a072025ca06</guid>
            <category><![CDATA[libraries]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[framework]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Tue, 16 Dec 2025 11:22:37 GMT</pubDate>
            <atom:updated>2025-12-16T11:22:37.296Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*q_yKZnD4LDIuFf0N9dsLgA.png" /><figcaption>Library vs Framework</figcaption></figure><p>Spaghetti code often isn’t the result of bad coding skills, it’s the result of bad architectural definitions.</p><p>In my years auditing codebases, I’ve noticed a recurring pattern: developers treating <strong>libraries</strong> like frameworks (resulting in a lack of structure) or treating <strong>frameworks</strong> like libraries (resulting in a constant fight against the tool).</p><blockquote>Original post on my personal blog. <a href="https://www.gperrucci.com/en/blog/engineering/library-vs-framework-decision-matrix">Click here to read the full article</a></blockquote><p>The distinction isn’t about file size, popularity, or complexity. It comes down to a single, non-negotiable principle.</p><p>Here is the heuristic I use to make the decision:</p><p><strong>The Litmus Test is “Inversion of Control”:</strong></p><ul><li><strong>Library:</strong> You call the code. You are the director. You decide when to render, when to fetch data, and when to route.</li><li><strong>Framework:</strong> The code calls you. The framework provides the stage and the script; you just fill in your lines at the right time (e.g., ngOnInit).</li></ul><p><strong>The Hollywood Principle:</strong></p><p>I tell junior engineers to think of frameworks as the Hollywood agent:</p><blockquote>“Don’t call us, we’ll call you.”</blockquote><p>If you are manually stitching together the entry point and execution flow, you are likely using a library. If you are writing classes that get magically instantiated by a scanner, you are in a frmework.</p><p><strong>Trade-Offs over Hype:</strong></p><ul><li><strong>Choose a Library</strong> when you need <strong>granular control</strong> (e.g., a complex data visualization tool) or when your problem is highly specific.</li><li><strong>Choose a Framework</strong> when you need <strong>velocity and consistency</strong> across a large team. You trade architectural freedom for the ability to onboard new developers instantly.</li></ul><p><strong>The Modern Confusion (React vs. Next.js):</strong></p><p>React is a library , it only cares about views. Next.js is a framework , it dictates your routing, file structure, and data fetching. If you try to force Next.js to behave like a loose collection of libraries, you will lose.</p><p>Original post on my personal blog. <a href="https://www.gperrucci.com/en/blog/engineering/library-vs-framework-decision-matrix">Click here to read the full article</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2a072025ca06" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/stop-confusing-libraries-with-frameworks-its-ruining-your-architecture-2a072025ca06">Stop Confusing Libraries with Frameworks (It’s Ruining Your Architecture)</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Stop Wasting Time: The 3 Pairing Styles That Actually Ship Better Code]]></title>
            <link>https://medium.com/the-software-engineers-path/stop-wasting-time-the-3-pairing-styles-that-actually-ship-better-code-5556fdcd047e?source=rss-9a903221e6d0------2</link>
            <guid isPermaLink="false">https://medium.com/p/5556fdcd047e</guid>
            <category><![CDATA[driver-navigator]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[pair-programming]]></category>
            <dc:creator><![CDATA[Gerardo Perrucci]]></dc:creator>
            <pubDate>Tue, 16 Dec 2025 08:19:56 GMT</pubDate>
            <atom:updated>2025-12-16T08:19:56.757Z</atom:updated>
            <content:encoded><![CDATA[<p>Let’s be honest. Most people hate pair programming.</p><p>Why? Because they do it wrong.</p><p>They sit together and one person types while the other person checks email. That’s not collaboration. That’s a highly paid spectator sport.</p><p>I’ve spent 12 years building software, and I can tell you this: <strong>Pairing is the single best investment you can make in code quality and team knowledge transfer</strong>. But you need structure.</p><p>If you jump into pairing without a defined style, you are going to waste time. Here are the three non-negotiable patterns you must use to make collaboration a productivity engine.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jXnzDf6Qssf8Mhi57DjKZQ.png" /></figure><h3>1. Driver/Navigator: The Essential Starter Kit</h3><p>This is the baseline structure. It’s what you use 80% of the time, especially when tackling features that require focused execution.</p><ul><li><strong>The Driver</strong> types. Their focus is 100% on the moment: translating the idea into working syntax.</li><li><strong>The Navigator</strong> guides. They look ahead, check for mistakes, and ensure the team is aligned with the overall design.</li></ul><p><strong>The Key Rule:</strong> <strong>You must swap roles every 10–15 minutes.</strong> If you don’t enforce this rotation, one person quickly becomes the passive observer. Ownership needs to be actively shared.</p><h3>2. Ping-Pong: The Code Quality Enforcer</h3><p>Do you practice Test-Driven Development (TDD)? Then you should be doing Ping-Pong.</p><p>This style forces a rapid, focused rhythm that ties implementation directly to testing. It is a brilliant way to ensure high code coverage.</p><ul><li><strong>Developer A</strong> (Ping) writes a failing test.</li><li><strong>Developer B</strong> (Pong) writes the minimal code to make that test pass.</li><li><strong>Developer A</strong> then either writes the next failing test or refactors the existing code.</li></ul><p>This pattern is a continuous loop of testing, coding, and quality assurance. <strong>If your project goal is to be highly testable, this is your style.</strong></p><h3>3. Strong Style: The Mentorship Accelerator</h3><p>This is my favorite trick for senior-to-junior knowledge transfer.</p><p>In Strong Style, the person with the solution (usually the senior engineer) <strong>cannot touch the keyboard.</strong> They are the Navigator.</p><p>The junior engineer is the Driver. They are the only one who types.</p><p>This forces the senior engineer to articulate their thoughts clearly, and it forces the junior engineer to internalize the logic by typing every keystroke. <strong>For an idea to enter the computer, it must pass through the other person’s hands.</strong></p><p>It might feel slower at first, but it accelerates ramp-up time for new team members exponentially.</p><h3>When To Just Code Alone</h3><p>Pairing is an investment, but not every task deserves two developers:</p><ul><li><strong>Boilerplate tasks:</strong> Simple file creation, repetitive configuration, or non-complex refactoring.</li><li><strong>Deep, uninterrupted focus:</strong> Debugging a highly intermittent, specific bug deep in a legacy system.</li><li><strong>Personality clashes:</strong> If the two engineers are not compatible or unwilling to communicate, it’s a net negative.</li></ul><p>Use these three structures to make your pairing sessions focused, intentional, and high-value. Stop screen-sharing and start collaborating.</p><p>Original post on my personal blog. <a href="https://www.gperrucci.com/en/blog/engineering/pair-programming-styles">Click here to read the full article</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5556fdcd047e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/the-software-engineers-path/stop-wasting-time-the-3-pairing-styles-that-actually-ship-better-code-5556fdcd047e">Stop Wasting Time: The 3 Pairing Styles That Actually Ship Better Code</a> was originally published in <a href="https://medium.com/the-software-engineers-path">The Software Engineer’s Path</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>