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
Go for speed
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
Nick Bruun
September 18, 2014
Programming
160
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Go for speed
A look at a use case for Go at Iconfinder, which shaved ~40 ms off asset load times.
Nick Bruun
September 18, 2014
More Decks by Nick Bruun
See All by Nick Bruun
The evolution of the Web stack
nickbruun
0
220
Getting to the post-industrial age of DevOps
nickbruun
2
170
At løbe med sakse (Danish)
nickbruun
1
230
Lessons learned defying Joel Spolsky with Django
nickbruun
145
35k
Other Decks in Programming
See All in Programming
Loosening the Reins: Go Generics Get More Flexible
kuro_kurorrr
0
340
Hono + Inertia + React で LP を構築した話
oukayuka
2
180
まだ間に合う!今年の夏こそSchemeのマクロ展開器を完全理解!
omasanori
0
560
Dockerfile CMD for Node.js
grazie1999
0
140
AWS DevOps AgentのAzure接続機能を検証して見えた活用法/Use Cases Verified for the AWS DevOps Agent's Azure Connectivity Feature
masakiokuda
1
280
AI時代に学ぶ 好きなルール 嫌いなルール Linter編
shorty5121
0
190
[PyCon KR 2026] More Variants, More Diversity for AI Accelerators
achimnol
0
120
言葉の格闘技のススメ~紙とペンと言葉から始める、キャリアの描き方~
progresscicada
2
180
S3 を使うアプリケーションをローカル完結で動かすことに全力を注いでみた / Running S3 Apps Offline
contour_gara
0
660
Pythonの実行はどこまで賢くなったのか? CPythonとPyPyから見る最適化のしくみ
curekoshimizu
3
2.2k
VibeCodingからAgenticWorkflowへ
starfish719
0
940
tsc.rip を支える技術 / Kyoto.なんか #8
susisu
0
3.7k
Featured
See All Featured
Claude Code どこまでも/ Claude Code Everywhere
nwiizo
67
57k
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
16
2.1k
We Have a Design System, Now What?
morganepeng
55
8.3k
Getting science done with accelerated Python computing platforms
jacobtomlinson
2
450
The SEO Collaboration Effect
kristinabergwall1
1
530
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Art, The Web, and Tiny UX
lynnandtonic
304
22k
Refactoring Trust on Your Teams (GOTO; Chicago 2020)
rmw
35
3.8k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
We Are The Robots
honzajavorek
0
310
Faster Mobile Websites
deanohume
310
32k
The Anti-SEO Checklist Checklist. Pubcon Cyber Week
ryanjones
0
220
Transcript
Go for speed
Nick Bruun github.com/nickbruun @nickbruun bruun.co CTO @ Iconfinder Fairly carnivorous
None
None
None
Trouble in icon paradise
None
None
None
None
41 ms average response time from Django application during peak
hours
~2,000 ms wasted per search
Perceivably slower
The internals
None
Icon ID Icon version ID Raster size https://www.iconfinder.com/icons/298255/677266/128/raster https://cdn0.iconfinder.com/data/icons/seo-smart-pack/128/ grey_new_seo2-43-128.png
Public raster URL Protected raster URL
None
Constant
Signing requests
https://www.iconfinder.com/icons/298255/677266/128/raster?token=…
None
we know if the user has access right now When
returning the link,
we know if the user has access right now When
returning the link,
We’re okay with “right now” being an approximation
Time limited token
<token secret> = "<expiration timestamp>-<session ID>-<nonce>-<URL>"
<token secret> = "<expiration timestamp>-<session ID>-<nonce>-<URL>" <signature> = hmac_sha1(<token secret>,
<shared secret>)
<token secret> = "<expiration timestamp>-<session ID>-<nonce>-<URL>" <signature> = hmac_sha1(<token secret>,
<shared secret>) <token> = "<expiration timestamp>-<nonce>-base64(<signature>)"
But, who checks the token?
Enter Go The World’s least Google-able language… from Google
None
Why Go?
Networked service
Highly concurrent ~3,000 requests/second from 100 connections/core
Low memory footprint 14.09 MiB after 21 days
Low CPU usage
Static binary Cross-compilation = deployment heaven
Less decisions to make
Caveats
Structured logging
DIY
Mature runtime != Mature language
Conciseness 608 lines of code
The end result
1.2 ms average response time at peak hours
0.1 % CPU usage at peak hours
Go is awesome
Go is awesome for simple services
Go is a trade-off
Go is a trade-off – choose wisely
return