Tuesday, December 30, 2008

2008 : The good, bad and ugly

I am so glad 2008 is finally coming to an end. It was indeed a roller coaster ride for me from the beginning. Lots of ups and downs.

The highlights of 2008 were speaking at conferences, giving presentations locally, wrote 68 articles for Javalobby, the three part SoapUI article was #1, #2 and #8 at Architecture Zone and SOA Zone. I also had the opportunity to learn and use many tools.

Now coming to the bad. I always wanted to learn Maven; I even tried to use it a few times. I first tried to use Maven was when I reviewed the book “Java Power Tools”. It was a simple project, and everything seemed to work fine. However, I failed miserably when I tried using Maven for a few other examples. Instead of persevering through my problems I gave up.I started out wanting to become an expert on Maven; I ended up being just another Novice.

Up until my spell of laziness, I read about 2-3 books a month. Starting in about October, I began to lose interest in reading and reviewing books. But I do hope to reverse this trend in the next year.

I never knew that there would be something worse waiting for me in 2008. I used to feel so bad whenever I heard on TV that a company was closing its operations and all the employees were laid off. I felt so bad for them, had no idea that it was going to happen to me also.

When I heard that the company I was working was closing its operations and we were given just 3 days notice, I was devastated, shocked and stunned. I just can't even write how I felt in those few days. My world had turned upside down. I had planned a trip to India to visit my parents and had collected 80 hours of vacation. Lost all of them, the company had no policy of paying for unused vacation. Hah, they tell me at the end. It was just bad.

However, I am sure I had done some good karma, I was able to find another job in just 3 days. Thanks to one of my Friends who referred me.

Now that I have gone through the worst, I am sure I will be able to cope better next time if the same happens.

Anyway, what an incredible year 2008 was. Life is full of surprises; good, bad and ugly, and if and only if we could predict the future........

Tuesday, December 16, 2008

Stripes Framework - Worth Trying

When I received an email a couple of weeks back from "The Pragmatic Bookshelf" about the book "Stripes ...and Java web development is fun again", I completely ignored the same. I didn't want to learn yet another web framework, and write a detailed review either. I wish I had signed up for reviewing this book.

Just a few days back, I read the article on "TSS" about Stripes called "A Stripes 1.5 Test Drive". The one and only one thing which attracted me to this article was that other than the web.xml file, there wasn't any XML configuration files to be written and to maintain.

I read the article with great interest, and also read the documentation on the Stripes web site. Next, downloaded the libraries and was able to get it working with the many samples I had in minutes. Yes, trust me just minutes.

So, I decided to do something even more interesting which I always do and surprisingly it worked like a charm. I am planning on writing a detailed article about how I was easily able to use Stripes with my existing sample projects.

Have you used Stripes? What do you think about the same? Isn't it a great framework?

Stay tuned about my article as well, I will keep you posted sooon.

If you haven't used Stripes, give it a try. You will be really surprised to see how easy it is to use Stripes.

Tuesday, December 9, 2008

The Three Pillars of Continuous Integration

Continuous Integration commonly known as CI is a process that consists of continuously compiling, testing, inspecting, and deploying source code. In any typical CI environment, this means running a new build every time code changes within a version control repository. Martin Fowler describes CI as:
A software development practice where members of a team integrate their work frequently, usually each person integrates at least daily - leading to multiple integrations per day. Each integration is verified by an automated build to detect integration errors as quickly as possible.

Many teams find that this approach leads to significantly reduced integration problems and allows a team to develop cohesive software more rapidly.

While CI is actually a process, the term Continuous Integration often is associated with three important tools in particular. As shown in the screen above the three pillars of CI are:

1. A version control repository like Subversion, or CVS.

2. A CI Server such as Hudson, or Cruise Control

3. An automated build process like Ant or Nant

So, let’s look at each of these in detail:

Version Control Repository:

Version control repositories also known as SCM (source code management) play a crucial role in any software development environment. They also play a very important role for a successful CI process. The SCM is a central place for the team to store every needed artifact for the project. It is mandatory for the teams to put everything needed for a successful build into this repository. This includes the build scripts, property files, database scripts, all the libraries required to build the software and so on.

The CI Server:

For CI to function properly, we also need to have an automated process that monitors a version control repository and runs a build when any changes are detected. There are several CI servers available, both open source and commercial. Most of them are similar in their basic configuration and monitor a particular version control repository and run builds when any changes are detected.

Some of the most commonly used open source CI servers are; Cruise Control, Continuum, and Hudson. Hudson is particularly interesting because of its ease of configuration and compelling plug-ins, which makes integration with test and static analysis tools much easier.

Automated Build:

The process of CI is about building software often, which is accomplished through the use of a build. A sturdy build strategy is by far the most important aspect of a successful CI process. In the absence of a solid build that does more than compile your code, CI withers. With automated builds, teams can reliably perform (in an automated fashion) otherwise manual tasks like compilation, testing, and even more interesting things like software inspection and deployment.

Now that we have seen the important tools in our CI process, let’s see how a typical CI scenario looks like for a developer:

* CI server is configured to poll the version control repository continuously for changes.
* Developer commits code to the repository.
* CI server detects this change, and retrieves the latest code from the repository.
* This causes the CI server to invoke the build script with the given targets and options.
* If configured, CI Server will send out an e-mail to the specified recipients when a certain important event occurs.
* The CI server continues to poll for changes.

Why is CI Important?

This is one of the most frequently asked questions, and here are a few points to note about this powerful technique:

* Building software often greatly increases the likelihood that you will spot defects early, when they still are relatively manageable.
* Extends defect visibility.
* CI ensures that you have production ready software at every change.
* CI also ensures that you have reduced the risk of integration issues by building software at every change.
* CI server can also be configured to run continuous inspection which can assist the development team in finding potential bugs, bad programming practice, automatically check coding standards, and also provide valuable feedback on the quality of code being written.

Over the past several months, I have assisted several companies in implementing CI. There was a little bit of resistance from the developers in the early stages when we implemented continuous feedback. But, never heard a single negative comment about this approach. If you already have a version control repository and automated builds, you are very close to the CI process.

Download one of the open source CI servers, configure and setup a simple project. It should take less than an hour if you have automated build scripts. Start adding additional features like code inspections, generating reports, metrics, documentation and so on. Most important, send continuous feedback to your team.

Give this process a try, you sure will be surprised to see how effective it is. And, as always share your thoughts, concerns or questions.

Monday, December 8, 2008

Spring vs EJB War : Will It Ever End?

I can't believe I am even writing this post. My article at Javalobby "EJB 3.1 - EJB New and Improved", became the place for a few people to make it a Spring vs EJB war.

I received several emails asking about my opinion. I did comment saying
As long as it is a healthy discussion on Spring Vs EJB and not a war of words between two individuals, I have no problem at all.

There was one person who went to say that "I was gaining more popularity with this article". I have been writing articles from many years now. Every time I have learnt something new or interesting, I have tried to share those with my community. I don't need such fame.

Of course, it had no effect, and the discussions took a completely different route.

I had seen such war of words and arguments when it came to Java vs .NET, but never had heard or read about two great and very useful framework and specification. I had one former colleague who went to such an extent saying:
I will jump off the bay bridge rather than work on Java.

I didn't understand that statement than, and don't even now. And now with this discussion taking a route which I had never imagined, I am even more confused.

What are your thoughts? Why do developers go to such extreme? Isn't it another language or framework? Don't we learn new languages when we go to different countries however hard it may be? Why we as developers have such hatred towards other technologies?

Thursday, December 4, 2008

Interesting books from Apress

