We all hear the term "DevOps" being thrown around on a daily basis, but what does it actually mean? With a little help from everyone's favourite 80's action hero, we'll undergo a whistle-stop tour of the philosophy, culture and tooling behind this buzzword, specifically aimed at Java Developers. We'll also look at a real-world case study from Instant Access Technologies Ltd, and explore the key role that DevOps has played during a successful upgrade of the epoints customer loyalty platform to support increasing traffic. The core discussion will focus on the challenges encountered as we moved from a monolithic app deployed into a data centre on a 'big bang' schedule, to a platform of loosely-coupled components, all being continuously deployed into the Cloud.
1. Chuck Norris Doesn’t Need DevOps…
but the rest of us might benefit
Daniel Bryant
CTO, Instant Access Technologies
d.bryant@iatltd.com
@taidevcouk
2. epoints.com
• At the center of IAT’s offerings
• Customer rewards/loyalty
• Earn everywhere
– Online shopping
– Social sites
– Your company? (partnerships available!)
23/11/2013
@taidevcouk
6. What is DevOps?
• “DevOps is a software development method that
stresses communication, collaboration and
integration between software developers and
information technology (IT) professionals.”
• “DevOps […] aims to help an organization rapidly
produce software products and services”
http://en.wikipedia.org/wiki/DevOps
23/11/2013
@taidevcouk
8. Chuck Norris doesn’t need DevOps…
…as a one-man army he codes with
one hand, tests with the other and
deploys with his beard
The rest of us…
…work in teams to develop software
23/11/2013
@taidevcouk
16. Culture is vital
• Culture drives behaviour, drives culture…
– Everyone is responsible for delivery
– Systems thinking
– Continuous experimentation and learning
• Not easy to change culture
– The hardest part of DevOps…
– …but you get to learn new things
23/11/2013
@taidevcouk
17. Changing Culture
• Greenfield
– Flickr’s story (slidesha.re/sHpYV)
– Sandro Mancuso “Why other people don’t get it”
(slidesha.re/1bcStpe)
• Enterprise
– “The Pheonix Project” by Gene Kim et al
• Create an effective team
– Martijn Verburg “Habits of highly effective technical
teams” (bit.ly/1aF9SnK)
23/11/2013
@taidevcouk
18. Chuck Norris doesn’t do iterative
development…
…all applications Chuck Norris creates
are right first time, every time
The rest of us…
…need to enable agility (and ideally
facilitate continuous delivery)
23/11/2013
@taidevcouk
19. We all do CI, right?
• “Continuous Delivery” is the next step
– Book by Jez Humble and Dave Farley
– Great InfoQ Video (bit.ly/XugWi8)
• Create a “build pipeline”
– Goal is fast feedback
• Continuous Deployment
– Awesome, but we don’t deploy to production (yet…)
23/11/2013
@taidevcouk
20. Gotchas
• Managing dependencies in SOA is hard, very hard
• Branching
– Gitflow, Branch Per Feature, or Trunk
– Integrate from ‘develop’ branch
• Migrating data can be challenging
– Liquibase / Flyway
– MongoDB / Solr Schema versions in data
– Wooga case study (bit.ly/1egArDC)
23/11/2013
@taidevcouk
21. Chuck Norris doesn’t do QA…
…Chuck Norris can test an entire
application with a single assert
(and get 110% code coverage)
The rest of us…
…need high-quality automated QA
23/11/2013
@taidevcouk
22. Automating QA
• Unit testing is essential
• Intra-component integration testing
– Spock is awesome (code.google.com/p/spock)
– Utilise embedded datastore/middleware
• Inter-component integration testing
– The hardest part of SOA…
23/11/2013
@taidevcouk
24. Automating QA
• Make it easy for everyone to execute
• Include within the build pipeline
• Make people care – fail the build!
• “Agile Testing” by Lisa Crispin, Janet Gregory
23/11/2013
@taidevcouk
25. Chuck Norris doesn’t need an OS…
…his keyboard has two keys, 0 and 1
The rest of us…
…need to provision bare metal, and
also be comfortable with the OS
23/11/2013
@taidevcouk
26. Say No To Snowflakes!
• Infrastructure as Code
– Version control everything
• Automate all provisioning
– Chef, Puppet, SaltStack, Python, AWS CLI
• Play with Vagrant (www.vagrantup.com)
– “providers” are super cool
23/11/2013
@taidevcouk
27. Thinking/Acting Like A Sysadmin
• Learn Linux fundamentals
• Diagnostic skills
– top, iotop, iostat, netstat, vmstat
– Java utils: jps, jstat, jmap, jhat
– “DevOps Troubleshooting” by Kyle Rankin
• Maybe grow a beard…
23/11/2013
@taidevcouk
28. Chuck Norris doesn’t fail…
…he just finds a new way in which
reality is broken
The rest of us…
…should plan for failure
23/11/2013
@taidevcouk
29. Design for failure
“Everything fails all the time [in the cloud]”
Werner Vogels, CTO, Amazon.com
• 21st Century Application Architecture
– www.skillsmatter.com (bit.ly/10jAdSV)
23/11/2013
@taidevcouk
30. Design for failure
• Design patterns
– Asynchronous communication
– Timeouts / retries
– Bulkheads / circuit-breakers
• Inspiration
– Chris Richardson (slidesha.re/1ft3vsg)
– Netflix (bit.ly/1h5GMid)
23/11/2013
@taidevcouk
32. All arrays Chuck Norris creates are of
infinite size…
…as Chuck Norris knows no bounds
The rest of us…
…should manage our resources and
cultivate ‘mechanical sympathy’
23/11/2013
@taidevcouk
33. Mechanical Sympathy
• Be aware of deployment platform properties
• …especially if in the cloud
– 1000Mbps network max transfer ~125MB/s
– EBS Optimised? PIOPs?
– “Noisy neighbours”
• Monitor everything (more on this later)
23/11/2013
@taidevcouk
34. When Chuck Norris throws Exceptions…
…everybody knows about it because they
land outside of the data center
The rest of us…
…should log all errors (and other vital
information for diagnostic purposes)
23/11/2013
@taidevcouk
35. Logging
• Log pretty much everything
– Use appropriate levels
• Make comments searchable/machine readable
– Good tips (bit.ly/hweqm4)
• Use centralised logging
– Especially if in the cloud
– Logstash, Loggly, Papertrail
23/11/2013
@taidevcouk
36. Chuck Norris doesn’t worry about
application downtime…
…Chuck Norris’ production servers are
so scared they constantly ping him
The rest of us…
…should monitor everything
23/11/2013
@taidevcouk
37. Monitor All The Things!
• Infrastructure monitoring
– Nagios
– Zabbix
23/11/2013
@taidevcouk
42. In Summary…
• DevOps is driving agile into QA and Ops
• Faster, leaner and more effective software
– The ability to experiment is awesome!
• There are some real benefits behind the buzz
• Now is the time to step-up as a developer
23/11/2013
@taidevcouk
43. The Developers DevOps Action Plan
•
•
•
•
•
•
•
Think about your company culture
Explore continuous delivery
Learn Linux basics
Automate provisioning
Design for failure
Cultivate mechanical sympathy
Improve logging/metrics
23/11/2013
@taidevcouk
44. Thanks For Listening
• Massive thanks to all the IAT team
– Especially our DevOps guru, Jamie Clarkson
• Questions / comments?
– d.bryant@iatltd.com
– @taidevcouk
23/11/2013
@taidevcouk