Java in the Age of Containers and Serverless Markus Eisele Director of Developer Advocacy, Lightbend JAVAMATTERS
@myfear 2
3
Java developers worldwide of the Fortune 500 are using Java EE of companies use Java to build over 80% of their applications 10M+ 90% 43% Stability Specifications Availability of developers #1 #2 #3 4
5
https://twitter.com/heathervc/status/1132671885647290368
7 “There are only two kinds of languages: the ones people complain about and the ones nobody uses.” — Bjarne Stroustrup “
Vibrant and Lively Development 8 1997 SE 1.1 2000 SE 1.3 2011 SE 7 2017 SE 9 9/2018 SE 11 9/2019 SE 13 9/2020 SE 15 1998 SE 1.2 2002 SE 1.4 2006 SE 6 3/2018 SE 10 3/2019 SE 12 3/2020 SE 14 3/2021 SE 16 9/2021 SE 17 2014 SE 8 2004 SE 5
Which versions of Java do you regularly use? 9 https://www.jetbrains.com/lp/devecosystem-2019/java/
Java is Exciting! 10 New features in Java 8 – Lambdas, Streams Module system in Java 9 Java 10 going to Java 11 New feature release process! Figuring out a way around “LTS”! Playing with Jshell! Packaging with jlink!
SharedCentralized Self Service “Big Iron” “Enterprise” “Cloud” Extreme Uptime (99.999) Custom Hardware Designed for availability (99.9) Commodity Hardware Replicated Designed for failure (99.999) Virtualized / Cloud Distributed Vertical Scaling Hardware High Availability Centralized Horizontal Scaling Software High Availability 11
Clustered MonolithsOne Big Application Distributed Microservices “Big Iron” “Enterprise” “Cloud” Extreme Uptime (99.999) Vertical Scaling Custom Hardware Hardware High Availability Centralized Designed for availability (99.9) Commodity Hardware Replicated Designed for failure (99.999) Horizontal Scaling Virtualized / Cloud Software High Availability Distributed 12 Clustered MonolithsOne Big Application Distributed Microservices “Big Iron” “Enterprise” “Cloud” 9
What JDK to use? How is support working? 13Thanks @CGuntur! https://medium.com/@javachampions/java-is-still-free-c02aef8c9e04
14
So far we only talked about deployment models and architectures … But what kind of applications and business models are the real drivers?
Faster, More, Easier, Cheaper, Better. Number of Devices Connected to the Internet 16
For many years the innovation around Java exclusively focused on performance. To support modern infrastructures (Moore’s Law) and developer productivity.
Today
Typical Java Application Memory Usage Start-up lag Over Peak Usage Thanks to @spoole167! 20 THROUGHPUT T I M E
Ideal Memory Usage Profile to Save $$$/€€€ THROUGHPUT T I M E 21
The immediate challenge for Java and the JVM is to innovate faster – or lose to the competition.
Low Latency/High Performance • Respect resource constraints • JDK-8179498: attach in Linux should be relative to /proc/pid/root and namespace aware as jcmd, jsack, etc. fail to attach (resolved in JDK 10) • JDK-8193710: jcmd –l and jps commands do not list Java processes running in Docker containers (resolved in JDK 11) • And more... JDK-8203357: Container Metrics (resolved in JDK 11.0.1) • JDK 11—JEP 318: Epsilon, i.e. No-Op, Garbage Collector (experimental) • Start fast • Moving Startup Costs to Build-Time • AOT • Run in small(er) images • Alpine, jlink, GraalVM Substrate 23
24 Tomorrow
New Challenges for Developers Systems that are too complex to run on your local machine • New development tooling • New deployment approaches 26 Proprietary APIs and non standard solutions that are hard to change • Black box services • Storage APIs New forms of applications that force developers to rethink established designs • 3-tier applications no longer suitable • Message and event driven systems • Streams
The JVM Needs to Learn New Tricks Too • Offer good machine learning and data analysis capabilities • More data transformation and stream capabilities. • Problem partitioning features • Better/easier parallel execution • Work with optimized hardware (GPU, FPGA, ASIC, etc.) 27
28 The Day After Tomorrow
29
30
What if We Don’t Change at All? 31
Thank You Page Markus Eisele @myfear blog.eisele.net
Reactive Microservices Architecture Written for architects and developers that must quickly gain a fundamental understanding of microservice-based architectures, this free O’Reilly report explores the journey from SOA to microservices, discusses approaches to dismantling your monolith, and reviews the key tenets of a Reactive microservice: • Isolate all the Things • Act Autonomously • Do One Thing, and Do It Well • Own Your State, Exclusively • Embrace Asynchronous Message-Passing • Stay Mobile, but Addressable • Collaborate as Systems to Solve Problems http://bit.ly/ReactiveMicroservice 33
Developing Reactive Microservices The detailed example in this report is based on Lagom, a new framework that helps you follow the requirements for building distributed, reactive systems. • Get an overview of the Reactive Programming model and basic requirements for developing reactive microservices • Learn how to create base services, expose endpoints, and then connect them with a simple, web-based user interface • Understand how to deal with persistence, state, and clients • Use integration technologies to start a successful migration away from legacy systems http://bit.ly/DevelopReactiveMicroservice 34
Modern Java EE Design Patterns • Understand the challenges of starting a greenfield development vs tearing apart an existing brownfield application into services • Examine your business domain to see if microservices would be a good fit • Explore best practices for automation, high availability, data separation, and performance • Align your development teams around business capabilities and responsibilities • Inspect design patterns such as aggregator, proxy, pipeline, or shared resources to model service interactions http://bit.ly/SustainableEnterprise 35

