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
mrubyとWebサーバ
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
MATSUMOTO Ryosuke
PRO
June 22, 2013
Programming
1.3k
6
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
mrubyとWebサーバ
mrubyをWebサーバソフトウェアに組み込む
MATSUMOTO Ryosuke
PRO
June 22, 2013
More Decks by MATSUMOTO Ryosuke
See All by MATSUMOTO Ryosuke
問いを起点に、社会と共鳴する知を育む場へ
matsumoto_r
PRO
0
910
さくらインターネット研究所 アップデート2025年
matsumoto_r
PRO
0
960
リモートワークにおけるパッシブ疲労
matsumoto_r
PRO
6
5.6k
エンジニアのキャリアパスはどう描く? まつもとりーさんと考える後悔しないキャリア選択
matsumoto_r
PRO
10
2.5k
まつもとりーのこれまでとCOGNANOのこれから
matsumoto_r
PRO
0
390
2022年の研究所の評価制度振り返りと今後
matsumoto_r
PRO
0
940
VUCAワールドから紐解く組織や評価制度の変遷と再設計
matsumoto_r
PRO
9
27k
コンテナの研究開発から学ぶLinuxの要素技術
matsumoto_r
PRO
2
1.6k
開発者体験をさらに向上させる 事業と研究との連携
matsumoto_r
PRO
2
2.6k
Other Decks in Programming
See All in Programming
Flow は今どうなっているか
mizdra
PRO
0
910
MIZARU@SPAJAM2026 第二回予選
1901drama
0
100
Oxlintはいいぞ(続)
yug1224
1
540
typoなんかねぇよ
raspython3
0
660
初めての模倣学習とVLA
natsutan
0
460
私のClaude Code活用法 (個人開発編) - PHPerKaigi mini #4(2026/08/24)
panda_program
1
210
ALB ログから Trace を気合で繋げる技術
fohte
7
860
The Good Stuff, Not the Slop: Engineering High-Quality Android Apps with Modern AI Tooling
danybony
1
180
What We Talk About When We Talk About XP
m_seki
2
350
Seeing Through Serverless: Observability for AWS Lambda with ADOT and CloudWatch Application Signals
seike460
PRO
1
120
思考垂れ流し開発 ~音声入力 × AIエージェント × 開発ハーネスによる試行錯誤~
npostring
0
810
新卒PdEのリアル
ryu1013
1
380
Featured
See All Featured
The SEO identity crisis: Don't let AI make you average
varn
0
550
SEO Brein meetup: CTRL+C is not how to scale international SEO
lindahogenes
1
2.9k
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.6k
How to make the Groovebox
asonas
2
2.4k
Large-scale JavaScript Application Architecture
addyosmani
515
110k
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.8k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
400
Ethics towards AI in product and experience design
skipperchong
2
360
Bash Introduction
62gerente
615
220k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
How to Build an AI Search Optimization Roadmap - Criteria and Steps to Take #SEOIRL
aleyda
1
2.2k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.3k
Transcript
mrubyとWebサーバ Kyoto University okabe lab MATSUMOTO, Ryosuke
• 松本 亮介 (@matsumotory) • 京都大学 岡部研 博士課程
– ウェブサーバの高度化に耐えうる基盤設計 – 大規模、運用、セキュリティ、性能、拡張 • フリーランスエンジニア
Agenda • mrubyの概要 • mod_mrubyとngx_mruby • ab-‐mruby
mrubyの概要 • 組み込みスクリプト言語 – C/C++ホストアプリケーションを主 • 最適化が容易
– Pluggable、組み込みAPI • 拡張の書きやすさ – mrubyをC実装のフレームワークのようにも使える • 応用範囲が広い – 組み込み機器、アプリ組み込み • 数年後を見据えて – mrubyの要求するスペックに組み込み機器が追いつく
mod_mrubyとngx_mruby • Apache、nginxモジュールをRubyで書ける – Rubyの記述による生産性の向上 – Webサーバを容易に拡張 • 高速性・軽量性
– ApacheCon NA 2013でmod_luaと速度比較された – mod_mrubyをかなり意識 • Rubyアプリの延長でWebサーバ拡張 – Webサーバソフトウェアの違いをmrubyで吸収 – mrubyによるWebサーバ拡張記述の標準化
VirtualHost by mod_mruby
Proxy by mod_mruby
BasicAuth by mod_mruby
BasicAuth with Redis by mod_mruby
suEXEC by mod_mruby
Access control by traffic
demo • Apacheの内部情報をmod_mrubyでAPI化 • node.jsからAPI経由で情報をグラフ化 • hYp://mon.matsumoto-‐r.jp/ Apache
api.rb (Ruby) node.js browser WebSocket JSON mod_mruby
ab-‐mruby • abコマンドのmruby拡張 • Rubyでベンチマークパターンを記述 • Rubyでテストスイートを記述
• URLを元に動的に記述できる
ベンチマークパターン
テストスイート
ab-‐mruby実行 ab-‐mruby –m config.rb -‐M test.rb hYp://192.168.12.251/
まとめ • mod_mrubyとngx_mruby – Webサーバ拡張の敷居を下げたい – 高速性・軽量性
– mod_mruby、ngx_mrubyによる拡張記述標準化 • Register Underflow (hYps://registerunderflow.org/) – Stack Overflowのようなコンピュータ技術共有サイト – 日本語版 TwiYer: @matsumotory