building systems that are never done jalewis@thoughtworks.com @boicy 1
never done 2
never done Incomplete adjective not having all the necessary or appropriate parts 3
never done Incomplete adjective not having all the necessary or appropriate parts 3
4
KERRBOX! 4
5
How big are they?
never done 10
never done 11
never done “This, milord, is my family's axe . We have owned it for almost nine hundred years, see. Of course, sometimes it needed a new blade . And sometimes it has required a new handle , new designs on the metalwork, a little refreshing of the ornamentation . . . but is this not the nine hundred-year-old axe of my family? And because it has changed gently over time, it is still a pretty good axe, y'know. Pretty good.” 11
replaceable component architectures Dan North 12
the future is scary 13
BACK IN 2004 (ISH) 14
15
TIME PASSES…
TIME PASSES… 16
These companies are doing things a bit di ff erently They can deploy small, independent services on demand They scale teams independently of one another around these services They operate at web-scale if they need to 17
HELL YEAH! CONSULTANTS!
Ability to adopt new technologies and practices Unicorns Enterprise And the speed at which they can deliver software is increasing 19
https://www.thoughtworks.com/radar/ 20
microservices should allow us to go as “fast as possible” be cheap to replace be deployable on demand be resilient on imperfect networks but it’s not as simple as that 21
“the fi rst post-devops architectural style” Neal Ford 22
a note on the law of unintended consequences 23
Consider a single application - its a website, lets call it A A 24
we want to get A into production and since we are hipsters we are going to practice continuous delivery - we will have a full automated build pipeline compile, unit acceptance integration and test test functional test deploy to production deployed on deployed to run on build build integration machine machine environment 25
we want to get A into production and since we are hipsters we are going to practice continuous delivery - we will have a full automated build pipeline Tappety tap compile, unit acceptance integration and test test functional test deploy to production deployed on deployed to run on build build integration machine machine environment 25
we want to get A into production and since we are hipsters we are going to practice continuous delivery - we will have a full automated build pipeline Tappety tap compile, unit acceptance integration and test test functional test deploy to production deployed on deployed to run on build build integration machine machine environment 25
How many environments do we need? 26
How many environments do we need? compile, unit acceptance integration and test test functional test deploy to production deployed on deployed to run on build build integration machine machine environment 27
OK, so we are going to be cool and use microservices A B 28
and we might as well call them something interesting webapp customers 29
and they have a dependency on one another… webapp customers 30
How do we traditionally make sure that new versions of the services work with each other? Let me illustrate this 31
V1 V1 32
git push origin master V1 V1 32
git push origin master V2 V1 V1 32
git push origin master V2 V1 V1 32
git push origin master V2 V1 V1 32
git push origin master V2 V1 V1 32
git push origin master V2 V1 V1 32
V2 V1 What should V2 of the blue app be tested against here 33
This is in production, so presumably we should test against this? V1 34
V1 V1 35
git push origin master V1 V1 git push origin master 35
git push origin master V2 V1 V1 V2 git push origin master 35
git push origin master V2 V1 V1 V2 git push origin master 35
git push origin master V2 V1 V1 V2 git push origin master 35
git push origin master V2 V1 V1 V2 git push origin master 35
git push origin master V2 V1 V1 V2 git push origin master 35
I’m sorry Dave, I can’t let you do that I’m sorry Dave, I can’t let you do that 36
37
37
Locks == Delay 38
V1 V1 s V1 s V1 39
40
41
41
2 services => 4 environments 42
2 services 43
2 services 4 43
2 services 4 >600 43
44
45
http://james-iry.blogspot.com.au/2009/05/brief-incomplete-and-mostly-wrong.html 45
<thinks> 46
if: 47
Integration testing if: 47
Integration testing if: Independent deployment 47
Integration testing if: Independent deployment Service versioning / evolution 47
Integration testing if: Independent deployment Service versioning / evolution is hard 47
What about some of our other sacred cows? 48
What about some of our other sacred cows? GRASP YAGNI World of Warcraft SOLID agile DRY BDD emergent design GoF Continuous Delivery TDD XP KISS Refactoring 48
GRASP World of Warcraft SOLID YAGNI agile DRY BDD emergent design GoF Continuous Delivery TDD XP KISS Refactoring 49
50
http://martinfowler.com/bliki/Yagni.html 50
build out services as you need them minimise holding cost and batch size 51 51
YAGNI World of Warcraft SOLID GRASP agile DRY BDD emergent design GoF Continuous Delivery TDD XP KISS Refactoring 52
Retail Ful fi lment 53
Retail Ful fi lment 54
Retail Ful fi lment 55
High cohesion Retail Ful fi lment Low coupling 56
GRASP YAGNI World of Warcraft SOLID DRY agile BDD emergent design GoF Continuous Delivery TDD XP KISS Refactoring 57
“Every piece of knowledge must have a single, unambiguous, authoritative representation within a system” Andrew Hunt, Dave Thomas: The Pragmatic Programmer. 1999-10-01. ISBN: 978-0-2016-1622-4 https://pragprog.com/book/tpp/the-pragmatic-programmer 58
DRY holds across services 59
GRASP YAGNI World of Warcraft SOLID TDD agile DRY BDD emergent design GoF Continuous Delivery XP KISS Refactoring 60
“The London school of Test Driven Development” Mike Feathers 61
should we bother with test driving our code if we are going to throw it away? 62
http://moleseyhill.com/blog/2009/08/27/dreyfus-model/ 63
All rules are contextual 64
Start 65
Start Am I Kent Beck? 65
Start Yes Am I Kent Do what I Beck? think is best 65
Start Yes Am I Kent Do what I Beck? think is best No Am I Dan North? 65
Start Yes Am I Kent Do what I Beck? think is best No Yes Am I Dan Do what I North? think is best 65
Start Yes Am I Kent Do what I Beck? think is best No Yes Am I Dan Do what I North? think is best No 65
Recommend
More recommend