I received an email yesterday from the contact I have for Apress about some new and interesting books. Some of these books are going to be available in January 2009, and some in late December.

Here is a sneak peek into the list:

978-1-4302-1877-7 Spring Persistence — A Running Start Fisher, Paul Jan 2009

978-1-4302-1648-3 Pro Spring Persistence with Hibernate Seddighi, Ahmad Jan 2009

978-1-4302-1881-4 Apache Batik: SVG Toolkit Kumar, Ajit Jan 2009

978-1-4302-1926-2 Grails Persistence with GORM and GSQL Fischer, Robert Jan 2009

978-1-59059-995-2 The Definitive Guide to Grails, Second Edition Rocher, Graeme Jan 2009

978-1-4302-1600-1 Groovy and Grails Recipes Jawad, Bashar Dec 2008

978-1-4302-1055-9 Practical RichFaces Katz, Max Dec 2008

978-1-4302-1883-8 Eclipse Rich Ajax Platform: Bringing Rich Client into the Web Lange, Fabian Dec 2008

And here is a list of books which have already been published and is available for you to purchase.

1. 978-1-4302-1061-0 Beginning Java™ ME Platform Rischpater, Ray Oct 2008

2. 978-1-4302-1624-7 The Definitive Guide to Spring Web Flow Vervaet, Erwin Oct 2008

3. 978-1-4302-0963-8 Beginning Database-Driven Application Development in Java™ EE: Using GlassFish™ Vasiliev, Yuli Sep 2008

4. 978-1-59059-737-8 The Definitive Guide to Apache MyFaces and Facelets Wadia, Zubin Sep 2008

5. 978-1-4302-1057-3 The Definitive Guide to SOA: Oracle® Service Bus, Second Edition Davies, Jeff Sep 2008

6. 978-1-4302-1031-3 Beginning Google Web Toolkit: From Novice to Professional Smeets, Bram Sep 2008

7. 978-1-4302-1009-2 Pro Java™ EE Spring Patterns: Best Practices and Design Strategies Implementing Java EE Patterns with the Spring Framework Kayal, Dhrubojyoti Aug 2008

8. 978-1-59059-921-1 Pro Spring 2.5 Machacek, Jan Aug 2008

9. 978-1-4302-0973-7 Practical API Design: Confessions of a Java™ Framework Architect Tulach, Jaroslav Jul 2008

10.978-1-59059-986-0 The Definitive Guide to Terracotta: Cluster the JVM for Spring, Hibernate and POJO Scalability , Terracotta, Inc. Jun 2008

11.978-1-59059-979-2 Spring Recipes: A Problem-Solution Approach Mak, Gary Jun 2008

12.978-1-4302-1045-0 Beginning Groovy and Grails: From Novice to Professional Judd, Christopher M. Jun 2008

Tuesday, December 2, 2008

Article Recursion

Sometime in late October, I wrote an article on code coverage for Javalobby called "Is Code Coverage Important?". This article had some very interesting comments. This article was quoted in many blogs.

And, just yesterday my friend Andrew Glover wrote an article in his The Disco Blog called Code coverage coterie confab.

The article was also quoted by another blog as well. The article is "Code Coverage, what is it good for?".

What are your thoughts about code coverage? Do you use it? Share your thoughts?

EJB 3.1 - A Brief Look

Just yesterday, the article I wrote on EJB 3.1 - EJB New and Improved! went live on Javalobby. In this article, I examine a few interesting topics being considered in the new and improved version of EJB such as optional Session Bean Business Interfaces, Global JNDI Names, Singleton Session Beans, and the EJB 3.1 Embeddable Container.

The article has generated very interesting discussion from many readers, and there are very good comments as well. Javalobby also posted it as a Spotlight Feature.

I used the latest version of OpenEJB which has support for quite a few features of EJB 3.1 to work out all the samples. I was able to unit test all the samples as well with just a click of the button in Eclipse IDE. Just amazing for how EJB's have come.

Monday, December 1, 2008

Any Code Analysis Tools for Groovy & Grails?

I had an interesting comment from one of the readers at Javalobby. To quote him:

Hello Meera,

I was just wondering if we have a code analysis tool in the market that integrates and works well with Grails & Groovy? Your response is very much appreciated and valued.

Many Thanks,


I have used code analysis tools for both Java & .NET, but none for Groovy until now. I am pretty sure FindBugs which analyzes the byte code might work for Groovy and Grails. All other tools inspect the source code, so we might not be able to use any of them.

Have you used any such tool with Groovy & Grails? Any ideas? If so, please share your thoughts.

Saturday, November 29, 2008

Terror in India

The terror attacks in Mumbai(Bombay) have made me so sad and mad from the past 2 days. Having had holiday on both Thursday and Friday, and watching this ongoing fight live on CNN, has troubled me even more. Like they say "Picture says a thousand words", seeing the images brings tears into my eyes.

I just don't understand how these terrorists could just go off and kill all the innocent people. They even went into a Maternity and Childrens hospital, can you believe how cruel these terrorists are? What might be going on in their minds? How do they get such hatred toward people?

Reading all the online stories makes me even more sad. Just unbelievable. With more than 1 billion people, how do we suspect any one person of this motive?

Who is responsible for the bloodshed? Can anyone stop this bloodshed at all?

If there is God, I pray to him sincerely to put some common sense into the brains of all these terrorists.

Wednesday, October 22, 2008

Why Pair Programming Should be made MANDATORY

Pair Programming is one of the most controversial topics discussed time and again. In the beginning I was a bit hesitant about this practice, but slowly I got used to this and really enjoyed working with another developer. However, when in one of my projects, I was the sole developer for nearly months, I knew how important it is for us to really have another pair of eyes. The few months I worked alone, I was not myself at all. Even though I had the opportunity to learn all the latest and the greatest technologies, I just couldn't take it anymore. I had to resign and so did I.

Now that I am reading the book "Pragmatic Thinking and Learning
", I was able to clearly understand why I felt the way I was in that Job working alone. In Chapter 4: Get In Your Right Mind Andy explains about Pair Programming and why it is important. He first explains about the R-Mode and the L-Mode of our brain. So, you may ask what is R-Mode and L-Mode:

If you're looking for global, holistic patterns, you need R-mode. If you need to analyze parts and look into detail, then you need a more L-mode approach. For most of us, this level of specialization is how it is. R-mode sees the forest; L-mode sees the tress.

For pair programming, Andy very well explains that we need to get both R-mode and L-mode working together, and the only way to do this is by having your L-mode work with another person's R-mode or their R-mode work with your L-mode.

Again,to quote from this excellent book:

The navigator is free to see these larger relationships and the larger picture, And most of the time, you cannot see these relationships if you're driving. So if you aren't pair programming, you definitely need to stop every so often and step away from the keyboard.

This doesn't mean that you should pair all the 8 hours you are working. I suggest we should pair when we are working on a critical piece of our module, when we are trying to fix bugs, learn a new language, writing build files. Always better to have another pair of eyes, and another mode of brain.

What do you think? Are you using Pair Programming at all? What are your thoughts?

Tuesday, October 14, 2008

Clean Code : MUST Read Book

Just yesterday, I posted a brief review of Clean Code: A Handbook of Agile Software Craftsmanship written by Robert C. Martin. at Javalobby.

What an amazing and interesting book it is. Around 4 weeks back, the book was at my front door when I came back from work. The next few weeks were quite hectic and I had no time to even open the book. Finally, two weeks back I decided to just browse the contents. I first read the foreword, which again is amazing. That was the beginning, I just couldn't stop.

