Sunday, December 16, 2012

Book Review : Oracle ADF Real World Developer's Guide

In October 2012 yet another ADF Book was published. This book "Oracle ADF Real World Developer's Guide" is authored by Jobinesh Purushothaman. Jobinsh works with Oracle as a Principal Solutions Architect for the Oracle Application Development Framework. The book is full of essential tips and tricks for building ADF applications. In this post I will share my book review with you and I give you the chance to win a free copy.



This book is suitable for ADF developers who are looking forward to build healthy and better performing applications using Oracle ADF. A book filled with step-by-step instructions and real-time examples with illustrations, diagrams, and tips that help developers learn the visual and declarative programming model offered by ADF. Using this book, readers will learn to get started with building business services using ADF business components, validate business data in different layers of an application and understand the use of EJB and web services in an ADF application.

The book contains 12 Chapters containing anything from getting started to Advcance topics.

Before I go into each chapter, I must say that this book has a couple of outstanding ways of explaining the ADF Framework. First of all there are many simple diagrams (and images) explaining the framework and parts of the framework. These diagrams are easy to understand, because thay only contain relevant information. You are not being distracted by colors or misleading images. It is just simple images, but very clear.

Next there are the sequence diagrams. These diagrams explain what exactly happens (at class level) when for instance you issue execute query from an ADF Application. As far as I know this is the first book that uses these sequence diagrams to explain ADF in a very clear way.

Finally I need to point out the valuable code samples that are in the book. Get yourself a digital copy so you can easy copy and past these code snippets into your ADF application.

Now lets take a look at the chapters.

Part I : getting started

1 : Getting Started with Oracle ADF
The most interesting part for me is the section on "Comparing the Fusion web application technology stack to the Java EE web application". This is explaining ADF in the context of a Java EE application. Currently I am involved in a project where we need to "rebuild" a Java EE application in ADF. There is a lot of discussion in this project about responsiblity of eaach layer. This chapter can help Java EE developers understand the ADF framework. The image on page 13 of the book ADF and Java EE by putting both in one diagram next to eachother.

Also the part about the generated Metadata files is valuable. Ussualy these files (like adf-settings, weblogic-application) are taken for granted, but Jobinesh explains what all the metadata files are about.

Part II : ADF Business Components

2 : Introduction to ADF Business Components
3 : Introducing Entity Object
4 : Introducing View Object
5 : Advanced Concepts on Entity Objects and View Objects
6 : Introducing the Application Module
This part provides a detailed look at how entities, view objects and application modules are defined and how they work at runtime. I was impressed by the level of detail in chapter 2. It is great that I have a couple of more chapters that go even into more detail.  This chapter really made me wanna continue reading. Chapters 3 and 4 are introducing the basic concepts of View Objects and Entity Objects. Both chapters contain very helpful sequence diagrams explaining what happens internally within entity objects and view objects.

At the start of chapter 5 Jobinesh tells the reader to "Take a deep breath and prepare yourself".  The part that follows takes a deep dive into entity objects. This chapter is full of in depth Entity Object knowledge. Allthough I have been working with ADF for many many years there were some interesting featured in this chapter that I did not know about. (mainly because I never had to use these). For instance, did you know that you can call getAttribute(attrIndex,EntityImpl.ORIGINAL_VERSION) on an entity object to read the originally retrieved value for an attribute ? I allways use(d) getPostedAttribute(int attribIndex).

At the end of the Entity Object section there is an interesting part on "Building programmatically managed entity objects" including code samples.

The most interesting part of the View Object section is about working with ViewCriteria Programmatically. Also the section about working with XML data is a noce one. I never got to use this functionallity in real life. Jobinesh explains very well how to do this, and I hope to get a use case soon. The chapter ends with a section about "Building business components dynamically".

After reading chapter 5 I can only say one thing: "I am impressed !".

Chapter 6 covers important topics like properties, passivation, activation, application module pooling.

7 : Binding Business Services with the User Interface
Chapter 7 really contained nothing new to me. However, if you are new to ADF, this chapter contains very good explanation of the binding layer. There is an interesting part about "Invoking an application module from a Java servlet". I did use this approach in several occassions. It is good to have a section on this in the book. Again in this chapter there are several simple diagrams that help you understand what happens in the binding layer.

