SlideShare a Scribd company logo
1 of 60
Download to read offline
“So, ihr macht dann mal Microservices!”
Und nu?
André Goliath
(English slide deck for a german title, because why not)
Disclaimer
Everything in this talk is based on experiences…
… from my current project
… from other projects I worked on
… from other colleagues’ projects
… from other smart people
About me?
Full-Stack Dev. since around 2006.
But basically just a guy that worked on
and discussed a lot about microservices.
Spoiler:
That´s not how it works.
Before we start:
What are we actually talking about?
What is a microservice?
A microservice is not…
… something with X lines of code.
A microservice is not…
… your monolith cut into pieces.
(Well, maybe it is, if it was a good one.)
(But most likely not.)
A microservice is not…
… the cure to all your pain.
Anyway, let´s start coding!
Microservices are not about code.
They are about functional domains.
(Bummer, I know.)
Designing a microservice landscape
is all about bounded contexts
and domain driven design.
https://www.infoq.com/minibooks/domain-driven-design-quickly
Loose Frontend Integration
Accounts
CustomerManagement
CreditCardManagement
One Microservice represents
one domain.
Domains are technically separated
all the way from the Frontend to the Backend.
The concept of ‘microservices’
is only the first step in the right direction.
Eventually we want to achieve
truly Self Contained Systems.
Messaging / Data Sync.
Big Pile of HTML
Accounts
Big Pile of Data
CustomerManagement
CreditCardManagement
You are not doing it right if your microservices
somewhat represent bounded contexts,
but everything above and below is shared
and tightly coupled. Things WILL break.
Please read up on domain driven
design before doing microservices.
Legacy Backends are no excuse.
Okay, okay, got it. Domain first.
So we can code now, right?
Yes, but know what you are doing!
Spring Boot can be scary!
(and sometimes somewhat frustrating)
Get to know it.
Understand auto configuration
C:exampletarget>java -jar demo-0.0.1-SNAPSHOT.jar –debug
…
2017-03-26 13:54:24.371 DEBUG 5316 --- [ main]
AutoConfigurationReportLoggingInitializer :
=========================
AUTO-CONFIGURATION REPORT
=========================
Positive matches:
-----------------
DispatcherServletAutoConfiguration matched:
- @ConditionalOnClass found required class
'org.springframework.web.servlet.DispatcherServlet';
@ConditionalOnMissingClass did not find unwanted class (OnClassCondition)
- @ConditionalOnWebApplication (required) found StandardServletEnvironment
(OnWebApplicationCondition)
…
Negative matches:
-----------------
ActiveMQAutoConfiguration:
Did not match:
- @ConditionalOnClass did not find required classes
'javax.jms.ConnectionFactory', 'org.apache.activemq.ActiveMQConnectionFactory'
(OnClassCondition)
Auto Configuration Test Questions
• What does @EnableAutoConfiguration do?
• What is the purpose of spring.factories files?
• How would you replace the standard Spring Boot error page?
 Try to solve this without looking up the docs, dive right into