This time since I hadn't signed up to review this book, I thought I should try a different format of writing the review. I mentioned 5 reasons why this book was worth reading, simple ones. And, later at the end summarized what I had learnt from this book. I guess it stuck a cord with the readers, and there were some good comments as well.

Take a look at the review, and try to get this book if you read or write code. Trust me it is worth the money and the time.

P.S: I sent an email to the publisher to find out who had shipped this book, and my contact at Pearson had sent the book. I did thank her profusely for sending this book along as well.

Friday, October 10, 2008

Maven: The Definitive Guide--New from O'Reilly

For those of you who are interested in learning and using Maven as your build tool, O'Reilly has just released a book called "Maven: The Definitive Guide".

To quote from the email I received:

For too long, developers have worked on disorganized application projects, where every part seemed to have its own build system, and no common repository existed for information about the state of the project. Now there's help. The long-awaited official documentation to Maven is here.

Maven: The Definitive Guide (O'Reilly, US $34.99) serves as both an introduction and a comprehensive reference for Apache Maven, the tool that will transform the way an organization builds and manages application development. Written by members of Sonatype's engineering team—including Jason van Zyl, the creator of the Maven central repository—the book explains why Maven is replacing Ant as the tool of choice, not just for open source Java projects, but for applications in many other languages, including Scala, Ruby, and Groovy. The book also provides the first in-depth overview of Maven 2.

The first half of this book introduces Maven by example, with a series of real-world, multi-module applications that can be used as templates. The second half serves as a reference to a wide range of topics, teaching readers how to:

* Get started with Maven
* Understand the Project Object Model (POM)
* Integrate Maven with Eclipse
* Master advanced dependency management
* Use the Nexus repository manager
* Integrate Maven with Spring and Hibernate
* Write and use Maven plugins
* Generate a project website
* Customize a build with properties
* Use build profiles and profile activation
* Create and use Maven assemblies
* Develop with Maven archetypes

I did try learning Maven several times, and each time got lost in the POM. It sounds like this book is for people like me, but I already have quite a few books in my list. And with this one for me to review, I sure will have to try all the examples, and there isn't just enough time right now.

Wednesday, October 1, 2008

What's FuseMetrics?

FuseMetrics is an open source tool written in Groovy, which can parse the reports of many of the most common analysis tools:

* Junit
* TestNG
* JDepend
* Checkstyle
* JavaNCSS
* FindBugs
* Simian
* Clover
* Cobertura

It produces summary metrics and graphs - sparkline and histograms.

No matter what build tool you are using, Ant, Maven, Gant or Gradle you can use FuseMetrics.

It’s completely open source and we have used it for many of our clients. To read more about FuseMetrics, take a look at the article I wrote at Javalobby here.

Try it out and give us your feedback.

Thursday, September 25, 2008

What's Gradle?

My article a few days ago in Javalobby "Ant or Gant" had some very interesting comments. One reader posted about a new build tool which I had never heard of called "Gradle". To quote his comment here:

gradle is another java+groovy based build-tool
IMO gradle is clearly superior to gant.
it implements support for dependency-management
and some other really smart concepts.
check it out: http://www.gradle.org

As always, I didn't waste anytime once I saw this comment, and read the Getting Started and also Users Guide. It sure looks interesting. I will download Gradle and give it a try and share my experience. In the mean time:

Have you used Gradle? Share your thoughts?

Wednesday, September 24, 2008

Ant or Gant?

If you have complicated build files and have no clue what and how to refactor these files, check out the article I wrote at Javalobby called "Ant or Gant?".

This article explains the following in detail:

1. When to choose Gant?
2. What's Gant?
3. Getting Started with Gant.

Of course, you should know Groovy before you decide to runaway from Ant.

Tuesday, September 23, 2008

Are Software Developers in America Lucky?

This isn't a controversial post. Trust me. Let me give you a small background before you start freaking out.

I have been in the software industry for a long time now. Every time someone moves back to India, and at the same time I chat with someone in India or UAE, I have this dreadful conversation. Read on:

Question 1: Meera, when are you coming back to India?

Meera: I have some family responsibilities, I am not sure I will be coming back soon.

Question 2: You should, the salary they pay here is amazing, do you know?

Meera: Yes, I do. But, I am really happy and content with my salary here as well.

Question 3: How is the working hours there?

Meera: I work 5 days a week if I am within the DC area, and if I am travelling I work 4 days.

Question 4: We work almost 10-14 hours everyday, do you know that?
Meera: Yes, I do. I have also worked when the project was due, and we had tight deadlines.

Question 5: See, that could be one reason why you will not fit in here?
Meera: I don't know, I really know how to manage my schedule and manage work which is assigned to me. So, I don't see any reason whatsoever to work 10-14 hours everyday. I sure wouldn't work at a place where my Manager would expect me to work like that.

Question 6: You guys working in America are really Lucky.
Meera: I don't know, when it comes to work, I can speak for myself and the team with whom I have worked and most worked hard. So, I am not sure why we are lucky?

At this point, I knew the conversation was taking a wrong path, and decided to logout of IM, and later saying that I got interrupted. This has not happened to me once or twice, but many times over the past 2 years. I should admit, I just can't argue at all.

But, I am still shell shocked. Why do developers in India have to work 10-14 hours? Is it really needed? And can you stay focused working 10-14 hours a day? Do you still have the ability to concentrate after 8-9 hours of work? I don't know? I should try working for a month or so in India just to see how things are now, don't you think so?

What are your thoughts? Are we developers working in America really lucky? What do you think?

I remembered the quote from Thomas Jefferson, which says

I'm a great believer in luck, and I find the harder I work the more I have of it.

I guess that sums up why American Developers are Lucky, right?

P.S: If you haven't yet noticed, I am an Indian and proud to be one as well. But, I just don't understand the logic behind working more than 40 hours every single week; and hence this post.

Update: The only reason I posted this article was to know why our fellow developers were working long hours, and to know their state of mind. And it was posted in good faith. I am seeing that the comments are taking a completely different direction, and I just don't want to start a war of words. I am not going to respond/approve any anonymous comments.

Friday, September 19, 2008

Is easyb Easy?

Yes, that's exactly what you will find out by reading the article I posted a few days back at Javalobby. easyb is a BDD framework for the Java platform written by Andrew Glover. And, I learnt quite a few things from Andy as well about easyb. This artcile goes in detail about how to write a

1. Scenarios within Stories
2. Run these Stories from Ant
3. Generate a report.

Check out the article to find out what my verdict was. Also, give it a try and let me know your verdict as well.

Thursday, September 18, 2008

Javadoc or Doxygen?

If you have been thinking about how to improve your technical documentation, than you have to take a look at the article I wrote last week at both Javalobby and also Test Early.

Here are a few reasons why you should consider using the Doxygen:

1. With Javadoc you have to remember all the HTML tags, you need to embed within your code comments. However, with Doxygen code comments are much more concise and polished, without the need for any HTML.

2. Doxygen can also generate a variety of diagrams, we will take a look at some of them later.

3. Doxygen also provides a structured view on the source code. As I mentioned in 2 above in the form of various diagrams, cross-referenced and syntax highlighted code.

4. You get all the above benefits even if the code does not have any comments at all.

5. Last but not the least, Doxygen is a documentation system not for just Java but also for various other languages like C++, C, Java, Objective-C, Python, IDL (Corba and Microsoft flavors), Fortran, VHDL, PHP, C#.

The article shows in detailed steps the following:

Step 1. Download, Install Doxygen.

Step 2: Configure Doxygen.

Step 3. Doxygen and Ant.

Step 4. Integrate with Hudson.

Thursday, September 11, 2008

See me at Software Development Best Practices 2008

I'd like to invite you to join me at …

Software Development Best Practices 2008
October 27–30
Hynes Convention Center, Boston, MA

Software Development Best Practices is where the software development community gathers to learn about the latest business-critical technologies, network with peers, connect with innovative vendors and get inspiration from industry visionaries. The conference features 140+ in-depth sessions covering today's most important topics including agile processes, requirements analysis, project/people management, security, testing, SOA, C++ and much more.

I'm pleased to announce that I'll be teaching following session at SD Best Practices:

"Web Services Testing Made Easy and Fun with SoapUI" on Thursday (October 30, 2008) 10:30am — 12:00pm

You can find additional details about my session here.

Register by Friday, September 19, to take advantage of generous early bird discounts. As a speaker, I can also offer you an additional $100 off the VIP Pass. Simply register at http://www.SDBestPractices.com with the code 8ESPK to get your discount.

I encourage you to visit the website and explore all the excellent educational opportunities SD Best Practices 2008 has to offer.

I look forward to seeing you in Boston!

Wednesday, September 10, 2008

The Art of Debugging with GDB, DDD, and Eclipse

Debugging, the demanding process of finding and fixing programming errors, is fundamental to successful software development. But even many experienced programmers find debugging a challenge.

The Art of Debugging with GDB, DDD, and Eclipse (No Starch Press, September 2008, 280 pp, ISBN 9781593271749) teaches readers how to effectively use the three most popular open source debugging tools: GDB, DDD, and Eclipse. The text-command based GDB (the GNU Project Debugger) is included with most Linux distributions. DDD is a popular GUI front end for GDB, while Eclipse provides a complete integrated development environment.

The Art of Debugging offers readers specific advice for debugging with each tool and explains general debugging strategies. Real world examples of coding errors help to clarify the authors' guiding principles, and readers will quickly understand why their programs crash or throw exceptions.
The authors are well-known for their popular online debugging tutorials, and a printed book is long overdue. According to No Starch Press publisher Bill Pollock, "Programmers are desperate for a book devoted to debugging, particularly with GDB and DDD. Finally, the wait is over. No more debugging by hand."

In the book, readers learn how to:

* Inspect variables and data structures
* Understand segmentation faults and core dumps
* Use features like catchpoints, convenience variables, and artificial arrays
* Avoid common debugging pitfalls
* Prevent errors in the first place by making the best usage of editors, compilers, and static code checkers

The book also includes coverage of advanced topics like thread, client-server, GUI, and parallel programming. Whether readers dread the thought of debugging programs or simply want to improve their current debugging efforts, they'll find a valuable ally in The Art of Debugging with GDB, DDD, and Eclipse.

Monday, September 8, 2008

Princeton Premier Registry Scam

I received an email which is listed here in its entirety. As soon as I saw it, I knew it was another scam. Being a thorough Google researcher, found out many had received the same, and it is just like one of those lottery emails we all receive. So, guys and gals, just delete this email if you ever receive one, and don't click on any of those links or pay any money.

Here is the email:

Subject: Meera Subbarao's Inclusion In Our Global Network

Meera Subbarao

It is my pleasure to inform you that you are being considered for inclusion into the 2008-2009 Princeton Premier Business Leaders and Professionals Honors Edition section of the registry.

The 2008-2009 edition of the registry will include biographies of the world's most accomplished individuals. Recognition of this kind is an honor shared by thousands of executives and professionals throughout the world each year. Inclusion is considered by many as the single highest mark of achievement.

You may access our application form using the following link:


Upon final confirmation, you will be listed among other accomplished individuals in the Princeton Premier Registry.

For accuracy and publication deadlines, please complete your application form and return it to us within five business days. There is no cost to be included in the registry.

If you've already received this email from us, there is no need to respond again. This email serves as our final invitation to potential members who have not yet responded.

On behalf of the Executive Publisher, we wish you continued success.


Jason Harris

Managing Director
Princeton Premier

Friday, September 5, 2008

CITCON Amsterdam

CITCON, the Continuous Integration and Testing Conference, hosted by
Jeffrey Fredrick and Paul Julius will take place in Amsterdam on
October 3 & 4. Attendance is free!

This is the third annual CITCON event in Europe. London in 2006 and
Brussels last year were both a blast. Everyone walked away having
learned a lot about the cutting edge of CI and Testing.

You're invited! Register at: http://citconf.com/amsterdam2008/register.php

So, what are you waiting for? If you live somewhere close to Amsterdam, register. Trust me, you will learn a lot from this conference.

Thursday, September 4, 2008

Spring 2.5 books from Apress

Apress has released three very interesting titles on Spring 2.5.

1. Spring Recipes: A Problem-Solution Approach

I read and reviewed this book for Javalobby, and gave it 5 stars for all the categories.

2. Pro Spring 2.5

I might start reading this soon..

3. Pro Java™ EE Spring Patterns: Best Practices and Design Strategies Implementing Java EE Patterns with the Spring Framework

I am reading this book currently, and didn't find anything new which I didn't otherwise know about the Java EE design patterns. Haven't tried working on the code samples either.

If you are using or planning to use Spring, than you definitely need 1 and either 2 or 3.

Wednesday, August 27, 2008

EJB 3.0 and Spring 2.5

For those of you who are interested in using EJB 3.0 components in Spring, I have written a detailed How-to article at Javalobby. This article shows you how easily you can call EJB 3.0 session beans from within your Spring beans.

Also, some interesting comments from readers and a few from Reza Rehman co-author of the "EJB3 in Action" book.

UML Diagrams from NetBeans

Based on the article I wrote at Javalobby: Reverse-engineer Source Code into UML Diagrams, my DZone colleague Geertjan Wielenga has written another article on how to generate these UML Diagrams from within the NetBeans IDE, called Generate UML Diagrams into Javadoc in NetBeans Projects.

I especially liked the way Geertjan starts off his article by saying:
One incredibly useful article recently on Javalobby is called Reverse-engineer Source Code into UML Diagrams, by Meera Subbarao.

Take a look at your leisure.

Monday, August 25, 2008

Reverse-engineer Source Code into UML Diagrams

I wrote an article at Javalobby and testearly about how to use UMLGraph to generate UML diagrams from existing source code, how to integrate these within your build file, and also use the Ant targets within Hudson CI job, and keep your code base and the UML diagrams in sync. I also show how to include these ant targets in your commit builds or nightly builds of your CI jobs, and also publish these artifacts as part of the post build process.

The article shows how easy and simple it is to include UML diagrams within your Javadoc and also keep them updated with every change in the source code repository. We can do these in less than a few minutes, and in a few simple steps.

Getting started with UmlGraph takes five steps:

  1. Download the source code for UMlGraph.
  2. Download and install Graphviz.
  3. Make changes to your Ant build file.
  4. Run the Ant target.
  5. Add this target to your CI job.
The above 5 steps are covered in detail in the article.

Take a look at the article, and share your thoughts. The response has been amazingly good for this article.

Friday, August 8, 2008

Spring's so Groovy

Just yesterday, I wrote an article at testearly.com about how easy it was to use Groovy within Spring. I was reading the book "Spring Recipes - A Problem-Solution Approach", and the last chapter is about "Scripting in Spring".

I wrote a simple "HelloWorldService" in Eclipse IDE following the samples provided by this book. Trust me, it was so easy.

In this tutorial written at testearly, you will learn how to use Groovy with Spring, using an external script source file, how to refresh changes when a script source file is changed, and finally see an inline script which was embedded within the Spring configuration file.

Have you used Spring and Groovy? If so, do you mind sharing your thoughts?

P.S: Stay tuned for a detailed review of the book "Spring Recipes - A Problem-Solution Approach" at Javalobby.

Monday, August 4, 2008

New Apress Java Books - Summer 08

Last week, I received an email from the contact I had for Apress publishers, and was given this list of books which would be available in Summer of 2008. I have already read and reviewed the Spring book "Beginning Groovy and Grails". It was a great book indeed. Here are several other books some of which are already available and a few coming soon.

Pro Spring 2.5

The Spring Framework remains the leader in the move from so-called heavyweight architectures, such as Enterprise JavaBeans, toward lightweight frameworks. Pro Spring 2.5 covers the new features of Spring 2.5, but moreover, it is focused on best practices and core standards of contemporary Spring development.

The Definitive Guide to Apache MyFaces and Facelets

The Definitive Guide to Apache MyFaces and Facelets is an ideal reference if you're looking to develop real–world applications with the open source lightweight Apache MyFaces and Dojo (the Ajax API). It focuses on aspects like scalability, design, optimization, and configurability. And it includes lucid code samples that reflect the pattern being described.

Practical API Design: Confessions of a Java™ Framework Architect

Practical API Design: Confessions of a Java Framework Architect will be required reading for all designers and engineers involved with the development, testing, and maintenance of APIs.

The Definitive Guide to Terracotta: Cluster the JVM for Spring, Hibernate and POJO Scalability

Terracotta CTO Ari Zilka and his team give you the ultimate guide on Terracotta Java application infrastructure, as well as user secrets, recipes, and prepackaged frameworks.

Spring Recipes: A Problem-Solution Approach

Spring Recipes: A Problem–Solution Approach focuses on the latest available Spring 2.x fundamentals that you require for building a three–tier Java EE application with web interface and database persistence. The topics of this book are introduced by complete and real–world code examples that you may follow step by step.

Beginning Groovy and Grails: From Novice to Professional

Beginning Groovy and Grails is the first introductory book on the Groovy language and its primary web framework, Grails. It gets you started with Groovy and Grails and culminates in the example and possible application of some real–world projects. You follow along with the development of each project, implementing and running each application while learning new features along the way.


Pro Java EE Spring Patterns: Best Practices and Design Strategies Implementing Java EE Patterns with the Spring Framework

Pro Java EE Spring Patterns focuses on enterprise patterns, best practices, design strategies, and proven solutions using key Java EE technologies including JSP™, servlets, EJB™, and JMS APIs. This Java EE patterns resource, catalog, and guide, with its patterns and numerous strategies, documents and promotes best practices for these technologies, implemented in a very pragmatic way using the Spring Framework and its counters.

Beginning Database Development in Java EE: Using GlassFish TopLink

Beginning Database Development in Java EE: Using GlassFish TopLink focuses on the open source TopLink persistence engine as a likely replacement for Hibernate long term. TopLink resides under the emerging official agile lightweight GlassFish application development framework and deployment platform project based on Java EE.

The Definitive Guide to SOA: Oracle Service Bus, Second Edition

The Definitive Guide to SOA: Oracle Service Bus, Second Edition is the first book to cover a practical approach to SOA using the BEA AquaLogic Service Bus tool. And it’s written from the “source”: BEA Systems AquaLogic product lead Jeff Davies.

Beginning Google Web Toolkit: From Novice to Professional

Learn to build rich, user–friendly web applications using a popular Java–based Ajax web framework, the Google Web Toolkit. The authors will guide you through the complete development of a GWT front end application with a no–nonsense, down–to–earth approach.

Thursday, July 31, 2008

[cobertura-instrument] WARN visitEnd, No line number information found for class

Have you seen this warning earlier? I have used cobertura for many years now, and while working on this demo was frequently seeing this warning. The cobertura-report was displaying N/A for Line and Branch coverage.

When I switched back to my Mac, things were working smoothly, when I moved back to my Windows Vista laptop on which I was preparing for the demo, I was getting the same warning and no coverage results.

I tried to run the target from ant with verbose on and it displayed the warning message saying:

[cobertura-instrument] WARN visitEnd, No line number information found for class com.stelligent.demo.CustomerInfo.
Perhaps you need to compile with debug=true?
[cobertura-instrument] WARN visitEnd, No line number information found for class com.stelligent.demo.StringToDate.
Perhaps you need to compile with debug=true?

Looked at the javac task at the Ant website, added a few more options and it worked like a charm. I have no clue why this happens on Vista, is it because I am using Java 6 here and Mc uses Java 5? Go figure.

The changes I added was as such for the javac task:

debug="true" debuglevel="vars,lines,source"

Wednesday, July 30, 2008

Windows Vista - Open Command Window Here

I have been working on Windows Vista machine to prepare for a demo which I was told needs Windows because the client was going to use Windows Live Meeting. So, no idea how to get this working on my Mac.

Anyway, each time I wanted to make sure my project works properly I had to open up a command window and go all the way to my project to run the build. This became frustrating and I looked at the "Windows Power Toys' and noticed that "Open Command Window Here" wouldn't work on Vista.

I accidentally was holding the shift key and also clicked the right mouse button, and viola magic happened. I was able to see the "Open Command Window Here" menu option with no additional downloads required.

Just click on this menu item and keep working. Isn't it neat. One nice thing about Vista.

P.S: I googled the same and found many had already blogged about the same as well. :)

