Having used NetBeans for a long long time, I thought I would share my views about some of the helpful aspects this IDE offers, some not so helpful, and finally finish off this post with the most annoying feature of NetBeans I have encountered. I started using NetBeans from version 4 on my windows machine for writing J2EE applications, the IDE took almost several minutes to startup which really annoyed me like it did for many others. I constantly switched back to Eclipse after trying each and every milestone and new release. From the last 4 weeks, I have been using NetBeans exclusively for writing a complex Java EE and a relatively simple Groovy and Grails applications.

So, here are some of the highlights about The Good, the Bad and the Ugly in my opinion:

With the latest 6.5 Milestone 1 version, it takes less than 7 seconds to start the IDE on my Mac laptop. So, the improved performance and faster startup is one of the biggest niceties when compared to the previous versions which drove me away from NetBeans towards Eclipse.

I am using the NetBeans IDE for development with the Java Persistence API(JSR-220), Enterprise JavaBeans(EJB) and web services. The Java EE module for the NetBeans IDE supports Java EE 5 and also the earlier versions of J2EE.

The Database support within the IDE is just awesome. With the wizard approach for creating connections and managing the same, it is very easy to create, update and also query your tables directly from within your IDE. By default, you can connect to Derby, MySQL and PostgreSQL. But, if you need to connect to other databases like MS SQL or Oracle, you just need to register the driver and you are all set as shown below:
driver-support

The IDE has wizards to work with the Java Persistence API. The Wizard enables you to generate entity classes from a database. The IDE looks at the database schema and generates all the necessary code for entity relationships.

driver-tables

However, the wizard here retrieves all the entity relationships(if Include Related Tables is checked) from the schema and there is no way to specify the directionality of the relationships. Lets say I have a relationship between the Customer and Address entity, I would have a relationship method within the Customer entity to retrieve the Address, I wouldn’t want to ask the Address entity who its Customer is? You can always open up the Java Source Editor and make changes, but it would have been really nice to have wizards in which you could manage relationships more efficiently. The NetBeans team should add, in my opinion, additional support to handle relationships well.

In many real life applications, you are most likely to develop read-only entities knowing that the table data changes relatively infrequently. There isn’t any support in any of the wizards to mark an Entity as read-only.

If you are using Java Persistence API in either the EJB module or web module, the IDE does allow you to create a persistence unit. As with all other modules, it does have a wizard approach in which you specify a few details and you have the persistence.xml file generated for you.
persistence-unti

Lets move from the persistence tier to the business logic tier. A wizard approach for generating Session beans as well as Message-Driven beans(MDB). Within the New Session Bean Wizard you can specify the session type(Stateless and Stateful) and also the type of interface you want the IDE to generate(Remote and/or Local). The wizard for the MDB’s is a little bit confusing when you have to choose between the project and server destinations, but the context sensitive help comes to our rescue here.

MDBS

The IDE also assists you with the development of Web Services; it supports a wide variety of web service standards such as the JAX-WS 2.1, JAX-RS (JSR-311), JAX-RPC (JSR-101). I have used the IDE for creating JSR311-compliant RESTful web services from JPA entity classes and SOAP-based web services from Java classes. To top this all, you can test web services using the new soapUI plugin.

NetBeans allows you to register any Java EE compliant server to deploy your applications. It supports all the major vendors out there as seen below:
application-servers

However, each time you want to deploy, run and test on an application server other than the one selected for your project, you would have to go through 3 steps as shown below.
target-server
I would rather have all the servers registered as sub menu items within the Run menu item. Don’t you agree?

I said a lot of things that are good and that need some improvement, so you may ask what is it that I find so ugly within the IDE. If you are writing enterprise Java application, in many cases Ant stands as the universal build platform. NetBeans by default creates all the build files for compiling, testing, deploying, undeploying and running your application. However, even after using Ant for several years now, I had serious trouble using these build files. I did use a tool called Grand and Vizant to generate visual documentation of the build files to understand them better and here is what I was able to get from them. The build files need heavy refactoring for anyone to continue to use within their enterprise applications.
ide-generated-build-file

So, here is my take on The Good, The Bad, & The Ugly I found within the NetBeans IDE for a simple Java EE application I was trying to create. Give it a try, and you will be surprised how far this IDE has come along.