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
YAPC::Fukuoka lunch session
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Harukasan
PRO
July 01, 2017
Technology
3.2k
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
YAPC::Fukuoka lunch session
YAPC::Fukuoka ランチスポンサーセッション
2017-07-01
Harukasan
PRO
July 01, 2017
More Decks by Harukasan
See All by Harukasan
Harucom Follow-up
harukasan
PRO
1
60
Building a Standalone Programming Environment
harukasan
PRO
1
2.2k
Successor to PicoRabbit: Ruby Programming Envorinment / RubyKaigi 2025 follow up
harukasan
PRO
1
1.4k
Write your own mrbgem, Create your own device
harukasan
PRO
1
490
PicoRabbit: a Tiny Presentation Device Powered by Ruby
harukasan
PRO
2
2k
pixivを支える技術 / 技育CAMPアカデミア
harukasan
PRO
3
660
20240401 新卒研修 - ピクシブにおける技術領域
harukasan
PRO
1
980
ピクシブのコンテンツ配信基盤技術 / pixiv TECH SALON
harukasan
PRO
5
6k
Goにおける画像ファイル処理 / golang.tokyo #19
harukasan
PRO
7
6.9k
Other Decks in Technology
See All in Technology
アカウント統制の健康診断
kenichinakamura
1
200
AWSセキュリティで活用するAI機能
cmusudakeisuke
1
310
2026-10-24 JAWS JAWS-UG 茨城 #18 IAM Policy Autopilotってなにさ。terraform planからIAM Policyつくれるの? / What's IAM Policy Autopilot
masasuzu
0
170
演劇と私とスクラム
chinmo
0
160
freeeにおけるSoftware Factory
freee
PRO
0
530
Draft AIエージェントの トークン消費を最小化する 8つの原則
kinopeee
5
1.7k
AWS Continuum for Penetration Testing に Deep Dive してみる
asanoharuki
1
1.4k
1週間、Opus封印でお願いします
kintotechdev
0
190
Devin プロモコードの受け取りと適用(2026.10.27)
kinopeee
0
530
LLM Content Moderationを支える評価・改善ループの実践
suikabar
2
360
正解のない研修に放り出されて / Being thrown into a training program with no right answers
ohnoeight
1
150
CSS2026:OWS研究会・招待講演「世界観を、実装する」
atsush1_sada
2
340
Featured
See All Featured
Typedesign – Prime Four
hannesfritz
42
3.2k
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
1
640
Designing Experiences People Love
moore
143
24k
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
460
brightonSEO & MeasureFest 2025 - Winning Strategies for Black Friday CRO & PPC - Christian Goodrich
cargoodrich
3
880
What Being in a Rock Band Can Teach Us About Real World SEO
427marketing
0
1.1k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
560
Building Adaptive Systems
keathley
44
3.3k
[Rails World 2026] Durable orchestration on Rails: from continuation to workflow
palkan
1
900
Technical Leadership for Architectural Decision Making
baasie
3
610
Claude Code のすすめ
schroneko
67
230k
Scaling GitHub
holman
464
140k
Transcript
ଵଦͰ͋ΔΤϯδχΞͷͨΊͷΫϥυը૾มαʔϏε @harukasan / MICHII Shunsuke 2017-07-01 :"1$'VLVPLBϥϯνεϙϯαʔηογϣϯ
)BSVLBTBOಓҪढ़հ ϐΫγϒ ג ϦʔυΤϯδχΞ *NBHF'MVYࣄۀऀ ԬΦϑΟεͰͳ͘౦ژຊࣾۈ Ԭݝٱཹถࢢੜ·Ε ٱཹถߴઐˠେ ൧௩ ˠஜେӃˠϐΫγϒೖࣾ
3VCZͱ(Pͱ͢͜͠4DBMBΛॻ͘ΠϯϑϥܥΤϯδχΞ ීஈࣇͷ
None
࡞׆ಈ͕ͬͱָ͘͠ͳΔॴΛͭ͘Δ
None
ϥϯνηογϣϯ
None
ϖ Image ϖ Image ϖ Image ϖ Image ϖ Image
ϖ Image
ϨΠΞτΛม͍͑ͨ ৽͍͠αΠζͷαϜωΠϧ͕΄͍͠ ৽͍͠σόΠεʹରԠ͍ͨ͠ ͍··ͰͷαϜωΠϧͩͱখ͍͞ ͖Ε͍ʹݟ͑ΔΑ͏ʹ͍ͨ͠ ը࣭Λམͱͣ͞ʹॖখ͍ͨ͠ දࣔΛ͍ͨ͘͠ WebPͰ৴͍ͨ͠
զʑΤϯδχΞͰ͋ΔͷͰ ͜ΕΒͷʹରͯ͋͠Δఔ·Ͱ ಠྗͰର߅͢Δ͜ͱ͕Ͱ͖Δ
ͨͱ͑Image::MagickΛ͏ use Image::Magick; $img = Image::Magick->new(); $img->Read("input.jpg"); $img->Resize( geometry =>
"400x400", ); ... $img->Write("output.jpg");
ͨͱ͑CSSͰ͏·͍͜ͱ߹ΘͤΔ .img { background-image: url("input.jpg"); /* style attributeͰࢦఆ͢Δͷ͕Ұൠత */ background-size:
cover; background-position: center center; width: 400px; height: 400px; }
ͨͱ͑ngx_small_lightΛ͏ server { listen 8000; server_name localhost; small_light on; small_light_pattern_define
square dw=400,dh=400,da=l,q=95,e=imagemagick,jpeghint=y; # http://localhost:8000/small_light(p=square)/input.jpg location ~ small_light[^/]*/(.+)$ { set $file $1; rewrite ^ /$file; } }
දࣔͰ͖ͯΔ͔ΒͱΓ͍͍͚͋͑ͣͲ͜ΕͰਖ਼͍͠ͷʁ ImageMagickʹresizeɺscaleͱthumbnail͕͋Δ͚Ͳ ͳΜ͔ಛఆͷϒϥβͰݟΔͱ৭͕มΘͬͯݟ͑Δ͚Ͳ ͕ࣗΊͨޙ୭͕ϝϯςͰ͖ΔΜͩΖ͏……
૿͑ଓ͚͍ͯ͘αʔϏε ͯ͢ͷWebαʔϏε͕ ը૾ॲཧΛ࣮/ӡ༻͢Δඞཁ͕͋Δͷ͔ʁ
ੲαʔόύʔπΛങ͍͚ͬͯͭͬͯͨ͘Ͳ……
ଵଦͰ͋ΔΤϯδχΞͷͨΊͷΫϥυը૾มαʔϏε
HTTP/S3ετϨʔδ ը૾มॲཧ ΦϦδφϧը૾Λऔಘ มޙΩϟογϡΛ৴ ΤϯυϢʔβ ίϯςϯπΩϟογϡ URLΛม͑Δ͚ͩͰը૾ม https://example.imageflux.jp/w=400,h=400/input.jpg ͍··Ͱ͍ͬͯͨ ετϨʔδΛͦͷ··͑Δ
ͭ·Γɺ͍͍ͩͨ small light as a service
ࣾͰར༻͍ͯͨ͠ը૾มγεςϜ͕ϕʔε ϐΫγϒ͕UGCը૾ϑΝΠϧͱઓ͖ͬͯͨྺ࢙ ࣾͰ͍͠B2BαʔϏε ͘͞ΒΠϯλʔωοτͱڞಉͰ։ൃɺӡ༻ ImageMagickΛ͍ͬͯͳ͍
LVS LB / DSR nginx HTTP front server ৴Ϋϥελ ཧαʔό
GRPC HTTP API Traffic Server HTTP front server Golang Thumbnailing server Golang Fetching server Golang Master server Scala Console / API
ͳͥGoͰॻ͍͍ͯΔͷ͔: - ܰྔεϨου(goroutine) - ඇಉظॲཧΛॎʹॻ͚Δʢωετ͠ͳ͍͍ͯ͘ʣ - γϯάϧόΠφϦ - CͷίʔυΛݺΔ
cgo package main // // int fortytwo() // { //
return 42; // } // import "C" import "fmt" func main() { fmt.Println(int(C.fortytwo())) // Output: 42 } ίϝϯτ෦ʹCͷίʔυΛهड़
cgo ίϝϯτ෦ʹCͷίʔυΛهड़ʢͪΐͬͱ͖ͪΘΔ͍ʣ Go͔ΒCͷܕΛ͑Δ - C.int - C.MyFunc
net/http libjpeg-turbo scale libpng CͷϥΠϒϥϦ GoͷHTTPαʔό࣮ GoͱCͷ͍͍ͱ͜ͲΓ
౦ژɺԬͷ྆ํʹ։ൃऀ/Ϛωʔδϟ͕͍·͢ appear.inͰ౦ژ-ԬΛ24࣌ؒଓ ͘͞Β౦ژɺϐΫγϒ౦ژɺ͘͞ΒେࡕɺϐΫγϒԬ ͰςϨΧϯ͢Δָ͍͠৬Ͱ͢ Tokyo Osaka Fukuoka
ImageFluxͰΤϯδχΞΛืू͍ͯ͠·͢ʂ Wantedlyɺฐࣾ࠾༻αΠτɺ࠙͘͠ձͰ HTTPϓϩΩγΛॻ͍ͨΓը૾มΛ࠷దԽͨ͠Γ ָ͍͠৬Ͱ͢ ౦ژͰԬͰಇ͚·͢ ϐΫγϒԬΦϑΟε ϐΫγϒ౦ژຊࣾ