org.springframework.boot.autoconfigure.web.ErrorMvcAutoConfiguration
Read the release notes!
There WILL be breaking changes
going from 1.x to 1.y
shamelessly copy&pasted from
https://github.com/spring-projects/spring-boot/wiki/spring-boot-1.3-release-notes
Now you´ve got 1 Microservice.
How about 2? Or 100?
1) Code sharing
2) Communication
3) Ops & Deployment
4) Compliance, Processes, Team Setup
1)
Code Sharing
sharing is caring
Share framework code, nothing else.
Share framework code, nothing else.
If you have no regrets
about sharing your code
on github, it is probably
framework code
Share framework code, nothing else.
Filter (security, logging, monitoring,…)
Error handling
Profile / Environment configuration
Logging configuration
Common documentation
If you have no regrets
about sharing your code
on github, it is probably
framework code
2)
Communication
Blah, blah, blah, blah…
There are (at least) 2 different kinds
of communication going on
Client  Microservice Communication
REST, but how?
HATEOAS yes/no/maybe?
One API for all clients?
Customer Search Card Management Account Management
„Backend“ Microservices
Mobile App Online Banking Branch
Actual Frontends
Customer Search Card Management Account Management
„Backend“ Microservices
Mobile App Online Banking Branch
Actual Frontends
„API Gateway“ / „BFF (Backend For Frontend)“ Microservices
Mobile App
BFF Service
Online Banking
BFF Service
Branch
BFF Service
Customer Search Card Management Account Management
„Backend“ Microservices
Mobile App
BFF Service
Online Banking
BFF Service
Branch
BFF Service
Mobile App Online Banking Branch
Actual Frontends
„API Gateway“ / „BFF (Backend For Frontend)“ Microservices
Data
Tailoring
HATEOAS
Links
Service
Orchestration
Clientspecific
Security
Microservice  Microservice Communication
REST will usually work.
But many use cases profit
from asynchronous messaging.
(Just talk to one of the ‘reactive’ experts)
3)
Ops and Deployment
Keep in mind:
Microservices make devs’ life a lot easier,
but will make ops’ life much more difficult.
Keep in mind:
Microservices make devs’ life a lot easier,
but will make ops’ life much more difficult.
TALK TO THEM. EARLY. OFTEN.
THEY ARE YOUR FRIENDS.
The three golden rules
of microservice deployments
(In my opinion. Don´t ask for scientific proof.)
1) Build once, run everywhere.
Build once, run everywhere.
A microservice JAR file is built exactly once
and then never touched again.
Good
java –jar service.jar –spring.profiles.active=“production”
Bad
mvn clean install spring-boot:repackage -P “production”
2) Use the same tools. Everywhere.
Use the same tools. Everywhere.
Development, test, production. Everywhere.
Use the same tools. Everywhere.
Development, test, production. Everywhere.
no can do
in
Production
“You can not use the same software tools and
infrastructure components in test and production.”
– No regulatory body, never.
Developer
Jenkins / Ansible / PaaS / …
Development / Test Environment
Service
Host A
Service
Host B
Config
Server
Ops Guy
Production Environment
Gateway
Jenkins / Ansible / PaaS / …
Service
Host A
Service
Host B
Config
Server
Use a gateway if you need to.
“You can not use the same software tools and
infrastructure components in test and production.”
– No regulatory body, never.
Note: This has nothing to do with DevOps*.
*) DevOps is helpful, but by no means required. Nevertheless, Dev and Ops need to talk.
3) if it hurts, do it more often.
You’ve heard that one before?
SCRUM feedback cycles maybe?
if it hurts, do it more often.
The most important steps of a delivery pipeline
should be based on the most tested and
bullet-proof processes and tools.
That´s hardly the case
if you deploy to production only twice a year
and use production-only scripts for that.
if it hurts, do it more often.
The most important steps of a delivery pipeline
should be based on the most tested and
bullet-proof processes and tools.
4)
Compliance, Processes, Team Setup
Strong, the dark side is with this one...
Very specific to your individual setting.
Here are two general tips though.
1)
Don´t let the word ‘Compliance’ stop you
from taking the first steps to revamp
your software delivery process.
2)
The company needs to work vertically,
not horizontally.
Team „Business“
Team „Frontend Developer“
Team „Middleware Developer“
Team „Database and Backend Gurus“
Credits Online Channels
Internal Online
JEE COBOL
COBOL DB Admins
Teaming up along technology
antagonizes a domain driven
software architecture.
(Ever heard of
Conway’s law?)
Team „Credit“
Domain Experts
Domain Experts
Frontend Frontend
Tester
Tester
Backend
Backend
Teaming up along domain
expertise makes
Domain Driven Development
much easier.
Team „Account“
Team „Credit“
Domain Experts
Domain Experts
Frontend
Tester
Tester
Backend
Backend
Still, Tech Experts
need to be aware
of each other.
But it remains a
“Domain First” organization.
Team „Account“
Frontend
Key Takeaways
A microservice is defined by a Bounded Context,
not by anything else.
Know your Spring Boot (or whatever else you use).
Build once, run everywhere.
Use the same tools. Everywhere.
if it hurts, do it more often.
Don’t let ‘Compliance’ stop you.
Only vertical teams will succeed.
Thank You!
André Goliath
andre.goliath@senacor.de
https://www.slideshare.net/andregoliath
https://blog.senacor.com/author/andre/

