COSCUP x UbuCon Asia 2026 標誌
  • 關於我們
  • 議程
  • 交通
  • 會場地圖
  • 社群
  • 贊助夥伴
    • 參與指南
    • 第一次參與
    • 活動參與
    • 講者參與
    • 前夜派對
    • 海外參與者
    • 開源社群、攤位及議程軌
    • 贊助夥伴
    • 邀請函申請指南
  • 工作人員
  • 周邊活動 / BoF
  • 部落格
  • 社群守則
English

Stoplight: Circuit Breakers for Ruby in the AI Era

時間
2026-08-08 14:10 ~ 14:40
講者
Georgy Asfur
位置
TR514
共筆
Ruby Taiwan 中階英語

議程簡介

A slow third-party API can take down your entire Rails app. One service starts timing out, requests pile up waiting for it, threads block, memory fills, and suddenly nothing responds - not even the parts of your app that have nothing to do with the failing service. This is a cascading failure.

Until recently, this was a problem for large engineering teams running dozens of services. But in 2026, even a small startup is calling out to LLMs, OCR engines, and other third-party APIs. Every one of those calls is a potential domino. Circuit breakers belong in any Ruby app shipping AI features.

This talk introduces the circuit breaker pattern through Stoplight, an MIT-licensed Ruby gem, I co-maintain with Tema Bolshakov. I'll start by unpacking how a single slow dependency cascades into a full outage, then walk through how Stoplight prevents it - and why its traffic-light metaphor (green/yellow/red) is more intuitive than the classical open/closed/half-open vocabulary.

The second half peels back the curtain on how we made Stoplight fast. Coordinating circuit breaker state across multiple Ruby processes means hitting Redis on every call, and a naive implementation incurs several round-trips per check. We'll look at how we collapsed those into single atomic Lua scripts - a technique that improved Stoplight's performance substantially and applies to anyone building Ruby tooling on top of Redis.

Outline (30 min):

  • (5 min) Cascading failures in the AI era
  • (6 min) The circuit breaker pattern and the traffic-light reframe
  • (6 min) Stoplight in practice: defaults, fallbacks, Rails integration
  • (8 min) Gem internals: improving performance with Lua scripts
  • (5 min) Stoplight admin panel, takeaways, Q&A

Target audience: Ruby and Rails developers building apps with external or AI service dependencies. However, the concepts from this talk translate to any language.

Background: Basic Ruby and a rough idea of what Redis is. No prior exposure to the circuit breaker pattern or the concept of cascading failure is needed.

Links:

  • Stoplight gem: https://github.com/bolshakov/stoplight
  • Companion article: https://evilmartians.com/chronicles/circuit-breakers-and-ruby-in-2025-dont-break-your-launch

講者

Georgy Asfur

Georgy Asfur

I'm Georgy (ゲオルギ), and I build backend applications written in Ruby (and sometimes in Go). Currently, I'm based in Osaka, Japan, and work at Evil Martians (https://evilmartians.com/), which puts a lot of effort into OSS. I occasionally contribute to OSS projects, but mainly I co-maintain Stoplight (https://github.com/bolshakov/stoplight/) - an OSS implementation of the circuit breaker pattern in Ruby. Besides writing code, I'm a huge coffee junkie, so I'll appreciate any coffee shop recommendations in Taipei.

鑽石級

Canonical

黃金級

連續贊助2 年中華民國資訊經理人協會連續贊助2 年國泰金融控股公司連續贊助5 年玉山銀行累計贊助12 年MySQL累計贊助6 年華捷智能股份有限公司Nitra

白銀級

累計贊助16 年慧邦科技股份有限公司  Gamesofa Inc.

青銅級

華娛網路娛樂股份有限公司財團法人國家實驗研究院國家高速網路與計算中心ONLYOFFICEQNAP Systems, Inc. 威聯通科技連續贊助16 年祐生研究基金會源鋼技術顧問有限公司 SUN SQUARE Co., Ltd

好朋友級

連續贊助3 年晶心科技股份有限公司沛星互動科技股份有限公司

特別感謝

連續贊助2 年臺北市政府資訊局美商賽發馥股份有限公司臺灣分公司Rozeta AI

共同主辦單位

累計合作9 年臺灣科技大學 電子工程系

協辦單位

累計合作12 年開放文化基金會

COSCUP x UbuCon Asia 2026

Conference for Open Source Coders, Users, and Promoters | 亞洲最大開源年會,由社群自發舉辦。

聯絡我們

  • 會眾服務
  • 贊助合作
  • 議程投稿
  • 行銷方案

相關資源

  • COSCUP 部落格
  • 訂閱電子報
  • 活動照片

網站導覽

  • 首頁
  • 關於我們
  • 交通資訊
  • 贊助夥伴
20062007200820092010201120122013201420152016201720182019202020212022202320242025