Feeds

The state of POJO play

'Plain Old Java' back in fashion

High performance access to file storage

Book review Few could deny that one of the biggest drivers of change in the Java world recently has been the complexity of "enterprise Java".

The complexities of EJB 2.x, with forests of XML configuration files, boiler plate script, the slow edit-compile-debug cycle forced by having to deploy to a server, the reliance on procedural code...

The list of problems is well known, and has been chronicled frequently and vociferously by any number of well-known Java developers.

However, a positive spin-off has been an explosion of interest and activity in what have been termed "rebel J2EE" frameworks. Spring, Hibernate, JDO and countless other frameworks have been developed to tackle some of the deficiencies in the Java enterprise arena. And, just as significantly there's also been a resurgence of interest in what are (very) loosely known as scripting languages, particularly Ruby. Similarly, interest in Ajax is extremely high in the Java community for some of the same reasons.

In POJOs in Action, Chris Richardson reprises all of these developments and shows how these new frameworks solve particular problems. POJOs (Plain Old Java Objects) is a term that was popularised by Martin Fowler (he of Refactoring fame), Rebbecca Parsons and Josh MacKenzie as a way of putting a fancy name on the practice of using regular Java objects rather than encapsulating business logic in Enterprise JavaBeans.

Part one of the book starts with a quick history lesson, outlines the major problems that enterprise applications have to solve (object relational mapping, data access, transactions, concurrency etc), and then looks at how these have been addressed using EJB 2.x. The POJO based alternatives are briefly outlined, along with a preview of EJB 3.0, which is considered to be a step in the right direction in that it is much more POJO-centric than its predecessor.

Part two goes into much more detail, and presents a series of design patterns for tackling things like object relational mapping, the encapsulation of business logic, and so on. Hibernate and JDO are used extensively, and a number of complex and realistic examples are developed to illustrate how to use them effectively.

While the book is heavy with source code, the writing goes into detail of the design process so that it's clear what the solutions are trying to do and why. Discussion of the pros and cons of Hibernate vs JDO vs EJB 3.0 is not neglected.

On the database transaction side of things there's discussion of JDBC and how iBatis and Spring can be used to implement the transaction script pattern in part three of the book. This section also looks in more detail at EJB 3.0 and shows how POJOs can be used with this to win back some of the benefits of "regular" Java development.

On the whole, the book is well written and provides solid technical advice. Richardson is a confident author, and he's well known within the Java enterprise community. No book on enterprise Java is easy reading, but for anyone seriously wanting to catch up with the current state of play this provides both an excellent over-view and some detailed hands-on examples.

POJOs In Action

Verdict: Excellent overview of enterprise Java

Author: Chris Richardson

Publisher: Manning Publications

ISBN: 1932394583

Media: Book

List Price: £31.99

Reg price: £25.59 (saving 20 per cent)

Buy this book at Cash 'n' Carrion.

High performance access to file storage

More from The Register

next story
Android engineer: We DIDN'T copy Apple OR follow Samsung's orders
Veep testifies for Samsung during Apple patent trial
This time it's 'Personal': new Office 365 sub covers just two devices
Redmond also brings Office into Google's back yard
Batten down the hatches, Ubuntu 14.04 LTS due in TWO DAYS
Admins dab straining server brows in advance of Trusty Tahr's long-term support landing
Microsoft lobs pre-release Windows Phone 8.1 at devs who dare
App makers can load it before anyone else, but if they do they're stuck with it
Half of Twitter's 'active users' are SILENT STALKERS
Nearly 50% have NEVER tweeted a word
Windows XP still has 27 per cent market share on its deathbed
Windows 7 making some gains on XP Death Day
Internet-of-stuff startup dumps NoSQL for ... SQL?
NoSQL taste great at first but lacks proper nutrients, says startup cloud whiz
Windows 8.1, which you probably haven't upgraded to yet, ALREADY OBSOLETE
Pre-Update versions of new Windows version will no longer support patches
Microsoft TIER SMEAR changes app prices whether devs ask or not
Some go up, some go down, Redmond goes silent
Red Hat to ship RHEL 7 release candidate with a taste of container tech
Grab 'near-final' version of next Enterprise Linux next week
prev story

Whitepapers

Securing web applications made simple and scalable
In this whitepaper learn how automated security testing can provide a simple and scalable way to protect your web applications.
Five 3D headsets to be won!
We were so impressed by the Durovis Dive headset we’ve asked the company to give some away to Reg readers.
HP ArcSight ESM solution helps Finansbank
Based on their experience using HP ArcSight Enterprise Security Manager for IT security operations, Finansbank moved to HP ArcSight ESM for fraud management.
The benefits of software based PBX
Why you should break free from your proprietary PBX and how to leverage your existing server hardware.
Mobile application security study
Download this report to see the alarming realities regarding the sheer number of applications vulnerable to attack, as well as the most common and easily addressable vulnerability errors.