Slide 1

Slide 1 text

@cyriux Cyrille Martraire Bounded Contexts for team organisation

Slide 2

Slide 2 text

Nick Tune

Slide 3

Slide 3 text

He usually talks about the socio-technical

Slide 4

Slide 4 text

I’m his Stunt Double

Slide 5

Slide 5 text

Don’t worry

Slide 6

Slide 6 text

I know socio-technical

Slide 7

Slide 7 text

I used to be a DJ

Slide 8

Slide 8 text

cyrille martraire PARIS Since 1999 @cyriux Cyrille Martraire

Slide 9

Slide 9 text

arolla.fr @arollafr crafting architecture

Slide 10

Slide 10 text

Transformations

Slide 11

Slide 11 text

@cyriux

Slide 12

Slide 12 text

so what about this socio-technical stuff?

Slide 13

Slide 13 text

code is the easy part, collaboration is the hard part - Indu.

Slide 14

Slide 14 text

imagine.

Slide 15

Slide 15 text

what if we didn’t bother organising teams?

Slide 16

Slide 16 text

@cyriux Photo by Dimitar Belchev Just people together

Slide 17

Slide 17 text

@cyriux Photo by Dimitar Belchev Please collaborate!

Slide 18

Slide 18 text

What does it mean to collaborate?

Slide 19

Slide 19 text

discussing & agreeing on: goals solutions words & their meaning ways to collaborate better where to go out for lunch…

Slide 20

Slide 20 text

@cyriux Photo by Ethan Hoover

Slide 21

Slide 21 text

@cyriux Photo by Ethan Hoover

Slide 22

Slide 22 text

@cyriux Photo by Ethan Hoover coordination cost

Slide 23

Slide 23 text

@cyriux Photo by Ethan Hoover

Slide 24

Slide 24 text

@cyriux Photo by Ethan Hoover

Slide 25

Slide 25 text

@cyriux Photo by Ethan Hoover

Slide 26

Slide 26 text

@cyriux Photo by Ethan Hoover

Slide 27

Slide 27 text

@cyriux Photo by Ethan Hoover

Slide 28

Slide 28 text

@cyriux Photo by Ethan Hoover

Slide 29

Slide 29 text

@cyriux lots of talking!

Slide 30

Slide 30 text

@cyriux meetings!

Slide 31

Slide 31 text

@cyriux miscommunication!

Slide 32

Slide 32 text

@cyriux frustration

Slide 33

Slide 33 text

@cyriux Photo by Taylor Vick

Slide 34

Slide 34 text

@cyriux Photo by Taylor Vick runtime & co-evolution

Slide 35

Slide 35 text

@cyriux Photo by Taylor Vick

Slide 36

Slide 36 text

@cyriux Photo by Taylor Vick

Slide 37

Slide 37 text

@cyriux Photo by Taylor Vick

Slide 38

Slide 38 text

@cyriux Photo by Taylor Vick

Slide 39

Slide 39 text

@cyriux Photo by Taylor Vick

Slide 40

Slide 40 text

@cyriux Photo by Taylor Vick LATENCY!

Slide 41

Slide 41 text

@cyriux Photo by Taylor Vick DOWNTIME!

Slide 42

Slide 42 text

@cyriux Photo by Taylor Vick BIG BANG DEPLOYMENTS!

Slide 43

Slide 43 text

so what do we do?

Slide 44

Slide 44 text

we want to reduce the coordination cost

Slide 45

Slide 45 text

we create smaller groups of people

Slide 46

Slide 46 text

tribes.

Slide 47

Slide 47 text

@cyriux the obligatory reference to Spotify

Slide 48

Slide 48 text

tribes.

Slide 49

Slide 49 text

@cyriux Photo by Ethan Hoover members know each other

Slide 50

Slide 50 text

tribes. <100 - 150 people ”Dunbar number” max size of tribes

Slide 51

Slide 51 text

@cyriux

Slide 52

Slide 52 text

@cyriux for all primates like us

Slide 53

Slide 53 text

we create smaller groups of people

Slide 54

Slide 54 text

teams.

Slide 55

Slide 55 text

@cyriux Photo by Ethan Hoover members know each other

Slide 56

Slide 56 text

@cyriux Photo by Ethan Hoover they also know what each other thinks about any other

Slide 57

Slide 57 text

@cyriux Photo by Ethan Hoover trust! speed!

Slide 58

Slide 58 text

@cyriux “There is a high cost associated with work that leaves your team” — James Lewis, Thoughtworks

Slide 59

Slide 59 text

@cyriux

Slide 60

Slide 60 text

teams. <5-9 people ”2-pizza team”

Slide 61

Slide 61 text

teams. <5-9 people ”2-pizza team” max size of teams

Slide 62

Slide 62 text

tribes. teams. <5-9 people <100 - 150 people ”2-pizza team” ”Dunbar number” max size

Slide 63

Slide 63 text

Max size of teams / tribes: you just can’t beat that

