Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
How does the unicorn work
Search
CucumisSativus
February 19, 2015
Technology
74
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
How does the unicorn work
Presentation shwon on 19.02.2015 at Łódź Ruby user Group
CucumisSativus
February 19, 2015
More Decks by CucumisSativus
See All by CucumisSativus
Cool things in dry-rb
cucumissativus
0
68
Neural networks basis
cucumissativus
0
82
Ruby - Hashe pod maską
cucumissativus
0
46
Rubinius vs. CRuby
cucumissativus
0
61
Garbage Collector w ruby
cucumissativus
0
94
Other Decks in Technology
See All in Technology
仕様と現実の間で落とし所を探るリモートMCPの認証・認可 — Sansanの認証基盤における課題と実践
sansantech
PRO
2
230
狙われているAPIの脆弱性!今こそ手をつけるべき根本的な対策とは?
nagix
0
110
The Author Pays
hiccupps
0
150
属人化したISMS運用をGitHubとAIで仕組み化した1年間の記録
sioncojp
4
1.9k
Content Mapper APIの応用例~CSS Modules、言語ファイル~
uhyo
2
630
Copilot Coworkで「みのるん式」やってみた
minorun365
PRO
2
1.7k
re:Invent2026 事前勉強会 歴史と愉しみ方10分LT編
toshi_atsumi
0
180
AWS基盤改善を支える 私たちの理念と行動指針
kentosuzuki
0
140
続・ソフトウェアアーキテクトのための意思決定術: Decision Readiness, Revisited — When AI Changes the Economics of Software Architecture
snoozer05
PRO
9
2.8k
[dbts2026]数十PBの超巨大データ×AI活用を支えるSnowflakeの実力〜大規模環境におけるアーキテクチャと運用のリアル〜
y_matsubara
0
130
Active Directory と Entra ID のむむむな関係
murachiakira
PRO
4
1.7k
evcc & Home Assistant
naltatis
0
490
Featured
See All Featured
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
470
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
660
Redefining SEO in the New Era of Traffic Generation
szymonslowik
1
520
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
650
AI in Enterprises - Java and Open Source to the Rescue
ivargrimstad
0
1.6k
Odyssey Design
rkendrick25
PRO
2
930
Self-Hosted WebAssembly Runtime for Runtime-Neutral Checkpoint/Restore in Edge–Cloud Continuum
chikuwait
0
930
Build The Right Thing And Hit Your Dates
maggiecrowley
39
3.5k
Music & Morning Musume
bryan
48
7.5k
Making Projects Easy
brettharned
120
6.9k
Utilizing Notion as your number one productivity tool
mfonobong
4
640
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.4k
Transcript
How does the Unicorn work? Michał Gutowski Binar::Apps
[email protected]
/
[email protected]
Agenda • Basic info • Rack • Connection handling •
Forking & load balancing • Parsing HTTP requests • Restarting
Basic info • Commonly used web server for RoR applications
• Rack based • uses traditional Unix prefork mode • and Unix signals
Rack • Interface between Ruby and Ruby frameworks • Wraps
HTTP requests and responses • You can exchange rack based severs without changing application
Connection handling • Master process creates listening socket • When
new connection arrives child process and new socket are created • Operating system takes care of load balancing
Parsing HTTP requests • Taken from Mongrel • Uses Ragel
state machine
None
Restarting • Possibility to hot swap • In case of
failure possibility to roll back 1. USR2 to master process 2. WHINCH to old master 3. QUIT to old master * in case of trouble HUP to reload old master and QUIT to new master
References • https://github.com/blog/517-unicorn • http://tomayko.com/writings/unicorn-is-unix • http://unicorn.bogomips.org/
ujeb.se/JMVA