SlideShare a Scribd company logo
TECHNOLOGY SOLUTIONS DELIVERED
Using Spring Boot Effectively in Cloud
Foundry
Josh Ghiloni (@joshghiloni)
Senior Consultant, ECS Team
Agenda
 What is Spring? Why use it?
 What is Spring Boot? Why use it?
 Side by side with traditional Spring
 Spring Boot in Action
What is Spring? Why use it?
 Premier Java inversion of control (IoC) /
dependency injection framework
 Presents common design patterns as first class
objects
 Robust community of developers
 Responsive component owners
What is Spring Boot? Why use it?
 Opinionated
It knows what you probably want your app
configuration to look like
 Passive
It knows to get out of the way when it’s wrong
 Accelerated time to market
Significantly less boilerplate code necessary
Side by side with Traditional Spring
Traditional Spring Spring Boot
Lines of Code Written 147 (34 actual app code) 53 (34 actual app code)
Compiled WAR Size 5202 KB 16539 KB
App Start Time ~ 4 sec ~ 7 sec
Side by side with Traditional Spring
Boilerplate code (Traditional Spring)
@Configuration
@ComponentScan
@Order(Ordered.HIGHEST_PRECEDENCE)
public class AppInitializer extends
AbstractDispatcherServletInitializer {
// 15 lines of code omitted
}
@Configuration
@Order(Ordered.HIGHEST_PRECEDENCE + 10)
public class SecurityInitializer extends
AbstractSecurityWebApplicationInitializer {
// 3 lines of code omitted
}
@Configuration
@EnableWebMvc
public class WebConfig {
// 10 lines of code omitted
}
@Configuration
@EnableWebMvcSecurity
public class WebSecurityConfig extends
WebSecurityConfigurerAdapter {
// 34 lines of code omitted
}
@SpringBootApplication
public class SpringBootExampleApplication extends SpringBootServletInitializer {
public static void main(String[] args) {
SpringApplication.run(SpringBootExampleApplication.class, args);
}
@Override
protected SpringApplicationBuilder configure(SpringApplicationBuilder application) {
return application.sources(SpringBootExampleApplication.class);
}
}
Side by side with Traditional Spring
Boilerplate code (Spring Boot)
Spring Boot in action
 Code located at
https://github.com/jghiloni/cf-meetup-march2015

More Related Content

What's hot

Mobile Test Automation at eBay
Mobile Test Automation at eBayMobile Test Automation at eBay
Mobile Test Automation at eBay
Dominik Dary
 
Appium Mobile Test Automation like WebDriver
Appium Mobile Test Automation like WebDriverAppium Mobile Test Automation like WebDriver
Appium Mobile Test Automation like WebDriver
Andrii Dzynia
 
RAD in Action: Building Connected Apps with Bluetooth and App Tethering
RAD in Action: Building Connected Apps with Bluetooth and App TetheringRAD in Action: Building Connected Apps with Bluetooth and App Tethering
RAD in Action: Building Connected Apps with Bluetooth and App Tethering
Embarcadero Technologies
 

What's hot (20)

Challenges of Developing BLE Application on Android
Challenges of Developing BLE Application on AndroidChallenges of Developing BLE Application on Android
Challenges of Developing BLE Application on Android
 
Android Test Automation – one year later
Android Test Automation – one year laterAndroid Test Automation – one year later
Android Test Automation – one year later
 
Android development at mercari 2015
Android development at mercari 2015Android development at mercari 2015
Android development at mercari 2015
 
Reactで話題のRecoilを使ってみた
Reactで話題のRecoilを使ってみたReactで話題のRecoilを使ってみた
Reactで話題のRecoilを使ってみた
 
Implementing Test Automation in Agile Projects
Implementing Test Automation in Agile ProjectsImplementing Test Automation in Agile Projects
Implementing Test Automation in Agile Projects
 
[Srijan Wednesday Webinars] Building a High Performance QA Team
[Srijan Wednesday Webinars] Building a High Performance QA Team[Srijan Wednesday Webinars] Building a High Performance QA Team
[Srijan Wednesday Webinars] Building a High Performance QA Team
 
Mobile Test Automation at eBay
Mobile Test Automation at eBayMobile Test Automation at eBay
Mobile Test Automation at eBay
 
