Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
The Worker Pattern
Search
Lee Jones
March 07, 2013
Programming
370
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
The Worker Pattern
A Lightning Talk I gave at the March 7, 2013 Nashville Ruby on Rails Meetup.
Lee Jones
March 07, 2013
More Decks by Lee Jones
See All by Lee Jones
Continuous Improvement
leejones
1
350
Getting Started with Docker
leejones
0
350
Cache Me If You Can
leejones
2
380
Packaging Rails Applications
leejones
0
75
Other Decks in Programming
See All in Programming
AIと壁打ちしながら進めるコスト管理
fufuhu
2
1.9k
My Marp Sample
sinoue0108
0
140
PHPプロジェクトの結合バランスを可視化する #php_night
kajitack
0
210
Hono + Inertia + React で LP を構築した話
oukayuka
2
200
LL言語やWebフレームワークのPostgreSQL対応 〜DBの機能がユーザーに届くまで〜
kentaroutakeda
0
130
一参加者から『中の人』へ 〜全通PHPerがブースに立って学んだ、カンファレンスを100倍楽しむコツ〜
wp_daisuke
0
110
Swift愛好会と私(ウホーイ) / Swift Fan Club and Uhooi
uhooi
0
120
kubernetes コンポーネント開発入門 / 新卒N年目の勉強会&交流会!〜〇〇への誘い〜 #n_study
mazrean
0
160
Go 1.27からのGODEBUG / Go 1.27 リリースパーティ #go127party
mazrean
0
300
「AI時代、配布するPythonコードをどう守るか: 難読化の実験と判断軸」 #PyconJP2026
pkshadeck
PRO
2
150
AI に Inclusive UI を書かせよう — Design Rules Skill で Compose UI を作り直す
theoriatec2024
1
440
バグを直したら useEffect が消えた
colorful12
3
830
Featured
See All Featured
Rebuilding a faster, lazier Slack
samanthasiow
85
9.6k
The Art of Programming - Codeland 2020
erikaheidi
57
14k
Claude Code のすすめ
schroneko
67
230k
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
570
Imperfection Machines: The Place of Print at Facebook
scottboms
270
14k
Practical Orchestrator
shlominoach
191
12k
Everyday Curiosity
cassininazir
0
310
Sam Torres - BigQuery for SEOs
techseoconnect
PRO
0
530
Ten Tips & Tricks for a 🌱 transition
stuffmc
0
190
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
Measuring Dark Social's Impact On Conversion and Attribution
stephenakadiri
2
270
Unsuck your backbone
ammeep
672
58k
Transcript
The Worker Pattern Thursday, March 7, 13
Confession Thursday, March 7, 13
BACKGROUND ALL THE THINGS! Thursday, March 7, 13
Request work •••••••••••• Thursday, March 7, 13
Example Acme API Feed * item 1 * item 2
* item 3 ... Thursday, March 7, 13
class AcmeIntegrationController def index api = AcmeAPI.new(user_token) @feed = api.get_user_feed
end end Thursday, March 7, 13
I heard you requests... so i put a request inside
your request Thursday, March 7, 13
class AcmeIntegrationController def index if fragment.exists? @feed = fragment.data else
fragment.fetch_in_background @feed = nil end ... Thursday, March 7, 13
# app/views/acme_integration/index.html <% if @feed.present? -%> <%= render @feed %>
<% else -%> <%= feed_fragment_helper %> <% end -%> Thursday, March 7, 13
Example Acme API Feed loading... Thursday, March 7, 13
http status 204 http://httpstatus.es/204 Thursday, March 7, 13
Example Acme API Feed * item 1 * item 2
* item 3 ... Thursday, March 7, 13
The Worker Pattern resources Ryan Smith: * slides: rails conf
2010 * Video: talk at waza 2011 Rack Worker on Github speakerdeck.com/leejones ••• Thursday, March 7, 13