Tuesday, July 29, 2008

Visual Documentation of Ant Dependencies in 3 Simple Steps

Last Friday, I wrote a blog entry at testearly.com about how to create visual representation of ant target dependencies using Grand and Vizant called "Visual Documentation of Ant Dependencies in 3 Simple Steps".

I was having trouble looking at build files generated automagically by one IDE. I like automation, but not which comes with magic. So, I tried using these two tools to generate the dot file and in turn open them using Graphviz. Graphviz is required to get the actual graph from this dot file which is generated by Grand and Vizant. Once you download and install Graphviz, you can run it as a standalone application and open these dot files generated as well.

Can you guess what IDE I was using? :)

Here is the link again for the blog at testearly:

1. Visual Documentation of Ant Dependencies in 3 simple steps.

Thursday, July 24, 2008

RESTful Web Services in 60 Seconds at Test Early

Just yesterday, I wrote a simple tutorial showing how easy it was to create, deploy and test RESTful web services using NetBeans IDE called "RESTful Web Services in 60 Seconds" at my company's blog Test Early.

I continued working on the same and was also able to quickly generate web services for the domain classes I had within my project. This was even more simple with all the CRUD services as well as relationships available in a few seconds as shown below:

Shown below is all the resource and converter classes generated by the IDE.

I was however disappointed that this same operation isn't available when you have a grails project. It would have been easier to right click on all your domain classes and say "generate REST web services" and it would create by default the REST Controller and the changes needed within the URLMappings.groovy class.