More Related Content

What's hot

9 anti-patterns for node.js teams
9 anti-patterns for node.js teams9 anti-patterns for node.js teams
9 anti-patterns for node.js teamsJeff Harrell
 
Going Node At Netflix
Going Node At NetflixGoing Node At Netflix
Going Node At NetflixRyan Anklam
 
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...Matt Raible
 
When Web meet Native App
When Web meet Native AppWhen Web meet Native App
When Web meet Native AppYu-Wei Chuang
 
High Performance JavaScript - jQuery Conference SF Bay Area 2010
High Performance JavaScript - jQuery Conference SF Bay Area 2010High Performance JavaScript - jQuery Conference SF Bay Area 2010
High Performance JavaScript - jQuery Conference SF Bay Area 2010Nicholas Zakas
 
Modern UI Development With Node.js
Modern UI Development With Node.jsModern UI Development With Node.js
Modern UI Development With Node.jsRyan Anklam
 
High Performance JavaScript - WebDirections USA 2010
High Performance JavaScript - WebDirections USA 2010High Performance JavaScript - WebDirections USA 2010
High Performance JavaScript - WebDirections USA 2010Nicholas Zakas
 
High Performance Snippets
High Performance SnippetsHigh Performance Snippets
High Performance SnippetsSteve Souders
 
Deploying JHipster Microservices
Deploying JHipster MicroservicesDeploying JHipster Microservices
Deploying JHipster MicroservicesJoe Kutner
 
High Performance JavaScript 2011
High Performance JavaScript 2011High Performance JavaScript 2011
High Performance JavaScript 2011Nicholas Zakas
 
探討Web ui自動化測試工具
探討Web ui自動化測試工具探討Web ui自動化測試工具
探討Web ui自動化測試工具政億 林
 
10 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 2020
10 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 202010 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 2020
10 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 2020Matt Raible
 
Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017Matt Raible
 
The Play Framework at LinkedIn
The Play Framework at LinkedInThe Play Framework at LinkedIn
The Play Framework at LinkedInYevgeniy Brikman
 
Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021Matt Raible
 
Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016
Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016
Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016Matt Raible
 
JavaOne India 2011 - Running your Java EE 6 Apps in the Cloud
JavaOne India 2011 - Running your Java EE 6 Apps in the CloudJavaOne India 2011 - Running your Java EE 6 Apps in the Cloud
JavaOne India 2011 - Running your Java EE 6 Apps in the CloudArun Gupta
 

What's hot (20)

9 anti-patterns for node.js teams
9 anti-patterns for node.js teams9 anti-patterns for node.js teams
9 anti-patterns for node.js teams
 
Going Node At Netflix
Going Node At NetflixGoing Node At Netflix
Going Node At Netflix
 
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...
Lock That Shit Down! Auth Security Patterns for Apps, APIs, and Infra - Sprin...
 
When Web meet Native App
When Web meet Native AppWhen Web meet Native App
When Web meet Native App
 
High Performance JavaScript - jQuery Conference SF Bay Area 2010
High Performance JavaScript - jQuery Conference SF Bay Area 2010High Performance JavaScript - jQuery Conference SF Bay Area 2010
High Performance JavaScript - jQuery Conference SF Bay Area 2010
 
Modern UI Development With Node.js
Modern UI Development With Node.jsModern UI Development With Node.js
Modern UI Development With Node.js
 
High Performance JavaScript - WebDirections USA 2010
High Performance JavaScript - WebDirections USA 2010High Performance JavaScript - WebDirections USA 2010
High Performance JavaScript - WebDirections USA 2010
 
Node.js vs Play Framework
Node.js vs Play FrameworkNode.js vs Play Framework
Node.js vs Play Framework
 
High Performance Snippets
High Performance SnippetsHigh Performance Snippets
High Performance Snippets
 
Deploying JHipster Microservices
Deploying JHipster MicroservicesDeploying JHipster Microservices
Deploying JHipster Microservices
 
High Performance JavaScript 2011
High Performance JavaScript 2011High Performance JavaScript 2011
High Performance JavaScript 2011
 
探討Web ui自動化測試工具
探討Web ui自動化測試工具探討Web ui自動化測試工具
探討Web ui自動化測試工具
 
