Thanks guys for the response. I figured out the problem. The issue is
OSGI has a concept of the framework bundle and by default it only
exports the java.*, javax.* packages. It doesn't export the sun.*
packages. So when user invoke the client application using hector it
needs to pass -Dorg.osgi.framework.bootdelegation=* and then the
framework bundle will export all the classes.
To understand more on the OSGI and details please look at the
following blogs.
http://blog.springsource.com/2009/01/19/exposing-the-boot-classpath-in-osgi/
I think it will be very valuable to have hector as a part of the osgi
spring source repository so that it can be used easily in the OSGI
Container.