fancy pants
DESCRIPTION
Down With the Fancy Pants! -- How People Have Been Optimizing the Wrong Things and Increased ComplexityOriginally given at Velocity 2012.TRANSCRIPT
Velocity 2012
Down with the fancy pants!How people have been optimizing the wrong things
and increased complexity.
Jan Schaumann <[email protected]>B60D A9F7 0D89 544A 7995 7D25 5A5B 4375 275F 0BB5
@jschauma
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/L1iiuo
Onions!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/KQDDSU
Distractions!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/nn3QDV
http://etsy.me/LlIZsf
The Art of Yak Shaving!
(Yak Wool)
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/L6tJ40
Silve
r Bull
ets!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Silve
r Bull
ets!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/L6tJ40
Sorry
!XThursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
How do we build websites?
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/LieAZe
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
How do we build websites?large scale
^
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Load Balancer
HTTP Servers
Message Broker
Database
Storage System
#dadops
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Load Balancer
HTTP Servers
Message Broker
Database
Storage SystemDNS
Systems Architect
#dadops
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Exciting, right?
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/zQMzBn
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Remember how a web server used to work?
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Hello, I'd like to get the contents of this file, please."GET / HTTP/1.0\n\n
Remember how a web server used to work?
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Hello, I'd like to get the contents of this file, please."GET / HTTP/1.0\n\n
Server: "Why, certainly, here you go." cat file > socket
Remember how a web server used to work?
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Hello, I'd like to get the contents of this file, please."GET / HTTP/1.0\n\n
Server: "Why, certainly, here you go." cat file > socket
Remember how a web server used to work?
http://etsy.me/L8TeSc
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Hello, I'd like to get the contents of this file on this server, please." GET / HTTP/1.1\n\n Host: this-server\n\n
HTTP today...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Hello, I'd like to get the contents of this file on this server, please." GET / HTTP/1.1\n\n Host: this-server\n\n
Server: "I'm sorry, Node.js just crashed." HTTP/1.1 500 Internal Server Error Server: Apache-Coyote/1.1
HTTP today...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Hello, I'd like to get the contents of this file on this server, please." GET / HTTP/1.1\n\n Host: this-server\n\n
Server: "I'm sorry, Node.js just crashed." HTTP/1.1 500 Internal Server Error Server: Apache-Coyote/1.1
HTTP today...
http://etsy.me/LlGtC5
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Uhm... Node.js? I thought you said you're an Apache server?"
Server: "Oh, sure, but I hand off LESS compilation to Node.js, which is faster than Rhino."
HTTP today...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Uhm... Node.js? I thought you said you're an Apache server?"
Server: "Oh, sure, but I hand off LESS compilation to Node.js, which is faster than Rhino."
Client: "Uhm... Rhino? So you're... running Javascript inside Java?"
Server: "Oh, sure, I'm a Tomcat server!"
HTTP today...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Uhm... Node.js? I thought you said you're an Apache server?"
Server: "Oh, sure, but I hand off LESS compilation to Node.js, which is faster than Rhino."
Client: "Uhm... Rhino? So you're... running Javascript inside Java?"
Server: "Oh, sure, I'm a Tomcat server!"
Client: "So I'm talking to... your Coyote 'HTTP connector', which hands my requests off to your ‘Catalina servlet container’, which..."
Server: "...looks up stuff in various databases, triggers actions in a message broker and hands the LESS compilation off to Node.js..."
HTTP today...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "Uhm... LESS? 'Compilation'? Why don't you just serve the plain old CSS?"
Server: "Don't be silly. 'All problems in computer science can be solved by another level of indirection.' Now where was I?"
Server: "Oh, right: ...hands the LESS compilation off to Node.js, which just crashed."
HTTP today...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Client: "My head hurts. How did we get here?"
HTTP today...
http://etsy.me/Lb57Y0
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
“Complex systems fail in complex ways.”Steven M. Bellovin
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
<!-- web0013.ny4.etsy.com at Wed 20 06 12:24:24 2012 in 462 ms -->
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Optimize for human time.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
// LESS
#header { h1 { font-size: 26px; font-weight: bold; } p { font-size: 12px; a { text-decoration: none; &:hover { border-width: 1px } } }}
Is less really more?
/* Compiled CSS */
#header h1 { font-size: 26px; font-weight: bold;}#header p { font-size: 12px;}#header p a { text-decoration: none;}#header p a:hover { border-width: 1px;}
http://etsy.me/KU1wJr
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
<script src="less.js" type="text/javascript"></script>
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
-- `$=`;$_=\%!;($_)=/(.)/;$==++$|;($.,$/,$,,$\,$",$;,$^,$#,$~,$*,$:,@%)=($!=~/(.)(.).(.)(.)(.)(.)..(.)(.)(.)..(.)......(.)/,$"),$=++;$.++;$.++;$_++;$_++;($_,$\,$,)=($~.$"."$;$/$%[$?]$_$\$,$:$%[$?]",$"&$~,$#,);$,++;$,++;$^|=$";`$_$\$,$/$:$;$~$*$%[$?]$.$~$*${#}$%[$?]$;$\$"$^$~$*.>&$=`
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/LrIexP
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
“Premature optimization is the root of all evil.”Donald Knuth
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Optimize for human time.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
How do we build websites?
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/w2pZPN
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
/bin/sh
http://etsy.me/L6Gb5O
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
/bin/sh
stdin stdout stderr
<< < | > >>
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
/bin/sh
stdin stdout stderr
<< < | > >>
awk(1)
tbl(1)tbl(1)Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
/bin/sh
stdin stdout stderr
<< < | > >>
awk(1) sed(1)
tbl(1)tbl(1)Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
/bin/sh
stdin stdout stderr
<< < | > >>
awk(1) sed(1)
uniq(1)
tbl(1)tbl(1)
sort(1)
wc(1)
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
/bin/sh
stdin stdout stderr
<< < | > >>
awk(1) sed(1)
*roff(1) uniq(1)
col(1)
tbl(1)tbl(1)
fmt(1)paste(1)
lam(1) comm(1) sort(1)
wc(1)
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
|
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
text stream | text stream
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/LoKw0B
http://etsy.me/LoKFRA
New Jersey vs. MIT
...it is on!
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
text stream | text stream
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
XML makes me YAML.Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
XSLT is a language with an XML-based syntaxthat is used to transform XML documents
into other XML documents...
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
XML makes me YAML.Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
The Dunning-Kruger effect applies toDomain-Specific Languages, too.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
“The purpose of JsonML is to provide a compact format for transporting XML-based markup as JSON which allows it to be losslessly converted back to its original form.”
http://www.jsonml.org/
http://etsy.me/Lbsj8kOn the internet, nobody knows if you’re trolling.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
object | object
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
tool1 | tool2
Public:
color: orange shape: rect
Private: corners: round
Public:
color: orange shape: rect
Private: corners:angular
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Complexity simplified:
•“essential complexity” is inherent to the problem and cannot be reduced
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Complexity simplified:
•“essential complexity” is inherent to the problem and cannot be reduced
•“accidental complexity” is inadvertent and frequently introduced indirectly
Thursday, June 28, 12
Public:
color: orange shape: rect
Private: corners:angular
Velocity 2012 - Down with the fancy pants!
tool1| filter | tool2
Public:
color: orange shape: rect
Private: corners: round
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
object | object
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://stackoverflow.com/questions/6260420/choices-of-message-queue
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://stackoverflow.com/questions/6260420/choices-of-message-queue
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/eZxOwz
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Total Cost of Ownership
purchase price time to evaluate solution
time to deploy solution
savings in $resource
support contract
time to on-ramp staff
time to integrate with existing tools
time to debug/update/maintain
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/LkuGI5
Thursday, June 28, 12
man
-hou
rs$$Total Cost of Ownership
Velocity 2012 - Down with the fancy pants!
Total Cost of Ownership
purchase price time to evaluate solution
time to deploy solution
savings in $resource
support contract
time to on-ramp staff
time to integrate with existing tools
time to debug/update/maintain
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Software maintenance is ~75% of TCO.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Software maintenance is ~75% of TCO.
Operational costs are the other 75%.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/Lj89aR
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/Lj8hqI
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/Lj8hqI
various ruby gems added / updatedminor PHP upgrade
libmemcached, sqlite, zlib, and openssl updated
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
runs linux
http://etsy.me/HT7BJm
http://etsy.me/Lj8hqI
libmemcached, sqlite, zlib, and openssl updated
various ruby gems added / updatedminor PHP upgrade
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/LtSSrp
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
“Adding manpower to a late softwareproject makes it later.”
Brooks’s Law
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Brooks’s Law also holds for software endpoints.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Group Intercommunication Formula:#of channels of communication =
n(n − 1) / 2
5 developers:5(5-1)/2 = 10
10 developers:10(10-1)/2 = 45
50 developers:50(50-1)/2 = 1225
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Brooks’s Law also holds for software endpoints.
Adding independent components to a software architecture increases complexity exponentially.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
“Optimization is the process of taking something that works and replacing it with something that
almost works, but costs less.”Roger Needham
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Identify accidental and essential complexity. Eliminate the former, then optimize the latter.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
•“Complex systems fail in complex ways.” (Bellovin)•“Premature optimization is the root of all evil.” (Knuth)•“Worse is better (is worse is still better).” (Gabriel)•“Complexity increases non-linearly.” (Brooks)•“Complexity is the enemy of security.” (Schneier)
•echo “import this” | python
http://etsy.me/LlIZsfhttp://etsy.me/Ly59Ly http://etsy.me/LnMCv7Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Optimize for human time.
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
http://etsy.me/L8WcGD
Thursday, June 28, 12
Velocity 2012 - Down with the fancy pants!
Related talks, presentations and articles in no particular order:
• http://concur.rspace.googlecode.com/hg/talk/concur.html• http://radar.oreilly.com/2012/04/complexity-vs-simplicity.html• http://www.confreaks.com/videos/860-railsconf2012-keynote-simplicity-matters• http://dreamsongs.com/WorseIsBetter.html• http://michaelochurch.wordpress.com/2012/04/13/java-shop-politics/• http://codebetter.com/markneedham/2010/03/18/essential-and-accidental-complexity/• http://html9responsiveboilerstrapjs.com/• http://jamesgolick.com/2010/10/27/we-are-experiencing-too-much-load-lets-add-a-new-
server..html
• http://is.gd/uCnnMg
Thursday, June 28, 12