Slide 64

Slide 64 text

who deserves to be in?

Slide 65

Slide 65 text

anyone who can make a difference in the outcome

Slide 66

Slide 66 text

@cyriux Photo by Hemant Latawa

Slide 67

Slide 67 text

(3+ amigos) dev product testing UX ops …

Slide 68

Slide 68 text

only the 5-9 MOST differentiating contributors IN the team

Slide 69

Slide 69 text

whole teams cross-functional teams

Slide 70

Slide 70 text

anyone else? outside the team!

Slide 71

Slide 71 text

anyone else? outside the team! Other team Support group External

Slide 72

Slide 72 text

ok.

Slide 73

Slide 73 text

ok. no controversy so far.

Slide 74

Slide 74 text

@cyriux

Slide 75

Slide 75 text

whole teams cross-functional teams

Slide 76

Slide 76 text

so beyond the skills, how do we organise teams?

Slide 77

Slide 77 text

@cyriux @cyriux the answer to any question is always…

Slide 78

Slide 78 text

BOUNDED Contexts

Slide 79

Slide 79 text

@cyriux @cyriux ”it depends”

Slide 80

Slide 80 text

BOUNDED Contexts

Slide 81

Slide 81 text

@cyriux “There is a high cost associated with work that leaves your team” — James Lewis, Thoughtworks

Slide 82

Slide 82 text

@cyriux

Slide 83

Slide 83 text

we want to encapsulate the work within the team

Slide 84

Slide 84 text

@cyriux Photo by Ethan Hoover work bandwidth

Slide 85

Slide 85 text

@cyriux Photo by Ethan Hoover work bandwidth

Slide 86

Slide 86 text

@cyriux Photo by Ethan Hoover

Slide 87

Slide 87 text

@cyriux Photo by Ethan Hoover

Slide 88

Slide 88 text

@cyriux Photo by Ethan Hoover

Slide 89

Slide 89 text

@cyriux Photo by Ethan Hoover

Slide 90

Slide 90 text

@cyriux Photo by Taylor Vick runtime bandwidth

Slide 91

Slide 91 text

@cyriux Photo by Taylor Vick ”chatty” communication

Slide 92

Slide 92 text

@cyriux Photo by Ethan Hoover better clusters

Slide 93

Slide 93 text

@cyriux Photo by Ethan Hoover better clusters

Slide 94

Slide 94 text

@cyriux Photo by Ethan Hoover better clusters

Slide 95

Slide 95 text

keep the bandwidth inside

Slide 96

Slide 96 text

@cyriux Photo by Ethan Hoover better clusters

Slide 97

Slide 97 text

@cyriux Photo by Ethan Hoover Bounded Contexts

Slide 98

Slide 98 text

BOUNDED Contexts

Slide 99

Slide 99 text

BOUNDED Contexts

Slide 100

Slide 100 text

BOUNDED Contexts

Slide 101

Slide 101 text

No content

Slide 102

Slide 102 text

in isolation

Slide 103

Slide 103 text

keep the work inside

Slide 104

Slide 104 text

keep the work inside full

Slide 105

Slide 105 text

@cyriux Photo by Ethan Hoover

Slide 106

Slide 106 text

heuristics: Bounded Contexts by business sub-domains

Slide 107

Slide 107 text

heuristics: Bounded Contexts by business sub-domains area of purpose areas of expertise

Slide 108

Slide 108 text

DESIGN DECISION BUSINESS PERSPECTIVE

Slide 109

Slide 109 text

@cyriux Event Storming PRACTICE

Slide 110

Slide 110 text

@cyriux e-commerce • SEO, Traffic Acquisition • Marketing & Targeting • PIM (Product Identification Management) • Catalogue • Categorization • Search • Recommendation • Pricing, Promotions • Basket • Discount, Loyalties • Shipping Cost Estimation • Payment • (Fraud Detection) • Order Management • Billing • Stock / Overbooking • Shipping • Return • CRM

Slide 111

Slide 111 text

heuristics: Bounded Contexts by audience experience crafting the optimal experience by persona

Slide 112

Slide 112 text

heuristics: Bounded Contexts by domain-agnostic (generic) stuff areas of expertise (for someone else)

Slide 113

Slide 113 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable

Slide 114

Slide 114 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable by audience

Slide 115

Slide 115 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable by sub-domains

Slide 116

Slide 116 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable generic sub-domains

Slide 117

Slide 117 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable can delegate / SaaS / offshore

Slide 118

Slide 118 text

Need fewer people! Downscale! #WIN

Slide 119

Slide 119 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable you never quite achieve that perfection

Slide 120

Slide 120 text

Mapping the Target Architecture Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable SpringBoot Postgres / Elastic Search RabbitMQ Microservice

Slide 121

Slide 121 text

Mapping the Target Architecture Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable Modular Monolith

Slide 122

Slide 122 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable legacy components not aligned (at all)

Slide 123

Slide 123 text

