Synopses & Reviews
You can choose several data access frameworks when building Java enterprise applications that work with relational databases. But what about big data? This hands-on introduction shows you how Spring Data makes it relatively easy to build applications across a wide range of new data access technologies such as NoSQL and Hadoop.
Through several sample projects, youll learn how Spring Data provides a consistent programming model that retains NoSQL-specific features and capabilities, and helps you develop Hadoop applications across a wide range of use-cases such as data analysis, event stream processing, and workflow. Youll also discover the features Spring Data adds to Springs existing JPA and JDBC support for writing RDBMS-based data access layers.
- Learn about Springs template helper classes to simplify the use ofdatabase-specific functionality
- Explore Spring Datas repository abstraction and advanced query functionality
- Use Spring Data with Redis (key/value store), HBase(column-family), MongoDB (document database), and Neo4j (graph database)
- Discover the GemFire distributed data grid solution
- Export Spring Data JPA-managed entities to the Web as RESTful web services
- Simplify the development of HBase applications, using a lightweight object-mapping framework
- Build example big-data pipelines with Spring Batch and Spring Integration
As a developer of Java enterprise applications, you can choose among several data access frameworks when working with relational databases. But what do you turn to when working with newer technologies such as NoSQL databases and Hadoop? This book shows you how Springs data access framework can help you connect to either non-relational or relational databases, or a combination of the two.
Youll learn how Spring Datas familiar and consistent programming model greatly reduces the learning curve for creating applications with newer data access technologies. And youll discover how to use Spring Datas improved JPA and JDBC support to increase your productivity when writing RDBMS-based data access layers.
Relational database technologies continue to be predominant in the enterprise, but theyre no longer considered a "one size fits all" solution. This book shows you how to increase your options.
About the Author
Dr. Mark Pollack has worked on Big Data solutions in High Energy Physics at Brookhaven National Laboratory and then moved to the financial services industry as a technical lead or architect for front office trading systems.Always interested in best practices and improving the software development process, Mark has been a core Spring (Java) developer since 2003 and founded its Microsoft counterpart, Spring.NET, in 2004.Mark now leads the Spring Data project that aims to simplify application development with new data technologies around Big Data and NoSQL databases.
Oliver Gierke is engineer at SpringSource, a division of VMware, project lead of the Spring Data JPA, MongoDB and core module. He has been into developing enterprise applications and open source projects for over 6 years now. His working focus is centered around software architecture, Spring and persistence technologies. He is regularly speaking at German and international conferences as well as author of technology articles.
Thomas Risberg is currently a member of the Spring Data team focusing on the MongoDB and JDBC Extensions projects. He is also a committer on the Spring Framework project, primarily contributing to enhancements of the JDBC framework portion.
Thomas works on the VMware's Cloud Foundry team developing integration for the various frameworks and languages supported by the Cloud Foundry project.
Thomas is co-author of “Professional Java Development with the Spring Framework” together with Rod Johnson, Juergen Hoeller, Alef Arendsen, and Colin Sampaleanu, published by Wiley in 2005.
Jon Brisbin is a member of the SpringSource Spring Data team and focuses on providing developers useful libraries to facilitate next-generation data manipulation. He's helped bring elements of the Grails GORM object mapper to Java-based MongoDB applications, he's provided key integration components between the Riak datastore and the RabbitMQ message broker, he blogs and speaks on evented application models, and is working diligently to bridge the gap between the bleeding-edge non-blocking and traditional JVM-based applications.
Michael Hunger has been passionate about software development for a long time. He is particularly interested in the people who develop software, software craftsmanship, programming languages, and improving code.
For the last two years he has been working with Neo Technology on the Neo4j graph database. As the project lead of Spring Data Neo4j he helped developing the idea to become a convenient and complete solution for object graph mapping. He is also taking care of Neo4j cloud hosting efforts.
As a developer he loves to work with many aspects of programming languages, learning new things every day, participating in exciting and ambitious open source projects and contributing to different programming related books. Michael is also an active editor and interviewer at InfoQ.
Table of Contents
Foreword; Preface; Overview of the New Data Access Landscape; How to Read This Book; Conventions Used in This Book; Using Code Examples; Safari® Books Online; How to Contact Us; Acknowledgments; Background; Chapter 1: The Spring Data Project; 1.1 NoSQL Data Access for Spring Developers; 1.2 General Themes; 1.3 The Domain; 1.4 The Sample Code; Chapter 2: Repositories: Convenient Data Access Layers; 2.1 Quick Start; 2.2 Defining Query Methods; 2.3 Defining Repositories; 2.4 IDE Integration; Chapter 3: Type-Safe Querying Using Querydsl; 3.1 Introduction to Querydsl; 3.2 Generating the Query Metamodel; 3.3 Integration with Spring Data Repositories; Relational Databases; Chapter 4: JPA Repositories; 4.1 The Sample Project; 4.2 The Traditional Approach; 4.3 Bootstrapping the Sample Code; 4.4 Using Spring Data Repositories; Chapter 5: Type-Safe JDBC Programming with Querydsl SQL; 5.1 The Sample Project and Setup; 5.2 The QueryDslJdbcTemplate; 5.3 Executing Queries; 5.4 Insert, Update, and Delete Operations; NoSQL; Chapter 6: MongoDB: A Document Store; 6.1 MongoDB in a Nutshell; 6.2 Setting Up the Infrastructure Using the Spring Namespace; 6.3 The Mapping Subsystem; 6.4 MongoTemplate; 6.5 Mongo Repositories; Chapter 7: Neo4j: A Graph Database; 7.1 Graph Databases; 7.2 Neo4j; 7.3 Spring Data Neo4j Overview; 7.4 Modeling the Domain as a Graph; 7.5 Persisting Domain Objects with Spring Data Neo4j; 7.6 Combining Graph and Repository Power; 7.7 Advanced Graph Use Cases in the Example Domain; 7.8 Transactions, Entity Life Cycle, and Fetch Strategies; 7.9 Advanced Mapping Mode; 7.10 Working with Neo4j Server; 7.11 Continuing From Here; Chapter 8: Redis: A Key/Value Store; 8.1 Redis in a Nutshell; 8.2 Connecting to Redis; 8.3 Object Conversion; 8.4 Object Mapping; 8.5 Atomic Counters; 8.6 Pub/Sub Functionality; 8.7 Using Spring's Cache Abstraction with Redis; Rapid Application Development; Chapter 9: Persistence Layers with Spring Roo; 9.1 A Brief Introduction to Roo; 9.2 Roo's Persistence Layers; 9.3 Quick Start; 9.4 A Spring Roo JPA Repository Example; 9.5 A Spring Roo MongoDB Repository Example; Chapter 10: REST Repository Exporter; 10.1 The Sample Project; Big Data; Chapter 11: Spring for Apache Hadoop; 11.1 Challenges Developing with Hadoop; 11.2 Hello World; 11.3 Hello World Revealed; 11.4 Hello World Using Spring for Apache Hadoop; 11.5 Scripting HDFS on the JVM; 11.6 Combining HDFS Scripting and Job Submission; 11.7 Job Scheduling; Chapter 12: Analyzing Data with Hadoop; 12.1 Using Hive; 12.2 Using Pig; 12.3 Using HBase; Chapter 13: Creating Big Data Pipelines with Spring Batch and Spring Integration; 13.1 Collecting and Loading Data into HDFS; 13.2 Hadoop Workflows; 13.3 Exporting Data from HDFS; 13.4 Collecting and Loading Data into Splunk; Data Grids; Chapter 14: GemFire: A Distributed Data Grid; 14.1 GemFire in a Nutshell; 14.2 Caches and Regions; 14.3 How to Get GemFire; 14.4 Configuring GemFire with the Spring XML Namespace; 14.5 Data Access with GemfireTemplate; 14.6 Repository Usage; 14.7 Continuous Query Support; Bibliography; Colophon;