background-image: url(img/explore.jpg)
name: about class: left background-image: url(img/about.jpg)
.right-column[ Open Minded
|> Science
|> Craftsman
.footnote[ cmg-dev
@codethonian ] ]
name: introduction class: middle, center background-image: url(img/space.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/space.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/space.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/space.jpg)
.regular[
.page_right[
]
]
.footnote[
XKCD
]
name: introduction class: left, middle background-image: url(img/space.jpg)
.page_left[
Instagram Netflix Whatsapp SAP ]
name: introduction class: left, middle background-image: url(img/space.jpg)
.page_left[
Instagram Python (Django) Monolith.
Netflix Well documented Microservice structure.
Whatsapp Monolithic structure; started out in Erlang.
SAP SAP Hana and Hybris as Cloud Microservice as a Service.
]
name: motivation class: left, middle background-image: url(img/space.jpg)
.regular[
The term "Microservice Architecture" (...) describe[s] a particular way of designing software applications as suites of independently deployable services. While there is no precise definition of this architectural style, there are certain common characteristics around (...) business capability, automated deployment, intelligence in the endpoints, and decentralized control of languages and data. [1]
So we are not sure. ]
.footnote[ [1]: https://www.martinfowler.com/articles/microservices.html ]
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
- Rule of Modularity
- Rule of Composition
- Rule of Separation
- Rule of Simplicity
- Rule of Robustness
- Rule of Transparency
- Rule of Parsimony
(...) ]
???
-
Rule of Modularity
Developers should build a program out of simple parts connected by well defined interfaces, so problems are local, and parts of the program can be replaced in future versions to support new features. This rule aims to save time on debugging code that is complex, long, and unreadable.
-
Rule of Composition
Developers should write programs that can communicate easily with other programs. This rule aims to allow developers to break down projects into small, simple programs rather than overly complex monolithic programs.
-
Rule of Separation
Developers should separate the mechanisms of the programs from the policies of the programs; one method is to divide a program into a front-end interface and a back-end engine with which that interface communicates. This rule aims to prevent bug introduction by allowing policies to be changed with minimum likelihood of destabilizing operational mechanisms.
-
Rule of Simplicity
Developers should design for simplicity by looking for ways to break up program systems into small, straightforward cooperating pieces. This rule aims to discourage developers’ affection for writing “intricate and beautiful complexities” that are in reality bug prone programs.
-
Rule of Parsimony
Developers should avoid writing big programs. This rule aims to prevent overinvestment of development time in failed or suboptimal approaches caused by the owners of the program’s reluctance to throw away visibly large pieces of work. Smaller programs are not only easier to write, optimize, and maintain; they are easier to delete when deprecated.
-
Rule of Transparency
Developers should design for visibility and discoverability by writing in a way that their thought process can lucidly be seen by future developers working on the project and using input and output formats that make it easy to identify valid input and correct output. This rule aims to reduce debugging time and extend the lifespan of programs.
-
Rule of Robustness
Developers should design robust programs by designing for transparency and discoverability, because code that is easy to understand is easier to stress test for unexpected conditions that may not be foreseeable in complex programs. This rule aims to help developers build robust, reliable products.
(...)
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
- Small is beautiful.
- Make each program do one thing well.
- Build a prototype as soon as possible.
- Choose portability over efficiency.
- Store data in flat text files.
- Use software leverage to your advantage.
- Use shell scripts to increase leverage and portability.
- Avoid captive user interfaces.
- Make every program a filter. ] .footnote[ The Unix Philosophy ]
??? In 1994, Mike Gancarz (a member of the team that designed the X Window System), drew on his own experience with Unix, as well as discussions with fellow programmers and people in other fields who depended on Unix, to produce The UNIX Philosophy which sums it up in 9 paramount precepts:
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
# Print all SVGs...
$ tree | grep svg | awk '{ print $3 }'
]
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
# Get all SVGs in tree
$ tree | grep svg
│ ├── complete_view.svg
│ ├── landscape.svg
│ ├── layered_architecture_with_processes.svg
│ ├── orchestration.svg
│ ├── process_delete.svg
│ ├── process_sample.svg
│ ├── three_landscapes.svg
# Print 3rd coloumn so we get the filenames
$ tree | grep svg | awk '{ print $3 }'
complete_view.svg
landscape.svg
layered_architecture_with_processes.svg
orchestration.svg
process_delete.svg
process_sample.svg
three_landscapes.svg
]
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
git branch --merged | egrep -v "(master|develop)" | xargs git branch -D
name: motivation class: left, middle background-image: url(img/extinct.jpg)
.regular[
# Get all merged branches.
git branch --merged
# All merged branches; exclude master and devevlop.
git branch --merged | egrep -v "(master|develop)"
# Delete all merged branches exept master and develop.
git branch --merged | egrep -v "(master|develop)" | xargs git branch -D
]
name: motivation class: center, middle background-image: url(img/space.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/tidy_stack_small.jpg)
.regular[
-
Know the Unix philosophy.
-
Design good APIs.
-
Use a centralized logging.
-
Communication is key.
-
Do 12 Factor apps. ] .footnote[ 12 Factor ]
background-image: url(img/breathe.jpg)
background-image: url(img/company_clouds.jpg)
name: introduction class: left, middle background-image: url(img/company_clouds.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/company_clouds.jpg)
.regular[
Missing link. ]
name: introduction class: center, middle background-image: url(img/company_clouds.jpg)
.regular[
name: introduction class: center, middle background-image: url(img/thunder.jpg)
name: introduction class: left, middle background-image: url(img/thunder.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/idea.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/idea.jpg)
.regular[
Processes as
- central tool of communication.
- core of the documentation.
- foundation for Microservices. ]
background-image: url(img/people_boss.jpg)
name: motivation class: left, middle background-image: url(img/people_boss.jpg)
.regular[
Money Money Money. ]
background-image: url(img/people_dev.jpg)
name: motivation class: left, middle background-image: url(img/people_dev.jpg)
.regular[
Code Code Code. ]
background-image: url(img/people_op.jpg)
name: motivation class: left, middle background-image: url(img/people_op.jpg)
.regular[
OMG. Mess. Help. ]
background-image: url(img/work_together.jpg)
name: motivation class: left, middle background-image: url(img/work_together.jpg)
.regular[
Find a common language. This is hard. ]
name: motivation class: left, middle background-image: url(img/business_case.jpg)
.regular[
]
name: motivation class: left, middle background-image: url(img/business_case.jpg)
.regular[
Wait, what about the Rules?
- Rule of Transparency
- Rule of Parsimony
- Rule of Generation
- Rule of Optimization ] .footnote[ From 17 Unix Rules ]
???
-
Rule of Generation
Developers should avoid writing code by hand and instead write abstract high-level programs that generate code. This rule aims to reduce human errors and save time.
-
Rule of Optimization
Developers should prototype software before polishing it. This rule aims to prevent developers from spending too much time for marginal gains.
-
Rule of Diversity
Developers should design their programs to be flexible and open. This rule aims to make programs flexible, allowing them to be used in ways other than those their developers intended.
-
Rule of Extensibility
Developers should design for the future by making their protocols extensible, allowing for easy plugins without modification to the program's architecture by other developers, noting the version of the program, and more. This rule aims to extend the lifespan and enhance the utility of the code the developer writes.
name: motivation class: center, top background-image: url(img/business_case.jpg)
.regular[
name: motivation class: center, top background-image: url(img/business_case.jpg)
.regular[
name: motivation class: center, top background-image: url(img/business_case.jpg)
.regular[
name: motivation class: center, top background-image: url(img/business_case.jpg)
name: motivation class: center, middle background-image: url(img/business_case.jpg)
name: motivation class: center, middle background-image: url(img/business_case.jpg)
name: motivation class: left, middle background-image: url(img/business_case.jpg)
.regular[
We already have plenty of them!
Using them is probably a good idea.
It will bring us to our common goal. ]
background-image: url(img/together.jpg)
background-image: url(img/final_scene.jpg)
name: motivation class: center, middle background-image: url(img/together.jpg)
.regular[
]
background-image: url(img/beautiful_stack.jpg)
name: introduction class: left, middle background-image: url(img/cinema.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/cinema.jpg)
.regular[
- We want to be fault tolerant.
- Dependencies are all transparent.
- We want well behaving services.
- Failures are just changes.
- We want to scale. ]
name: introduction class: left, middle background-image: url(img/workshop_garage.jpg)
.regular[
]
name: introduction class: left, middle background-image: url(img/workshop_garage.jpg)
.regular[
- Service Discovery
- Load Balancing
- Automated failover
- Config changes
- Architectural Monitoring ]
name: introduction class: left, middle background-image: url(img/pilot.jpg)
name: introduction class: center, middle background-image: url(img/pilot.jpg)
.footnote[ Source ]
name: introduction class: left, middle background-image: url(img/pilot.jpg)
.regular[
- preStart - to initialize the microservice (e.g. to create configuration files).
- preStop/postStop - to perform a cleanup right before or after main process stopped.
- health - to periodically check if the application behaves as expected.
- onChange - whenever a dependency changes its state. ]
name: introduction class: center, middle background-image: url(img/pilot.jpg)
.regular[
]
.footnote[
Autopilot Hello-World
]
name: introduction class: left, middle background-image: url(img/pilot.jpg)
.regular[
- Nginx - nginx server rendering static assets.
- Consul - service catalog used to keep track of registered services.
- Hello - Node.js service responding with the word "Hello".
- World - Node.js service responding with the word "World". ]
name: demo class: left, middle background-image: url(img/solo_1.jpg)
.regular[
Let's check out the ContainerPilot Pattern... ]
background-image: url(img/construct.jpg)
name: introduction class: center, middle background-image: url(img/construct.jpg)
.regular[
]
.footnote[
Source
]
name: introduction class: center, middle background-image: url(img/construct.jpg)
.regular[
]
.footnote[
Source
]
name: introduction class: center, middle background-image: url(img/construct.jpg)
.regular[
]
.footnote[
Source
]
name: introduction class: center, middle background-image: url(img/construct.jpg)
.regular[
]
.footnote[
Source
]
name: introduction class: center, middle background-image: url(img/construct.jpg)
.regular[
]
.footnote[
Source
]
name: introduction class: center, middle background-image: url(img/construct.jpg)
.regular[
]
.footnote[
Source
]
name: introduction class: left, middle background-image: url(img/construct.jpg)
.regular[
- Technology agnostic orchestration pattern.
- Will bring you transparency.
- Devs learn to think like operators.
- Available on your platform. ]
name: introduction class: center, middle background-image: url(img/travel.jpg)
name: explore class: left, middle background-image: url(img/playground.jpg)
.regular[
Visit our Meetups!
name: explore class: left, middle background-image: url(img/curious.jpg)
.page_left[ #... Stay Curious! ]