10 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 2020
10 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 202010 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 2020
10 Excellent Ways to Secure Spring Boot Applications - Okta Webinar 2020
 
Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017Bootiful Development with Spring Boot and React - SpringOne 2017
Bootiful Development with Spring Boot and React - SpringOne 2017
 
The Play Framework at LinkedIn
The Play Framework at LinkedInThe Play Framework at LinkedIn
The Play Framework at LinkedIn
 
Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021Java REST API Framework Comparison - PWX 2021
Java REST API Framework Comparison - PWX 2021
 
Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016
Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016
Microservices for the Masses with Spring Boot, JHipster, and JWT - Rich Web 2016
 
JavaOne India 2011 - Running your Java EE 6 Apps in the Cloud
JavaOne India 2011 - Running your Java EE 6 Apps in the CloudJavaOne India 2011 - Running your Java EE 6 Apps in the Cloud
JavaOne India 2011 - Running your Java EE 6 Apps in the Cloud
 
Dust.js
Dust.jsDust.js
Dust.js
 
Night Watch with QA
Night Watch with QANight Watch with QA
Night Watch with QA
 

Similar to Javaland 2017: "You´ll do microservices now". Now what?

Cloud computing - an architect's perspective
Cloud computing - an architect's perspectiveCloud computing - an architect's perspective
Cloud computing - an architect's perspectiveHARMAN Services
 
10 Ways To Improve Your Code( Neal Ford)
10  Ways To  Improve  Your  Code( Neal  Ford)10  Ways To  Improve  Your  Code( Neal  Ford)
10 Ways To Improve Your Code( Neal Ford)guestebde
 
Moved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmx
Moved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmxMoved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmx
Moved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmxMilen Dyankov
 
Deploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
Deploying 3 times a day without a downtime @ Rocket Tech Summit in BerlinDeploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
Deploying 3 times a day without a downtime @ Rocket Tech Summit in BerlinAlessandro Nadalin
 
2019 StartIT - Boosting your performance with Blackfire
2019 StartIT - Boosting your performance with Blackfire2019 StartIT - Boosting your performance with Blackfire
2019 StartIT - Boosting your performance with BlackfireMarko Mitranić
 
Continuous Delivery: The Dirty Details
Continuous Delivery: The Dirty DetailsContinuous Delivery: The Dirty Details
Continuous Delivery: The Dirty DetailsMike Brittain
 
A Software Problem (and a maybe-solution)
A Software Problem (and a maybe-solution)A Software Problem (and a maybe-solution)
A Software Problem (and a maybe-solution)YangJerng Hwa
 
Angular js mobile jsday 2014 - Verona 14 may
Angular js mobile   jsday 2014 - Verona 14 mayAngular js mobile   jsday 2014 - Verona 14 may
Angular js mobile jsday 2014 - Verona 14 mayLuciano Amodio
 
Automated Scaling of Microservice Stacks for JavaEE Applications
Automated Scaling of Microservice Stacks for JavaEE ApplicationsAutomated Scaling of Microservice Stacks for JavaEE Applications
Automated Scaling of Microservice Stacks for JavaEE ApplicationsJelastic Multi-Cloud PaaS
 
[RHFSeoul2017]6 Steps to Transform Enterprise Applications
[RHFSeoul2017]6 Steps to Transform Enterprise Applications[RHFSeoul2017]6 Steps to Transform Enterprise Applications
[RHFSeoul2017]6 Steps to Transform Enterprise ApplicationsDaniel Oh
 
Cloud Best Practices
Cloud Best PracticesCloud Best Practices
Cloud Best PracticesEric Bottard
 
Microsoft azure interview questions
Microsoft azure interview questionsMicrosoft azure interview questions
Microsoft azure interview questionspkmsexchange
 
Serverless in production, an experience report
Serverless in production, an experience reportServerless in production, an experience report
Serverless in production, an experience reportYan Cui
 
NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...
NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...
NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...Hafez Kamal
 
IT Trends 120-ish in the real world
 IT Trends 120-ish in the real world IT Trends 120-ish in the real world
IT Trends 120-ish in the real worldChristian John Felix
 
