You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Matthias Gommeringer <ma...@web.de> on 2006/09/12 12:39:51 UTC

[Axis2] Problem with CodeGenerator in Eclipse

Hello everyone,

I am trying to generate the java classes from a WSDL and Schema that I 
have written by hand. When I click on "Finish" in the last step of the 
Codegen Wizard, the following message pops up:

An error occured while code generating java.lang.InterruptedException:
org.apache.axis2.wsdl.codegen.CodeGenerationException:
java.lang.RuntimeException: WSDL writing failed!


Then I inspected my WSDL (because I was pretty sure that something must 
be wrong there) and found that I declared a namespace in a wrong way 
(which means that the WSDL was invalid). My mistake was that I defined

   xmlns:xsd="http://www.w3.org/2001/XMLSchema/"

in the "wsdl:definitions" tag instead of

   xmlns:xsd="http://www.w3.org/2001/XMLSchema"

After having fixed this problem, the code generation succeeded.

I'd like to know if you have plans to validate whether the preconditions 
for a successful code generation are satisfied when a WSDL file is 
selected by the user (just for dumb users like me :-) An error message 
that shows the real problem would be really helpful.

Thanks and regards,
Matthias


---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: [Axis2] Problem with CodeGenerator in Eclipse

Posted by Anne Thomas Manes <at...@gmail.com>.
Matthias,

Declaring the namespace at a higher level is not an error. And if that
is in fact the reason that the execution occurred, then it's a bug in
the code generator.

Note that the Eclipse wizard is based on Axis2 1.0 and there are lots
of bugs in 1.0. You'll do much better using the command line tool from
the latest nightly.

Anne

On 9/12/06, Matthias Gommeringer <ma...@web.de> wrote:
> Hello everyone,
>
> I am trying to generate the java classes from a WSDL and Schema that I
> have written by hand. When I click on "Finish" in the last step of the
> Codegen Wizard, the following message pops up:
>
> An error occured while code generating java.lang.InterruptedException:
> org.apache.axis2.wsdl.codegen.CodeGenerationException:
> java.lang.RuntimeException: WSDL writing failed!
>
>
> Then I inspected my WSDL (because I was pretty sure that something must
> be wrong there) and found that I declared a namespace in a wrong way
> (which means that the WSDL was invalid). My mistake was that I defined
>
>    xmlns:xsd="http://www.w3.org/2001/XMLSchema/"
>
> in the "wsdl:definitions" tag instead of
>
>    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>
> After having fixed this problem, the code generation succeeded.
>
> I'd like to know if you have plans to validate whether the preconditions
> for a successful code generation are satisfied when a WSDL file is
> selected by the user (just for dumb users like me :-) An error message
> that shows the real problem would be really helpful.
>
> Thanks and regards,
> Matthias
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org