Selenium Camp 2016
Selenium Camp 2016Selenium Camp 2016
Selenium Camp 2016
 
How to Leverage Appium in Your Mobile App Testing
How to Leverage Appium in Your Mobile App TestingHow to Leverage Appium in Your Mobile App Testing
How to Leverage Appium in Your Mobile App Testing
 
How to explain what JRebel does to a developer
How to explain what JRebel does to a developerHow to explain what JRebel does to a developer
How to explain what JRebel does to a developer
 
10 things you didnt know about appium + whats new in appium 1.5
10 things you didnt know about appium + whats new in appium 1.510 things you didnt know about appium + whats new in appium 1.5
10 things you didnt know about appium + whats new in appium 1.5
 
What's New With Appium? From 1.0 to Now
What's New With Appium? From 1.0 to NowWhat's New With Appium? From 1.0 to Now
What's New With Appium? From 1.0 to Now
 
Appium Mobile Test Automation like WebDriver
Appium Mobile Test Automation like WebDriverAppium Mobile Test Automation like WebDriver
Appium Mobile Test Automation like WebDriver
 
Best Practices in Mobile CI (webinar)
Best Practices in Mobile CI (webinar)Best Practices in Mobile CI (webinar)
Best Practices in Mobile CI (webinar)
 
Applied Testing Heuristics in the Context of eBay
Applied Testing Heuristics in the Context of eBayApplied Testing Heuristics in the Context of eBay
Applied Testing Heuristics in the Context of eBay
 
Scrum Events and Artifacts in Action
Scrum Events and Artifacts in ActionScrum Events and Artifacts in Action
Scrum Events and Artifacts in Action
 
Mobile Testing Tips - Let's achieve fast feedback loops
Mobile Testing Tips - Let's achieve fast feedback loopsMobile Testing Tips - Let's achieve fast feedback loops
Mobile Testing Tips - Let's achieve fast feedback loops
 
Test Driven Development - Workshop
Test Driven Development - WorkshopTest Driven Development - Workshop
Test Driven Development - Workshop
 
Different Android Test Automation Frameworks - What Works You the Best?
Different Android Test Automation Frameworks - What Works You the Best?Different Android Test Automation Frameworks - What Works You the Best?
Different Android Test Automation Frameworks - What Works You the Best?
 
RAD in Action: Building Connected Apps with Bluetooth and App Tethering
RAD in Action: Building Connected Apps with Bluetooth and App TetheringRAD in Action: Building Connected Apps with Bluetooth and App Tethering
RAD in Action: Building Connected Apps with Bluetooth and App Tethering
 

Similar to Using Spring Boot Effectively in Cloud Foundry

TheSpringFramework
TheSpringFrameworkTheSpringFramework
TheSpringFramework
Shankar Nair
 
Spring presentecion isil
Spring presentecion isilSpring presentecion isil
Spring presentecion isil
Willy Aguirre
 
Kelly potvin nosurprises_odtug_oow12
Kelly potvin nosurprises_odtug_oow12Kelly potvin nosurprises_odtug_oow12
Kelly potvin nosurprises_odtug_oow12
Enkitec
 

Similar to Using Spring Boot Effectively in Cloud Foundry (20)

Spring Framework Rohit
Spring Framework RohitSpring Framework Rohit
Spring Framework Rohit
 
TheSpringFramework
TheSpringFrameworkTheSpringFramework
TheSpringFramework
 
Spring Framework
Spring FrameworkSpring Framework
Spring Framework
 
So You Just Inherited a $Legacy Application… NomadPHP July 2016
So You Just Inherited a $Legacy Application… NomadPHP July 2016So You Just Inherited a $Legacy Application… NomadPHP July 2016
So You Just Inherited a $Legacy Application… NomadPHP July 2016
 
Oleksandr Valetskyy - Become a .NET dependency injection ninja with Ninject
Oleksandr Valetskyy - Become a .NET dependency injection ninja with NinjectOleksandr Valetskyy - Become a .NET dependency injection ninja with Ninject
Oleksandr Valetskyy - Become a .NET dependency injection ninja with Ninject
 
