SlideShare a Scribd company logo
Building a
Spring Boot
Application
(ask the audience)
Hanno Embregts @hannotify
Hanno?
Introducing
Spring Boot
Spring Boot?
( )
"Takes an opinionated view of building
production-ready Spring applications.
Favors convention over con guration and
is designed to get you up and running as
quickly as possible."
https://projects.spring.io/spring-boot
Key features?
create stand-alone Spring applications
embed web server directly (no WAR les)
automatic Spring con guration wherever
possible
no code generation and no XML con guration
still offering all Spring features.
Pros?
no separate web server needed
better debugging in IDEs
faster deployments (about 50%)
no web.xml or con guration classes needed
up and running with one Java le and a build
script.
( )https://www.ethode.com/blog/6-simple-reasons-why-spring-boot-rocks
Cons?
custom con guration will be a bit of a puzzle
porting your legacy Spring project would be a
disaster!
it uses Spring, excluding roughly half of the Java
community.
Starting Out
About What We Claimed
Earlier...
"up and running with one Java le and a
build script"
Java le(s)
// imports...
@RestController
public class HelloController {
@RequestMapping("/")
public String index() {
return "Greetings from Spring Boot!";
}
}
// imports...
@SpringBootApplication
public class Application {
public static void main(String[] args) {
SpringApplication.run(Application.class, args);
}
}
Build script
apply plugin: 'java'
apply plugin: 'idea'
apply plugin: 'org.springframework.boot'
jar {
// some properties...
}
// repositories...
dependencies {
compile("org.springframework.boot:spring-boot-starter-web")
testCompile("junit:junit")
}
Starter Dependencies
a set of convenient dependency descriptors
follow the naming pattern spring-boot-starter-
*
Name Purpose
spring-boot-starter Core starter, includes auto-con g & logging
spring-boot-starter-test Test starter, includes JUnit, Hamcrest & Mockito
spring-boot-starter-web Starter for Spring MVC Web applications
spring-boot-starter-data-jpa Spring Data with JPA
(more starters at
)
https://docs.spring.io/spring-
boot/docs/current/reference/htmlsingle/#using-boot-starter
Spring Initializr
(a quick way to download a project setup)
http://start.spring.io/
Live coding
Kahoot! #1
Kahoot! #2
Wrap-up &
Questions
Wrap-up
Spring Boot
gets you up & running quickly;
assumes standard con guration for rapid
development;
plays nice with a wide range of frameworks;
is up to the task no matter what choices you make.
And what if I prefer JavaEE?
At least you can use embedded servers:
TomEE Embedded
( )
Wild y Swarm
( )
Quick assembly with JBoss ShrinkWrap
(
)
http://tomee.apache.org/advanced/tomee-embedded/index.html
http://wild y-swarm.io/
http://www.lordofthejars.com/2014/09/apache-tomee-shrinkwrap-javaee-boot-
not.html
Any questions?
Thank you! ☺
You can contact me at:
@hannotify
hanno.embregts@infosupport.com

More Related Content

What's hot (20)

PDF
Spring Boot Intro
Alberto Flores
 
PDF
Introduction to Spring Boot!
Jakub Kubrynski
 
ODP
Xke spring boot
sourabh aggarwal
 
PDF
Spring Boot
HongSeong Jeon
 
PDF
Building a Spring Boot Application - Ask the Audience! (from JavaLand 2017)
🎤 Hanno Embregts 🎸
 
PPTX
Spring Boot and REST API
07.pallav
 
PDF
Spring Boot & Actuators
VMware Tanzu
 
PDF
Getting Reactive with Spring Framework 5.0’s GA release
VMware Tanzu
 
PPTX
How to customize Spring Boot?
GilWon Oh
 
PPTX
Spring boot 3g
vasya10
 
PDF
Building a Spring Boot Application - Ask the Audience! (from JVMCon 2018)
🎤 Hanno Embregts 🎸
 
PPTX
Spring Boot Showcase
Naphachara Rattanawilai
 
PPTX
Spring boot
Pradeep Shanmugam
 
PDF
Spring Boot 1.3 News #渋谷Java
Toshiaki Maki
 
PPTX
What is Spring Boot and Why Spring Boot ?
narendrachinnu
 
PPTX
Introduction to Spring Boot
Purbarun Chakrabarti
 
PDF
Spring boot入門ハンズオン第二回
haruki ueno
 
PPTX
Spring boot
Shatrughna Singh
 
PPT
Apache ANT vs Apache Maven
Mudit Gupta
 
PDF
Developing Modern Java Web Applications with Java EE 7 and AngularJS
Shekhar Gulati
 
Spring Boot Intro
Alberto Flores
 
Introduction to Spring Boot!
Jakub Kubrynski
 
Xke spring boot
sourabh aggarwal
 
