Spring Boot allows Java developers to create standalone Spring applications that “just run,” typically using an embedded instance of Tomcat or Jetty.  Such applications require no code generation or XML configuration, while at the same time they feature integrated health monitoring and a much simplified Maven configuration. In this course, the student will build and monitor Web Applications and Restful web services with minimal configuration. Students will learn how to customize the SpringApplication, expose Endpoints configure Databases, use Spring Data Repositories, apply Spring Security to Endpoints and build Java Messaging Services (JMS).

Audience: Java Developers wishing to build Web Applications and Restful Services via the Spring framework without the need for extensive configuration
Course Duration: 2 days
Prerequisites:

Students should have knowledge of Java, Spring Dependency Injection and some Spring MVC or Servlets and JSP

Course Objectives:
  • Build Restful web services via Spring Boot
  • Achieve XMl and JSON data exchange over services
  • Write Java clients via RestTemplate to access services
  • Expose service metrics for monitoring
  • Utilize embedded and external databases in a service
  • Customize the application via Initializers and CommandLineRunners
  • Secure web applications and services using Spring Security
  • Decouple Producer and consumer Services via JMS
  • Orchestrate workflow of services
Course Outline:
  • Getting Started with Groovy
    • Installing Spring Boot CLI
    • Using Gradle
    • Build and Deploy an Application
  • Using Java with Maven
    • The pom.xml
    • Spring Boot starters, CLI, Gradle plugin
    • Application class
    • CommandLineRunner
    • @SpringBootApplication
    • Build as a Runnable jar
    • Dependency injection, component scans, Configuration classes
  • Developing Web Applications
    • Starting with Groovy and CLI
    • Using Spring Initializer
    • MVC Applications
    • Restful Services
  • Customizations
    • Logging
    • Using application..properties
    • Context Root
    • Management ports
    • Active Profiles
    • Gathering metrics
    • Health Endpoint
    • Info Endpoint
  • RESTful Web Services
    • Core REST concepts
    • REST support in Spring 4.x
    • Use Spring MVC to create RESTful Web services
    • REST specific Annotations in Spring
    • URITemplates, @PathVariable, @RequestParam
    • JSON and XML data exchange
    • @RequestMapping
    • Contract Negotiation (CONNEG)
    • Client access with HttpClient or RestTemplate
  • Databases
    • Embedded database with JdbcTemplate
    • Executing Sql scripts
    • Using a production database
    • JPA Data and JPA Repositories
    • Spring Data REST – Exposing a Repository as a RESTful service Endpoint
  • Securing an Application (Optional)
    • Authentication and Authorization basics
    • Secure endpoints
    • Using Spring Security
    • @EnableGlobalMethodSecurity
  • JMS Services (Optional)
    • ActiveMQ support
    • Using JmsTemplate
    • MessageListenerAdapter
    • SimpleMessageListenerContainer
    • JmsListenerContainerFactory