Spring in Action - Craig Walls

Spring in Action

Covers Spring 4

(Autor)

Buch | Softcover
624 Seiten
2014 | 4. Auflage
Manning Publications (Verlag)
978-1-61729-120-3 (ISBN)
47,95 inkl. MwSt
Spring in Action, Fourth Edition is a hands-on guide to the Spring Framework, updated for version 4. It covers the latest features, tools, and practices including Spring MVC, REST, Security, Web Flow, and more. You'll move between short snippets and an ongoing example as you learn to build simple and efficient J2EE applications. Author Craig Walls has a special knack for crisp and entertaining examples that zoom in on the features and techniques you really need.
Designed in 2003 as a lighter approach to J2EE development, Spring Framework has since become a standard choice for building enterprise applications and required knowledge for Java developers.
Spring 4, the latest major version, provides full Java 8 integration along with key upgrades like new annotations for the IoC container, improvements to Spring Expression Language, and much-needed support for REST. Whether you're just discovering Spring or you want to absorb the new features, there's no better way to master Spring than with this book.

Spring in Action, Fourth Edition continues the practical, hands-on style of the previous bestselling editions. Author Craig Walls has a special knack for crisp and entertaining examples that zoom in on the features and techniques really needed. The Spring framework is required knowledge for Java developers, and this edition brings readers up to speed with Spring 3.1 and then highlights some of the new Spring 3.2 features such as asynchronous Spring MVC Controllers.

It also covers testing support for Spring MVC controllers and RestTemplate-based clients which enables a richer form of testing for controllers and clients without having to fire up a server or hitting an actual REST API-in other words no-network involved.
  • Written by esteemed Spring expert
  • Offers practical solutions to real-world problems
  • Contains concise, easy to follow examples

Written for Java developers and software architects.

Craig Walls is a software developer at SpringSource. He's a popular author and a frequent speaker at user groups and conferences. Craig lives in Plano, Texas.

preface
acknowledgments
about this book
Part 1 Core Spring

Chapter 1 Springing into action
Simplifying Java development
Containing your beans
Surveying the Spring landscape
What’s new in Spring
Summary
Chapter 2 Wiring beans
Exploring Spring’s configuration options
Automatically wiring beans
Wiring beans with Java
Wiring beans with XML
Importing and mixing configurations
Summary
Chapter 3 Advanced wiring
Environments and profiles
Conditional beans
Addressing ambiguity in autowiring
Scoping beans
Runtime value injection
Summary
Chapter 4 Aspect-oriented Spring
What is aspect-oriented programming?
Selecting join points with pointcuts
Creating annotated aspects
Declaring aspects in XML
Injecting AspectJ aspects
Summary

Part 2 Spring on the Web

Chapter 5 Building Spring web applications
Getting started with Spring MVC
Writing a simple controller
Accepting request input
Processing forms
Summary
Chapter 6 Rendering web views
Understanding view resolution
Creating JSP views
Defining a layout with Apache Tiles views
Working with Thymeleaf
Summary
Chapter 7 Advanced Spring MVC
Alternate Spring MVC configuration
Processing multipart form data
Handling exceptions
Advising controllers
Carrying data across redirect requests
Summary
Chapter 8 Working with Spring Web Flow
Configuring Web Flow in Spring
The components of a flow
Putting it all together: the pizza flow
Securing web flows
Summary
Chapter 9 Securing web applications
Getting started with Spring Security
Selecting user details services
Intercepting requests
Authenticating users
Securing the view
Summary

Part 3 Spring in the back end

Chapter 10 Hitting the database with Spring and JDBC
Learning Spring’s data-access philosophy
Configuring a data source
Using JDBC with Spring
Summary
Chapter 11 Persisting data with object-relational mapping
Integrating Hibernate with Spring
Spring and the Java Persistence API
Automatic JPA repositories with Spring Data
Summary
Chapter 12 Working with NoSQL databases
Persisting documents with MongoDB
Working with graph data in Neo4j
Working with key-value data in Redis
Summary
Chapter 13 Caching data
Enabling cache support
Annotating methods for caching
Declaring caching in XML
Summary
Chapter 14 Securing methods
Securing methods with annotations
Using expressions for method-level security
Summary