You can read all my blog entires at testearly.com here:
1. My entries

Sunday, June 29, 2008

Interesting Book: Persistence in the Enterprise

I received a copy of "Persistence in the Enterprise - A guide to Persistence technologies" book sometime back, I was so busy the last couple of weeks, I literally had no time to even look at the table of contents. Over the weekend, I finally decided it was time to do some justice to this book. So, here is a sneak peek of my review. A detailed review will be posted as always on Javalobby as well.

This book is mainly divided into two parts:

Part 1, "A Question of Persistence", helps the reader understand the many issues and trade-offs we normally face while choosing a persistence framework. This part has 4 chapters that cover the following:
Chapter 1 - A brief history of Object-Relational Mapping. This gives a brief history lesson of some popular relational database persistence mechanisms associated with a few object-oriented languages.

Chapter 2 - High Level Requirements and Persistence. As the name itself suggests, this chapter discusses IT requirements around your persistence framework that you should consider.

Chapter 3 - Designing Persistent Object Services. This chapter introduces the reader to some fundamentals and best practices of domain modeling. Also discusses some common strategies of mapping a domain model to a database with an example-driven approach.

Chapter 4 - Evaluating your Options. This chapter takes you through some best practices for conducting an evaluation based on an objective questionnaire, which is used as a template for comparison in part 2. The questionnaire is very comprehensive, and covers the following sections:
  • Background
  • Architectural Overview
  • Programming Model
  • ORM Features Supported
  • Tuning options
  • Development Process for the Common Example
