Today i had a little issue consuming a web service with Apache CXF. Normally it is very straightforwarding, you use the wsdl2java console tool and voila you have the classes you need.
But not today, CXF didn't like the wsdl definition and throw a little error:
WSDLToJava Error: Thrown by JAXB : A class/interface with the same name "*************" is already in use. Use a class customization to resolve this conflict.
So then i started looking a Customizing JAXB Bindings because the error suggested that. I wasn't that happy, i didn't wanted to spend a while unterstanding the inside and out of those bindings.
Reading a bit more about the flags and options of wsdl2java i found this very nice option called autoNameResolution which in the documentation had the following explanation.
-autoNameResolution (Automatically resolve naming conflicts without requiring the use of binding customizations)
I also added an error description and solution in devblood: Read Here.
Additionally i added an issue to the CXF Project, they could mention the autoNameResolution option in their message error, i think it would be of great help for some people out there.
You can check out the issue here.
Happy Coding.
Klaus Stefan Gerber
Bangkok, Thailand
Friday, January 1, 2010
Hello World!
Well i'm a programmer... i started with this hobby a long time ago and it has been a very long journey... it never stops... technology evolves and you keep learning new things.
Somehow i avoided the latest technology in the form of blogs or web 2.0, but i decided the moment has come and i should share my personal journey with others... some will be interested some will be not... this is my little corner in the internet, where i will posts things related to my hobby... which by mere coincidence it also what i do every day at work... ;)
Here it goes... my first code written in blogger...
Best Wishes for Everybody....
Klaus Stefan Gerber
Bangkok, Thailand
Somehow i avoided the latest technology in the form of blogs or web 2.0, but i decided the moment has come and i should share my personal journey with others... some will be interested some will be not... this is my little corner in the internet, where i will posts things related to my hobby... which by mere coincidence it also what i do every day at work... ;)
Here it goes... my first code written in blogger...
- Hello World
Best Wishes for Everybody....
Klaus Stefan Gerber
Bangkok, Thailand
Subscribe to:
Posts (Atom)