Java in the Age of Containers and Serverless

  • 1.
    Java in theAge of Containers and Serverless Markus Eisele Director of Developer Advocacy, Lightbend JAVAMATTERS
  • 2.
  • 3.
  • 4.
    Java developers worldwide of theFortune 500 are using Java EE of companies use Java to build over 80% of their applications 10M+ 90% 43% Stability Specifications Availability of developers #1 #2 #3 4
  • 5.
  • 6.
  • 7.
    7 “There are onlytwo kinds of languages: the ones people complain about and the ones nobody uses.” — Bjarne Stroustrup “
  • 8.
    Vibrant and LivelyDevelopment 8 1997 SE 1.1 2000 SE 1.3 2011 SE 7 2017 SE 9 9/2018 SE 11 9/2019 SE 13 9/2020 SE 15 1998 SE 1.2 2002 SE 1.4 2006 SE 6 3/2018 SE 10 3/2019 SE 12 3/2020 SE 14 3/2021 SE 16 9/2021 SE 17 2014 SE 8 2004 SE 5
  • 9.
    Which versions ofJava do you regularly use? 9 https://www.jetbrains.com/lp/devecosystem-2019/java/
  • 10.
    Java is Exciting! 10 Newfeatures in Java 8 – Lambdas, Streams Module system in Java 9 Java 10 going to Java 11 New feature release process! Figuring out a way around “LTS”! Playing with Jshell! Packaging with jlink!
  • 11.
    SharedCentralized Self Service “BigIron” “Enterprise” “Cloud” Extreme Uptime (99.999) Custom Hardware Designed for availability (99.9) Commodity Hardware Replicated Designed for failure (99.999) Virtualized / Cloud Distributed Vertical Scaling Hardware High Availability Centralized Horizontal Scaling Software High Availability 11
  • 12.
    Clustered MonolithsOne BigApplication Distributed Microservices “Big Iron” “Enterprise” “Cloud” Extreme Uptime (99.999) Vertical Scaling Custom Hardware Hardware High Availability Centralized Designed for availability (99.9) Commodity Hardware Replicated Designed for failure (99.999) Horizontal Scaling Virtualized / Cloud Software High Availability Distributed 12 Clustered MonolithsOne Big Application Distributed Microservices “Big Iron” “Enterprise” “Cloud” 9
  • 13.
    What JDK touse? How is support working? 13Thanks @CGuntur! https://medium.com/@javachampions/java-is-still-free-c02aef8c9e04
  • 14.
  • 15.
    So far weonly talked about deployment models and architectures … But what kind of applications and business models are the real drivers?
  • 16.
    Faster, More, Easier,Cheaper, Better. Number of Devices Connected to the Internet 16
  • 17.
    For many yearsthe innovation around Java exclusively focused on performance. To support modern infrastructures (Moore’s Law) and developer productivity.
  • 18.
  • 20.
    Typical Java ApplicationMemory Usage Start-up lag Over Peak Usage Thanks to @spoole167! 20 THROUGHPUT T I M E
  • 21.
    Ideal Memory UsageProfile to Save $$$/€€€ THROUGHPUT T I M E 21
  • 22.
    The immediate challengefor Java and the JVM is to innovate faster – or lose to the competition.
  • 23.
    Low Latency/High Performance •Respect resource constraints • JDK-8179498: attach in Linux should be relative to /proc/pid/root and namespace aware as jcmd, jsack, etc. fail to attach (resolved in JDK 10) • JDK-8193710: jcmd –l and jps commands do not list Java processes running in Docker containers (resolved in JDK 11) • And more... JDK-8203357: Container Metrics (resolved in JDK 11.0.1) • JDK 11—JEP 318: Epsilon, i.e. No-Op, Garbage Collector (experimental) • Start fast • Moving Startup Costs to Build-Time • AOT • Run in small(er) images • Alpine, jlink, GraalVM Substrate 23
  • 24.
  • 26.
    New Challenges forDevelopers Systems that are too complex to run on your local machine • New development tooling • New deployment approaches 26 Proprietary APIs and non standard solutions that are hard to change • Black box services • Storage APIs New forms of applications that force developers to rethink established designs • 3-tier applications no longer suitable • Message and event driven systems • Streams
  • 27.
    The JVM Needsto Learn New Tricks Too • Offer good machine learning and data analysis capabilities • More data transformation and stream capabilities. • Problem partitioning features • Better/easier parallel execution • Work with optimized hardware (GPU, FPGA, ASIC, etc.) 27
  • 28.
  • 29.
  • 30.
  • 31.
    What if WeDon’t Change at All? 31
  • 32.
    Thank You Page MarkusEisele @myfear blog.eisele.net
  • 33.
    Reactive Microservices Architecture Written forarchitects and developers that must quickly gain a fundamental understanding of microservice-based architectures, this free O’Reilly report explores the journey from SOA to microservices, discusses approaches to dismantling your monolith, and reviews the key tenets of a Reactive microservice: • Isolate all the Things • Act Autonomously • Do One Thing, and Do It Well • Own Your State, Exclusively • Embrace Asynchronous Message-Passing • Stay Mobile, but Addressable • Collaborate as Systems to Solve Problems http://bit.ly/ReactiveMicroservice 33
  • 34.
    Developing Reactive Microservices The detailedexample in this report is based on Lagom, a new framework that helps you follow the requirements for building distributed, reactive systems. • Get an overview of the Reactive Programming model and basic requirements for developing reactive microservices • Learn how to create base services, expose endpoints, and then connect them with a simple, web-based user interface • Understand how to deal with persistence, state, and clients • Use integration technologies to start a successful migration away from legacy systems http://bit.ly/DevelopReactiveMicroservice 34
  • 35.
    Modern Java EE DesignPatterns • Understand the challenges of starting a greenfield development vs tearing apart an existing brownfield application into services • Examine your business domain to see if microservices would be a good fit • Explore best practices for automation, high availability, data separation, and performance • Align your development teams around business capabilities and responsibilities • Inspect design patterns such as aggregator, proxy, pipeline, or shared resources to model service interactions http://bit.ly/SustainableEnterprise 35