Part 2, "Comparing Apples to Apples". This part has 6 chapters, the first five cover five frameworks using the approach and questionnaire discussed in chapter 4. The five frameworks covered in the next few chapters are
  • Chapter 5 JDBC
  • Chapter 6 Apache iBatis
  • Chapter 7 Hibernate Core
  • Chapter 8 Apache OpenJPA
  • Chapter 9 pureQuery and ProjectZero
Part 2 is finished with Chapter 10 which gives a summary that compares the mechanisms side by side and goes through a few scenarios in which one or the other best applies.

Appendix - Setting Up the Common Example. This section shows you how to set up and run the example for each persistence framework discussed. It has almost 30 pages, and has every detail and screen shots to get the examples working using Apache Derby as the database, Eclipse as the IDE, and JUnit and DbUnit as the testing frameworks.

Each and every chapter has a summary section, links to developerworks, and references which are really valuable.

If you have are using a home grown persistence framework, or considering writing one, or trying to move from one which you have been using, you should read this book before you venture into either one of those scenarios.

You can find the soft copy of the questionnaire at the link below:
Download the source code here:

Thursday, June 12, 2008

Chapter-wise review: The ThoughtWorks Anthology

The detailed chapter-wise review of the book "The ThoughtWorks Anthology" was published by Javalobby. If you are following TDD, or even planning to do so, this is a good book. There are some very good essays in this book. You can read the review here:

1. Javalobby

The essays which were very interesting and the ones I could apply immediately to my work were:
1. Object Calisthenics essay written by Jeff Bay
2. Consumer Driven Contracts: A Service Evolution Pattern by Ian Robinson
3. Refactoring Ant Build files by Julian Simpson
4. Single-Click Software Release by Dave Farley
5. Agile vs. Waterfall Testing for Enterprise Web Apps by Kristan Vingrys

Did you read this book? What are your thoughts?

Why do you need the latest version of Hudson?

It is hard to keep up with the latest version of Hudson, since they come-up with new releases at least 2-3 times a week. If you want to keep your plug-ins up-to date, you sure should get the latest version. With the latest 1.222 release of Hudson, installing or updating plug-ins is so easy. If you haven't been updating Hudson, this is the time to do so to the latest version which now by the way is 1.223.

Here are the steps to use the latest Hudson version:

1. Download the 1.223 version from here.
2. Stop Hudson and replace your hudson.war with the latest version.
3. Start Hudson, and go to dashboard and click on Manage Hudson which should bring a page like this:

4. Click on Manage Plugins, which will open up a new page as shown below:

5. Now, select the plugins you want to install and click the Install button which is all the way down on the right hand corner.

6. Restart Hudson, and you have the plug-ins installed.

Also, some other new features are useful as well as per the Hudson changelog:

a. "Hudson's own user database" can be now configured to prevent sign-up.
b. Administrator can now create user accounts for others (issue 1193)
c. Authentication failure now leaves the INFO log on Hudson server log.

Tuesday, June 10, 2008

Effective Java - A Must Read Book

After having finished the review for Java Power Tools, and having just submitted the review for "The Thoughtworks Anthology", I was planning on taking a small break from reviewing books.

Last week, I received an email from Addison-Wesley about their 4 new books. Out of those 4 books, Effective Java and Persistence in the Enterprise were the 2 books which interested me. Even before volunteering to review these books, I logged into safari and did read a few chapter links to see if it was worth all the time I was spending. The table of contents and the sample chapters did change my mind.

I just received these books yesterday, and already half way through the "Effective Java" book.
It is just unbelievable. The book is filled with pragmatic advice, plenty of samples, and is also very readable.

Stay tuned for the detailed review which will be published at Javalobby soon.

Monday, June 9, 2008

Hudson - Tips and Tricks

Hudson is an open source CI server that is by far the easiest one to configure. Second to ease of use is Hudson’s impressive plug-in framework, which makes it easy to add features. For instance, Hudson has a plug-in for tracking FindBugs issues, PMD issues, and CheckStyle issues over time as well as code coverage. It also trends test results from JUnit, as well as build results and corresponding execution times. In spite of all these cool features, we had to find ways to get around some common issues we faced at work using Hudson.

The article I wrote at my company's blog Test Early describes a few real-life tips and tricks that I have found at work and will assist in configuring Hudson to work most effectively in your environment as well:

  1. Changing Hudson home directory
  2. OutOfMemoryError
  3. Securing Hudson
  4. Hudson Views
  5. Hudson and Groovy
  6. Spaces in directory names
  7. Browser to use
If you are using Hudson, and need to know what these tips and tricks are check out the article at Test Early here.

Wednesday, May 28, 2008

Java Power Tools Book Review

Just yesterday, I finally finished reading and working out some of the samples from the Java Power Tools book. The detailed chapter wise review is now live at Javalobby.

I am really amazed at how many tools John has covered, and also with such great detail.

It took me a while to add just the links to all the 30 tools John has covered in my review. Each time I added a link, I kept wondering how much time John must have spent writing about each one of these. Awesome. I have such great admiration for John for providing us with such a wonderful book.

Even though the book is heavy, and has 910 pages, I carry it everyday to work. It is a great reference book for all the tools as well.

Also, with the help of this book, and only this book I was able to write my first simple and most simple project using Maven. Yes, you heard me right Maven. Had tried using Maven many times, and every sample I downloaded just failed complaining about some dependency which I wasn't even sure where it was being stored.

Tuesday, May 20, 2008

SoapUI, CI and Coverage

In the first two parts(part 1 and part 2) of this series we have seen how to use SoapUI to write functional tests for web services and also how to use Groovy for test setup, properties transfer, and assertions. As we have already said, tests should be integrated with your builds and should be able to be run with them. If you have automated your builds and they are running as part of your continuous integration (CI) setup, SoapUI comes in even handier: you can run the test suites and the test cases you created and, moreover, you can generate JUnit reports.

This part of the series guides you step-by-step through the Ant tasks for running tests written using SoapUI, generating JUnit reports, integrating with CI, and to top it all off getting code coverage using Cobertura. When you are done with this part, you will be able to reap the benefits of writing tests, continuous integration, and code coverage.

Read the complete article here at Javalobby.

Functional Web Services Testing Made Easy with SoapUI - Part 3

Tuesday, May 13, 2008

SoapUI's so Groovy

Functional Web Services Testing Made Easy with SoapUI - Part 2 is live at the at Javalobby. Part 1 of this series helped provide the background needed to begin exploring web services testing. We learned the basics of SoapUI and how easy it was to write functional tests without writing a single line of code. We also saw how to add assertions to these tests. What we will examine now is how to use Groovy within SoapUI for test setup, test teardown, response validation, and much, much more.

Take a look at your leisure, as always give me a yell in case you need to find out more.

Friday, May 9, 2008

Java Power Tools Finally Arrived

I came home today after work, exhausted sitting in the traffic for almost 2 hours. Opened the door, and to my surprise, I saw the Java Power Tools book waiting for me to be opened. The book is indeed heavy with almost 900 pages. This was one of the books I was waiting to read and review so badly.