8 : Building Data Bound Web User Interfaces

This is about building data bound web user interfaces. It has a small section on layout components. It also talks about working with tree and treetables programmatically. One of the things I learned form this chapter is how to use the "RowCountThreshold" attribute in an iterator binding. Never did that before.... On page 327 there is a "best practice" that you should know about: "If the scope of the managed bean is higher than the request, then you should not bind the UI components' elements in the JSF page with the UI component instances defined in a managed bean using the binding attribute in the component tag"

9 : Controlling the Page Navigation
For me there really wasn't anything new but, if you are new to ADF, it is again a very nice chapter.

10: Taking a Closer Look at the Bounded Task Flow
This chapter takes a deep dive into the bounded taskflow. There are sections on "dynamic taskflow calls, Lazy Loading and there is even a section on Contextual events.

11: More on Validations and Error Handling
Yet another chapter containing very valuable tips. Very interesting is the part where you learn how to vreate a custom validator containing client side java scriupt validation.
Also you learn how to define model layer validation which is in fact rarely used. And there is an interesting diagram that helps you understand how the framework engages
DCErrorHandlerImpl during the page life cycle for handling exceptions thrown by business components when accessing them in the binding context

12: Oracle ADF Best Practices
This chapter summarizes the best practices and coding tips that developers will find useful when building ADF applications. Learning the best practices will help you to avoid common pitfalls that others might have faced.  The content for this chapter is based on input from various teams who have successfully used ADF.

My advise is that you should really buy this book ! It is full of valuable tips and tricks ! When you buy this book, all code samples in this book are available online so you can download these and play with them.
The book is available here.

Get yourself a free Christmas present !

For the contest I have two copies of Oracle ADF Real World Developer’s Guide to be given away to two lucky winners.

How you can win:
To win your copy of this book, all you need to do is come up with a comment below highlighting the reason "why you would like to win this book”.

Please note: Winners residing only in the USA and Europe would get a chance to win print copies. Others would be provided with eBook copies.
Duration of the contest & selection of winners:The contest is valid for 7 days (contest ends 23-12-2012 23:59 GMT) , and is open to everyone. Winners will be selected on the basis of their comment posted.

9 comments:

Jay Williams said...

Luc, thanks for taking the time to review the book. I have seen mention of it in the Twittersphere and to have an industry expert give it a great review makes me want to add it to my bookshelf. I am in the utility industry and my company was recently acquired by and merged with another utility. The new company is implementing the Oracle Utilities Customer Self Service (OUCSS) product which is developed in ADF. Our development team is going to be responsible for maintaining and extending the site post go-live so I need to ramp up my ADF skillset. I took an Oracle ADF course but this book seems it would be a great reference to go back and gain a deeper understanding of the framework. Thanks again and Merry Christmas. @jaydev_vt

Ganesh Kamble said...

Very informative Luc. As per your review, I think the book covers the entire lifecycle of development with ADF. The addition of validations, error handling and best practices will help a lot of developers save their time.
And the answer to why 'I would like to win this book' is because I wanted to have the printed copy of the book since the day it was released but could not order it as no one really had published any comments about the book. Now after reading your reviews, I think every ADF Developer must have this book.

Unknown said...

Another book on my wishlist !

Mario Ribeiro said...

I've used Jobinesh's blog several times over the years to find real world ADF solutions for real world ADF problems. I am glad he has put his valuable knowledge and experience in a book form and it is definitely on my wish list.

Menno Homan said...
This comment has been removed by the author.
Menno Homan said...

Hi Luc,

Excelent Post!!!!!!

This post is very helpful for me in real ADF-life ;-)

tidam said...

First of all, thanks for the review. I am recent entry into ADF world from .Net. I have been working as .Net Architect and recently attended a day long ADF seminar by Oracle. At work, there is plan to move our apps to Oracle ADF. So, is the reason. I hope Santa empowers me with knowledge, as they say Knowledge is the best GIFT.

Thanks,
Murali

Luc Bors said...

Comments are now closed. Winners will be contacted soon.

Luc Bors said...

Winners have been informed and should have received their copy by now