SlideShare ist ein Scribd-Unternehmen logo
1 von 33
Downloaden Sie, um offline zu lesen
Introduction to Micronaut
Ultra-Lightweight Microservices for the JVM
— by Graeme Rocher
About Me - Graeme Rocher
— Creator of Grails (http://grails.org)
— Creator of Micronaut (http://micronaut.io)
— Author "The Definitive Guide to Grails"
— Former SpringSource -> VMware -> Pivotal
— Senior Engineer at Object Computing (http://
objectcomputing.com)
— Just Received 2018 Oracle Groundbreaker award -
Thanks!
Agenda
— How we got here
— Microservice Challenges
— Microservice Framework Lanscape
— Micronaut Demos
Then and Now
— Since 2008, a lot has changed
— 10 Years is a long time in
technology
— Everybody was building
Monoliths
— No Angular, No React,
No Docker, No Microservices
So We Try to Adapt
— Let's try adapt existing legacy technologies for
Microservices
— Technologies like Spring, Jakarta EE etc were never
optimized for low memory footprint Microservices
What to do, What to do?
Shall we:
1. Try and convince people that
something never designed for
Microservices is still ok?
2. Go back to the drawing board
© Object Computing Inc., 2018
The Goal
— Create a New Framework designed from the ground-
up for Microservices and Serverless Computing
— Blazing fast startup time
— Low Memory Footprint
— As Small As Possible JAR Sizes
— Zero Dependency
— 12 Factor - https://12factor.net
The Analysis
To meet this goal we performed
an analysis of Spring and Grails
and the challenges to using them
to develop Microservice
applications
© Object Computing Inc., 2018
What Spring and Jakarta EE Do
Spring is an amazing technical achievement and does so
many things, but does them at Runtime.
— Reads the byte code of every bean it finds
— Synthesizes new annotations for each annotation on
each bean method, constructor, field etc. to support
Annotation metadata
— Builds Reflective Metadata for each bean for every
method, constructor, field etc.
So What's the Problem?
The Micro Reality
— Frameworks based on reflection
and annotations become fat
— But we love the programming
model and productivity so
we live with it
— So ... why should we be
more efficient?
Imagine if Kubernetes or
Docker had been wri!en in
Spring or Jakarta EE instead of
Go?
© Object Computing Inc., 2018
Already Solved by Ahead of Time (AOT) Compilation
— The Android Community already solved the problem
— Ahead of Time Compilation used extensively
— Google Dagger 2.x
— Compile Time Dependency Injector
— Reflection Free
— Limited in Scope to just DI
© Object Computing Inc., 2018
Introducing Micronaut
— Designed from the ground up
with Microservices in mind
— Ultra-light weight and
Reactive - Based on Netty
— Uses Ahead of Time Compilation
— HTTP Client & Server
— Support for Java, Kotlin
and Groovy
DEMO— Hello Micronaut
Hello Micronaut
@Controller
class HelloController {
@Get("/hello/{name}")
String hello(String name) { return "Hello " + name; }
}
@Client("/") // Client Generated at Compile Time
interface HelloClient {
@Get("/hello/{name}")
String hello(String name);
}
How Small?
— Smallest Micronaut Hello World JAR is 10MB when
written Java or 12MB in Groovy
— Can be run with as little as 10mb Max Heap with
Kotlin or Java (22mb for Groovy)
— Startup time around a second for Kotlin or Java (a
little more for Groovy)
— All Dependency Injection, AOP and Proxy generation
happens at compile time
What Micronaut Computes at Compile Time
— All Dependency & Configuration Injection
— Annotation Metadata (Meta annotations)
— AOP Proxies
— Essentially all framework infrastructure
— ie. What Spring/CDI do at runtime
Not Another Framework!?
— If all we had achieved was
another HTTP server
Micronaut wouldn't be very
interesting
— So what else does it do?
Natively Cloud Native
— Service Discovery - Consul, Eureka, Route 53 and
Kubernetes
— Configuration Sharing - Consul Supported and
Amazon ParameterStore
— Client Side Load Balancing - Integrated or Netflix
Ribbon Supported
— Support for Serverless Computing; AWS Lambda,
OpenFaas, Fn Supported; Azure coming
DEMO— Micronaut Pet Store
Serverless Computing
— Write Functions and Run them locally or as regular
server applications
— Deploy Functions to AWS Lambda - after warm-up
functions execute in milliseconds
@Field @Inject Twitter twitter
@CompileStatic
URL updateStatus(Message status) {
Status s = twitter.updateStatus(status.text)
String url = "https://twitter.com/$s.user.screenName/status/${s.id}"
return new URL(url)
}
GraalVM
— New Polyglot VM from Oracle
— Runs JS, Java, Ruby, R etc.
— Ability to turn Java code
native
— https://www.graalvm.org
© Object Computing Inc., 2018
GraalVM Native
— Works well when:
— Little or no runtime
reflection is used
— Limited or no dynamic
classloading
— You plan ahead
— You use third party libraries
selectively
© Object Computing Inc., 2018
DEMO
— Micronaut + GraalVM
Micronaut 1.0 Out Now
— Compile Time DI & AOP
— HTTP Client & Server
— Service Discovery
— Distributed Tracing
— Serverless Functions
— Data Access: SQL, MongoDB,
Redis, Cassandra etc.
Micronaut 1.0 on SDKman!
— The Micronaut CLI now available
via SDKman!
$ curl -s "https://get.sdkman.io" | bash
$ source "$HOME/.sdkman/bin/sdkman-init.sh"
$ sdk install micronaut
$ mn create-app hello-world
Micronaut Resources
— Gitter Community: https://gitter.im/micronautfw
— User Guide: http://micronaut.io/documentation.html
— Micronaut Guides: http://guides.micronaut.io
— FAQ: http://micronaut.io/faq.html
— Github: https://github.com/micronaut-projects/
micronaut-core
— Examples: https://github.com/micronaut-projects/
micronaut-examples
© Object Computing Inc., 2018
Micronaut Events
— Loads of upcoming Events
— Checkout - http://
micronaut.io/events.html
— Fancy a trip to Paris?
— https://voxxeddays.com
© Object Computing Inc., 2018
Summary
— Micronaut aims to provide the same wow factor for
Microservices that Grails did for Monoliths
— Built by the people that made Grails, leveraging over
10 years experience in framework development
— Uses Ahead of Time Compilation to support low-
memory footprint
— Micronaut 1.0 is available now
© Object Computing Inc., 2018
Q & A

Weitere ähnliche Inhalte

Was ist angesagt?

Spring cloud for microservices architecture
Spring cloud for microservices architectureSpring cloud for microservices architecture
Spring cloud for microservices architectureIgor Khotin
 
JavaEE Microservices platforms
JavaEE Microservices platformsJavaEE Microservices platforms
JavaEE Microservices platformsPayara
 
Gwt overview & getting started
Gwt overview & getting startedGwt overview & getting started
Gwt overview & getting startedBinh Bui
 
Polygot Java EE on the GraalVM
Polygot Java EE on the GraalVMPolygot Java EE on the GraalVM
Polygot Java EE on the GraalVMRyan Cuprak
 
JEE Conf 2015: Less JS!
JEE Conf 2015: Less JS!JEE Conf 2015: Less JS!
JEE Conf 2015: Less JS!_Dewy_
 
Spring Boot. Boot up your development. JEEConf 2015
Spring Boot. Boot up your development. JEEConf 2015Spring Boot. Boot up your development. JEEConf 2015
Spring Boot. Boot up your development. JEEConf 2015Strannik_2013
 
Web application I have always dreamt of
Web application I have always dreamt ofWeb application I have always dreamt of
Web application I have always dreamt ofVictor_Cr
 
Microservices with Spring Cloud
Microservices with Spring CloudMicroservices with Spring Cloud
Microservices with Spring CloudDaniel Eichten
 
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
 
High performance java ee with j cache and cdi
High performance java ee with j cache and cdiHigh performance java ee with j cache and cdi
High performance java ee with j cache and cdiPayara
 
How Class Data Sharing Can Speed up Your Jakarta EE Application Startup
How Class Data Sharing Can Speed up Your Jakarta EE Application StartupHow Class Data Sharing Can Speed up Your Jakarta EE Application Startup
How Class Data Sharing Can Speed up Your Jakarta EE Application StartupRudy De Busscher
 
Blazor, lo sapevi che...
Blazor, lo sapevi che...Blazor, lo sapevi che...
Blazor, lo sapevi che...Andrea Dottor
 
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...VMware Tanzu
 
Java 8: Nashorn & avatar.js di Enrico Risa al JUG Roma
Java 8: Nashorn & avatar.js di Enrico Risa al JUG RomaJava 8: Nashorn & avatar.js di Enrico Risa al JUG Roma
Java 8: Nashorn & avatar.js di Enrico Risa al JUG RomaVitalij Zadneprovskij
 
Deploying Elastic Java EE Microservices in the Cloud with Docker
Deploying Elastic Java EE Microservices in the Cloud with DockerDeploying Elastic Java EE Microservices in the Cloud with Docker
Deploying Elastic Java EE Microservices in the Cloud with DockerPayara
 
Secure JAX-RS
Secure JAX-RSSecure JAX-RS
Secure JAX-RSPayara
 

Was ist angesagt? (20)

Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...
Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...
Javantura v4 - (Spring)Boot your application on Red Hat middleware stack - Al...
 
Spring cloud for microservices architecture
Spring cloud for microservices architectureSpring cloud for microservices architecture
Spring cloud for microservices architecture
 
Javantura v4 - The power of cloud in professional services company - Ivan Krn...
Javantura v4 - The power of cloud in professional services company - Ivan Krn...Javantura v4 - The power of cloud in professional services company - Ivan Krn...
Javantura v4 - The power of cloud in professional services company - Ivan Krn...
 
Javantura v4 - JVM++ The GraalVM - Martin Toshev
Javantura v4 - JVM++ The GraalVM - Martin ToshevJavantura v4 - JVM++ The GraalVM - Martin Toshev
Javantura v4 - JVM++ The GraalVM - Martin Toshev
 
JavaEE Microservices platforms
JavaEE Microservices platformsJavaEE Microservices platforms
JavaEE Microservices platforms
 
Gwt overview & getting started
Gwt overview & getting startedGwt overview & getting started
Gwt overview & getting started
 
Polygot Java EE on the GraalVM
Polygot Java EE on the GraalVMPolygot Java EE on the GraalVM
Polygot Java EE on the GraalVM
 
JEE Conf 2015: Less JS!
JEE Conf 2015: Less JS!JEE Conf 2015: Less JS!
JEE Conf 2015: Less JS!
 
Spring Boot. Boot up your development. JEEConf 2015
Spring Boot. Boot up your development. JEEConf 2015Spring Boot. Boot up your development. JEEConf 2015
Spring Boot. Boot up your development. JEEConf 2015
 
Web application I have always dreamt of
Web application I have always dreamt ofWeb application I have always dreamt of
Web application I have always dreamt of
 
Microservices with Spring Cloud
Microservices with Spring CloudMicroservices with Spring Cloud
Microservices with Spring Cloud
 
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
 
High performance java ee with j cache and cdi
High performance java ee with j cache and cdiHigh performance java ee with j cache and cdi
High performance java ee with j cache and cdi
 
How Class Data Sharing Can Speed up Your Jakarta EE Application Startup
How Class Data Sharing Can Speed up Your Jakarta EE Application StartupHow Class Data Sharing Can Speed up Your Jakarta EE Application Startup
How Class Data Sharing Can Speed up Your Jakarta EE Application Startup
 
Blazor, lo sapevi che...
Blazor, lo sapevi che...Blazor, lo sapevi che...
Blazor, lo sapevi che...
 
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
The Making of the Oracle R2DBC Driver and How to Take Your Code from Synchron...
 
Micro Frontends
Micro FrontendsMicro Frontends
Micro Frontends
 
Java 8: Nashorn & avatar.js di Enrico Risa al JUG Roma
Java 8: Nashorn & avatar.js di Enrico Risa al JUG RomaJava 8: Nashorn & avatar.js di Enrico Risa al JUG Roma
Java 8: Nashorn & avatar.js di Enrico Risa al JUG Roma
 
Deploying Elastic Java EE Microservices in the Cloud with Docker
Deploying Elastic Java EE Microservices in the Cloud with DockerDeploying Elastic Java EE Microservices in the Cloud with Docker
Deploying Elastic Java EE Microservices in the Cloud with Docker
 
Secure JAX-RS
Secure JAX-RSSecure JAX-RS
Secure JAX-RS
 

Ähnlich wie Introduction to Micronaut at Oracle CodeOne 2018

Micronaut: A new way to build microservices
Micronaut: A new way to build microservicesMicronaut: A new way to build microservices
Micronaut: A new way to build microservicesLuram Archanjo
 
Reactive Amsterdam - Maxim Burgerhout - Quarkus Intro
Reactive Amsterdam - Maxim Burgerhout - Quarkus IntroReactive Amsterdam - Maxim Burgerhout - Quarkus Intro
Reactive Amsterdam - Maxim Burgerhout - Quarkus IntroFabio Tiriticco
 
Red Hat Java Update and Quarkus Introduction
Red Hat Java Update and Quarkus IntroductionRed Hat Java Update and Quarkus Introduction
Red Hat Java Update and Quarkus IntroductionJohn Archer
 
SpringBoot and Spring Cloud Service for MSA
SpringBoot and Spring Cloud Service for MSASpringBoot and Spring Cloud Service for MSA
SpringBoot and Spring Cloud Service for MSAOracle Korea
 
Microservices with kubernetes @190316
Microservices with kubernetes @190316Microservices with kubernetes @190316
Microservices with kubernetes @190316Jupil Hwang
 
Intro to creating kubernetes operators
Intro to creating kubernetes operators Intro to creating kubernetes operators
Intro to creating kubernetes operators Juraj Hantak
 
Developing Microservices using Spring - Beginner's Guide
Developing Microservices using Spring - Beginner's GuideDeveloping Microservices using Spring - Beginner's Guide
Developing Microservices using Spring - Beginner's GuideMohanraj Thirumoorthy
 
IBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClassIBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClassPaul Withers
 
D. Andreadis, Red Hat: Concepts and technical overview of Quarkus
D. Andreadis, Red Hat: Concepts and technical overview of QuarkusD. Andreadis, Red Hat: Concepts and technical overview of Quarkus
D. Andreadis, Red Hat: Concepts and technical overview of QuarkusUni Systems S.M.S.A.
 
The Future Is The Cloud
The Future Is The CloudThe Future Is The Cloud
The Future Is The CloudGatsbyjs
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And BeyondVMware Tanzu
 
Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC  Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC vipin kumar
 
Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020
Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020
Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020Matt Raible
 
Openstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platformOpenstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platformNagaraj Shenoy
 
Saturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt Stam
Saturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt StamSaturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt Stam
Saturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt StamKurt Stam
 
Microsoft, java and you!
Microsoft, java and you!Microsoft, java and you!
Microsoft, java and you!George Adams
 
Performance and Scale: Billions of request per day (DDD2019)
Performance and Scale: Billions of request per day (DDD2019)Performance and Scale: Billions of request per day (DDD2019)
Performance and Scale: Billions of request per day (DDD2019)Marcel Dempers
 

Ähnlich wie Introduction to Micronaut at Oracle CodeOne 2018 (20)

Micronaut: A new way to build microservices
Micronaut: A new way to build microservicesMicronaut: A new way to build microservices
Micronaut: A new way to build microservices
 
Reactive Amsterdam - Maxim Burgerhout - Quarkus Intro
Reactive Amsterdam - Maxim Burgerhout - Quarkus IntroReactive Amsterdam - Maxim Burgerhout - Quarkus Intro
Reactive Amsterdam - Maxim Burgerhout - Quarkus Intro
 
Red Hat Java Update and Quarkus Introduction
Red Hat Java Update and Quarkus IntroductionRed Hat Java Update and Quarkus Introduction
Red Hat Java Update and Quarkus Introduction
 
SpringBoot and Spring Cloud Service for MSA
SpringBoot and Spring Cloud Service for MSASpringBoot and Spring Cloud Service for MSA
SpringBoot and Spring Cloud Service for MSA
 
Microservices with kubernetes @190316
Microservices with kubernetes @190316Microservices with kubernetes @190316
Microservices with kubernetes @190316
 
Intro to creating kubernetes operators
Intro to creating kubernetes operators Intro to creating kubernetes operators
Intro to creating kubernetes operators
 
Micronaut brainbit
Micronaut brainbitMicronaut brainbit
Micronaut brainbit
 
Developing Microservices using Spring - Beginner's Guide
Developing Microservices using Spring - Beginner's GuideDeveloping Microservices using Spring - Beginner's Guide
Developing Microservices using Spring - Beginner's Guide
 
IBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClassIBM Think Session 8598 Domino and JavaScript Development MasterClass
IBM Think Session 8598 Domino and JavaScript Development MasterClass
 
D. Andreadis, Red Hat: Concepts and technical overview of Quarkus
D. Andreadis, Red Hat: Concepts and technical overview of QuarkusD. Andreadis, Red Hat: Concepts and technical overview of Quarkus
D. Andreadis, Red Hat: Concepts and technical overview of Quarkus
 
The Future Is The Cloud
The Future Is The CloudThe Future Is The Cloud
The Future Is The Cloud
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And Beyond
 
The rise of microservices
The rise of microservicesThe rise of microservices
The rise of microservices
 
Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC  Cloud compiler - Minor Project by students of CBPGEC
Cloud compiler - Minor Project by students of CBPGEC
 
Code One 2018 maven
Code One 2018   mavenCode One 2018   maven
Code One 2018 maven
 
Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020
Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020
Choose Your Own Adventure with JHipster & Kubernetes - Denver JUG 2020
 
Openstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platformOpenstack - Enterprise cloud management platform
Openstack - Enterprise cloud management platform
 
Saturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt Stam
Saturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt StamSaturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt Stam
Saturn 2019 - Serveless Integration on Kubernetes/OpenShift by Kurt Stam
 
Microsoft, java and you!
Microsoft, java and you!Microsoft, java and you!
Microsoft, java and you!
 
Performance and Scale: Billions of request per day (DDD2019)
Performance and Scale: Billions of request per day (DDD2019)Performance and Scale: Billions of request per day (DDD2019)
Performance and Scale: Billions of request per day (DDD2019)
 

Kürzlich hochgeladen

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilV3cube
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 

Kürzlich hochgeladen (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 

Introduction to Micronaut at Oracle CodeOne 2018

  • 1. Introduction to Micronaut Ultra-Lightweight Microservices for the JVM — by Graeme Rocher
  • 2. About Me - Graeme Rocher — Creator of Grails (http://grails.org) — Creator of Micronaut (http://micronaut.io) — Author "The Definitive Guide to Grails" — Former SpringSource -> VMware -> Pivotal — Senior Engineer at Object Computing (http:// objectcomputing.com) — Just Received 2018 Oracle Groundbreaker award - Thanks!
  • 3. Agenda — How we got here — Microservice Challenges — Microservice Framework Lanscape — Micronaut Demos
  • 4. Then and Now — Since 2008, a lot has changed — 10 Years is a long time in technology — Everybody was building Monoliths — No Angular, No React, No Docker, No Microservices
  • 5. So We Try to Adapt — Let's try adapt existing legacy technologies for Microservices — Technologies like Spring, Jakarta EE etc were never optimized for low memory footprint Microservices
  • 6. What to do, What to do? Shall we: 1. Try and convince people that something never designed for Microservices is still ok? 2. Go back to the drawing board © Object Computing Inc., 2018
  • 7. The Goal — Create a New Framework designed from the ground- up for Microservices and Serverless Computing — Blazing fast startup time — Low Memory Footprint — As Small As Possible JAR Sizes — Zero Dependency — 12 Factor - https://12factor.net
  • 8. The Analysis To meet this goal we performed an analysis of Spring and Grails and the challenges to using them to develop Microservice applications © Object Computing Inc., 2018
  • 9. What Spring and Jakarta EE Do Spring is an amazing technical achievement and does so many things, but does them at Runtime. — Reads the byte code of every bean it finds — Synthesizes new annotations for each annotation on each bean method, constructor, field etc. to support Annotation metadata — Builds Reflective Metadata for each bean for every method, constructor, field etc.
  • 10. So What's the Problem?
  • 11.
  • 12. The Micro Reality — Frameworks based on reflection and annotations become fat — But we love the programming model and productivity so we live with it — So ... why should we be more efficient?
  • 13. Imagine if Kubernetes or Docker had been wri!en in Spring or Jakarta EE instead of Go? © Object Computing Inc., 2018
  • 14. Already Solved by Ahead of Time (AOT) Compilation — The Android Community already solved the problem — Ahead of Time Compilation used extensively — Google Dagger 2.x — Compile Time Dependency Injector — Reflection Free — Limited in Scope to just DI © Object Computing Inc., 2018
  • 15.
  • 16. Introducing Micronaut — Designed from the ground up with Microservices in mind — Ultra-light weight and Reactive - Based on Netty — Uses Ahead of Time Compilation — HTTP Client & Server — Support for Java, Kotlin and Groovy
  • 18. Hello Micronaut @Controller class HelloController { @Get("/hello/{name}") String hello(String name) { return "Hello " + name; } } @Client("/") // Client Generated at Compile Time interface HelloClient { @Get("/hello/{name}") String hello(String name); }
  • 19. How Small? — Smallest Micronaut Hello World JAR is 10MB when written Java or 12MB in Groovy — Can be run with as little as 10mb Max Heap with Kotlin or Java (22mb for Groovy) — Startup time around a second for Kotlin or Java (a little more for Groovy) — All Dependency Injection, AOP and Proxy generation happens at compile time
  • 20. What Micronaut Computes at Compile Time — All Dependency & Configuration Injection — Annotation Metadata (Meta annotations) — AOP Proxies — Essentially all framework infrastructure — ie. What Spring/CDI do at runtime
  • 21. Not Another Framework!? — If all we had achieved was another HTTP server Micronaut wouldn't be very interesting — So what else does it do?
  • 22. Natively Cloud Native — Service Discovery - Consul, Eureka, Route 53 and Kubernetes — Configuration Sharing - Consul Supported and Amazon ParameterStore — Client Side Load Balancing - Integrated or Netflix Ribbon Supported — Support for Serverless Computing; AWS Lambda, OpenFaas, Fn Supported; Azure coming
  • 24. Serverless Computing — Write Functions and Run them locally or as regular server applications — Deploy Functions to AWS Lambda - after warm-up functions execute in milliseconds @Field @Inject Twitter twitter @CompileStatic URL updateStatus(Message status) { Status s = twitter.updateStatus(status.text) String url = "https://twitter.com/$s.user.screenName/status/${s.id}" return new URL(url) }
  • 25. GraalVM — New Polyglot VM from Oracle — Runs JS, Java, Ruby, R etc. — Ability to turn Java code native — https://www.graalvm.org © Object Computing Inc., 2018
  • 26. GraalVM Native — Works well when: — Little or no runtime reflection is used — Limited or no dynamic classloading — You plan ahead — You use third party libraries selectively © Object Computing Inc., 2018
  • 28. Micronaut 1.0 Out Now — Compile Time DI & AOP — HTTP Client & Server — Service Discovery — Distributed Tracing — Serverless Functions — Data Access: SQL, MongoDB, Redis, Cassandra etc.
  • 29. Micronaut 1.0 on SDKman! — The Micronaut CLI now available via SDKman! $ curl -s "https://get.sdkman.io" | bash $ source "$HOME/.sdkman/bin/sdkman-init.sh" $ sdk install micronaut $ mn create-app hello-world
  • 30. Micronaut Resources — Gitter Community: https://gitter.im/micronautfw — User Guide: http://micronaut.io/documentation.html — Micronaut Guides: http://guides.micronaut.io — FAQ: http://micronaut.io/faq.html — Github: https://github.com/micronaut-projects/ micronaut-core — Examples: https://github.com/micronaut-projects/ micronaut-examples © Object Computing Inc., 2018
  • 31. Micronaut Events — Loads of upcoming Events — Checkout - http:// micronaut.io/events.html — Fancy a trip to Paris? — https://voxxeddays.com © Object Computing Inc., 2018
  • 32. Summary — Micronaut aims to provide the same wow factor for Microservices that Grails did for Monoliths — Built by the people that made Grails, leveraging over 10 years experience in framework development — Uses Ahead of Time Compilation to support low- memory footprint — Micronaut 1.0 is available now © Object Computing Inc., 2018
  • 33. Q & A