I had interviewed John Ferguson Smart a long time back for Javalobby. From the day I did this interview, I was so enthusiastically waiting to read the book. I did glance over a few of the chapters, it is just unbelievable. With 30 tools being covered in this book, I will have to review this book in two parts.

I should mention that I did read the foreword first, since it is written by Andrew Glover, President of Stelligent. And that's where I work. :)

If you are writing software using Java, you should without a doubt get this book.

Stay tuned for the detailed review at Javalobby.

Tuesday, May 6, 2008

Functional Web Services Testing Made Easy with SoapUI - Part 1

I have written a detailed article at Javalobby which provides step by step instructions on how to write functional tests for your web services using SoapUI.

Here are the links where you can find the article on various Zones at Javalobby:
1. Java Zone
2. Architects Zone
3. SOA Zone

The next part in this article will cover SoapUI and Groovy.
Give me a yell if you need any help.

Wednesday, April 16, 2008

SoapUI and WebLogic Web Services

I am assisting one of our clients who is using WebLogic Web Services to test these web services using SoapUI. I have used SoapUI for almost 4 years and had never found this bug. So, here is what's happening:

The weblogic.webservice.GenericHandler is extended to do some security checks. Within this special Class, the handleRequest method is overridden as such:

public boolean handleRequest(MessageContext mc) {
SOAPMessageContext messageContext = (SOAPMessageContext) mc;
SOAPBody soapBody = messageContext.getMessage().getSOAPPart()
Iterator itBody = soapBody.getChildElements();
while (itBody.hasNext()) {
Object obj = itBody.next();
SOAPElement bodyElement = (SOAPElement) obj;
String name = bodyElement.getElementName().getLocalName();

The following line:
SOAPElement bodyElement = (SOAPElement) obj;

throws a ClassCastException, the stack trace is shown below:
java.lang.ClassCastException: weblogic.webservice.core.soap.SOAPTextElement
at weblogic.webservice.core.HandlerChainImpl.handleRequest(HandlerChainImpl.java:143)
at weblogic.webservice.core.DefaultOperation.process(DefaultOperation.java:549)
at weblogic.webservice.server.Dispatcher.process(Dispatcher.java:204)
at weblogic.webservice.server.Dispatcher.doDispatch(Dispatcher.java:176)
at weblogic.webservice.server.Dispatcher.dispatch(Dispatcher.java:96)
at weblogic.webservice.server.WebServiceManager.dispatch(WebServiceManager.java:100)
at weblogic.webservice.server.servlet.WebServiceServlet.serverSideInvoke(WebServiceServlet.java:297)
at weblogic.webservice.server.servlet.ServletBase.doPost(ServletBase.java:498)
at weblogic.webservice.server.servlet.WebServiceServlet.doPost(WebServiceServlet.java:267)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl$ServletInvocationAction.run(ServletStubImpl.java:1077)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:465)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:348)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:7047)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:3902)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:2773)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:224)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:183)

I did read in just one post that any default spaces in the request is converted
to a SoapTextElement.

If I add a simple guardian to check for
and skip the loop it works, but I know that's isn't the right solution.

If I create a simple Web Services Client using Axis(WSDL2Java),
I don't see the same exception.

Have you seen this, how did you fix this? Any ideas?
Here is the thread which I saw on bea web site.

1. bea site
And this one which I guess is related to Spring:

2. Spring site

Tuesday, March 25, 2008

Matrix-based security in Hudson doesn't work in IE

As I mentioned in my earlier posts, I have been using Hudson CI engine from the past 3 weeks. Pretty easy and cool as well. No complaints so far.

I started working on getting the standard security setup and am having problems doing the same. I am using the 1.195 version. In this version, once I select the Matrix-based security, I am unable to add users or group.

I did find a workaround wherein I can go and change the config.xml file and manually grant permissions to users. But, if I go back and make any other configuration changes and save, my security changes are lost.

Are you having these problems? How did you manage to secure Hudson? Any ideas?

P.S: After I posted this and searched a lot on the net and didn't find any reference, I was a bit surprised. Downloaded Hudson on my laptop, and was able to use the Matrix-based security. Once it worked on my laptop, I knew who the culprit was. It was IE, my laptop by default uses Firefox as the browser. Once I downloaded and installed Firefox as well on the desktop, I was able to add users and roles.

Monday, March 24, 2008

Joined Stelligent

Two weeks back, I joined Stelligent Incorporated as Senior Software Consultant. Having had many years of experience, it was time for a new challenge. I am really excited to work with Industry experts like Andrew Glover, Paul Julius, Paul Duvall and also learn a lot from them. :)

Saturday, March 22, 2008

Hudson's so Groovy

Having used Cruise Control for almost 4 years, when I started looking at Hudson last week, I was impressed seeing how easy it was to configure and get it up and running in just a few minutes. It also has several plugins available, and if you don't find one you can quickly write one as well.

Andrew Glover, in the TestEarly Blog, shows us how to use Groovy with Hudson. Hudson has a Groovy plug-in which can execute Groovy Scripts.

To quote from the blog "as a part of a CI project setup, another dependent
project’s directories were becoming read-only due to an SCM feature.
Consequently, a child project couldn’t write to the filesystem.

This problem was easily solved using Groovy (plus a little Ant)– a triggered build executes a small Groovy script that uses Ant’s chmod
task to make target directories read-write enabled. As you can see, the
fix requires 2 lines of code (which could, arguably, be reduced to one)"

