java.lang.annotation.IncompleteAnnotationException: javax.xml.bind.annotation.XmlSchemaType missing element name

Hi

The use case happened when i was trying to generate the java files from the wsdl using the CXF codegen maven plugin. The generated code  started failing with the above exception when tried to invoke via Eclipse.

Note : the same wsdl worked in Soap UI. The generated code in SOAP UI using the WSIMPORT tool also worked.

So the issue i figures out is related to the Jaxb in the project. So what i did is upgraded the Jaxb to this version

                 <dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>2.2</version>
</dependency>

It all started working. So this has something to do with the internal element generation of Jaxb and what happens is when a latest version is not found falls back to the jaxb version embedded in SDK leading to that error.

Now i dont have a proof for that just an educated guess. :)

Comments

Popular posts from this blog

'jasypt.encryptor.password' or one of ['jasypt.encryptor.privateKeyString', 'jasypt.encryptor.privateKeyLocation'] must be provided for Password-based or Asymmetric encryption

Field or property 'jobParameters' cannot be found on object of type 'org.springframework.beans.factory.config.BeanExpressionContext' - Spring Batch

Couldn't store job: Unable to serialize JobDataMap for insertion into database because the value of property 'jobLauncher' is not serializable