<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Amine Mbarki</title>
    <description>The latest articles on DEV Community by Amine Mbarki (@aminembarki).</description>
    <link>https://dev.to/aminembarki</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F247984%2Ff5bbb01c-b7cf-44cf-b577-9762f2d0f344.png</url>
      <title>DEV Community: Amine Mbarki</title>
      <link>https://dev.to/aminembarki</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/aminembarki"/>
    <language>en</language>
    <item>
      <title>Apify went down yesterday. Our monitoring business didn't notice.</title>
      <dc:creator>Amine Mbarki</dc:creator>
      <pubDate>Wed, 22 Jul 2026 11:50:14 +0000</pubDate>
      <link>https://dev.to/aminembarki/apify-went-down-yesterday-our-monitoring-business-didnt-notice-78f</link>
      <guid>https://dev.to/aminembarki/apify-went-down-yesterday-our-monitoring-business-didnt-notice-78f</guid>
      <description>&lt;p&gt;Yesterday afternoon, &lt;a href="https://status.apify.com" rel="noopener noreferrer"&gt;Apify had an incident&lt;/a&gt;. If your scraping pipeline lives entirely on their platform, you know exactly what that afternoon felt like: stalled runs, missing data windows, refreshing the status page.&lt;/p&gt;

&lt;p&gt;Our price-monitoring pipelines didn't miss a single cycle. Not because we got lucky — because of an architecture decision we made months ago that I want to talk you into copying.&lt;/p&gt;

&lt;h2&gt;
  
  
  The architecture: self-hosted first, managed as insurance
&lt;/h2&gt;

&lt;p&gt;We run &lt;a href="https://crawlee.cloud" rel="noopener noreferrer"&gt;Crawlee Cloud&lt;/a&gt; — a self-hosted, open-source platform that implements the Apify API — as our &lt;strong&gt;primary&lt;/strong&gt;. Apify itself is our &lt;strong&gt;fallback&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;Read that again, because the order is backwards from what most teams do. The open-source thing on our own droplets is production. The managed platform is the insurance policy.&lt;/p&gt;

&lt;p&gt;This works for one reason: &lt;strong&gt;both platforms speak the same protocol.&lt;/strong&gt; Our Actors use the official, unmodified Apify SDK. They genuinely don't know which platform they're running on. Same &lt;code&gt;Actor.pushData()&lt;/code&gt;, same datasets, same request queues. Failover isn't a rewrite or an adapter layer — it's a base URL.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;┌────────────────────────────────────────────┐
│              Your Actors                   │
│   (official Apify SDK, zero code changes)  │
└─────────┬──────────────────────┬───────────┘
          │ primary              │ fallback
          ▼                      ▼
   Crawlee Cloud            Apify platform
   (your droplets)          (their cloud)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yesterday that architecture earned its keep: 100% uptime for pipelines whose entire value proposition is freshness, on a day the upstream platform was having a bad time.&lt;/p&gt;

&lt;h2&gt;
  
  
  It's also 3x cheaper
&lt;/h2&gt;

&lt;p&gt;The failover story is the dramatic part, but the boring part is what made the decision easy in the first place: &lt;strong&gt;on real production runs, our costs dropped roughly 3x versus running the same workloads on Apify.&lt;/strong&gt; Actual client workloads, compared invoice to invoice — I track runner costs daily from our DigitalOcean billing export.&lt;/p&gt;

&lt;p&gt;The mechanics are simple. Metered platforms charge per compute unit, per proxy GB, per storage op. Great for prototypes, punishing at scale: your bill grows linearly with your success. Self-hosted runners are flat droplet-hours on infrastructure you already pay for. Scale up for a backfill, scale down after, using the same tooling as the rest of your stack. The heavier your usage, the wider the gap.&lt;/p&gt;

&lt;p&gt;(Fair caveat before the comments write it for me: that's infrastructure cost only. You're trading dollars for ops ownership. Keep reading — that trade is exactly what the rest of this post is about.)&lt;/p&gt;

&lt;h2&gt;
  
  
  The part where I admit how this was built
&lt;/h2&gt;

&lt;p&gt;A large share of Crawlee Cloud was written with heavy AI assistance. Vibe-coded, if you like. I'm not embarrassed by that, but I learned something important from it: &lt;strong&gt;AI writes plausible code, not audited code.&lt;/strong&gt; During a deep review of my own codebase I found an insecure default, a container network isolation gap, and a Docker network name mismatch — all generated confidently, all wrong.&lt;/p&gt;

&lt;p&gt;Building has become trivial. Any developer with an AI assistant can scaffold an actor orchestrator in a weekend — I've watched three separate teams in my own network each grow their own private, 80%-identical, half-maintained version. The hard part was never generation. It's verification, hardening, and the 3am pager. Those costs didn't go away when the first draft became free.&lt;/p&gt;

&lt;h2&gt;
  
  
  Which is the whole argument for sharing one codebase
&lt;/h2&gt;

&lt;p&gt;If everyone can build it and nobody wants to maintain it, the worst outcome is a thousand private forks each carrying a full maintenance burden alone. The rational move is one shared, MIT-licensed codebase where the maintenance is split:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;I fix sticky-session handling → your deployment gets it.&lt;/li&gt;
&lt;li&gt;You harden runner isolation → mine gets it.&lt;/li&gt;
&lt;li&gt;Someone adds a MinIO edge case for their compliance setup → everyone gets it.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Open source has always made this argument. AI made it sharper: when writing code costs nothing, all the value concentrates in the shared, battle-tested, collectively audited artifact.&lt;/p&gt;

&lt;h2&gt;
  
  
  Steal this setup
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;git clone https://github.com/crawlee-cloud/crawlee-cloud
&lt;span class="nb"&gt;cd &lt;/span&gt;crawlee-cloud
docker compose up
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Point your existing Actors at it. Keep Apify configured as fallback if you want the same insurance we have — the protocol compatibility means you never have to pick a side, and either platform can cover for the other.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;⭐ &lt;a href="https://github.com/crawlee-cloud/crawlee-cloud" rel="noopener noreferrer"&gt;Star the repo&lt;/a&gt; — it's how other teams find this instead of vibe-coding their own.&lt;/li&gt;
&lt;li&gt;🐛 Break it on your weird infra and file issues.&lt;/li&gt;
&lt;li&gt;🔀 Send the PR you'd otherwise keep in a private fork.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Vendor lock-in isn't just a pricing problem. Yesterday it was an uptime problem. One shared open codebase solves both.&lt;/p&gt;

</description>
      <category>webscraping</category>
      <category>opensource</category>
      <category>devops</category>
      <category>selfhosted</category>
    </item>
  </channel>
</rss>
