img src: https://wallup.net/super-mario-bros-8-bit-super-mario-2/
SUPER
FRAMEWORK
BROS.
> PLAYER 1
> PLAYER 2 ... RDY?
whoami
background image src: https://images7.alphacoders.com/333/333222.jpg
@ipreferespresso
andrew.petryk@gmail.com
2
Andrew Petryk
Why I THINk i know things
@ipreferespresso
3
DISCLAIMER
Everything described here is true and complete to the
best of author’s knowledge.
All recommendations and inferences are made without
guarantee on the part of author.
The author disclaim any liability in connection with
the use of this information.
@ipreferespresso
4
?
princess java
Hello, %username%!
I need youR help!
image src: http://starsmedia.ign.com/stars/image/article/834/834987/princess-peach_420_1194999440.jpg @ipreferespresso
5
Please,
only you can save me!
I was seized
and held hostage by
bloody enterprise
?
@ipreferespresso
6
image src: http://starsmedia.ign.com/stars/image/article/834/834987/princess-peach_420_1194999440.jpg
princess java
The time is short!
We must use
microservices to get
rid of that monster!
?
@ipreferespresso
7
image src: http://starsmedia.ign.com/stars/image/article/834/834987/princess-peach_420_1194999440.jpg
princess java
Maybe someone
or something
can help you?
?
@ipreferespresso
8
image src: http://starsmedia.ign.com/stars/image/article/834/834987/princess-peach_420_1194999440.jpg
princess java
@ipreferespresso
9
motivation
why
microservices?
@ipreferespresso
Why MICROSERVICES matters?
10
@ipreferespresso
11
WHAT we expect
from microservice?
> fast startup
> low memory consumption
> cloud ready
> easy to develop
EXPECTATIONS
what we have ?
1 curious developer
1 Life
APX 50 minutes
@ipreferespresso
12IT’S about time to start our
quest for java rescue
TO BEAT THE BLOODY ENTERPRISE
princess Java
@ipreferespresso
13IT’S about time to start our
quest for java rescue
LET THE JOURNEY BEGIN
@ipreferespresso
14
HARDCODE MODE ONLY!
our brave developer Java
@ipreferespresso
15
Java Developer
@ipreferespresso
16
@ipreferespresso
17
Assistance
princess peach Java
mentioned
that someone can help us
with microservices!
Who could that be?
@ipreferespresso
18
Assistance
of course!
let’s use Spring!
image src: http://digitalspyuk.cdnds.net/16/30/480x240/landscape-1469624095-nintendo-mario.gif
..there was a time when Spring wasn’t a big
thinG...
but that time have changeD...
@ipreferespresso
19
JetBrain’s 2018 State of
Java Developer Ecosystem Survey
image src: https://www.jetbrains.com/research/devecosystem-2018/java/ @ipreferespresso
20
SNYK.IO 2018 JAVA MAGAZINE
JVM Survey REPORT
image src: https://snyk.io/blog/jvm-ecosystem-report-2018 @ipreferespresso
21
Spring ?!
@ipreferespresso
22
@ipreferespresso
23
image src: http://www.bilan.ch/entreprises/elon-musk-parler-de-lui-une-interview-dejantee
Less Bugs, 

Smaller Time-to-Market, 

Less Complexity
@ipreferespresso
24
Spring Developer
But, hey! SOMETHING is wrong!
Spring doesn’t have that fireballs!
@ipreferespresso
25
Less Bugs, 

Smaller Time-to-Market, 

Less ComplexitySpring Developer
image src: https://i.kym-cdn.com/entries/icons/original/000/025/957/scoobbb.jpg
revealed! that’s a Spring boot!
@ipreferespresso
26
Embedded Server
Spring
ASM
Environment
Executable JAR
SIMPLIFIED Spring Boot ANATOMY
@ipreferespresso
27
@ipreferespresso
28
LET’S CREATE A SIMPLE SPING BOOT app
image src:https://www.deviantart.com/nelde/art/Free-New-Paper-Mario-Demo-481194908
29
@ipreferespresso
What we get?
A SIMPLE SPING BOOT app
hardware: MacBook Pro 2013 Late, 2.6 GHz Intel Core i5, 16 GB 1600 MHz DDR3, SSD
@ipreferespresso
30
MEMORY USAGE
@ipreferespresso
31
Less Bugs, 

Smaller Time-to-Market, 

