Pro Spring 5: an in-depth guide to the Spring framework and its tools 5th edition by Iuliana Cosmina, Rob Harrop, Chris Schaefer, Clarence Ho – Ebook PDF Instant Download/DeliveryISBN: 1484228081, 9781484228081
Full download Pro Spring 5: an in-depth guide to the Spring framework and its tools 5th edition after payment.
Product details:
ISBN-10 : 1484228081
ISBN-13 : 9781484228081
Author: Iuliana Cosmina, Rob Harrop, Chris Schaefer, Clarence Ho
Master Spring basics and core topics, and share the authors’ insights and real–world experiences with remoting, Hibernate, and EJB. Beyond the basics, you’ll learn how to leverage the Spring Framework to build the various tiers and parts of an enterprise Java application: transactions, web and presentation tiers, deployment, and much more. A full sample application allows you to apply many of the technologies and techniques covered in Pro Spring 5 and see how they work together. This book updates the perennial bestseller with the latest that the new Spring Framework 5 has to offer. Now in its fifth edition, this popular title is by far the most comprehensive and definitive treatment of Spring available. It covers the new functional web framework and interoperability with Java 9. After reading this definitive book, you’ll be armed with the power of Spring to build complex Spring applications, top to bottom. The agile, lightweight, open-source Spring Framework continues to be the de facto leading enterprise Java application development framework for today’s Java programmers and developers. It works with other leading open-source, agile, and lightweight Java technologies such as Hibernate, Groovy, MyBatis, and more. Spring now works with Java EE and JPA 2 as well. What You’ll Learn Discover what’s new in Spring Framework 5 Use the Spring Framework with Java 9 Master data access and transactions Work with the new functional web framework Create microservices and other web services Who This Book Is For Experienced Java and enterprise Java developers and programmers. Some experience with Spring highly recommended.
Pro Spring 5: an in-depth guide to the Spring framework and its tools 5th table of contents:
Chapter 1: Introducing Spring
What Is Spring?
Evolution of the Spring Framework
Inverting Control or Injecting Dependencies?
Evolution of Dependency Injection
Beyond Dependency Injection
Support for Java 9
Aspect-Oriented Programming with Spring
Spring Expression Language
Validation in Spring
Accessing Data in Spring
Object/XML Mapping in Spring
Managing Transactions
Simplifying and Integrating with JEE
MVC in the Web Tier
WebSocket Support
Remoting Support
Mail Support
Job Scheduling Support
Dynamic Scripting Support
Simplified Exception Handling
The Spring Project
Origins of Spring
The Spring Community
The Spring Tool Suite
The Spring Security Project
Spring Boot
Spring Batch and Integration
Many Other Projects
Alternatives to Spring
JBoss Seam Framework
Google Guice
PicoContainer
JEE 7 Container7
Summary
Chapter 2: Getting Started
Obtaining the Spring Framework
Getting Started Quickly
Checking Spring Out of GitHub
Using the Right JDK
Understanding Spring Packaging
Choosing Modules for Your Application
Accessing Spring Modules on the Maven Repository
Accessing Spring Modules Using Gradle
Using Spring Documentation
Putting a Spring into Hello World
Building the Sample Hello World Application
Refactoring with Spring
Spring Configuration Using Annotations
Summary
Chapter 3: Introducing IoC and DI in Spring
Inversion of Control and Dependency Injection
Types of Inversion of Control
Dependency Pull
Contextualized Dependency Lookup
Constructor Dependency Injection
Setter Dependency Injection
Injection vs. Lookup
Setter Injection vs. Constructor Injection
Inversion of Control in Spring
Dependency Injection in Spring
Beans and BeanFactory
BeanFactory Implementations
ApplicationContext
Configuring ApplicationContext
Setting Spring Configuration Options
Basic Configuration Overview
Declaring Spring Components
Using Java Configuration
Using Setter Injection
Using Constructor Injection
Using Field Injection
Using Injection Parameters
Injecting Simple Values
Injecting Values by Using SpEL
Injecting Beans in the Same XML Unit
Injection and ApplicationContext Nesting
Injecting Collections
Using Method Injection
Lookup Method Injection
Considerations for Lookup Method Injection
Method Replacement
When to Use Method Replacement
Understanding Bean Naming
Bean Name Aliasing
Bean Naming with Annotation Configurations
Understanding Bean Instantiation Mode
Choosing an Instantiation Mode
Implementing Bean Scopes
Resolving Dependencies
Autowiring Your Bean
When to Use Autowiring
Setting Bean Inheritance
Summary
Chapter 4: Spring Configuration in Detail and Spring Boot
Spring’s Impact on Application Portability
Bean Life-Cycle Management
Hooking into Bean Creation
Executing a Method When a Bean Is Created
Implementing the InitializingBean Interface
Using the JSR-250 @PostConstruct Annotation
Declaring an Initialization Method Using @Bean
Understanding Order of Resolution
Hooking into Bean Destruction
Executing a Method When a Bean Is Destroyed
Implementing the DisposableBean Interface
Using the JSR-250 @PreDestroy Annotation
Declaring a Destroy Method Using @Bean
Understanding Order of Resolution
Using a Shutdown Hook
Making Your Beans “Spring Aware”
Using the BeanNameAware Interface
Using the ApplicationContextAware Interface
Use of FactoryBeans
FactoryBean Example: The MessageDigestFactoryBean
Accessing a FactoryBean Directly
Using the factory-bean and factory-method Attributes
JavaBeans PropertyEditors
Using the Built-in PropertyEditors
Creating a Custom PropertyEditor
More Spring ApplicationContext Configuration
Internationalization with the MessageSource
Internationalization with the MessageSource
Using the getMessage() Method
Why Use ApplicationContext As a MessageSource?
Using MessageSource in Stand-Alone Applications
The MessageSourceResolvable Interface
Application Events
Using Application Events
Considerations for Event Usage
Accessing Resources
Configuration Using Java Classes
ApplicationContext Configuration in Java
Spring Mixed Configuration
Java or XML Configuration?
Profiles
An Example of Using the Spring Profiles Feature
Spring Profiles Using Java Configuration
Considerations for Using Profiles
Environment and PropertySource Abstraction
Configuration Using JSR-330 Annotations
Configuration Using Groovy
Spring Boot
Summary
Chapter 5: Introducing Spring AOP
AOP Concepts
Types of AOP
Using Static AOP
Using Dynamic AOP
Choosing an AOP Type
AOP in Spring
The AOP Alliance
Hello World in AOP
Spring AOP Architecture
Joinpoints in Spring
Aspects in Spring
About the ProxyFactory Class
Creating Advice in Spring
Interfaces for Advice
Creating Before Advice
Securing Method Access by Using Before Advice
Creating After-Returning Advice
Creating Around Advice
Creating Throws Advice
Choosing an Advice Type
Advisors and Pointcuts in Spring
The Pointcut Interface
Available Pointcut Implementations
Using DefaultPointcutAdvisor
Creating a Static Pointcut by Using StaticMethodMatcherPointcut
Creating a Dynamic Pointcut by Using DyanmicMethod MatcherPointcut
Using Simple Name Matching
Creating Pointcuts with Regular Expressions
Creating Pointcuts with AspectJ Pointcut Expression
Creating Annotation Matching Pointcuts
Convenience Advisor Implementations
Understanding Proxies
Using JDK Dynamic Proxies
Using CGLIB Proxies
Comparing Proxy Performance
Choosing a Proxy to Use
Advanced Use of Pointcuts
Using Control Flow Pointcuts
Using a Composable Pointcut
Composition and the Pointcut Interface
Pointcut Summary
Getting Started with Introductions
Introduction Basics
Object Modification Detection with Introductions
Using the IsModified Interface
Creating a Mixin
Creating an Advisor
Putting It All Together
Introduction Summary
Framework Services for AOP
Configuring AOP Declaratively
Using ProxyFactoryBean
ProxyFactoryBean in Action
Using ProxyFactoryBean for Introductions
ProxyFactoryBean Summary
Using the aop Namespace
Using @AspectJ-Style Annotations
Considerations for Declarative Spring AOP Configuration
AspectJ Integration
About AspectJ
Using Singleton Aspects
Summary
Chapter 6: Spring JDBC Support
Introducing Lambda Expressions
Sample Data Model for Example Code
Exploring the JDBC Infrastructure
Spring JDBC Infrastructure
Overview and Used Packages
Database Connections and DataSources
Embedded Database Support
Using DataSources in DAO Classes
Exception Handling
The JdbcTemplate Class
Initializing JdbcTemplate in a DAO Class
Using Named Parameters with NamedParameterJdbcTemplate
Retrieving Domain Objects with RowMapper
Retrieving Nested Domain Objects with ResultSetExtractor
Spring Classes That Model JDBC Operations
Querying Data by Using MappingSqlQuery
Updating Data by Using SqlUpdate
Inserting Data and Retrieving the Generated Key
Batching Operations with BatchSqlUpdate
Calling Stored Functions by Using SqlFunction
Spring Data Project: JDBC Extensions
Considerations for Using JDBC
Spring Boot JDBC
Summary
Chapter 7: Using Hibernate in Spring
Sample Data Model for Example Code
Configuring Hibernate’s SessionFactory
ORM Mapping Using Hibernate Annotations
Simple Mappings
One-to-Many Mappings
Many-to-Many Mappings
The Hibernate Session Interface
Querying Data by Using the Hibernate Query Language
Simple Querying with Lazy Fetching
Querying with Associations Fetching
Inserting Data
Updating Data
Deleting Data
Configuring Hibernate to Generate Tables from Entities
Annotating Methods or Fields?
Considerations When Using Hibernate
Summary
Chapter 8: Data Access in Spring with JPA2
Introducing JPA 2.1
Sample Data Model for Example Code
Configuring JPA’s EntityManagerFactory
Using JPA Annotations for ORM Mapping
Performing Database Operations with JPA
Using the Java Persistence Query Language to Query Data
Querying with Untyped Results
Querying for a Custom Result Type with a Constructor Expression
Inserting Data
Updating Data
Deleting data
Using a Native Query
Using a Simple Native Query
Native Querying with SQL ResultSet Mapping
Using the JPA 2 Criteria API for a Criteria Query
Introducing Spring Data JPA
Adding Spring Data JPA Library Dependencies
Using Spring Data JPA Repository Abstraction for Database Operations
Using JpaRepository
Spring Data JPA with Custom Queries
Keeping Track of Changes on the Entity Class
Keeping Entity Versions by Using Hibernate Envers
Adding Tables for Entity Versioning
Configuring EntityManagerFactory for Entity Versioning
Enabling Entity Versioning and History Retrieval
Testing Entity Versioning
Spring Boot JPA
Considerations When Using JPA
Summary
Chapter 9: Transaction Management
Exploring the Spring Transaction Abstraction Layer
Transaction Types
Implementations of the PlatformTransactionManager
Analyzing Transaction Properties
The TransactionDefinition Interface
The TransactionStatus Interface
Sample Data Model and Infrastructure for Example Code
Creating a Simple Spring JPA Project with Dependencies
Sample Data Model and Common Classes
Using AOP Configuration for Transaction Management
Using Programmatic Transactions
Considerations on Transaction Management
Global Transactions with Spring
Infrastructure for Implementing the JTA Sample
Implementing Global Transactions with JTA
Spring Boot JTA
Considerations on Using JTA Transaction Manager
Summary
Chapter 10: Validation with Type Conversion and Formatting
Dependencies
Spring Type Conversion System
Conversion from a String Using PropertyEditors
Introducing Spring Type Conversion
Implementing a Custom Converter
Configuring ConversionService
Converting Between Arbitrary Types
Field Formatting in Spring
Implementing a Custom Formatter
Configuring ConversionServiceFactoryBean
Validation in Spring
Using the Spring Validator Interface
Using JSR-349 Bean Validation
Defining Validation Constraints on Object Properties
Configuring Bean Validation Support in Spring
Creating a Custom Validator
Using AssertTrue for Custom Validation
Considerations for Custom Validation
Deciding Which Validation API to Use
Summary
Chapter 11: Task Scheduling
Dependencies for the Task Scheduling Samples
Task Scheduling in Spring
Introducing the Spring TaskScheduler Abstraction
Exploring a Sample Task
Using Annotations for Task Scheduling
Asynchronous Task Execution in Spring
Task Execution in Spring
Summary
Chapter 12: Using Spring Remoting
Using a Data Model for Samples
Adding Required Dependencies for the JPA Back End
Implementing and Configuring SingerService
Implementing SingerService
Configuring SingerService
Exposing the Service
Invoking the Service
Using JMS in Spring
Implementing a JMS Listener in Spring
Sending JMS Messages in Spring
Spring Boot Artemis Starter
Using RESTful-WS in Spring
Introducing RESTful Web Services
Adding Required Dependencies for Samples
Designing the Singer RESTful Web Service
Using Spring MVC to Expose RESTful Web Services
Configuring Castor XML
Implementing SingerController
Configuring a Spring Web Application
Using curl to Test RESTful-WS
Using RestTemplate to Access RESTful-WS
Securing RESTful-WS with Spring Security
RESTful-WS with Spring with Spring Boot
Using AMQP in Spring
Using AMQP with Spring Boot
Summary
Chapter 13: Spring Testing
Introducing Testing Categories
Using Spring Test Annotations
Implementing Logic Unit Tests
Adding Required Dependencies
Unit Testing Spring MVC Controllers
Testing the listData( ) Method
Testing the create( ) Method
Implementing an Integration Test
Adding Required Dependencies
Configuring the Profile for Service-Layer Testing
Java Configuration Version
Implementing the Infrastructure Classes
Implementing Custom TestExecutionListener
Implementing the Configuration Class
Unit Testing the Service Layer
Dropping DbUnit
Implementing a Front-End Unit Test
Introducing Selenium
Summary
Chapter 14: Scripting Support in Spring
Working with Scripting Support in Java
Introducing Groovy
Dynamic Typing
Simplified Syntax
Closure
Using Groovy with Spring
Developing the Singer Domain
Implementing the Rule Engine
Implementing the Rule Factory as a Spring Refreshable Bean
Testing the Age Category Rule
Inlining Dynamic Language Code
Summary
Chapter 15: Application Monitoring
JMX Support in Spring
Exporting a Spring Bean to JMX
Using Java VisualVM for JMX Monitoring
Monitoring Hibernate Statistics
JMX with Spring Boot
Summary
Chapter 16: Web Applications
Implementing the Service Layer for Samples
Using a Data Model for the Samples
Implementing the DAO Layer
Implementing the Service Layer
Configuring SingerService
Introducing MVC and Spring MVC
Introducing MVC
Introducing Spring MVC
Spring MVC WebApplicationContext Hierarchy
Spring MVC Request Life Cycle
Spring MVC Configuration
Creating the First View in Spring MVC
Configuring DispatcherServlet
Implementing SingerController
Implementing the Singer List View
Testing the Singer List View
Understanding the Spring MVC Project Structure
Enabling Internationalization (i18n)
Configuring i18n in the DispatcherServlet Configuration
Modifying the Singer List View for i18n Support
Using Theming and Templating
Theming Support
View Templating with Apache Tiles
Designing the Template Layout
Implementing Page Layout Components
Configuring Tiles in Spring MVC
Implementing the Views for Singer Information
Mapping URLs to the Views
Implementing the Show Singer View
Implementing the Edit Singer View
Implementing the Add Singer View
Enabling JSR-349 (Bean Validation)
Using jQuery and jQuery UI
Introducing jQuery and jQuery UI
Enabling jQuery and jQuery UI in a View
Rich-Text Editing with CKEditor
Using jqGrid for a Data Grid with Pagination
Enabling jqGrid in the Singer List View
Enabling Pagination on the Server Side
Handling File Upload
Configuring File Upload Support
Modifying Views for File Upload Support
Modifying Controllers for File Upload Support
Securing a Web Application with Spring Security
Configuring Spring Security
Adding Login Functions to the Application
Using Annotations to Secure Controller Methods
Creating Spring Web Applications with Spring Boot
Setting Up the DAO Layer
Setting Up the Service Layer
Setting Up the Web Layer
Setting Up Spring Security
Creating Thymeleaf Views
Using Thymeleaf Extensions
Using Webjars
Summary
Chapter 17: WebSocket
Introducing WebSocket
Using WebSocket with Spring
Using the WebSocket API
Using SockJS
Sending Messages with STOMP
Summary
Chapter 18: Spring Projects: Batch, Integration, XD, and More
Spring Batch
JSR-352
Spring Boot Batch
Spring Integration
Spring XD
Spring Framework’s Five Most Notable Features
The Functional Web Framework
Java 9 Interoperabiliy
JDK Modularity
Reactive Programming with Java 9 and Spring WebFlux
Spring Support for JUnit 5 Jupiter
Summary
Appendix A: Setting Up Your Development Environment
Introducing Project pro-spring-15
Understanding the Gradle Configuration
Building and Troubleshooting
Deploy on Apache Tomcat
People also search for Pro Spring 5: an in-depth guide to the Spring framework and its tools 5th:
spring 5 design patterns
spring 5 docs
e-5226 spring
e spring guide
e-5115 spring
Tags: Pro Spring, depth guide, Spring framework, Iuliana Cosmina, Rob Harrop, Chris Schaefer, Clarence Ho