Part 4 Integrating Spring

Chapter 15 Working with remote services
An overview of Spring remoting
Working with RMI
Exposing remote services with Hessian and Burlap
Using Spring’s HttpInvoker
Publishing and consuming web services
Summary
Chapter 16 Creating REST APIs with Spring MVC
Getting REST
Creating your first REST endpoint
Serving more than resources
Consuming REST resources
Summary
Chapter 17 Messaging in Spring
A brief introduction to asynchronous messaging
Sending messages with JMS
Messaging with AMQP
Summary
Chapter 18 Messaging with WebSocket and STOMP
Working with Spring’s low-level WebSocket API
Coping with a lack of WebSocket support
Working with STOMP messaging
Working with user-targeted messages
Handling message exceptions
Summary
Chapter 19 Sending email with Spring
Configuring Spring to send email
Constructing rich email messages
Generating email with templates
Summary
Chapter 20 Managing Spring beans with JMX
Exporting Spring beans as MBeans
Remoting MBeans
Handling notifications
Summary
Chapter 21 Simplifying Spring development with Spring Boot
Introducing Spring Boot
Building an application with Spring Boot
Going Groovy with the Spring Boot CLI
Gaining application insight with the Actuator
Summary
index

The best keeps getting better. More than a dozen years ago, Spring entered the Java development scene with the ambitious goal of simplifying enterprise Java development. It challenged the heavyweight programming models of the time with a simpler and lighter programming model based on plain old Java objects. Now, several years and many releases later, we see that Spring has had a tremendous impact on enterprise application development. It has become a de facto standard framework for countless Java projects and has had an impact on the evolution of some of the specifications and frameworks that it originally set out to replace. It’d be hard to deny that the current Enterprise JavaBeans (EJB) specification may have turned out very differently had Spring not challenged earlier versions of the EJB spec. But Spring itself continues to evolve and improve upon itself, always seeking to make the difficult development tasks simpler and empower Java developers with innovative features. Where Spring had first set out to challenge the status quo, Spring now has leapt ahead and is paving trails in Java application development. Therefore, it’s time for an updated edition of this book to expose the current state of Spring. There’s so much that has happened in the past few years since the previous edition of this book; it’d be impossible to cover everything in a single edition. Nevertheless, I still tried to pack this fourth edition of Spring in Action with as much as I could. Here are just a few of the exciting new things that have been added in this edition: An emphasis on Java-based Spring configuration with Java configuration options available for almost every area of Spring development Conditional configuration and profiles that make runtime decisions regarding what Spring configuration should be used or ignored Several enhancements and improvements to Spring MVC, especially with regard to creating REST services Using Thymeleaf with Spring web applications as an alternative to JSP Enabling Spring Security with Java-based configuration Using Spring Data to automatically generate repository implementations at runtime for JPA, MongoDB, and Neo4j Spring’s new declarative caching support Asynchronous web messaging with WebSocket and STOMP Spring Boot, a game-changing new approach to working with Spring If you’re a seasoned Spring veteran, you’ll find that these new elements will become valuable additions to your Spring toolkit. On the other hand, if you’re new to Spring, you’ve picked a good time to learn Spring, and this book will help you get started. This is, indeed, an exciting time to be working with Spring. It’s been a blast to develop with Spring and write about it during the past 12 years. I can’t wait to see what Spring does next!

Verlagsort New York
Sprache englisch
Gewicht 1050 g
Einbandart kartoniert
Themenwelt Informatik Programmiersprachen / -werkzeuge Java
Mathematik / Informatik Informatik Software Entwicklung
Mathematik / Informatik Informatik Web / Internet
Schlagworte Java 8 (Programmiersprache) • JAVA (Programmiersprache) • Softwareentwicklung • Spring (Framework)
ISBN-10 1-61729-120-X / 161729120X
ISBN-13 978-1-61729-120-3 / 9781617291203
Zustand Neuware
Haben Sie eine Frage zum Produkt?
Wie bewerten Sie den Artikel?
Bitte geben Sie Ihre Bewertung ein:
Bitte geben Sie Daten ein:
Mehr entdecken
aus dem Bereich