Code instrumentation
Code instrumentationCode instrumentation
Code instrumentationMennan Tekbir
 
Android Internals (This is not the droid you’re loking for...)
Android Internals (This is not the droid you’re loking for...)Android Internals (This is not the droid you’re loking for...)
Android Internals (This is not the droid you’re loking for...)Giacomo Bergami
 
Connecting with the enterprise - The how and why of connecting to Enterprise ...
Connecting with the enterprise - The how and why of connecting to Enterprise ...Connecting with the enterprise - The how and why of connecting to Enterprise ...
Connecting with the enterprise - The how and why of connecting to Enterprise ...Kevin Poorman
 

Similar to Javaland 2017: "You´ll do microservices now". Now what? (20)

Cloud computing - an architect's perspective
Cloud computing - an architect's perspectiveCloud computing - an architect's perspective
Cloud computing - an architect's perspective
 
10 Ways To Improve Your Code( Neal Ford)
10  Ways To  Improve  Your  Code( Neal  Ford)10  Ways To  Improve  Your  Code( Neal  Ford)
10 Ways To Improve Your Code( Neal Ford)
 
Moved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmx
Moved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmxMoved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmx
Moved to https://slidr.io/azzazzel/web-application-performance-tuning-beyond-xmx
 
10 Ways To Improve Your Code
10 Ways To Improve Your Code10 Ways To Improve Your Code
10 Ways To Improve Your Code
 
Deploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
Deploying 3 times a day without a downtime @ Rocket Tech Summit in BerlinDeploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
Deploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
 
2019 StartIT - Boosting your performance with Blackfire
2019 StartIT - Boosting your performance with Blackfire2019 StartIT - Boosting your performance with Blackfire
2019 StartIT - Boosting your performance with Blackfire
 
Continuous Delivery: The Dirty Details
Continuous Delivery: The Dirty DetailsContinuous Delivery: The Dirty Details
Continuous Delivery: The Dirty Details
 
A Software Problem (and a maybe-solution)
A Software Problem (and a maybe-solution)A Software Problem (and a maybe-solution)
A Software Problem (and a maybe-solution)
 
Angular js mobile jsday 2014 - Verona 14 may
Angular js mobile   jsday 2014 - Verona 14 mayAngular js mobile   jsday 2014 - Verona 14 may
Angular js mobile jsday 2014 - Verona 14 may
 
Automated Scaling of Microservice Stacks for JavaEE Applications
Automated Scaling of Microservice Stacks for JavaEE ApplicationsAutomated Scaling of Microservice Stacks for JavaEE Applications
Automated Scaling of Microservice Stacks for JavaEE Applications
 
Micro services
Micro servicesMicro services
Micro services
 
[RHFSeoul2017]6 Steps to Transform Enterprise Applications
[RHFSeoul2017]6 Steps to Transform Enterprise Applications[RHFSeoul2017]6 Steps to Transform Enterprise Applications
[RHFSeoul2017]6 Steps to Transform Enterprise Applications
 
Cloud Best Practices
Cloud Best PracticesCloud Best Practices
Cloud Best Practices
 
Microsoft azure interview questions
Microsoft azure interview questionsMicrosoft azure interview questions
Microsoft azure interview questions
 
Serverless in production, an experience report
Serverless in production, an experience reportServerless in production, an experience report
Serverless in production, an experience report
 
NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...
NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...
NanoSec Conference 2019: Code Execution Analysis in Mobile Apps - Abdullah Jo...
 
IT Trends 120-ish in the real world
 IT Trends 120-ish in the real world IT Trends 120-ish in the real world
IT Trends 120-ish in the real world
 
Code instrumentation
Code instrumentationCode instrumentation
Code instrumentation
 
Android Internals (This is not the droid you’re loking for...)
Android Internals (This is not the droid you’re loking for...)Android Internals (This is not the droid you’re loking for...)
Android Internals (This is not the droid you’re loking for...)
 
Connecting with the enterprise - The how and why of connecting to Enterprise ...
Connecting with the enterprise - The how and why of connecting to Enterprise ...Connecting with the enterprise - The how and why of connecting to Enterprise ...
Connecting with the enterprise - The how and why of connecting to Enterprise ...
 

