Beginning Spring - Mert Caliskan - Libros - John Wiley & Sons Inc - 9781118892923 - 17 de febrero de 2015
En caso de que portada y título no coincidan, el título será el correcto

Beginning Spring


Recibe un correo electrónico cuando el artículo esté disponible
¿Tienes un perfil? Iniciar sesión
Añadir a tu lista de deseos de iMusic

Get up to speed quickly with this comprehensive guide to Spring Beginning Spring is the complete beginner's guide to Java's most popular framework. Written with an eye toward real-world enterprises, the book covers all aspects of application development within the Spring Framework.


Marc Notes: Get up to speed quickly with this comprehensive guide to Spring. 'Beginning Spring' is the complete beginner's guide to Java's most popular framework. Written with an eye toward real-world enterprises, the book covers all aspects of application development within the Spring Framework. Table of Contents: FOREWORDS xxviiINTRODUCTION xxxiCHAPTER 1: POJO PROGRAMMING MODEL, LIGHTWEIGHT CONTAINERS, AND INVERSION OF CONTROL 1POJO Programming Model 2Problems of the Old EJB Programming Model 2Benefits of the POJO Programming Model 7Lightweight Containers and Inversion of Control (IoC) 8Lightweight Containers 8Inversion of Control (IoC) 9Dependency Injection 10Setter Injection 11Constructor Injection 11Setter or Constructor Injection 12Summary 12CHAPTER 2: DEPENDENCY INJECTION WITH SPRING 17Spring IoC Container 18Configuration Metadata 18Configuring and Using the Container 21Dependency Injection 29Setter Injection 30Constructor Injection 31Circular Dependencies 34Dependency Resolution Process 35Overriding Bean Definitions 36Using the depends?]on Attribute 38Autowiring 39Bean Lookups 43Spring?]Managed Beans 44Naming Beans 44Bean Instantiation Methods 45Bean Scopes 48Lazy Initialization 51Life-Cycle Callbacks 52Bean Definition Profiles 54Environment 56Summary 59CHAPTER 3: BUILDING WEB APPLICATIONS USING SPRING MVC 63Learning the Features and Benefits of Spring MVC 64Using the Dispatcher Servlet Mechanism 65Defining the Servlet 66Accessing Servlet Context 67Creating Your First Spring MVC Application 68Configuring Spring MVC with Annotations 71Handling Forms with JSP 73Configuring the Form Tag Library 73Understanding the Power of Binding 74Working with Forms 74Using Input Elements 75Entering Dates 76Selecting from a Drop?]Down 77Selecting with Radio Buttons 78Selecting with Checkboxes 78Adding Labels 78Placing Buttons 79Styling 79Exploiting the Power of Annotations 84@Controller 84@RequestMapping 84@ModelAttribute 84@PathVariable 85@ControllerAdvice 85@InitBinder 85@ExceptionHandler 85Validating User Input 86Uploading Files 90Handling Exceptions 93Implementing Internationalization (i18n) 95Using Themes 97Summary 100CHAPTER 4: JDBC DATA ACCESS WITH SPRING 103Problems with Using Vanilla JDBC 104Introducing Spring's JDBC Support 105Managing JDBC Connections 105Embedded DB Support 108Using a Connection?]Pooled DataSource 110Initializing DB 111Configuring and Using Spring's JDBC Support 112Performing Data Access Operations with Spring 114Running Queries 114Queries with Named Parameters 117Writing Queries Using the IN Clause 118Using PreparedStatements within JdbcTemplate 119Inserting, Updating, and Deleting Records 121Calling Stored Procedures and Stored Functions 124Performing Batch Operations 126Handling BLOB and CLOB Objects 126Accessing Vendor?]Specific JDBC Methods 127Executing DDL Operations 127Modeling JDBC Operations as Java Objects 128Encapsulating SQL Query Executions 128Encapsulating SQL DML Operations 130Encapsulating Stored Procedure Executions 131Exception Handling and Error Code Translation 132Common Data Access Exception Hierarchy 132Automatic Handling and Translation of SQLException 132Summary 133CHAPTER 5: DATA ACCESS WITH JPA USING SPRING 137Brief Introduction to ORM and JPA 138Paradigm Mismatch 138Building Blocks of an ORM Framework 139What JPA Offers 139Mapping the Object Model to the Relational Model 140Defining Entities 140Mapping Attributes to Columns 141Creating Associations between Objects 142Mapping Java Types to SQL Types 145Configuring and Using JPA 147Performing CRUD Operations on Objects 150Querying with Object Query Language 155Spring's JPA Support 156Setting Up JPA in Spring Container 156Implementing DAOs Based on Plain JPA 161Handling and Translating Exceptions 166Further JPA Configuration in Spring Environment 167JpaDialect 168JpaVendorAdapter 168JPA and Load Time Weaving 169Dealing with Multiple Persistence Units 170Summary 171CHAPTER 6: MANAGING TRANSACTIONS WITH SPRING 175Understanding Transaction Management 176Spring's Transaction Abstraction Model 180Local versus Global Transactions 182PlatformTransactionManager Implementations 182Advantages of Spring's Abstract Transaction Model 183Declarative Transaction Management with Spring 183Isolating the Service Layer from Data Access Technology Details 186Customizing Default Transactional Behavior 189Using @Transactional on the Class Level 190Understanding Transaction Propagation Rules 191Propagation REQUIRED 191Propagation REQUIRES_NEW 192Propagation NESTED 192Propagation SUPPORTS 192Propagation NOT_SUPPORTED 192Propagation NEVER 193Propagation MANDATORY 193Using for Declarative Transaction Management 195Programmatic Transaction Management with Spring 197Using the PlatformTransactionManager Approach 201Executing Custom Logic Before or After Transactions 203Advising Transactional Operations 203Executing Logic after Transactions Using TransactionSynchronization 204Summary 205CHAPTER 7: TEST?]DRIVEN DEVELOPMENT WITH SPRING 209Configuring and Caching ApplicationContext 210Using XML?] and Java?]Based Context Configuration in Tests 210Confi guring Context with ApplicationContextInitializer 214Inheriting Context Configuration 214ApplicationContext Caching 216Injecting Dependencies of Test Fixtures 217Using Transaction Management in Tests 219Testing Web Applications 222Context Hierarchies in Tests 225Testing Request?] and Session?]Scoped Beans 225Testing Spring MVC Projects 227Testing Controllers 227Testing Form Submit 228Testing Exception Handlers 230Printing Mock Request and Response 231Using Mock Objects and Other Utilities for Testing 231Spring Provided Mock Objects for Testing 231Other Utilities and Test Annotations 232Summary 233CHAPTER 8: ASPECT?]ORIENTED PROGRAMMING WITH SPRING 237Getting Started with AOP with Spring 239Becoming Familiar with Types of Advices 243Before 245After Returning 245After Throwing 245After (Finally) 246Around 247Defining Point?]Cut Designators 248The Type Signature Expressions 248The Method Signature Expressions 249Other Alternative Point?]Cut Designators 249Wildcards 250Capitalizing on the Power of Annotations 250@Before 250@Pointcut 251@After 252@AfterReturning 252@AfterThrowing 252@Aspect 253@Around 253@DeclareParents 254Blending AspectJ with Spring 255Configuring Spring AOP with Annotations 259Summary 259CHAPTER 9: SPRING EXPRESSION LANGUAGE 263Configuring Applications with SpEL 264Creating a Parser 267Invoking Methods 270Calling Constructors 272Calling Static Methods 272Working with Variables and Functions 273#root 273#this 274Accessing System Properties and Environment 274Inline Lists 274Registering Functions 274Understanding SpEL Operators 275Relational Operators 276Arithmetic Operators 276Logical Operators 276Conditional Operators 277Regular Expression Operator 278Safe Navigation Operator 278Collection Selection and Projection 279Selecting the First and Last Element of a Collection 280Using Utilities in SpEL 280Accessing Spring Beans 280281Expressions in Caching 281Summary 281CHAPTER 10: CACHING 285Building Your First Caching Application 286Configuring the Cache Manager with a Different Name 289Configuring the Caching Abstraction with Annotations 289Working with Cache Annotations 290@Cacheable 290Key Generator 291Conditional Caching 291@CacheEvict 292@CachePut 292@Caching 293Implementing Cache Managers 293SimpleCacheManager 293NoOpCacheManager 294ConcurrentMapCacheManager 294CompositeCacheManager 294Casting Your SpEL on Caches 295Initializing Your Caches Programmatically 296Finding Alternative Cache Providers 298Ehcache 299Guava 302Hazelcast 302Summary 303CHAPTER 11: RESTFUL WEB SERVICES WITH SPRING 305Creating Your First REST Web Service 306Returning Different HTTP Status Codes from REST Web Service 318Learning an Annotation?]Based Configuration Alternative 318Using REST Web Services with XML 320Using the Exception Handling Mechanism 322Unit Testing RESTful Services 326Summary 328CHAPTER 12: SECURING WEB APPLICATIONS WITH SPRING SECURITY 331Why Spring Security? 332Features of Spring Security 333Configuring and Using Spring Security 334Understanding the Fundamental Building Blocks of Spring Security 340Authenticating Users 341Unsuccessful Login Flow 342Successful Login Flow 342Anonymous Authentication 344Customizing the Login Page 344Logout Process 346Accessing UserDetails Using JDBC 346Encrypting Passwords 349Remember?]Me Support 350User Session Management 351Basic Authentication 352Authorizing Web Requests and Service Method Calls 353Authorizing Web Requests 353How Does Authorization Work? 355Expression?]Based Authorization 357Using JSP Security Tags 358Authorize Tag 359Authenticate Tag 359Authorizing Service Methods 359Summary 364CHAPTER 13: NEXT STOP: SPRING 4.0 369Keeping Up with the Latest: Java 8 and Java EE7 Support 370Lambda Expressions 370Method References 373Bean Validation Integration 374JSR 310: Date Time Value Type Support 374Configuring Injection with Conditional Dependency 374Ordering the Elements of Autowired Collections 377Repeating Annotations 379Introducing New Annotations 381Documenting with @Description 381Using the @RestController Annotation 382Summary 382APPENDIX: SOLUTIONS TO EXERCISES 385INDEX 425Jacket Description/Back: Real-world Spring for savvy enterprise application developmentThis is your thorough introduction to the Spring Framework, the most popular framework among Java developers and the de facto standard for enterprise application development. Specifically focused on real-world enterprise solutions, "Beginning Spring" provides comprehensive examples and hands-on learning in each chapter to help you quickly build a skillset that exploits the full capabilities of Java and to drive successful application development. Coverage includes the foundations of the POJO model, ORM support, Spring MVC, REST services, Spring Security, and much more to provide a comprehensive guide to the real-world functionality of this complete enterprise application toolset."Beginning Spring: "Covers all aspects of application development using Spring Framework 4.0, which supports Java(R) 8.0 and Java(R) EE 7Emphasizes practicality by addressing real-world needs and providing actionable insight with hands-on practiceIncludes extensive examples for concrete experimentation reference and thorough exploitation of Java's full capabilitiesBuilds skill upon skill to help developers master the most commonly used tools and fundamental concepts in any Spring projectFeatures detailed discussion on the cross-cutting concerns every enterprise application needs, such as transaction management and securityWrox Beginning guides are crafted to make learning programming languages and technologies easier than you think, providing a structured, tutorial format that will guide you through all the techniques involved. Visit us at wrox.com where you have access to free code samples, Programmer to Programmer forums, and discussions on the latest industry happenings from around the world. Biographical Note: Mert Çal??kan is an Oracle Java Champion and has been working as Principal Architect in Turkey. He has more than 10 years? experience in software development, where he has focused on architectural design of enterprise web applications. Kenan Sevindik is a Sun certified Java J2EE Business and Web Component developer, with more than 15 years of Java development experience. He has extensive experience with the major enterprise Java frameworks and gives seminars on a variety of Java concepts. Publisher Marketing: Get up to speed quickly with this comprehensive guide toSpring "Beginning Spring" is the complete beginner's guide toJava's most popular framework. Written with an eye towardreal-world enterprises, the book covers all aspects of applicationdevelopment within the Spring Framework. Extensive samples withineach chapter allow developers to get up to speed quickly byproviding concrete references for experimentation, building askillset that drives successful application development byexploiting the full capabilities of Java's latest advances. Spring provides the exact toolset required to build anenterprise application, and has become the standard within thefield. This book covers Spring 4.0, which contains support for Java8 and Java EE 7. Readers begin with the basics of the framework, then go on to master the most commonly used tools and fundamentalconcepts inherent in any Spring project. The book emphasizespracticality and real-world application by addressing needs such asmeeting customer demand and boosting productivity, and by providingactionable information that helps developers get the most out ofthe framework. Topics include: Dependency Injection and Inversion of ControlUnit testing Spring enabled Web Applications Data Access using Spring JDBC and ORM support along withTransaction ManagementBuilding Web Applications and RESTful Web Services with SpringMVCSecuring Web Applications using Spring SecuritySpring Expression Language with its Extensive FeaturesAspect Oriented Programming Facilities Provided by SpringAOPCaching with 3rd Party Cache Providers' SupportThe Best of the Breed: Spring 4.0The information is organized and structured an ideal way forstudents and corporate training programs, and explanations aboutinner workings of the framework make it a handy desk reference evenfor experienced developers. For novices, "Beginning Spring" isinvaluable as a comprehensive guide to the real-world functionalityof Spring.

Medios de comunicación Libros     Paperback Book   (Libro con tapa blanda y lomo encolado)
Publicado 17 de febrero de 2015
ISBN13 9781118892923
Editores John Wiley & Sons Inc
Páginas 480
Dimensiones 236 × 189 × 29 mm   ·   771 g
Lengua Inglés  

Mas por Mert Caliskan

Mostrar todo