Spring Boot
HongSeong Jeon
 
Building a Spring Boot Application - Ask the Audience! (from JavaLand 2017)
🎤 Hanno Embregts 🎸
 
Spring Boot and REST API
07.pallav
 
Spring Boot & Actuators
VMware Tanzu
 
Getting Reactive with Spring Framework 5.0’s GA release
VMware Tanzu
 
How to customize Spring Boot?
GilWon Oh
 
Spring boot 3g
vasya10
 
Building a Spring Boot Application - Ask the Audience! (from JVMCon 2018)
🎤 Hanno Embregts 🎸
 
Spring Boot Showcase
Naphachara Rattanawilai
 
Spring boot
Pradeep Shanmugam
 
Spring Boot 1.3 News #渋谷Java
Toshiaki Maki
 
What is Spring Boot and Why Spring Boot ?
narendrachinnu
 
Introduction to Spring Boot
Purbarun Chakrabarti
 
Spring boot入門ハンズオン第二回
haruki ueno
 
Spring boot
Shatrughna Singh
 
Apache ANT vs Apache Maven
Mudit Gupta
 
Developing Modern Java Web Applications with Java EE 7 and AngularJS
Shekhar Gulati
 

Similar to Building a Spring Boot Application - Ask the Audience! (20)

PDF
Building a Spring Boot 2 Application - Ask the Audience! (from Voxxed Days Vi...
🎤 Hanno Embregts 🎸
 
PDF
Building a Spring Boot 2 Application - Ask the Audience! (from Voxxed Days Vi...
RianneEmbregts
 
PDF
Spring Boot Interview Questions PDF By ScholarHat
Scholarhat
 
PDF
Spring boot jpa
Hamid Ghorbani
 
PPTX
Spring boot Introduction
Jeevesh Pandey
 
PPTX
dokumen.tips_introduction-to-spring-boot-58bb649a21ce5.pptx
Appster1
 
PDF
Spring Boot Whirlwind Tour
VMware Tanzu
 
PPTX
Introduction to spring boot
Santosh Kumar Kar
 
PPT
Developing Java Web Applications
hchen1
 
PDF
Spring Boot
Jaran Flaath
 
PPTX
Module 6 _ Spring Boot for java application to begin
Deepakprasad838637
 
PPTX
Bootify your spring application
Jimmy Lu
 
PPTX
Java and services code lab spring boot and spring data using mongo db
Staples
 
PPTX
Java and services code lab spring boot and spring data using mongo db
Staples
 
PPT
Play framework
sambaochung
 
PDF
Using HttpWatch Plug-in with Selenium Automation in Java
Sandeep Tol
 
PPTX
Spring boot - an introduction
Jonathan Holloway
 
DOCX
Spring competitive tests
SkillPracticalEdTech
 
PDF
JVM Web Frameworks Exploration
Kevin H.A. Tan
 
PPTX
Deploying applications to Cloud with Google App Engine
Alexander Zamkovyi
 
Building a Spring Boot 2 Application - Ask the Audience! (from Voxxed Days Vi...
🎤 Hanno Embregts 🎸
 
Building a Spring Boot 2 Application - Ask the Audience! (from Voxxed Days Vi...
RianneEmbregts
 
Spring Boot Interview Questions PDF By ScholarHat
Scholarhat
 
Spring boot jpa
Hamid Ghorbani
 
Spring boot Introduction
Jeevesh Pandey
 
dokumen.tips_introduction-to-spring-boot-58bb649a21ce5.pptx
Appster1
 
Spring Boot Whirlwind Tour
VMware Tanzu
 
Introduction to spring boot
Santosh Kumar Kar
 
Developing Java Web Applications
hchen1
 
Spring Boot
Jaran Flaath
 
Module 6 _ Spring Boot for java application to begin
Deepakprasad838637
 
Bootify your spring application
Jimmy Lu
 
Java and services code lab spring boot and spring data using mongo db
Staples
 
Java and services code lab spring boot and spring data using mongo db
Staples
 
Play framework
sambaochung
 
Using HttpWatch Plug-in with Selenium Automation in Java
Sandeep Tol
 
Spring boot - an introduction
Jonathan Holloway
 
Spring competitive tests
SkillPracticalEdTech
 
JVM Web Frameworks Exploration
Kevin H.A. Tan
 
Deploying applications to Cloud with Google App Engine
Alexander Zamkovyi
 
Ad

More from 🎤 Hanno Embregts 🎸 (17)

PDF
Pattern Matching: Small Enhancement or Major Feature?
🎤 Hanno Embregts 🎸
 
PDF
Pattern Matching - Small Enhancement or Major Feature? from Developer Week 202
🎤 Hanno Embregts 🎸
 
PDF
"Will Git Be Around Forever? A List of Possible Successors" from Devoxx 2022
🎤 Hanno Embregts 🎸
 
PDF
"Will Git Be Around Forever? A List of Possible Successors" from FrontMania 2022
🎤 Hanno Embregts 🎸
 
PDF
Pattern Matching: Small Enhancement or Major Feature?
🎤 Hanno Embregts 🎸
 
PDF
JCON 2021 talk - "Wil Git Be Around Forever? A List of Possible Successors"
🎤 Hanno Embregts 🎸
 
PDF
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
🎤 Hanno Embregts 🎸
 
PDF
Pattern Matching: Small Enhancement or Major Feature? (talk from jLove 2021)
🎤 Hanno Embregts 🎸
 
PDF
Pattern Matching: From Small Enhancement to Major Feature (talk from JavaLand...
🎤 Hanno Embregts 🎸
 
PDF
Entering the Fourth Dimension of OCR with Tesseract
🎤 Hanno Embregts 🎸
 
PDF
The Soft Side of Software Development / Devoxx 2019
🎤 Hanno Embregts 🎸
 
PDF
Beware of Survivorship Bias! (conference talk at J-Fall 2019)
🎤 Hanno Embregts 🎸
 
PDF
Will Git Be Around Forever? A List of Possible Successors
🎤 Hanno Embregts 🎸
 
PDF
Entering the Fourth Dimension of OCR with Tesseract - Talk from Voxxed Days B...
🎤 Hanno Embregts 🎸
 
PDF
QWERTY or DVORAK? Debunking the Keyboard Layout Myths -- from GeeCON 2018
🎤 Hanno Embregts 🎸
 
PDF
QWERTY or DVORAK? Debunking the Keyboard Layout Myths
🎤 Hanno Embregts 🎸
 
PDF
Migrating 25K lines of Ant scripting to Gradle
🎤 Hanno Embregts 🎸
 
Pattern Matching: Small Enhancement or Major Feature?
🎤 Hanno Embregts 🎸
 
Pattern Matching - Small Enhancement or Major Feature? from Developer Week 202
🎤 Hanno Embregts 🎸
 
"Will Git Be Around Forever? A List of Possible Successors" from Devoxx 2022
🎤 Hanno Embregts 🎸
 
"Will Git Be Around Forever? A List of Possible Successors" from FrontMania 2022
🎤 Hanno Embregts 🎸
 
Pattern Matching: Small Enhancement or Major Feature?
🎤 Hanno Embregts 🎸
 
JCON 2021 talk - "Wil Git Be Around Forever? A List of Possible Successors"
🎤 Hanno Embregts 🎸
 
"Will Git Be Around Forever? A List of Possible Successors" at UtrechtJUG
🎤 Hanno Embregts 🎸
 
Pattern Matching: Small Enhancement or Major Feature? (talk from jLove 2021)
🎤 Hanno Embregts 🎸
 
Pattern Matching: From Small Enhancement to Major Feature (talk from JavaLand...
🎤 Hanno Embregts 🎸
 
Entering the Fourth Dimension of OCR with Tesseract
🎤 Hanno Embregts 🎸
 
The Soft Side of Software Development / Devoxx 2019
🎤 Hanno Embregts 🎸
 
Beware of Survivorship Bias! (conference talk at J-Fall 2019)
🎤 Hanno Embregts 🎸
 
Will Git Be Around Forever? A List of Possible Successors
🎤 Hanno Embregts 🎸
 
Entering the Fourth Dimension of OCR with Tesseract - Talk from Voxxed Days B...
🎤 Hanno Embregts 🎸
 
QWERTY or DVORAK? Debunking the Keyboard Layout Myths -- from GeeCON 2018
🎤 Hanno Embregts 🎸
 
QWERTY or DVORAK? Debunking the Keyboard Layout Myths
🎤 Hanno Embregts 🎸
 
Migrating 25K lines of Ant scripting to Gradle
🎤 Hanno Embregts 🎸
 
Ad

Recently uploaded (20)

PDF
Python basic programing language for automation
DanialHabibi2
 
PDF
HubSpot Main Hub: A Unified Growth Platform
Jaswinder Singh
 
PDF
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
PDF
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
PPTX
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
PDF
Presentation - Vibe Coding The Future of Tech
yanuarsinggih1
 
PDF
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
PDF
DevBcn - Building 10x Organizations Using Modern Productivity Metrics
Justin Reock
 
PPTX
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
PDF
Building Real-Time Digital Twins with IBM Maximo & ArcGIS Indoors
Safe Software
 
PDF
July Patch Tuesday
Ivanti
 
PDF
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
PPTX
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
PDF
From Code to Challenge: Crafting Skill-Based Games That Engage and Reward
aiyshauae
 
PDF
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
PDF
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
PDF
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
PDF
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
PDF
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
PPTX
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 
Python basic programing language for automation
DanialHabibi2
 
HubSpot Main Hub: A Unified Growth Platform
Jaswinder Singh
 
Bitcoin for Millennials podcast with Bram, Power Laws of Bitcoin
Stephen Perrenod
 
Exolore The Essential AI Tools in 2025.pdf
Srinivasan M
 
AI Penetration Testing Essentials: A Cybersecurity Guide for 2025
defencerabbit Team
 
Presentation - Vibe Coding The Future of Tech
yanuarsinggih1
 
New from BookNet Canada for 2025: BNC BiblioShare - Tech Forum 2025
BookNet Canada
 
DevBcn - Building 10x Organizations Using Modern Productivity Metrics
Justin Reock
 
From Sci-Fi to Reality: Exploring AI Evolution
Svetlana Meissner
 
Building Real-Time Digital Twins with IBM Maximo & ArcGIS Indoors
Safe Software
 
July Patch Tuesday
Ivanti
 
Empower Inclusion Through Accessible Java Applications
Ana-Maria Mihalceanu
 
WooCommerce Workshop: Bring Your Laptop
Laura Hartwig
 
From Code to Challenge: Crafting Skill-Based Games That Engage and Reward
aiyshauae
 
Fl Studio 24.2.2 Build 4597 Crack for Windows Free Download 2025
faizk77g
 
"Beyond English: Navigating the Challenges of Building a Ukrainian-language R...
Fwdays
 
Log-Based Anomaly Detection: Enhancing System Reliability with Machine Learning
Mohammed BEKKOUCHE
 
Chris Elwell Woburn, MA - Passionate About IT Innovation
Chris Elwell Woburn, MA
 
Newgen 2022-Forrester Newgen TEI_13 05 2022-The-Total-Economic-Impact-Newgen-...
darshakparmar
 
COMPARISON OF RASTER ANALYSIS TOOLS OF QGIS AND ARCGIS
Sharanya Sarkar
 

Building a Spring Boot Application - Ask the Audience!

  • 1. Building a Spring Boot Application (ask the audience) Hanno Embregts @hannotify
  • 4. Spring Boot? ( ) "Takes an opinionated view of building production-ready Spring applications. Favors convention over con guration and is designed to get you up and running as quickly as possible." https://projects.spring.io/spring-boot
  • 5. Key features? create stand-alone Spring applications embed web server directly (no WAR les) automatic Spring con guration wherever possible no code generation and no XML con guration still offering all Spring features.
  • 6. Pros? no separate web server needed better debugging in IDEs faster deployments (about 50%) no web.xml or con guration classes needed up and running with one Java le and a build script. ( )https://www.ethode.com/blog/6-simple-reasons-why-spring-boot-rocks
  • 7. Cons? custom con guration will be a bit of a puzzle porting your legacy Spring project would be a disaster! it uses Spring, excluding roughly half of the Java community.
  • 9. About What We Claimed Earlier... "up and running with one Java le and a build script"
  • 10. Java le(s) // imports... @RestController public class HelloController { @RequestMapping("/") public String index() { return "Greetings from Spring Boot!"; } } // imports... @SpringBootApplication public class Application { public static void main(String[] args) { SpringApplication.run(Application.class, args); } }
  • 11. Build script apply plugin: 'java' apply plugin: 'idea' apply plugin: 'org.springframework.boot' jar { // some properties... } // repositories... dependencies { compile("org.springframework.boot:spring-boot-starter-web") testCompile("junit:junit") }
  • 12. Starter Dependencies a set of convenient dependency descriptors follow the naming pattern spring-boot-starter- * Name Purpose spring-boot-starter Core starter, includes auto-con g & logging spring-boot-starter-test Test starter, includes JUnit, Hamcrest & Mockito spring-boot-starter-web Starter for Spring MVC Web applications spring-boot-starter-data-jpa Spring Data with JPA (more starters at ) https://docs.spring.io/spring- boot/docs/current/reference/htmlsingle/#using-boot-starter
  • 13. Spring Initializr (a quick way to download a project setup) http://start.spring.io/
  • 18. Wrap-up Spring Boot gets you up & running quickly; assumes standard con guration for rapid development; plays nice with a wide range of frameworks; is up to the task no matter what choices you make.
  • 19. And what if I prefer JavaEE? At least you can use embedded servers: TomEE Embedded ( ) Wild y Swarm ( ) Quick assembly with JBoss ShrinkWrap ( ) http://tomee.apache.org/advanced/tomee-embedded/index.html http://wild y-swarm.io/ http://www.lordofthejars.com/2014/09/apache-tomee-shrinkwrap-javaee-boot- not.html
  • 21. Thank you! ☺ You can contact me at: @hannotify [email protected]