I've been developing Netbeans plugin for Java EE development for the past eight years, and have knowledge of most part of the tools. When approached for help by Netbeans users, they were either guided to sparse documents in the Netbeans Knowledge base or a blog was written for their benefit. I wished for an one stop book, which I could point Netbeans users to. I'm glad to see that David Heffelfinger has written a book similar to what I wished for and published by Packt Publishing.
The book is written to help Java developers who want to learn Java EE, as well as seasoned Java EE developers who would want to use an IDE for their development. Since Netbeans is an ideal tool for Java EE 5 development, the book explains how to develop end to end Java EE application using Netbeans IDE. Netbeans has numerous Java EE development support tools to develop a full-fledged Java EE application fairly easily. This book is not to teach you all the principles of Java EE, but to put all the Java EE related Netbeans tools into perspective so that a novice user can easily navigate through the maze of tools offered by Netbeans to develop a Java EE application from scratch.
If you are new to Netbeans IDE and don't know where to start, then the first chapter is a must read. It has complete instructions for downloading, installing and starting the IDE for the first time and more - how to set various Java EE servers for deploying your Java EE application, creating data sources for your application, good tips for effective Java development, etc.
Java Server Pages (JSP) and Java Servlets are two key technologies of Java EE. Netbeans IDE has plenty of support for authoring JSP and Servlet pages. Chapter 2 introduces these technologies and explains in detail how to develop them using Netbeans IDE . This chapter provides a full working example that explains how to: code the complete Servlet/JSP request-response cycle , use a Java Bean as a model for the JSP, configure the Servlet deployment using web.xml configuration tool, etc.. In this chapter you get the complete picture of coding, deploying and monitoring a JSP & Servlet based Java EE Web Application using Netbeans tools.
In a real world application binding a Java EE application to a database is very common. Much of these can be accomplished via hand-coding JSP and Servlet pages. However, it could easily be achieved using readily available JSP Standard Tag Library (JST). Even though Netbeans provides decent support for JSTL, some coding is still required to do CReate, Update and Delete (CRUD) operations on database records. Chapter 3 explains everything you need to start using JSTL to access database from your Java EE application.
JSTL is good but could fall short of your needs. In such cases Custom JSP tags will come to your rescue. Netbeans provides excellent support to create custom tags, including creating the Tag Handler. Thugh books does not fully cover the Custom Tag creation, it provides some simple explanation on how to create custom tags.
If you are one among the rare species called hard core Java EE professionals, you will love to write much of your Java EE web application front end using Servlet, JSP and JSTL. Netbeans IDE provides all the nuts and bolts you need to develop your applications. But for mere mortals, Java Server Faces (JSF) is the alternative. Much of the complicated logic of creating custom tags and application logic is hidden away by the JSF framework. Java Server Faces is quickly emerging as a champion among Web Application frameworks. Next version JSF 2.0 is slated to be released during spring of 2009.
Netbeans provides ample support to develop JSF application, both for advanced users and novices who are comfortable in drag and drop development. Chapter 4 is for non visual based JSF application development. One of the powerful JSF tool provided by the Netbeans IDE is the JSF Faces configuration editor, whose usage is well explained in this chapter along with the creation of JSF page by drag and drop components from the Palette. Data binding to JSF components is another aspect covered.
JSTL tags allow database access via its SQL tags. Similarly JSF components could be bound directly to database as explained in chapter 3 & 4. Java 5 introduces Java Persistence API (JPA) as the standard to access data from database. The fundamental philosophy behind the approach is to use Plain Old Java Objects (POJO) as the model using Object-Relational mapping. Netbeans has complete support to include JPA in to Java EE application. Chapter 5 goes in to detail on how to add JPA functionalities into your application. It also covers the creation of master-detail JSF pages directly from database connection, which is very handy if you don't want to hand craft lots of JSF code required to write a Java EE CRUD application.
Chapter 6 is my favorite, because it covers Visual JSF development tool in Netbeans, for which I was the principal developer and architect. However, the chapter covers only the basics of Visual JSF tool, component drag and drop, binding to database, enabling AJAX capabilities of bundled Woodstock Components, etc. Details on the Visual JSF Application model (which I think is the basic foundation of the tool), Data Providers, Layout Components and Page Fragments etc would have been much appreciated. However, the book is about Java EE development, not just about visual JSF development.
Years ago, most Java developers (including me) started to panick if the assignment involved the infamous Enterprise Java Bean 2 (EJB2) development. All changed in recent years with the introduction of Enterprise Java Bean 3 (EJB3) , which simplified EJB development using simple POJO based approach, pioneered by Framework such as Spring, Hibernate. Netbeans has excellent support EJB3. Netbeans also has excellent support for Spring and Hibernate, which are not covered in this book. Chapter 7 covers EJB3 Session Bean development. EJB3 is made possible by the introduction of annotation in Java 5. EJB3 methods are decorated with annotation for various functionalities, some of which are explained in this chapter. There are two aspects of Session Bean development - creating and deploying it to a Java EE server and accessing the Session bean from a client. Both the aspects are supported by Netbeans and details can be found in this chapter.
While EJB Session Beans provides business logic to you application, the communication between loosely bound Java EE applications are done through the Message Driven Beans, which are part of Java Messaging Service (JMS). Messages are sent to a JMS destination by message producers and the message consumers fetch the message from the JMS destination. The whole concept of JMS is well explained in Chapter 8 along with how to use Netbeans Tools to create the Message Producers, JMS Destination and the Message Consumers. It is nice to see various dialogs and wizards are nicely explained in their order of use.
Finally the Java EE technology covered in this book is Web Services. The older technology is XML-RPC based Web Services (not covered in this book) and the newer one is based on Java API for XML Web Services (JAX-WS) specification, which is covered in this book. Like Session Bean, Web Services also have two concepts - creation and consumption. Netbeans tools provide ways to create Web Services from POJOs and from deployed EJB3 Session Beans, which are explained in detail in Chapter 9. It also covers how Web Service clients can be created from locally deployed Web Services or WSDL from Web Services deployed elsewhere in the internet. One aspect not covered is the creation of AJAX clients from REST based Web Services, well supported by Netbeans and becoming popular for Web 2.0 development.
Over all Java EE 5 Development With Netbeans 6 is a good read. With lots of visual aids, the concepts are well explained. Though this book is not a dedicated book for learning Java EE technology, Java EE concepts are clearly explained where ever needed, which makes it an easy read for non Java EE developers. This book has enough information for a novice user to write an end-to-end Java EE application including the front end, back end, business logic, deployment and testing, although it does not cover all the Java EE technologies supported by Netbeans.
A pleasant and useful book to read and recommended by me.