def ant = new AntBuilder()
ant.chmod(dir:"./ci09_i/ui/rep2/reports/", perm:"ugo+rw",

You can read the complete story at TestEarly.com

Isn't that cool? However, I am not sure if there is a way to specify Hudson to run the Groovy Script first before executing any build script or vice versa, any ideas?

Here are some useful links for additional reading:

1. TestEarly.com

2. thediscoblog.com

Friday, February 1, 2008

Any idea when JBoss 5 will be out?

I have been using JBoss for years now, and it was one of those servers which was so easy to setup, and get it running in a few minutes. Above all the deployment was so easy, copy and paste your ear/war in the deploy directory and you are done. Anything I wanted to learn, the first app server I used to choose was JBoss. I guess many developers agree with me on this, when you had to do something in J2EE world, the first thing anyone would try was JBoss.

I am not sure JBoss is dependable anymore. Especially with the current version JBoss 5. I know it's still in beta, but it has been there since 2006. Even the latest JBoss 5.0.0 Beta3 has many problems; especially with Java 6.

With all the problems with JBoss and having no clear cut idea when the final release is due, I had to look for other options. I am glad I did, and found Oracle and GlassFish working with just no problems at all.

When I did an interview with the authors of the book "JBoss in Action", they did mention that all the features in JBoss 5 were already available in later versions of JBoss 4.

You can read the entire interview here.

To quote from the interview:
Javid : The difficult thing about putting out a book is that it starts getting outdated even before it is published (it takes 3-4 months to go through editing / printing). By the time the book is released, JBoss AS 5 should be available. By the time an organization starts standardizing on it, they'll probably have a patch or two released. In all honesty, it *is* a bit of guesswork. But, the reason we feel confident making the recommendation is that many of the technologies that will be available in JBoss AS 5 are already running in the latest versions of JBoss 4 , or as independent applications. The problems that will likely arise with these technologies in JBoss AS 5 are likely to be integration issues, which will hopefully get resolved fairly quickly.

Peter : Many of the technologies that will appear in JBoss Application Server 5.0 are already available in other versions. EJB3, the JBoss Web Server which is based on the Tomcat and the Apache Portable Runtime, and JAX-WS based web services using JBoss Web Services are already available in 4.2. JBoss Messaging can be added to 4.2. So once 5.0 comes out, many of its components will have already been tested. And because 5.0 will be Java EE 5 certified, I expect that it will generate a lot of interest from the community.

When most of the features have been already tested on earlier versions, of course not on Java 6, what's the delay?

In spite of finding alternate solutions, I still would like to use JBoss 5. I guess old habits don't go away easily right?

What are your thoughts?
Any ideas if we are going to get the final version in 2008 soon?

Book Review: Windows Vista Annoyances

I posted the review for the book "Windows Vista Annoyances" yesterday on IT Book Zone. Having purchased a new Vista laptop for my daughter, this book was timely.

In the "How To Use This Book" section, the author says "Windows Vista Annoyances" is not documentation; you can get that anywhere. Rather, it's a unique and thorough collection of solutions, hacks and time-saving tips to help you get the most from your PC". That's exactly what you will get from reading this book.

Anyone having a Windows Vista PC will find this invaluable for its tips, solutions and hacks. You will also find plenty of information on setup, installation, upgrade from other Windows versions, security features, performance, troubleshooting, and many more.

David Karp, has given us a unique guide which not only discusses the annoyances of Vista and workarounds for the same, but this book also helps you improve your experience with Windows Vista.

To read the review, chapter wise you can take a look at the review on IT Book Zone.

  1. Windows Vista Annoyances on IT Book Zone

Tuesday, January 29, 2008

Issues with SOAP address location in EJB 3.0

I am deploying my EJB 3.0 application on 3 servers for right now; JBoss, GlassFish and Oracle Application Server.
I have a simple Stateless Session Bean with the appropriate WebService annotations.
When I deploy my application to these 3 servers, each one has a different WSDL URL.

The name and serviceName are as specified in the @WebService annotation.

@WebService(name="HelloManager", serviceName = "HelloManagerService", targetNamespace = "urn:HelloManagerService")

There is however some consistency between JBoss and Oracle. They use the following notation:

soap:address location="http://hostname:portname/earfilename/name"

For e.g:
soap:address location="http://localhost:8080/ejb3webservices/HelloManager"

GlassFish on the other hand, uses the following notation:

soap:address location="http://hostname:portname/servicename/name"

For e.g:
soap:address location="http://localhost:8484/HelloManagerService/HelloManager"

I am trying to use SOAP UI to test my web services once they are deployed using Ant.

I didn't see any reference in the EJB 3.0 spec regarding the WSDL location. Is this vendor specific? Is there any place where we can customize the WSDL?

Also, I don't see any configurable attribute in the documentation for the @WebService annotation.

Saturday, January 26, 2008

Several Exciting New Books For Web Developers

I was preparing my draft for interviewing some of the authors for Manning as well as Apress, and browsing their web sites for updates. There are several new books for web developers which have been published recently or coming soon.

The following 2 books are being published by Manning and the print edition will be available in a few days.

1. Laszlo in Action by Norman Klein and Max Carlson with Glenn MacEwen

2. jQuery in Action by Bear Bibeault and Yehuda Katz

The 3rd book from Apress is on Struts 2

3. Practical Apache Struts 2 Web 2.0 Projects by Ian Roughley

Have you read any of these books? Are you planning on buying these?

Friday, January 25, 2008

The SpringSource Certification Program Announced

For those of us who have been working on Spring for many years now, we have a wonderful opportunity to take this exam. So, who can write the Exam is a big question since they do have some requirements and they are as follows:
Quote from SpringSource:
Eligible individuals can register to take the Spring Framework Professional certification examination, via the web, at one of over 4500 world-wide testing facilities, and can begin taking the exam on 31 January 2008. A person is eligible for registration if he or she has recently taken the 4-day “CoreSpring” class from SpringSource (or a SpringSource certified training partner in Europe, Africa or the MiddleEast (EMEA)). A person may also be eligible for registration, without attending the 4-day course, if he or she can demonstrate having significantly contributed to the Spring community or can provide a reference to a Spring development effort in which he or she was actively involved. This person is referred to as a “grandfathered” candidate.

I did contact Daryl Heinz Director of Training for SpringSource, Inc. with just one question. Please explain how we can provide a reference to show that we are using Spring in our Development?

Daryl replied back immediately with all the details. We just need to provide the contact information of our Manager so that SpringSource will be able to validate that we indeed have experience using Spring.

You can find all the details about the Certification here:

1. SpringSource Certification Program

I am really excited to take this Exam, how about you?

Wednesday, January 23, 2008

New features in EJB 3.1 : Article on ServerSide.com

Reza Rahman, co-author of the book "EJB3 in Action", has an article in TheServerSide.com which gives a preview of the next version of Java EE spec EJB 3.1.

You can read the article here:
1. New features in 3.1

The ones I am interested are:

1. Support for stateful web services via Stateful Session Bean web service endpoints.
2. The standardization of JNDI mapping. I had to workaround a solution for testing on 3 different application servers, JBoss, Oracle and GlassFish. Each of them have completely different naming convention for the Remote Interfaces.

The GlassFish AS uses the fully qualified name of the remote business interface as default.
Object obj = initialContext.lookup("com.os.ent.CustomerManagerRemote");

JBoss on the other hand uses the Application Name, followed by the EJB name and followed by /remoteconstant.
Object obj = initialContext.lookup("ejb3sampleapp/CustomerManager/remote");

Oracle, uses the name specified in the @Stateless annotation.
Object obj = initialContext.lookup("CustomerManager");

What new features are you looking forward in the coming version?

Friday, January 18, 2008

Which one do you prefer; Liferay or JBoss Portal?

The book "JBoss in Action" has 2 chapters dedicated to JBoss Portal.The book covers JBoss Portal 2.6.1 running in JBoss Application Server 4.2.1. I haven't yet downloaded and tried this version.

But, I had tried Liferay 4.0 and JBoss 2.4 in early 2007 at work. We found Liferay more user friendly than JBoss; especially while using the Management Portlet. We finally scraped the idea of using Portals since there was indeed a huge learning curve.

Both of these complies with JSR 168.

With several releases from both these vendors, I am curious to know which one you would prefer.

Liferay or JBoss, which one are you using?

Thanks to all those who commenetd. The links you added(and the ones I added) were not displayed properly. So, I have added them here as well for your convenience.
1. InfoWorld - Comparision of Liferay and JBoss portal
2. JBoss Portal Presentation
3. Creating new Themes in Liferay

Friday, January 4, 2008

Error in OC4J Version Ant Tasks

I have been trying to write Ant tasks to deploy, undeploy applications as well as create,delete and test data sources and connection pools using OC4J for Oracle Application Server.

The deployment and undeployment went smoothly with no problems at all.

But, once I started working on Data Sources and connection factories, I started getting errors like the following:

Problem: failed to create task or type antlib:oracle:testDataSourceConnectionPool
Cause: The name is undefined.
Action: Check the spelling.
Action: Check that any custom tasks/types have been declared.
Action: Check that any / declarations have taken place.

This appears to be an antlib declaration.

You will not find any documentation at all since these tasks are not in the Documentation. I looked at many samples provided and all of them had the old tasks. I finally looked at the Ant jar file and was able to find the correct task names.

The task addDataSourceConnectionPool was replaced with createJDBCConnectionPool, addManagedDataSource with createManagedDataSource, and testDataSourceConnectionPool with testConnectionPool.

I am not sure about other tasks, but these are the ones which I changed to get my build files working and happy.

You can find detailed documentation for OC4J Ant Tasks here.