Das „Schwergewicht“ Java EE scheint nicht wirklich mit der Wunderwelt der Microservices und den damit einhergehenden Architekturpatterns zu harmonisieren. Dabei bringt der Java-Enterprise-Standard technologisch gesehen alles mit, was es zur Umsetzung von Microservices benötigt. Wo also liegt das Problem? In der Session werden wir Schritt für Schritt eine monolithische Java-EE-Anwendung „sezieren“ und uns den damit einhergehenden Herausforderungen der neu entstandenen, Microservice-basierten Architektur stellen. Aha-Effekte garantiert!
3. Lars Röwekamp (a.k.a. @mobileLarson)
ÜBER MICH
LR
#WISSENTEILEN
Wer bin ich - und wen ja, wie viele?
• CIO New Technologies
• Enterprise & Mobile
• Author, Speaker, Coach & Mentor
• Snowboard & MTB Enthusiast
• mehrfacher Vater, einfacher Ehemann
8. MONOLITH
#WISSENTEILEN
Aber nur wenn ...
• Separation of Concerns (SoC)
• High Cohesion & Low Coupling (via APIs)
• Don’t Repeat Yourself (DRY)
• Law of Demeter (LoD)
• Domain Driven Design (DDD)
• You Aren’t Going to Need It (YAGNI)
10. MONOLITH
#WISSENTEILEN
Aber die Realität sieht anders aus ...
• Umsetzung von Features dauert zu lange
• Technologische Schulden wohin man schaut
• Architektur-Qualität nimmt ab (an Bedeutung)
• „-ility“-Probleme an allen Ecken und Enden
• Deployment ist kompliziert und dauert lang
• Skalierung hat Limit erreicht
13. MONOLITH
#WISSENTEILEN
Der Big Ball of Mud ...
• „one monolithic Database“
• „one Programming Language“
• „very huge and slow Test Suite“
• „logic is buried in Abstraction“
• „logic is hidden in generated Code“
• „no survival without handmade Caching“
14. MONOLITH
#WISSENTEILEN
„For a monolith to change
all must agree on
each change.
Each change can has
unanticipated effects
requiring testing beforehead.“
23. #WISSENTEILEN
„In short, the microservice architectural style is an
approach to developing a single application as a
suite of small services, each running in its own
process and communicating with lightweight
mechanisms, often an HTTP resource API.”
24. #WISSENTEILEN
„As well as the fact that services are independently
deployable and scalable, each service also
provides a firm module boundary, even allowing for
different services to be written in different
programming languages. They can also be
managed by different teams.”
39. DAS GEHT MIT JEE?
#WISSENTEILEN
Aber passt das wirklich zusammen?
• „Maximal cohesion, minimal coupling.“1)
• JEE Business Component
• Boundary Entity Control Pattern
• In einem eigenen WAR
• Kommunikation via REST
• Deployed in einer eigenen Domain
1)
Blogbeitrag
von
Adam
Bien
43. DAS GEHT MIT JEE?
#WISSENTEILEN
Idee: „Just enough Server“
• Self-Contained Java Microservices (.jar)
• Java EE Komponenten on demand
• Embedded Servlet / Web Engine
• Health Checks, Metrics, Security
• externe Konfiguration via CommandLine & Co
65. MicroProfile.io
#WISSENTEILEN
The Mission:
An open forum to optimize Enterprise Java
for a microservices architecture by innovating
across multiple implementations and
collaborating on common areas of interest
with a goal of standardization.