Recently uploaded

The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Enterprise Knowledge
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024Stephanie Beckett
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 

Recently uploaded (20)

The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024Designing IA for AI - Information Architecture Conference 2024
Designing IA for AI - Information Architecture Conference 2024
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024What's New in Teams Calling, Meetings and Devices March 2024
What's New in Teams Calling, Meetings and Devices March 2024
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 

Javaland 2017: "You´ll do microservices now". Now what?

  • 1. “So, ihr macht dann mal Microservices!” Und nu? André Goliath (English slide deck for a german title, because why not)
  • 2. Disclaimer Everything in this talk is based on experiences… … from my current project … from other projects I worked on … from other colleagues’ projects … from other smart people About me? Full-Stack Dev. since around 2006. But basically just a guy that worked on and discussed a lot about microservices.
  • 3.
  • 5. Before we start: What are we actually talking about? What is a microservice?
  • 6. A microservice is not… … something with X lines of code.
  • 7. A microservice is not… … your monolith cut into pieces. (Well, maybe it is, if it was a good one.) (But most likely not.)
  • 8. A microservice is not… … the cure to all your pain.
  • 10.
  • 11. Microservices are not about code. They are about functional domains. (Bummer, I know.)
  • 12. Designing a microservice landscape is all about bounded contexts and domain driven design. https://www.infoq.com/minibooks/domain-driven-design-quickly
  • 13. Loose Frontend Integration Accounts CustomerManagement CreditCardManagement One Microservice represents one domain. Domains are technically separated all the way from the Frontend to the Backend. The concept of ‘microservices’ is only the first step in the right direction. Eventually we want to achieve truly Self Contained Systems. Messaging / Data Sync.
  • 14. Big Pile of HTML Accounts Big Pile of Data CustomerManagement CreditCardManagement You are not doing it right if your microservices somewhat represent bounded contexts, but everything above and below is shared and tightly coupled. Things WILL break. Please read up on domain driven design before doing microservices. Legacy Backends are no excuse.
  • 15. Okay, okay, got it. Domain first. So we can code now, right?
  • 16. Yes, but know what you are doing!
  • 17. Spring Boot can be scary! (and sometimes somewhat frustrating) Get to know it.
  • 19. C:exampletarget>java -jar demo-0.0.1-SNAPSHOT.jar –debug … 2017-03-26 13:54:24.371 DEBUG 5316 --- [ main] AutoConfigurationReportLoggingInitializer : ========================= AUTO-CONFIGURATION REPORT ========================= Positive matches: ----------------- DispatcherServletAutoConfiguration matched: - @ConditionalOnClass found required class 'org.springframework.web.servlet.DispatcherServlet'; @ConditionalOnMissingClass did not find unwanted class (OnClassCondition) - @ConditionalOnWebApplication (required) found StandardServletEnvironment (OnWebApplicationCondition) … Negative matches: ----------------- ActiveMQAutoConfiguration: Did not match: - @ConditionalOnClass did not find required classes 'javax.jms.ConnectionFactory', 'org.apache.activemq.ActiveMQConnectionFactory' (OnClassCondition)
  • 20. Auto Configuration Test Questions • What does @EnableAutoConfiguration do? • What is the purpose of spring.factories files? • How would you replace the standard Spring Boot error page?  Try to solve this without looking up the docs, dive right into org.springframework.boot.autoconfigure.web.ErrorMvcAutoConfiguration
  • 21. Read the release notes! There WILL be breaking changes going from 1.x to 1.y
  • 23. Now you´ve got 1 Microservice. How about 2? Or 100?
  • 24. 1) Code sharing 2) Communication 3) Ops & Deployment 4) Compliance, Processes, Team Setup
  • 26. Share framework code, nothing else.
  • 27. Share framework code, nothing else. If you have no regrets about sharing your code on github, it is probably framework code
  • 28. Share framework code, nothing else. Filter (security, logging, monitoring,…) Error handling Profile / Environment configuration Logging configuration Common documentation If you have no regrets about sharing your code on github, it is probably framework code
  • 30. There are (at least) 2 different kinds of communication going on
  • 31. Client  Microservice Communication REST, but how? HATEOAS yes/no/maybe? One API for all clients?
  • 32. Customer Search Card Management Account Management „Backend“ Microservices Mobile App Online Banking Branch Actual Frontends
  • 33. Customer Search Card Management Account Management „Backend“ Microservices Mobile App Online Banking Branch Actual Frontends „API Gateway“ / „BFF (Backend For Frontend)“ Microservices Mobile App BFF Service Online Banking BFF Service Branch BFF Service
  • 34. Customer Search Card Management Account Management „Backend“ Microservices Mobile App BFF Service Online Banking BFF Service Branch BFF Service Mobile App Online Banking Branch Actual Frontends „API Gateway“ / „BFF (Backend For Frontend)“ Microservices Data Tailoring HATEOAS Links Service Orchestration Clientspecific Security
  • 35. Microservice  Microservice Communication REST will usually work. But many use cases profit from asynchronous messaging. (Just talk to one of the ‘reactive’ experts)
  • 37. Keep in mind: Microservices make devs’ life a lot easier, but will make ops’ life much more difficult.
  • 38. Keep in mind: Microservices make devs’ life a lot easier, but will make ops’ life much more difficult. TALK TO THEM. EARLY. OFTEN. THEY ARE YOUR FRIENDS.
  • 39. The three golden rules of microservice deployments (In my opinion. Don´t ask for scientific proof.)
  • 40. 1) Build once, run everywhere.
  • 41. Build once, run everywhere. A microservice JAR file is built exactly once and then never touched again. Good java –jar service.jar –spring.profiles.active=“production” Bad mvn clean install spring-boot:repackage -P “production”
  • 42. 2) Use the same tools. Everywhere.
  • 43. Use the same tools. Everywhere. Development, test, production. Everywhere.
  • 44. Use the same tools. Everywhere. Development, test, production. Everywhere. no can do in Production
  • 45.
  • 46. “You can not use the same software tools and infrastructure components in test and production.” – No regulatory body, never.
  • 47. Developer Jenkins / Ansible / PaaS / … Development / Test Environment Service Host A Service Host B Config Server Ops Guy Production Environment Gateway Jenkins / Ansible / PaaS / … Service Host A Service Host B Config Server Use a gateway if you need to. “You can not use the same software tools and infrastructure components in test and production.” – No regulatory body, never. Note: This has nothing to do with DevOps*. *) DevOps is helpful, but by no means required. Nevertheless, Dev and Ops need to talk.
  • 48. 3) if it hurts, do it more often. You’ve heard that one before? SCRUM feedback cycles maybe?
  • 49. if it hurts, do it more often. The most important steps of a delivery pipeline should be based on the most tested and bullet-proof processes and tools.
  • 50. That´s hardly the case if you deploy to production only twice a year and use production-only scripts for that. if it hurts, do it more often. The most important steps of a delivery pipeline should be based on the most tested and bullet-proof processes and tools.
  • 51. 4) Compliance, Processes, Team Setup Strong, the dark side is with this one...
  • 52. Very specific to your individual setting. Here are two general tips though.
  • 53. 1) Don´t let the word ‘Compliance’ stop you from taking the first steps to revamp your software delivery process.
  • 54. 2) The company needs to work vertically, not horizontally.
  • 55. Team „Business“ Team „Frontend Developer“ Team „Middleware Developer“ Team „Database and Backend Gurus“ Credits Online Channels Internal Online JEE COBOL COBOL DB Admins Teaming up along technology antagonizes a domain driven software architecture. (Ever heard of Conway’s law?)
  • 56. Team „Credit“ Domain Experts Domain Experts Frontend Frontend Tester Tester Backend Backend Teaming up along domain expertise makes Domain Driven Development much easier. Team „Account“
  • 57. Team „Credit“ Domain Experts Domain Experts Frontend Tester Tester Backend Backend Still, Tech Experts need to be aware of each other. But it remains a “Domain First” organization. Team „Account“ Frontend
  • 59. A microservice is defined by a Bounded Context, not by anything else. Know your Spring Boot (or whatever else you use). Build once, run everywhere. Use the same tools. Everywhere. if it hurts, do it more often. Don’t let ‘Compliance’ stop you. Only vertical teams will succeed.