I am working on a project to secure Java web services running under JBoss and WebSphere application servers. As part of this effort, I’ve created some ‘Hello World’ type web services and consumers to use for the team’s integration testing and implementation verification. This has allowed me to launch two identical projects: one using MyEclipse targeting the JBoss application server and the other using WebSphere Studio Application Developer 5.1 (WSAD) targeting the WebSphere 5 application server environment. By doing these two Java development projects side by side, I’ve been able to compare the two development environments on equal grounds for one very specific type of development.

Initial Setup of Eclipse Projects and Local Servers

Furthermore, the applications for JBoss used the XFire SOAP implementation for web services. This is an external component, but MyEclipse supports this and has a simple wizard to generate a web service. I found resources on the web and within MyEclipse that helped me struggle through writing my first web service and I learned a lot. It was harder to learn how to do get it to work in the MyEclipse environment than it was to learn how it to configure it, but I appreciate the features in MyEclipse. MyEclipse’s support for JBoss is also nice and it is really easy to integrate with a JBoss server, which must be installed and configured separately. One-click server start/stop and one-click deploy from your Eclipse project was really nice.

Setting up the WebSphere applications was a different experience as everything was done within the WSAD IDE. You used wizards (Eclipse plug-ins) to generate both web services and clients, and when you are done, you also get JSP’s and Java classes that allow you to test them. I admit I had some more experienced help in setting this environment up, but it was real point-and-click. And, so was the server configuration. Everything about the server is in a ’server’ Eclipse project and you can control parameters within WSAD. In fact, it was so easy that we decided to run two WebSphere servers listening on different ports and deploy the service to one and the consumer to the other. To do the same for JBoss, you have to define a separate server using the configuration files and MyEclipse will happily support it, but I don’t really have the time to learn about details of JBoss server administration to do that. WSAD wins there, but everything else in setting up the applications was pretty equivalent.

Iterative Development

Going forward to create the applications I wanted, with naming standards and just the right Hello World message, I first had to contend with port conflicts between the JBoss server and the Windows operating system. It seems that a lot of the port numbers for JBoss are around the 1000’s and that’s just where Windows starts giving away port numbers. This required us to learn how to reserve ports by manually modifying the registry. OK, maybe JBoss is not to blame there.

Finally we get JBoss working properly and the second annoying thing arises. After deploying your web application to the JBoss server (a nice one-click that physically copies files from the Eclipse workspace to the deploy folder on the JBoss server) it works fine, but redeploying or removing the application is problematic. The Windows operating system again intrudes and locks at least some JAR files. In order to redeploy your entire application, you have to stop the JBoss server, redeploy and restart the server. Restarting takes awhile. If you forget to shut down the server first, you will get a nasty gram and a half-deployed application. To be fair, files are copied to the server when you save them in your workspace preventing the need to constantly redeploy, but starting up the project required a lot of redeploying and it was very tedious.

Here is where IBM rockets ahead. With two WebSphere servers running on different ports, it was pretty simple to associate different projects with the different servers for one-click everything. Because of the inevitable mis-starts (like using the wrong JDK version), we had to redefine and redeploy the applications a number of times at the beginning of the project. This procedure was definitely less painful than the JBoss experience and we had more capabilities in the end with two servers. Also, the server configurations are stored in an Eclipse project, which are shared via version control to other developers. One thing that helps architecturally is that the WebSphere servers use your actual Java Eclipse project folders as the deployed application area. This prevents the need to copy files around. There is also a nice server management view that allows you to look at the different logs and perform server start/stops.

Summary

I like the more lightweight MyEclipse/JBoss combination that seems to be more simple and understandable, and also gives me the freedom to screw up my own project. The painful redeployment process and the external configuration of JBoss were drawbacks. For a multi-developer environment, a number of standards would need to be defined to get everyone working on the same page. IBM’s WSAD did most of the configuration for me for the servers and it also generated web services applications that were complete and robust, but it was impossible to understand the inner workings (for me). Changing any of the major parameters of your web service required you to regenerate it completely, but it worked great and it was easy. I also ended up with more capabilities by having two servers. The version of WSAD I used, 5.1, is quite old, but I will soon be able to go through the same exercise with Rational Application Developer for WebSphere Software version 7. I can’t wait!