Mapping the Potential Bounded Contexts Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X1 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4 Very specific Generic Specific audience Domain- Specific Domain- Agnostic Volatile Stable you never quite achieve that perfection c’est la vie!

Slide 124

Slide 124 text

how did we do before Bounded Contexts ?

Slide 125

Slide 125 text

Traditionally…

Slide 126

Slide 126 text

@cyriux

Slide 127

Slide 127 text

@cyriux Component Component Component Feature Feature Feature

Slide 128

Slide 128 text

@cyriux Component Component Component Feature Feature Feature Component team

Slide 129

Slide 129 text

@cyriux Component Component Component Feature Feature Feature Feature team

Slide 130

Slide 130 text

@cyriux Component Component Component Feature Feature Feature Component teams X X X Cross-Component coordination to deliver a feature :(

Slide 131

Slide 131 text

@cyriux Component Component Component Feature Feature Feature Feature team X X X System owners to protect integrity of components :(

Slide 132

Slide 132 text

@cyriux Feature teams are better!

Slide 133

Slide 133 text

@cyriux http://www.bebetterleader.com/know-how/how-do-i-form-teams.html Feature teams are better!

Slide 134

Slide 134 text

but components & features are not independent…

Slide 135

Slide 135 text

@cyriux https://www.adapttransformation.com/devops-journey/foundations/conways-law/

Slide 136

Slide 136 text

Any organization that designs a system (…) will inevitably produce a design whose structure is a copy of the organization's communication structure ~ Mel Conway

Slide 137

Slide 137 text

If you have four groups working on a compiler, you'll get a 4-pass compiler.

Slide 138

Slide 138 text

@cyriux https://www.adapttransformation.com/devops-journey/foundations/conways-law/

Slide 139

Slide 139 text

Conway’s Law: you can’t beat that.

Slide 140

Slide 140 text

design components boundaries on feature boundaries

Slide 141

Slide 141 text

BOUNDED Contexts

Slide 142

Slide 142 text

@cyriux Component Component Component Feature Feature Feature Component team

Slide 143

Slide 143 text

@cyriux Component Component Component Feature Feature Feature Feature team

Slide 144

Slide 144 text

@cyriux Component Component Component Feature Feature Feature Component teams X X X Feature teams

Slide 145

Slide 145 text

@cyriux @cyriux domain boundaries ≡ component boundaries

Slide 146

Slide 146 text

product oriented

Slide 147

Slide 147 text

Smarter Components Boundaries Sub-Domain A sub-sub domain A1 sub-sub domain B1 sub-sub domain C1 Domain Sub-Domain B Sub-Domain C sub-sub domain A2 sub-sub domain C2 Customers Experience X2 Customers Experience X3 Generic enabler Audience Experiences Business (Sub)- Domains Domain- agnostic Enablers Collaborators Experience X4

Slide 148

Slide 148 text

That’s what they did at Spotify indeed!

Slide 149

Slide 149 text

@cyriux ”Numerous autonomous squads that function as independent mini-startups”

Slide 150

Slide 150 text

@cyriux Component Component Component Feature Feature Feature You never quite achieve that perfection X X X

Slide 151

Slide 151 text

@cyriux Component Component Component Feature Feature Feature you will still have some cross-component/team coordination X X X X

Slide 152

Slide 152 text

@cyriux Component Component Component Feature Feature Feature some is acceptable X X X X

Slide 153

Slide 153 text

@cyriux Component Component Component Feature Feature Feature X X X X c’est la vie!

Slide 154

Slide 154 text

@cyriux Component Component Component Feature Feature Feature X X a contract!

Slide 155

Slide 155 text

@cyriux Component Component Component Feature Feature Feature X X a contract! stable!

Slide 156

Slide 156 text

@cyriux Know your decoupling patterns! All the avoidable coupling must be avoided!

Slide 157

Slide 157 text

@cyriux • Depend on a third-party contract • Tunnelling a payload
 Generic (e.g. key-value) • Expose your published language other can call • Micro-frontends • GraphQL

Slide 158

Slide 158 text

@cyriux https://martinfowler.com/articles/data-monolith-to-mesh.html Zhamak Dehghani Data mesh

Slide 159

Slide 159 text

in Closing

Slide 160

Slide 160 text

@cyriux BUY MY BOOK!

Slide 161

Slide 161 text

@cyriux https://medium.com/nick-tune-tech-strategy-blog/the-challenges-and-traps-of- architecting-sociotechnical-systems-94272a7c790f

Slide 162

Slide 162 text

socio-technical is about teams

Slide 163

Slide 163 text

and about components

Slide 164

Slide 164 text

which are both about Bounded Contexts

Slide 165

Slide 165 text

Take care of your Bounded Contexts

Slide 166

Slide 166 text

And the Bounded Contexts will take care of yourself.

Slide 167

Slide 167 text

Thanks! Cyrille MARTRAIRE @cyriux

Slide 168

Slide 168 text

@cyriux