Preface |
|
ix | |
|
1 Just Enough Microservices |
|
|
1 | (32) |
|
|
1 | (11) |
|
Independent Deployability |
|
|
2 | (1) |
|
Modeled Around a Business Domain |
|
|
2 | (3) |
|
|
5 | (1) |
|
What Advantages Can Microservices Bring? |
|
|
6 | (1) |
|
What Problems Do They Create? |
|
|
6 | (1) |
|
|
7 | (1) |
|
|
8 | (1) |
|
|
8 | (2) |
|
|
10 | (2) |
|
|
12 | (4) |
|
The Single Process Monolith |
|
|
12 | (2) |
|
|
14 | (1) |
|
Third-Party Black-Box Systems |
|
|
14 | (1) |
|
|
15 | (1) |
|
|
15 | (1) |
|
|
16 | (12) |
|
|
17 | (1) |
|
|
17 | (11) |
|
Just Enough Domain-Driven Design |
|
|
28 | (4) |
|
|
29 | (2) |
|
|
31 | (1) |
|
Mapping Aggregates and Bounded Contexts to Microservices |
|
|
31 | (1) |
|
|
32 | (1) |
|
|
32 | (1) |
|
|
33 | (42) |
|
|
33 | (2) |
|
|
35 | (1) |
|
Why Might You Choose Microservices? |
|
|
35 | (7) |
|
|
35 | (2) |
|
|
37 | (1) |
|
Scale Cost-Effectively for Load |
|
|
37 | (1) |
|
|
38 | (2) |
|
Scale the Number of Developers |
|
|
40 | (1) |
|
|
41 | (1) |
|
When Might Microservices Be a Bad Idea? |
|
|
42 | (3) |
|
|
43 | (1) |
|
|
43 | (1) |
|
Customer-Installed and Managed Software |
|
|
44 | (1) |
|
Not Having a Good Reason! |
|
|
45 | (1) |
|
|
45 | (2) |
|
Taking People on the Journey |
|
|
47 | (1) |
|
|
47 | (6) |
|
Establishing a Sense of Urgency |
|
|
48 | (1) |
|
Creating the Guiding Coalition |
|
|
48 | (1) |
|
Developing a Vision and Strategy |
|
|
49 | (1) |
|
Communicating the Change Vision |
|
|
50 | (1) |
|
Empowering Employees for Broad-Based Action |
|
|
51 | (1) |
|
Generating Short-Term Wins |
|
|
51 | (1) |
|
Consolidating Gains and Producing More Change |
|
|
52 | (1) |
|
Anchoring New Approaches in the Culture |
|
|
52 | (1) |
|
Importance of Incremental Migration |
|
|
53 | (1) |
|
It's Production That Counts |
|
|
53 | (1) |
|
|
54 | (2) |
|
Reversible and Irreversible Decisions |
|
|
54 | (2) |
|
Easier Places to Experiment |
|
|
56 | (1) |
|
|
56 | (1) |
|
|
56 | (4) |
|
How Far Do You Have to Go? |
|
|
57 | (1) |
|
|
58 | (1) |
|
Using a Domain Model for Prioritization |
|
|
58 | (2) |
|
|
60 | (2) |
|
|
62 | (9) |
|
|
62 | (1) |
|
It's Not One Size Fits All |
|
|
63 | (2) |
|
|
65 | (3) |
|
|
68 | (3) |
|
How Will You Know if the Transition Is Working? |
|
|
71 | (3) |
|
Having Regular Checkpoints |
|
|
71 | (1) |
|
|
72 | (1) |
|
|
72 | (1) |
|
Avoiding the Sunk Cost Fallacy |
|
|
73 | (1) |
|
Being Open to New Approaches |
|
|
73 | (1) |
|
|
74 | (1) |
|
|
75 | (50) |
|
To Change the Monolith, or Not? |
|
|
76 | (2) |
|
Cut, Copy, or Reimplement? |
|
|
76 | (1) |
|
|
77 | (1) |
|
|
78 | (1) |
|
Pattern: Strangler Fig Application |
|
|
79 | (18) |
|
|
79 | (2) |
|
|
81 | (2) |
|
Example: HTTP Reverse Proxy |
|
|
83 | (3) |
|
|
86 | (1) |
|
|
86 | (4) |
|
|
90 | (3) |
|
|
93 | (1) |
|
Example: Message Interception |
|
|
94 | (3) |
|
|
97 | (1) |
|
Other Examples of the Strangler Fig Pattern |
|
|
97 | (1) |
|
Changing Behavior While Migrating Functionality |
|
|
97 | (1) |
|
|
98 | (6) |
|
Example: Page Composition |
|
|
99 | (1) |
|
Example: Widget Composition |
|
|
99 | (4) |
|
|
103 | (1) |
|
|
104 | (1) |
|
Pattern: Branch by Abstraction |
|
|
104 | (9) |
|
|
105 | (6) |
|
|
111 | (1) |
|
|
112 | (1) |
|
|
113 | (5) |
|
Example: Comparing Credit Derivative Pricing |
|
|
113 | (2) |
|
Example: Homegate Listings |
|
|
115 | (1) |
|
|
116 | (1) |
|
|
116 | (1) |
|
|
117 | (1) |
|
Dark Launching and Canary Releasing |
|
|
118 | (1) |
|
|
118 | (1) |
|
Pattern: Decorating Collaborator |
|
|
118 | (2) |
|
|
119 | (1) |
|
|
120 | (1) |
|
Pattern: Change Data Capture |
|
|
120 | (4) |
|
Example: Issuing Loyalty Cards |
|
|
120 | (1) |
|
Implementing Change Data Capture |
|
|
121 | (3) |
|
|
124 | (1) |
|
|
124 | (1) |
|
4 Decomposing the Database |
|
|
125 | (82) |
|
Pattern: The Shared Database |
|
|
125 | (2) |
|
|
127 | (1) |
|
|
127 | (1) |
|
|
127 | (1) |
|
|
128 | (4) |
|
The Database as a Public Contract |
|
|
129 | (1) |
|
|
130 | (1) |
|
|
131 | (1) |
|
|
131 | (1) |
|
|
132 | (1) |
|
Pattern: Database Wrapping Service |
|
|
132 | (3) |
|
|
134 | (1) |
|
Pattern: Database-as-a-Service Interface |
|
|
135 | (2) |
|
Implementing a Mapping Engine |
|
|
136 | (1) |
|
|
137 | (1) |
|
|
137 | (1) |
|
|
137 | (6) |
|
Pattern: Aggregate Exposing Monolith |
|
|
138 | (3) |
|
Pattern: Change Data Ownership |
|
|
141 | (2) |
|
|
143 | (2) |
|
Pattern: Synchronize Data in Application |
|
|
145 | (4) |
|
Step 1 Bulk Synchronize Data |
|
|
145 | (1) |
|
Step 2 Synchronize on Write, Read from Old Schema |
|
|
146 | (1) |
|
Step 3 Synchronize on Write, Read from New Schema |
|
|
147 | (1) |
|
Where to Use This Pattern |
|
|
148 | (1) |
|
|
148 | (1) |
|
|
149 | (9) |
|
|
152 | (2) |
|
Example: Orders at Square |
|
|
154 | (4) |
|
|
158 | (1) |
|
Splitting Apart the Database |
|
|
158 | (2) |
|
Physical Versus Logical Database Separation |
|
|
158 | (2) |
|
Splitting the Database First, or the Code? |
|
|
160 | (11) |
|
|
161 | (4) |
|
|
165 | (5) |
|
Split Database and Code Together |
|
|
170 | (1) |
|
So, Which Should I Split First? |
|
|
170 | (1) |
|
Schema Separation Examples |
|
|
171 | (1) |
|
|
171 | (2) |
|
|
173 | (1) |
|
Pattern: Move Foreign-Key Relationship to Code |
|
|
173 | (14) |
|
|
175 | (1) |
|
|
176 | (2) |
|
|
178 | (1) |
|
Example: Shared Static Data |
|
|
178 | (9) |
|
|
187 | (6) |
|
|
187 | (1) |
|
Still ACID, but Lacking Atomicity? |
|
|
188 | (2) |
|
|
190 | (3) |
|
Distributed Transactions---Just Say No |
|
|
193 | (1) |
|
|
193 | (13) |
|
|
195 | (4) |
|
|
199 | (6) |
|
Sagas Versus Distributed Transactions |
|
|
205 | (1) |
|
|
206 | (1) |
|
|
207 | (30) |
|
|
207 | (2) |
|
|
209 | (1) |
|
How Can This Problem Show Itself? |
|
|
209 | (1) |
|
When Might This Problem Occur? |
|
|
210 | (1) |
|
|
210 | (1) |
|
|
210 | (5) |
|
How Can This Problem Show Itself? |
|
|
211 | (1) |
|
When Might This Problem Occur? |
|
|
211 | (1) |
|
|
212 | (3) |
|
|
215 | (2) |
|
When Might This Problem Occur? |
|
|
216 | (1) |
|
|
216 | (1) |
|
Monitoring and Troubleshooting |
|
|
217 | (5) |
|
When Might These Problems Occur? |
|
|
218 | (1) |
|
How Can These Problems Occur? |
|
|
218 | (1) |
|
|
218 | (4) |
|
Local Developer Experience |
|
|
222 | (2) |
|
How Can This Problem Show Itself? |
|
|
223 | (1) |
|
|
223 | (1) |
|
|
223 | (1) |
|
|
224 | (2) |
|
How Might This Problem Show Itself? |
|
|
224 | (1) |
|
When Might This Problem Occur? |
|
|
224 | (1) |
|
|
224 | (2) |
|
|
226 | (3) |
|
How Can This Problem Show Itself? |
|
|
226 | (1) |
|
When Might This Problem Occur? |
|
|
226 | (1) |
|
|
227 | (2) |
|
Global Versus Local Optimization |
|
|
229 | (3) |
|
How Can This Problem Show Itself? |
|
|
229 | (1) |
|
When Might This Problem Occur? |
|
|
229 | (1) |
|
|
230 | (2) |
|
Robustness and Resiliency |
|
|
232 | (1) |
|
How Can This Problem Show Itself? |
|
|
232 | (1) |
|
When Might This Problem Occur? |
|
|
232 | (1) |
|
|
232 | (1) |
|
|
233 | (3) |
|
How Can This Problem Show Itself? |
|
|
233 | (1) |
|
When Might This Problem Occur? |
|
|
234 | (1) |
|
|
234 | (2) |
|
|
236 | (1) |
|
|
237 | (2) |
A Bibliography |
|
239 | (4) |
B Pattern Index |
|
243 | (2) |
Index |
|
245 | |