Less Complexity
SpringBoot
Developer
image src: https://imgflip.com/i/hfpcf
Extreme
use
of
Reflection
Testing
might be the
hell of a
problem
relatively
LONG
STARTUP
TIME
@ipreferespresso
32
Tuning
requires really
deep knowledge
@ipreferespresso
33
OOOPS!
more like Spring, But...
Maybe SOMEONE
ELSE can SAVE ME?
Do we have an alternative
to spRing boot?
?
princess java
YES! WE HAVE!
@ipreferespresso
34
Welcome! Player 2 - Micronaut
ABOUT OCI MICRONAUT DOCS
@ipreferespresso
35
WHY not
HElidon/spark/RATPACK/vert.x ETC.
@ipreferespresso
36
Has own
cli/project generation
Dependency Injection
Supports java/groovy/kotlin
FULL-STACK FRAMEWORKS
WHY not
HElidon/spark/RATPACK/vert.x ETC.
@ipreferespresso
37
u can download it from
http://micronaut.io/download.html
as binary
OR
@ipreferespresso
38
how to GET started
u can download it from
http://micronaut.io/download.html
as binary
OR
u can use
@ipreferespresso
39
how to GET started
@ipreferespresso
40
how to GET started
DESIGNED TO BE COOL
FROM THE VERY BEGINNING
MICRONAUT was designed
CONSIDERING PREVIOUS
SPRING AND GRAILS
EXPERIENCE,
BUT ALSO
with microservices AND
CLOUD in mind
@ipreferespresso
41
DESIGNED TO BE COOL
REACTIVE NATURE
Build on top of
by default use
event-loop model
@ipreferespresso
42
but
will switch to
pre-configured
I/O thread pool
when blocking is needed
DESIGNED TO BE COOL
@ipreferespressoimage src: https://www.techempower.com/benchmarks/#section=data-r17&hw=ph&test=json
according to TechEmpower web framework
benchmark
Micronaut 

is pretty solid in terms of 

JSON serialization
Benchmark Round 17/ 2018-10-30
43
DESIGNED TO BE COOL
with cloud in heart
@ipreferespresso
44
P.S.The list described on the slide is not exclusive or full
@ipreferespresso
COMPETITION
45
image src: http://animated-video-games-muscular.wikia.com/wiki/Mario
But Spring Boot provides
all of this too,
and many more.
And is already production
proven.
What can be a game-changer?
BOOT
@ipreferespresso
46
image src: https://giphy.com/gifs/trolli-luigi-mario-kart-8-death-stare-yc6LwDe1NmOsM
LET’s FIND OUT!
@ipreferespresso
THE PART WHERE PLAYER 2... READY?
47
and again HARDCODE MODE ONLY!
@ipreferespresso
48
Micronaut
@ipreferespresso
49
image src: https://gfycat.com/uk/gifs/detail/DeafeningAllGermanshepherd
@ipreferespresso
50
Micronaut Developer
problems,
insomnia,
disturbing thoughts
@ipreferespresso
51
FIRST MICRONAUT APP
@ipreferespresso
52
FIRST MICRONAUT APP
FIRST MICRONAUT APP
@ipreferespresso
53
FIRST MICRONAUT APP
@ipreferespresso
54
FIRST MICRONAUT APP
@ipreferespresso
55
What we get?
@ipreferespresso
56
Micronaut from scratch
hardware: MacBook Pro 2013 Late, 2.6 GHz Intel Core i5, 16 GB 1600 MHz DDR3, SSD
MEMORY USAGE
@ipreferespresso
57
java: Java(TM) SE Runtime Environment (build 1.8.0_181-b13)Java HotSpot(TM) 64-Bit Server VM (build 25.181-b13, mixed mode)
hardware: MacBook Pro 2013 Late, 2.6 GHz Intel Core i5, 16 GB 1600 MHz DDR3, SSD @ipreferespresso
58
What About extreme env?
@ipreferespresso
59
image src: https://pp.userapi.com/c841520/v841520753/6b0ce/gehIwIHd6JA.jpg
FIRST IMPRESSION
At first, you may think that
Micronaut looks something like this
@ipreferespresso
60
FIRST IMPRESSION
@ipreferespresso
61
IN COMPILATION WE TRUST
BUT WHAT MAKES the DIFFERENCE?
@ipreferespresso
62
IN COMPILATION WE TRUST
Compile-time Dependency injection,
AHEAD-OF-TIME AOP FRAMEWORK,
and compile-TIME auto-configurations.
@ipreferespresso
63
IN COMPILATION WE TRUST
AnnoTATion
processor
AST
@ipreferespresso
64
IN COMPILATION WE TRUST
@ipreferespresso
65
SPRING MICRONAUT
COMPILE
RUN
SCAN CLASSPATH
CGLIB/Proxy
COMPILE
INJECT
RUN/
New Instance
INJECT
IN COMPILATION WE TRUST
@ipreferespresso
66
Spring Interlope
@ipreferespresso
67
SPRING INTERLOPE
@ipreferespresso
68
MIcronaut test
@ipreferespresso
69
@ipreferespresso
70
GRAALVM
Micronaut has built-in support for GraalVM
While spring boot is all about DIY and has some issues
with Graal(svm) atm
GRAALVM
@ipreferespresso
71
GRAALVM
@ipreferespresso
72
right tool for the job
@ipreferespresso
73
> Fast startup time
> Easy testing
> compile-time config
@ipreferespresso
74
> LOW footprint
WHY MN rock?
Spring DO HELP US TO BEAT ENTERPRISE
BUT...
@ipreferespresso
75
@ipreferespresso
76
MEANWHILE IN ANOTHER CASTLE
@ipreferespresso
77
@ipreferespresso
78
instead of conclusion
Micronaut and Spring Boot ain’t foes.
They both solve the same problem - help
developer to focus on Business problems and not
on infrastructure.
And they both do it pretty well.
@ipreferespresso
79
@ipreferespresso
80
THAT’s all, FOLKS!
Q&A
image src:https://i.ytimg.com/vi/7RZQRt5_33k/maxresdefault.jpg @ipreferespresso
81

Player 2 Ready: Micronaut, a Spring Boot competitor, #DevoxxUA_2018