Spring Framework Tutorial | VirtualNuggets
Spring Framework Tutorial | VirtualNuggetsSpring Framework Tutorial | VirtualNuggets
Spring Framework Tutorial | VirtualNuggets
 
So You Just Inherited a $Legacy Application...
So You Just Inherited a $Legacy Application...So You Just Inherited a $Legacy Application...
So You Just Inherited a $Legacy Application...
 
Reverse Engineering - Protecting and Breaking the Software
Reverse Engineering - Protecting and Breaking the SoftwareReverse Engineering - Protecting and Breaking the Software
Reverse Engineering - Protecting and Breaking the Software
 
Spring presentecion isil
Spring presentecion isilSpring presentecion isil
Spring presentecion isil
 
Spring presentecion isil
Spring presentecion isilSpring presentecion isil
Spring presentecion isil
 
Spring basics for freshers
Spring basics for freshersSpring basics for freshers
Spring basics for freshers
 
Domain Modeling & Full-Stack Web Development F#
Domain Modeling & Full-Stack Web Development F#Domain Modeling & Full-Stack Web Development F#
Domain Modeling & Full-Stack Web Development F#
 
Plugin style EA
Plugin style EAPlugin style EA
Plugin style EA
 
Kelly potvin nosurprises_odtug_oow12
Kelly potvin nosurprises_odtug_oow12Kelly potvin nosurprises_odtug_oow12
Kelly potvin nosurprises_odtug_oow12
 
Host Simulation
Host SimulationHost Simulation
Host Simulation
 
Spring boot vs spring framework razor sharp web applications
Spring boot vs spring framework razor sharp web applicationsSpring boot vs spring framework razor sharp web applications
Spring boot vs spring framework razor sharp web applications
 
Reverse Engineering: Protecting and Breaking the Software
Reverse Engineering: Protecting and Breaking the SoftwareReverse Engineering: Protecting and Breaking the Software
Reverse Engineering: Protecting and Breaking the Software
 
springtraning-7024840-phpapp01.pdf
springtraning-7024840-phpapp01.pdfspringtraning-7024840-phpapp01.pdf
springtraning-7024840-phpapp01.pdf
 
Spring ppt
Spring pptSpring ppt
Spring ppt
 
Software Development Standard Operating Procedure
Software Development Standard Operating Procedure Software Development Standard Operating Procedure
Software Development Standard Operating Procedure
 

Recently uploaded

AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
Alluxio, Inc.
 

Recently uploaded (20)

Abortion ^Clinic ^%[+971588192166''] Abortion Pill Al Ain (?@?) Abortion Pill...
Abortion ^Clinic ^%[+971588192166''] Abortion Pill Al Ain (?@?) Abortion Pill...Abortion ^Clinic ^%[+971588192166''] Abortion Pill Al Ain (?@?) Abortion Pill...
Abortion ^Clinic ^%[+971588192166''] Abortion Pill Al Ain (?@?) Abortion Pill...
 
iGaming Platform & Lottery Solutions by Skilrock
iGaming Platform & Lottery Solutions by SkilrockiGaming Platform & Lottery Solutions by Skilrock
iGaming Platform & Lottery Solutions by Skilrock
 
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
Gamify Your Mind; The Secret Sauce to Delivering Success, Continuously Improv...
 
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
How Does XfilesPro Ensure Security While Sharing Documents in Salesforce?
 
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital TransformationWSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
WSO2Con2024 - WSO2's IAM Vision: Identity-Led Digital Transformation
 
De mooiste recreatieve routes ontdekken met RouteYou en FME
De mooiste recreatieve routes ontdekken met RouteYou en FMEDe mooiste recreatieve routes ontdekken met RouteYou en FME
De mooiste recreatieve routes ontdekken met RouteYou en FME
 
Cyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdfCyaniclab : Software Development Agency Portfolio.pdf
Cyaniclab : Software Development Agency Portfolio.pdf
 
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
AI/ML Infra Meetup | Improve Speed and GPU Utilization for Model Training & S...
 
Advanced Flow Concepts Every Developer Should Know
Advanced Flow Concepts Every Developer Should KnowAdvanced Flow Concepts Every Developer Should Know
Advanced Flow Concepts Every Developer Should Know
 
Vitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume MontevideoVitthal Shirke Microservices Resume Montevideo
Vitthal Shirke Microservices Resume Montevideo
 
Studiovity film pre-production and screenwriting software
Studiovity film pre-production and screenwriting softwareStudiovity film pre-production and screenwriting software
Studiovity film pre-production and screenwriting software
 
Agnieszka Andrzejewska - BIM School Course in Kraków
Agnieszka Andrzejewska - BIM School Course in KrakówAgnieszka Andrzejewska - BIM School Course in Kraków
Agnieszka Andrzejewska - BIM School Course in Kraków
 
AI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning FrameworkAI/ML Infra Meetup | Perspective on Deep Learning Framework
AI/ML Infra Meetup | Perspective on Deep Learning Framework
 
Paketo Buildpacks : la meilleure façon de construire des images OCI? DevopsDa...
Paketo Buildpacks : la meilleure façon de construire des images OCI? DevopsDa...Paketo Buildpacks : la meilleure façon de construire des images OCI? DevopsDa...
Paketo Buildpacks : la meilleure façon de construire des images OCI? DevopsDa...
 
SOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBrokerSOCRadar Research Team: Latest Activities of IntelBroker
SOCRadar Research Team: Latest Activities of IntelBroker
 
A Comprehensive Appium Guide for Hybrid App Automation Testing.pdf
A Comprehensive Appium Guide for Hybrid App Automation Testing.pdfA Comprehensive Appium Guide for Hybrid App Automation Testing.pdf
A Comprehensive Appium Guide for Hybrid App Automation Testing.pdf
 
top nidhi software solution freedownload
top nidhi software solution freedownloadtop nidhi software solution freedownload
top nidhi software solution freedownload
 
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
Facemoji Keyboard released its 2023 State of Emoji report, outlining the most...
 
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERRORTROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
TROUBLESHOOTING 9 TYPES OF OUTOFMEMORYERROR
 
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoamOpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
OpenFOAM solver for Helmholtz equation, helmholtzFoam / helmholtzBubbleFoam
 

Using Spring Boot Effectively in Cloud Foundry

  • 1. TECHNOLOGY SOLUTIONS DELIVERED Using Spring Boot Effectively in Cloud Foundry Josh Ghiloni (@joshghiloni) Senior Consultant, ECS Team
  • 2. Agenda  What is Spring? Why use it?  What is Spring Boot? Why use it?  Side by side with traditional Spring  Spring Boot in Action
  • 3. What is Spring? Why use it?  Premier Java inversion of control (IoC) / dependency injection framework  Presents common design patterns as first class objects  Robust community of developers  Responsive component owners
  • 4. What is Spring Boot? Why use it?  Opinionated It knows what you probably want your app configuration to look like  Passive It knows to get out of the way when it’s wrong  Accelerated time to market Significantly less boilerplate code necessary
  • 5. Side by side with Traditional Spring Traditional Spring Spring Boot Lines of Code Written 147 (34 actual app code) 53 (34 actual app code) Compiled WAR Size 5202 KB 16539 KB App Start Time ~ 4 sec ~ 7 sec
  • 6. Side by side with Traditional Spring Boilerplate code (Traditional Spring) @Configuration @ComponentScan @Order(Ordered.HIGHEST_PRECEDENCE) public class AppInitializer extends AbstractDispatcherServletInitializer { // 15 lines of code omitted } @Configuration @Order(Ordered.HIGHEST_PRECEDENCE + 10) public class SecurityInitializer extends AbstractSecurityWebApplicationInitializer { // 3 lines of code omitted } @Configuration @EnableWebMvc public class WebConfig { // 10 lines of code omitted } @Configuration @EnableWebMvcSecurity public class WebSecurityConfig extends WebSecurityConfigurerAdapter { // 34 lines of code omitted }
  • 7. @SpringBootApplication public class SpringBootExampleApplication extends SpringBootServletInitializer { public static void main(String[] args) { SpringApplication.run(SpringBootExampleApplication.class, args); } @Override protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { return application.sources(SpringBootExampleApplication.class); } } Side by side with Traditional Spring Boilerplate code (Spring Boot)
  • 8. Spring Boot in action  Code located at https://github.com/jghiloni/cf-meetup-march2015