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 Bram Biesbrouck <b...@beligum.org> on 2006/01/12 15:15:01 UTC

[Axis2-0.94] Skeleton changes

Hi all,

Could sombody write some sample code to use the generated Request/Response 
xsd-classes of Axis2 0.94, since I don't see any Factory-classes anymore...
Btw, the API looks much cleaner now, thanks !

Bram

Re: [Axis2] Converting from XmlObject to OMElement

Posted by Davanum Srinivas <da...@gmail.com>.
Ruben,

Please log a bug with your code, we will try with latest SVN to see if
it has problems and try to fix it.

thanks,
dims

On 1/19/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
>    I forgot to attach the stacktrace:
>
>
> org.apache.axis2.om.OMException
>         at org.apache.axis2.om.impl.llom.builder.StAXOMBuilder.next(StAXOMBuilder.java:273)
>         at org.apache.axis2.om.impl.llom.OMDocumentImpl.getOMDocumentElement(OMDocumentImpl.java:109)
>         at org.apache.axis2.om.impl.llom.builder.StAXOMBuilder.getDocumentElement(StAXOMBuilder.java:289)
>         at org.objectweb.ResponseHandlerPortTypeStub.toOM(ResponseHandlerPortTypeStub.java:162)
>         at org.objectweb.ResponseHandlerPortTypeStub.toEnvelope(ResponseHandlerPortTypeStub.java:176)
>         at org.objectweb.ResponseHandlerPortTypeStub.contents(ResponseHandlerPortTypeStub.java:102)
>         at org.objectweb.ResponseHandlerTest.main(ResponseHandlerTest.java:31)
>
>    I really need help. I need to insert that info, but I can't... Any work around at least?
>
>    Thanks,
>
>      Ruben
>
>
> On Wednesday 18 January 2006 18:30, Rubén Naranjo Izquierdo wrote:
> >    Hi all,
> >
> >    I need to insert some information in SOAP Header field. In fact I need
> > to insert a class created by wsdl2java which extends
> > org.apache.xmlbeans.XmlObject. To do so I try the next on my PortType's
> > stub:
> >
> > (...)
> > SOAPHeaderBlock headBlock = envelope.getHeader().addHeaderBlock(...);
> > headBlock.addChild(toOM(myType))
> > (...)
> >
> > private OMElement toOM(XmlObject param) {
> >       StAXOMBuilder builder = new
> > StAXOMBuilder(OMAbstractFactory.getOMFactory(), new
> > StreamWrapper(param.newXMLStreamReader()));
> >       OMElement documentElement = builder.getDocumentElement();
> >       ((OMNodeEx) documentElement).setParent(null);
> >       return documentElement;
> > }
> >
> >    Depending on the class I use when calling "toOM", I get a
> > "java.lang.IllegalStateException", an "org.apache.axis2.om.OMException", or
> > just works fine (as you may suppose, it works fine with the classes I don't
> > need)
> >
> >    What am I doing wrong? Is that the correct way to convert from XmlObject
> > to OMElement?
> >
> >    Thank you in advance,
> >
> >      Rubén
>


--
Davanum Srinivas : http://wso2.com/blogs/

Re: [Axis2] Converting from XmlObject to OMElement

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
   I forgot to attach the stacktrace:


org.apache.axis2.om.OMException
	at org.apache.axis2.om.impl.llom.builder.StAXOMBuilder.next(StAXOMBuilder.java:273)
	at org.apache.axis2.om.impl.llom.OMDocumentImpl.getOMDocumentElement(OMDocumentImpl.java:109)
	at org.apache.axis2.om.impl.llom.builder.StAXOMBuilder.getDocumentElement(StAXOMBuilder.java:289)
	at org.objectweb.ResponseHandlerPortTypeStub.toOM(ResponseHandlerPortTypeStub.java:162)
	at org.objectweb.ResponseHandlerPortTypeStub.toEnvelope(ResponseHandlerPortTypeStub.java:176)
	at org.objectweb.ResponseHandlerPortTypeStub.contents(ResponseHandlerPortTypeStub.java:102)
	at org.objectweb.ResponseHandlerTest.main(ResponseHandlerTest.java:31)

   I really need help. I need to insert that info, but I can't... Any work around at least?

   Thanks,

     Ruben


On Wednesday 18 January 2006 18:30, Rubén Naranjo Izquierdo wrote:
>    Hi all,
>
>    I need to insert some information in SOAP Header field. In fact I need
> to insert a class created by wsdl2java which extends
> org.apache.xmlbeans.XmlObject. To do so I try the next on my PortType's
> stub:
>
> (...)
> SOAPHeaderBlock headBlock = envelope.getHeader().addHeaderBlock(...);
> headBlock.addChild(toOM(myType))
> (...)
>
> private OMElement toOM(XmlObject param) {
> 	StAXOMBuilder builder = new
> StAXOMBuilder(OMAbstractFactory.getOMFactory(), new
> StreamWrapper(param.newXMLStreamReader()));
> 	OMElement documentElement = builder.getDocumentElement();
> 	((OMNodeEx) documentElement).setParent(null);
> 	return documentElement;
> }
>
>    Depending on the class I use when calling "toOM", I get a
> "java.lang.IllegalStateException", an "org.apache.axis2.om.OMException", or
> just works fine (as you may suppose, it works fine with the classes I don't
> need)
>
>    What am I doing wrong? Is that the correct way to convert from XmlObject
> to OMElement?
>
>    Thank you in advance,
>
>      Rubén

[Axis2] Converting from XmlObject to OMElement

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
   Hi all,

   I need to insert some information in SOAP Header field. In fact I need to 
insert a class created by wsdl2java which extends 
org.apache.xmlbeans.XmlObject. To do so I try the next on my PortType's stub:

(...)
SOAPHeaderBlock headBlock = envelope.getHeader().addHeaderBlock(...);
headBlock.addChild(toOM(myType))
(...)

private OMElement toOM(XmlObject param) {
	StAXOMBuilder builder = new StAXOMBuilder(OMAbstractFactory.getOMFactory(), 
new StreamWrapper(param.newXMLStreamReader()));
	OMElement documentElement = builder.getDocumentElement();
	((OMNodeEx) documentElement).setParent(null);
	return documentElement;
}

   Depending on the class I use when calling "toOM", I get a 
"java.lang.IllegalStateException", an "org.apache.axis2.om.OMException", or 
just works fine (as you may suppose, it works fine with the classes I don't 
need)

   What am I doing wrong? Is that the correct way to convert from XmlObject to 
OMElement?

   Thank you in advance,

     Rubén

Re: [Axis2-0.94] wsdl2java -N option

Posted by Ajith Ranabahu <aj...@gmail.com>.
Hi Ruben,
Well we  are planning to do this enhancement in the near future but it has
not been done yet. sadly there's no workaround at the moment.

On 1/18/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
>
>    Hi all,
>
>    I've been looking at the Axis2-0.94's wsdl2java documentation and I
> can't
> find any option similar to Axis1's -N, which maps a namespace to a
> concrete
> package.
>
>    Is there any way of getting a similar behaviour in Axis2? If I just
> change
> the package name and update all references in generated code, I get
> ClassCastExceptions when invoking to Factorys (surely because of the
> classes
> generated in the "resources/schemaorg_apache_xmlbeans/system" folder).
>
>    There is a particular reason why this option hasn't been implemented?
>
>    Thank you in advance,
>
>      Rubén.
>



--
Ajith Ranabahu

[Axis2-0.94] wsdl2java -N option

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
   Hi all,

   I've been looking at the Axis2-0.94's wsdl2java documentation and I can't 
find any option similar to Axis1's -N, which maps a namespace to a concrete 
package.

   Is there any way of getting a similar behaviour in Axis2? If I just change 
the package name and update all references in generated code, I get 
ClassCastExceptions when invoking to Factorys (surely because of the classes 
generated in the "resources/schemaorg_apache_xmlbeans/system" folder).

   There is a particular reason why this option hasn't been implemented? 

   Thank you in advance,

     Rubén.

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
   Sorry for taking so long to answer! I modified the .sh file changing "%1 
%2..." for "%*", and wsdl2java worked as expected. "-p" and "-pn" options 
work at last. 

  I also tried invoking java directly on the wsdl2java class 
(org.apache.axis2.wsdl.WSDL2Java) and it worked in the same way that the 
modified (%*) script.

  Thanks for your help,

        Ruben.

On Friday 13 January 2006 18:37, Davanum Srinivas wrote:
> hmm, we should switch to "%*" instead of listing "%1 %2..."
>
> Ruben can u please try editing the bat file and do that?
>
> thanks,
> -- dims
>
> On 1/13/06, Ajith Ranabahu <aj...@gmail.com> wrote:
> > Hi,
> >  This is not really a bug in the codegen but in the script. If you have a
> > look at the shell script you'll see that it takes only the first 9
> > arguments and not the rest! Same issue is with the bat file.
> >
> > On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
> > > Rubén,
> > >
> > > Please log a jira issue and upload your wsdl.
> > >
> > > thanks,
> > > dims
> > >
> > > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es> wrote:
> > > >   Hi all,
> > > >
> > > >   I've been using Axis2-0.94 wsdl2java this last two days and I've
> >
> > realized that "-p" and "-pn" options have no efect when compiling my
> > wsdl. I mean, they have no effect.
> >
> > > >   But the real weird thing comes when I change the order of the
> >
> > parameters in wsdl2java call. With the following call:
> > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d
> >
> > xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn
> > MySecondPortType
> >
> > > >   I get the code generated (in default package) and this output:
> > > >
> > > > Warning - Multiple endpoints found - picking the first endpoint!
> > > >
> > > >
> > > >   But with the following call (note that is the same call, but with
> > > > the
> >
> > parameters's order canged):
> > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o $HOME/project/
> > > > -p
> >
> > org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> > MySecondPortType
> >
> > > >  I get the following exception with no code generated:
> > > >
> > > > Exception in thread "main"
> >
> > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > java.lang.RuntimeException :
> > java.lang.IllegalArgumentException: Local part not allowed
> > to be null
> >
> > > >         at
> >
> > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGeneratio
> >nEngine.java:118)
> >
> > > >         at org.apache.axis2.wsdl.WSDL2Code.main
> >
> > (WSDL2Code.java:31)
> >
> > > >         at
> >
> > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> >
> > > > Caused by: java.lang.RuntimeException:
> >
> > java.lang.IllegalArgumentException: Local part not allowed
> > to be null
> >
> > > >         at
> >
> > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDB
> >Extension.java:152)
> >
> > > >         at
> >
> > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGeneratio
> >nEngine.java:80)
> >
> > > >         ... 2 more
> > > > Caused by: java.lang.IllegalArgumentException: Local
> >
> > part not allowed to be null
> >
> > > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > > >         at
> >
> > org.apache.ws.commons.schema.XmlSchemaType.getQName(XmlSchemaType.java:91
> >)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.ja
> >va:1496)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleSequence(SchemaBuilder.j
> >ava:979)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension(
> >SchemaBuilder.java:895)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> > (SchemaBuilder.java:684)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(SchemaBuilde
> >r.java:592)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.ja
> >va
> >
> > :1501)
> > :
> > > >         at
> >
> > org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(SchemaB
> >uilder.java:107)
> >
> > > >         at
> >
> > org.apache.ws.commons.schema.XmlSchemaCollection.read(XmlSchemaCollection
> >.java:233)
> >
> > > >         at
> >
> > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDB
> >Extension.java:86)
> >
> > > >         ... 3 more
> > >
> > > --
> > > Davanum Srinivas : http://wso2.com/blogs/
> >
> > --
> > Ajith Ranabahu
>
> --
> Davanum Srinivas : http://wso2.com/blogs/

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Davanum Srinivas <da...@gmail.com>.
i fixed it in SVN yesterday, we will use AXIS2_HOME from now on.

On 1/13/06, Dong Liu <ed...@gmail.com> wrote:
> I agree.
>
> However, in my cases, I have both axis 1 and axis2 installed. AXIS_HOME is
> already defined for axis 1, and I had to change the tool .bat files when I
> wanted to use them.
>
> Cheers,
>
> Don
>
>
>  On 1/13/06, Ajith Ranabahu <aj...@gmail.com> wrote:
> > Hi Dong,all
> > My guess is users would find a bat/sh script very useful if they want to
> get into business directly. take the tomcat example. There's nothing to do
> other than dbl clicking the bat file (or the sh equivalent) to start the
> tomcat server (which I, as a user, find very useful and convenient)
> > We need to provide similar experience to Axis2 users as well.
> >
> >
> >
> > On 1/13/06, Dong Liu < edongliu@gmail.com> wrote:
> > > The same idea is appliable to testing all the samples instead supply the
> .bat and .sh scripts.
> > >
> > > Don
> > >
> > >
> > >
> > >
> > > On 1/13/06, Dong Liu < edongliu@gmail.com> wrote:
> > > > I still think it is better to supply a document to suggest the user to
> create proper classpath definitions in their systems. And run the utils by
> calling the class directly. What do you think?
> > > >
> > > > Cheers,
> > > >
> > > > Don
> > > >
> > > >
> > > >
> > > > On 1/13/06, Davanum Srinivas <davanum@gmail.com > wrote:
> > > > > hmm, we should switch to "%*" instead of listing "%1 %2..."
> > > > >
> > > > > Ruben can u please try editing the bat file and do that?
> > > > >
> > > > > thanks,
> > > > > -- dims
> > > > >
> > > > > On 1/13/06, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > > > > > Hi,
> > > > > >  This is not really a bug in the codegen but in the script. If you
> have a
> > > > > > look at the shell script you'll see that it takes only the first 9
> arguments
> > > > > > and not the rest! Same issue is with the bat file.
> > > > > >
> > > > > >
> > > > > > On 1/13/06, Davanum Srinivas <davanum@gmail.com > wrote:
> > > > > > > Rubén,
> > > > > > >
> > > > > > > Please log a jira issue and upload your wsdl.
> > > > > > >
> > > > > > > thanks,
> > > > > > > dims
> > > > > > >
> > > > > > > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es>
> wrote:
> > > > > > > >   Hi all,
> > > > > > > >
> > > > > > > >   I've been using Axis2-0.94 wsdl2java this last two days and
> I've
> > > > > > realized that "-p" and "-pn" options have no efect when compiling
> my wsdl. I
> > > > > > mean, they have no effect.
> > > > > > > >
> > > > > > > >   But the real weird thing comes when I change the order of
> the
> > > > > > parameters in wsdl2java call. With the following call:
> > > > > > > >
> > > > > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t
> -d
> > > > > > xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService
> -pn
> > > > > > MySecondPortType
> > > > > > > >
> > > > > > > >   I get the code generated (in default package) and this
> output:
> > > > > > > >
> > > > > > > > Warning - Multiple endpoints found - picking the first
> endpoint!
> > > > > > > >
> > > > > > > >
> > > > > > > >   But with the following call (note that is the same call, but
> with the
> > > > > > parameters's order canged):
> > > > > > > >
> > > > > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o
> $HOME/project/ -p
> > > > > > org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> > > > > > MySecondPortType
> > > > > > > >
> > > > > > > >  I get the following exception with no code generated:
> > > > > > > >
> > > > > > > > Exception in thread "main"
> > > > > >
> org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > > > > > java.lang.RuntimeException :
> > > > > > java.lang.IllegalArgumentException: Local part
> not allowed
> > > > > > to be null
> > > > > > > >         at
> > > > > >
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:118)
> > > > > > > >         at
> org.apache.axis2.wsdl.WSDL2Code.main
> > > > > > (WSDL2Code.java:31)
> > > > > > > >         at
> > > > > >
> org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > > > > > > > Caused by: java.lang.RuntimeException:
> > > > > > java.lang.IllegalArgumentException: Local part
> not allowed
> > > > > > to be null
> > > > > > > >         at
> > > > > >
> org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:152)
> > > > > > > >         at
> > > > > >
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:80)
> > > > > > > >         ... 2 more
> > > > > > > > Caused by:
> java.lang.IllegalArgumentException: Local
> > > > > > part not allowed to be null
> > > > > > > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > > > > > > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.XmlSchemaType.getQName
> (XmlSchemaType.java:91)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java:1496)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleSequence
> (SchemaBuilder.java:979)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension(SchemaBuilder.java:895)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> > > > > > (SchemaBuilder.java:684)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(SchemaBuilder.java:592)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleElement
> (SchemaBuilder.java
> > > > > > :1501)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(SchemaBuilder.java:107)
> > > > > > > >         at
> > > > > >
> org.apache.ws.commons.schema.XmlSchemaCollection.read
> (XmlSchemaCollection.java:233)
> > > > > > > >         at
> > > > > >
> org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:86)
> > > > > > > >         ... 3 more
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > > > --
> > > > > > > Davanum Srinivas : http://wso2.com/blogs/
> > > > > > >
> > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Ajith Ranabahu
> > > > >
> > > > >
> > > > > --
> > > > > Davanum Srinivas : http://wso2.com/blogs/
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
> >
> > --
> > Ajith Ranabahu
>
>


--
Davanum Srinivas : http://wso2.com/blogs/

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Dong Liu <ed...@gmail.com>.
I agree.

However, in my cases, I have both axis 1 and axis2 installed. AXIS_HOME is
already defined for axis 1, and I had to change the tool .bat files when I
wanted to use them.

Cheers,

Don

On 1/13/06, Ajith Ranabahu <aj...@gmail.com> wrote:
>
> Hi Dong,all
> My guess is users would find a bat/sh script very useful if they want to
> get into business directly. take the tomcat example. There's nothing to do
> other than dbl clicking the bat file (or the sh equivalent) to start the
> tomcat server (which I, as a user, find very useful and convenient)
> We need to provide similar experience to Axis2 users as well.
>
> On 1/13/06, Dong Liu <ed...@gmail.com> wrote:
> >
> > The same idea is appliable to testing all the samples instead supply the
> > .bat and .sh scripts.
> >
> > Don
> >
> >
> > On 1/13/06, Dong Liu < edongliu@gmail.com> wrote:
> > >
> > > I still think it is better to supply a document to suggest the user to
> > > create proper classpath definitions in their systems. And run the utils by
> > > calling the class directly. What do you think?
> > >
> > > Cheers,
> > >
> > > Don
> > >
> > > On 1/13/06, Davanum Srinivas <davanum@gmail.com > wrote:
> > > >
> > > > hmm, we should switch to "%*" instead of listing "%1 %2..."
> > > >
> > > > Ruben can u please try editing the bat file and do that?
> > > >
> > > > thanks,
> > > > -- dims
> > > >
> > > > On 1/13/06, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > > > > Hi,
> > > > >  This is not really a bug in the codegen but in the script. If you
> > > > have a
> > > > > look at the shell script you'll see that it takes only the first 9
> > > > arguments
> > > > > and not the rest! Same issue is with the bat file.
> > > > >
> > > > >
> > > > > On 1/13/06, Davanum Srinivas <davanum@gmail.com > wrote:
> > > > > > Rubén,
> > > > > >
> > > > > > Please log a jira issue and upload your wsdl.
> > > > > >
> > > > > > thanks,
> > > > > > dims
> > > > > >
> > > > > > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es>
> > > > wrote:
> > > > > > >   Hi all,
> > > > > > >
> > > > > > >   I've been using Axis2-0.94 wsdl2java this last two days and
> > > > I've
> > > > > realized that "-p" and "-pn" options have no efect when compiling
> > > > my wsdl. I
> > > > > mean, they have no effect.
> > > > > > >
> > > > > > >   But the real weird thing comes when I change the order of
> > > > the
> > > > > parameters in wsdl2java call. With the following call:
> > > > > > >
> > > > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t
> > > > -d
> > > > > xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService
> > > > -pn
> > > > > MySecondPortType
> > > > > > >
> > > > > > >   I get the code generated (in default package) and this
> > > > output:
> > > > > > >
> > > > > > > Warning - Multiple endpoints found - picking the first
> > > > endpoint!
> > > > > > >
> > > > > > >
> > > > > > >   But with the following call (note that is the same call, but
> > > > with the
> > > > > parameters's order canged):
> > > > > > >
> > > > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o
> > > > $HOME/project/ -p
> > > > > org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> > > > > MySecondPortType
> > > > > > >
> > > > > > >  I get the following exception with no code generated:
> > > > > > >
> > > > > > > Exception in thread "main"
> > > > > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > > > > java.lang.RuntimeException :
> > > > > java.lang.IllegalArgumentException: Local part not allowed
> > > > > to be null
> > > > > > >         at
> > > > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> > > > CodeGenerationEngine.java:118)
> > > > > > >         at org.apache.axis2.wsdl.WSDL2Code.main
> > > > > (WSDL2Code.java:31)
> > > > > > >         at
> > > > > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > > > > > > Caused by: java.lang.RuntimeException:
> > > > > java.lang.IllegalArgumentException: Local part not allowed
> > > > > to be null
> > > > > > >         at
> > > > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> > > > SimpleDBExtension.java:152)
> > > > > > >         at
> > > > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> > > > CodeGenerationEngine.java:80)
> > > > > > >         ... 2 more
> > > > > > > Caused by: java.lang.IllegalArgumentException: Local
> > > > > part not allowed to be null
> > > > > > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > > > > > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.XmlSchemaType.getQName (
> > > > XmlSchemaType.java:91)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> > > > SchemaBuilder.java:1496)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.SchemaBuilder.handleSequence (
> > > > SchemaBuilder.java:979)
> > > > > > >         at
> > > > >
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension
> > > > (SchemaBuilder.java:895)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> > > > > (SchemaBuilder.java:684)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(
> > > > SchemaBuilder.java:592)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.SchemaBuilder.handleElement (
> > > > SchemaBuilder.java
> > > > > :1501)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(
> > > > SchemaBuilder.java:107)
> > > > > > >         at
> > > > > org.apache.ws.commons.schema.XmlSchemaCollection.read (
> > > > XmlSchemaCollection.java:233)
> > > > > > >         at
> > > > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> > > > SimpleDBExtension.java:86)
> > > > > > >         ... 3 more
> > > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Davanum Srinivas : http://wso2.com/blogs/
> > > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Ajith Ranabahu
> > > >
> > > >
> > > > --
> > > > Davanum Srinivas : http://wso2.com/blogs/
> > > >
> > >
> > >
> >
>
>
> --
> Ajith Ranabahu

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Ajith Ranabahu <aj...@gmail.com>.
Hi Dong,all
My guess is users would find a bat/sh script very useful if they want to get
into business directly. take the tomcat example. There's nothing to do other
than dbl clicking the bat file (or the sh equivalent) to start the tomcat
server (which I, as a user, find very useful and convenient)
We need to provide similar experience to Axis2 users as well.

On 1/13/06, Dong Liu <ed...@gmail.com> wrote:
>
> The same idea is appliable to testing all the samples instead supply the
> .bat and .sh scripts.
>
> Don
>
>
> On 1/13/06, Dong Liu < edongliu@gmail.com> wrote:
> >
> > I still think it is better to supply a document to suggest the user to
> > create proper classpath definitions in their systems. And run the utils by
> > calling the class directly. What do you think?
> >
> > Cheers,
> >
> > Don
> >
> > On 1/13/06, Davanum Srinivas <davanum@gmail.com > wrote:
> > >
> > > hmm, we should switch to "%*" instead of listing "%1 %2..."
> > >
> > > Ruben can u please try editing the bat file and do that?
> > >
> > > thanks,
> > > -- dims
> > >
> > > On 1/13/06, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > > > Hi,
> > > >  This is not really a bug in the codegen but in the script. If you
> > > have a
> > > > look at the shell script you'll see that it takes only the first 9
> > > arguments
> > > > and not the rest! Same issue is with the bat file.
> > > >
> > > >
> > > > On 1/13/06, Davanum Srinivas <davanum@gmail.com > wrote:
> > > > > Rubén,
> > > > >
> > > > > Please log a jira issue and upload your wsdl.
> > > > >
> > > > > thanks,
> > > > > dims
> > > > >
> > > > > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es>
> > > wrote:
> > > > > >   Hi all,
> > > > > >
> > > > > >   I've been using Axis2-0.94 wsdl2java this last two days and
> > > I've
> > > > realized that "-p" and "-pn" options have no efect when compiling my
> > > wsdl. I
> > > > mean, they have no effect.
> > > > > >
> > > > > >   But the real weird thing comes when I change the order of the
> > > > parameters in wsdl2java call. With the following call:
> > > > > >
> > > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d
> > >
> > > > xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService
> > > -pn
> > > > MySecondPortType
> > > > > >
> > > > > >   I get the code generated (in default package) and this output:
> > > > > >
> > > > > > Warning - Multiple endpoints found - picking the first endpoint!
> > > > > >
> > > > > >
> > > > > >   But with the following call (note that is the same call, but
> > > with the
> > > > parameters's order canged):
> > > > > >
> > > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o
> > > $HOME/project/ -p
> > > > org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> > > > MySecondPortType
> > > > > >
> > > > > >  I get the following exception with no code generated:
> > > > > >
> > > > > > Exception in thread "main"
> > > > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > > > java.lang.RuntimeException :
> > > > java.lang.IllegalArgumentException: Local part not allowed
> > > > to be null
> > > > > >         at
> > > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> > > CodeGenerationEngine.java:118)
> > > > > >         at org.apache.axis2.wsdl.WSDL2Code.main
> > > > (WSDL2Code.java:31)
> > > > > >         at
> > > > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > > > > > Caused by: java.lang.RuntimeException:
> > > > java.lang.IllegalArgumentException: Local part not allowed
> > > > to be null
> > > > > >         at
> > > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> > > SimpleDBExtension.java:152)
> > > > > >         at
> > > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> > > CodeGenerationEngine.java:80)
> > > > > >         ... 2 more
> > > > > > Caused by: java.lang.IllegalArgumentException: Local
> > > > part not allowed to be null
> > > > > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > > > > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > > > > >         at
> > > > org.apache.ws.commons.schema.XmlSchemaType.getQName (
> > > XmlSchemaType.java:91)
> > > > > >         at
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> > > SchemaBuilder.java:1496)
> > > > > >         at
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleSequence (
> > > SchemaBuilder.java:979)
> > > > > >         at
> > > >
> > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension
> > > (SchemaBuilder.java:895)
> > > > > >         at
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> > > > (SchemaBuilder.java:684)
> > > > > >         at
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(
> > > SchemaBuilder.java:592)
> > > > > >         at
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleElement (
> > > SchemaBuilder.java
> > > > :1501)
> > > > > >         at
> > > > org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(
> > > SchemaBuilder.java:107)
> > > > > >         at
> > > > org.apache.ws.commons.schema.XmlSchemaCollection.read (
> > > XmlSchemaCollection.java:233)
> > > > > >         at
> > > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> > > SimpleDBExtension.java:86)
> > > > > >         ... 3 more
> > > > > >
> > > > >
> > > > >
> > > > > --
> > > > > Davanum Srinivas : http://wso2.com/blogs/
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > Ajith Ranabahu
> > >
> > >
> > > --
> > > Davanum Srinivas : http://wso2.com/blogs/
> > >
> >
> >
>


--
Ajith Ranabahu

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Dong Liu <ed...@gmail.com>.
The same idea is appliable to testing all the samples instead supply the
.bat and .sh scripts.

Don


On 1/13/06, Dong Liu <ed...@gmail.com> wrote:
>
> I still think it is better to supply a document to suggest the user to
> create proper classpath definitions in their systems. And run the utils by
> calling the class directly. What do you think?
>
> Cheers,
>
> Don
>
> On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
> >
> > hmm, we should switch to "%*" instead of listing "%1 %2..."
> >
> > Ruben can u please try editing the bat file and do that?
> >
> > thanks,
> > -- dims
> >
> > On 1/13/06, Ajith Ranabahu < ajith.ranabahu@gmail.com> wrote:
> > > Hi,
> > >  This is not really a bug in the codegen but in the script. If you
> > have a
> > > look at the shell script you'll see that it takes only the first 9
> > arguments
> > > and not the rest! Same issue is with the bat file.
> > >
> > >
> > > On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
> > > > Rubén,
> > > >
> > > > Please log a jira issue and upload your wsdl.
> > > >
> > > > thanks,
> > > > dims
> > > >
> > > > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es>
> > wrote:
> > > > >   Hi all,
> > > > >
> > > > >   I've been using Axis2-0.94 wsdl2java this last two days and I've
> > > realized that "-p" and "-pn" options have no efect when compiling my
> > wsdl. I
> > > mean, they have no effect.
> > > > >
> > > > >   But the real weird thing comes when I change the order of the
> > > parameters in wsdl2java call. With the following call:
> > > > >
> > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d
> > > xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn
> > > MySecondPortType
> > > > >
> > > > >   I get the code generated (in default package) and this output:
> > > > >
> > > > > Warning - Multiple endpoints found - picking the first endpoint!
> > > > >
> > > > >
> > > > >   But with the following call (note that is the same call, but
> > with the
> > > parameters's order canged):
> > > > >
> > > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o
> > $HOME/project/ -p
> > > org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> > > MySecondPortType
> > > > >
> > > > >  I get the following exception with no code generated:
> > > > >
> > > > > Exception in thread "main"
> > > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > > java.lang.RuntimeException :
> > > java.lang.IllegalArgumentException: Local part not allowed
> > > to be null
> > > > >         at
> > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> > CodeGenerationEngine.java:118)
> > > > >         at org.apache.axis2.wsdl.WSDL2Code.main
> > > (WSDL2Code.java:31)
> > > > >         at
> > > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > > > > Caused by: java.lang.RuntimeException:
> > > java.lang.IllegalArgumentException: Local part not allowed
> > > to be null
> > > > >         at
> > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> > SimpleDBExtension.java:152)
> > > > >         at
> > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> > CodeGenerationEngine.java:80)
> > > > >         ... 2 more
> > > > > Caused by: java.lang.IllegalArgumentException: Local
> > > part not allowed to be null
> > > > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > > > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > > > >         at
> > > org.apache.ws.commons.schema.XmlSchemaType.getQName (
> > XmlSchemaType.java:91)
> > > > >         at
> > > org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> > SchemaBuilder.java:1496)
> > > > >         at
> > > org.apache.ws.commons.schema.SchemaBuilder.handleSequence (
> > SchemaBuilder.java:979)
> > > > >         at
> > >
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension
> > (SchemaBuilder.java:895)
> > > > >         at
> > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> > > (SchemaBuilder.java:684)
> > > > >         at
> > > org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(
> > SchemaBuilder.java:592)
> > > > >         at
> > > org.apache.ws.commons.schema.SchemaBuilder.handleElement (
> > SchemaBuilder.java
> > > :1501)
> > > > >         at
> > > org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(
> > SchemaBuilder.java:107)
> > > > >         at
> > > org.apache.ws.commons.schema.XmlSchemaCollection.read (
> > XmlSchemaCollection.java:233)
> > > > >         at
> > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> > SimpleDBExtension.java:86)
> > > > >         ... 3 more
> > > > >
> > > >
> > > >
> > > > --
> > > > Davanum Srinivas : http://wso2.com/blogs/
> > > >
> > >
> > >
> > >
> > > --
> > > Ajith Ranabahu
> >
> >
> > --
> > Davanum Srinivas : http://wso2.com/blogs/
> >
>
>

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Dong Liu <ed...@gmail.com>.
I still think it is better to supply a document to suggest the user to
create proper classpath definitions in their systems. And run the utils by
calling the class directly. What do you think?

Cheers,

Don

On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
>
> hmm, we should switch to "%*" instead of listing "%1 %2..."
>
> Ruben can u please try editing the bat file and do that?
>
> thanks,
> -- dims
>
> On 1/13/06, Ajith Ranabahu <aj...@gmail.com> wrote:
> > Hi,
> >  This is not really a bug in the codegen but in the script. If you have
> a
> > look at the shell script you'll see that it takes only the first 9
> arguments
> > and not the rest! Same issue is with the bat file.
> >
> >
> > On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
> > > Rubén,
> > >
> > > Please log a jira issue and upload your wsdl.
> > >
> > > thanks,
> > > dims
> > >
> > > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es> wrote:
> > > >   Hi all,
> > > >
> > > >   I've been using Axis2-0.94 wsdl2java this last two days and I've
> > realized that "-p" and "-pn" options have no efect when compiling my
> wsdl. I
> > mean, they have no effect.
> > > >
> > > >   But the real weird thing comes when I change the order of the
> > parameters in wsdl2java call. With the following call:
> > > >
> > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d
> > xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn
> > MySecondPortType
> > > >
> > > >   I get the code generated (in default package) and this output:
> > > >
> > > > Warning - Multiple endpoints found - picking the first endpoint!
> > > >
> > > >
> > > >   But with the following call (note that is the same call, but with
> the
> > parameters's order canged):
> > > >
> > > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o $HOME/project/
> -p
> > org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> > MySecondPortType
> > > >
> > > >  I get the following exception with no code generated:
> > > >
> > > > Exception in thread "main"
> > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > java.lang.RuntimeException :
> > java.lang.IllegalArgumentException: Local part not allowed
> > to be null
> > > >         at
> > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> CodeGenerationEngine.java:118)
> > > >         at org.apache.axis2.wsdl.WSDL2Code.main
> > (WSDL2Code.java:31)
> > > >         at
> > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > > > Caused by: java.lang.RuntimeException:
> > java.lang.IllegalArgumentException: Local part not allowed
> > to be null
> > > >         at
> > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> SimpleDBExtension.java:152)
> > > >         at
> > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> CodeGenerationEngine.java:80)
> > > >         ... 2 more
> > > > Caused by: java.lang.IllegalArgumentException: Local
> > part not allowed to be null
> > > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > > >         at
> > org.apache.ws.commons.schema.XmlSchemaType.getQName(XmlSchemaType.java
> :91)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> SchemaBuilder.java:1496)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleSequence(
> SchemaBuilder.java:979)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension
> (SchemaBuilder.java:895)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> > (SchemaBuilder.java:684)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(
> SchemaBuilder.java:592)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> SchemaBuilder.java
> > :1501)
> > > >         at
> > org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(
> SchemaBuilder.java:107)
> > > >         at
> > org.apache.ws.commons.schema.XmlSchemaCollection.read(
> XmlSchemaCollection.java:233)
> > > >         at
> > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> SimpleDBExtension.java:86)
> > > >         ... 3 more
> > > >
> > >
> > >
> > > --
> > > Davanum Srinivas : http://wso2.com/blogs/
> > >
> >
> >
> >
> > --
> > Ajith Ranabahu
>
>
> --
> Davanum Srinivas : http://wso2.com/blogs/
>

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Davanum Srinivas <da...@gmail.com>.
hmm, we should switch to "%*" instead of listing "%1 %2..."

Ruben can u please try editing the bat file and do that?

thanks,
-- dims

On 1/13/06, Ajith Ranabahu <aj...@gmail.com> wrote:
> Hi,
>  This is not really a bug in the codegen but in the script. If you have a
> look at the shell script you'll see that it takes only the first 9 arguments
> and not the rest! Same issue is with the bat file.
>
>
> On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
> > Rubén,
> >
> > Please log a jira issue and upload your wsdl.
> >
> > thanks,
> > dims
> >
> > On 1/13/06, Rubén Naranjo Izquierdo < rnaranjo@alumnos.upm.es> wrote:
> > >   Hi all,
> > >
> > >   I've been using Axis2-0.94 wsdl2java this last two days and I've
> realized that "-p" and "-pn" options have no efect when compiling my wsdl. I
> mean, they have no effect.
> > >
> > >   But the real weird thing comes when I change the order of the
> parameters in wsdl2java call. With the following call:
> > >
> > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d
> xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn
> MySecondPortType
> > >
> > >   I get the code generated (in default package) and this output:
> > >
> > > Warning - Multiple endpoints found - picking the first endpoint!
> > >
> > >
> > >   But with the following call (note that is the same call, but with the
> parameters's order canged):
> > >
> > > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o $HOME/project/ -p
> org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> MySecondPortType
> > >
> > >  I get the following exception with no code generated:
> > >
> > > Exception in thread "main"
> org.apache.axis2.wsdl.codegen.CodeGenerationException:
> java.lang.RuntimeException :
> java.lang.IllegalArgumentException: Local part not allowed
> to be null
> > >         at
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:118)
> > >         at org.apache.axis2.wsdl.WSDL2Code.main
> (WSDL2Code.java:31)
> > >         at
> org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > > Caused by: java.lang.RuntimeException:
> java.lang.IllegalArgumentException: Local part not allowed
> to be null
> > >         at
> org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:152)
> > >         at
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:80)
> > >         ... 2 more
> > > Caused by: java.lang.IllegalArgumentException: Local
> part not allowed to be null
> > >         at javax.xml.namespace.QName.<init>(QName.java:85)
> > >         at javax.xml.namespace.QName.<init>( QName.java:70)
> > >         at
> org.apache.ws.commons.schema.XmlSchemaType.getQName(XmlSchemaType.java:91)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java:1496)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleSequence(SchemaBuilder.java:979)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension(SchemaBuilder.java:895)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent
> (SchemaBuilder.java:684)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(SchemaBuilder.java:592)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java
> :1501)
> > >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(SchemaBuilder.java:107)
> > >         at
> org.apache.ws.commons.schema.XmlSchemaCollection.read(XmlSchemaCollection.java:233)
> > >         at
> org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:86)
> > >         ... 3 more
> > >
> >
> >
> > --
> > Davanum Srinivas : http://wso2.com/blogs/
> >
>
>
>
> --
> Ajith Ranabahu


--
Davanum Srinivas : http://wso2.com/blogs/

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Ajith Ranabahu <aj...@gmail.com>.
Hi,
This is not really a bug in the codegen but in the script. If you have a
look at the shell script you'll see that it takes only the first 9 arguments
and not the rest! Same issue is with the bat file.

On 1/13/06, Davanum Srinivas <da...@gmail.com> wrote:
>
> Rubén,
>
> Please log a jira issue and upload your wsdl.
>
> thanks,
> dims
>
> On 1/13/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
> >   Hi all,
> >
> >   I've been using Axis2-0.94 wsdl2java this last two days and I've
> realized that "-p" and "-pn" options have no efect when compiling my wsdl. I
> mean, they have no effect.
> >
> >   But the real weird thing comes when I change the order of the
> parameters in wsdl2java call. With the following call:
> >
> > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d
> xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn
> MySecondPortType
> >
> >   I get the code generated (in default package) and this output:
> >
> > Warning - Multiple endpoints found - picking the first endpoint!
> >
> >
> >   But with the following call (note that is the same call, but with the
> parameters's order canged):
> >
> > ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o $HOME/project/ -p
> org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn
> MySecondPortType
> >
> >  I get the following exception with no code generated:
> >
> > Exception in thread "main"
> org.apache.axis2.wsdl.codegen.CodeGenerationException:
> java.lang.RuntimeException : java.lang.IllegalArgumentException: Local
> part not allowed to be null
> >         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> CodeGenerationEngine.java:118)
> >         at org.apache.axis2.wsdl.WSDL2Code.main (WSDL2Code.java:31)
> >         at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> > Caused by: java.lang.RuntimeException:
> java.lang.IllegalArgumentException: Local part not allowed to be null
> >         at
> org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> SimpleDBExtension.java:152)
> >         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> CodeGenerationEngine.java:80)
> >         ... 2 more
> > Caused by: java.lang.IllegalArgumentException: Local part not allowed to
> be null
> >         at javax.xml.namespace.QName.<init>(QName.java:85)
> >         at javax.xml.namespace.QName.<init>( QName.java:70)
> >         at org.apache.ws.commons.schema.XmlSchemaType.getQName(
> XmlSchemaType.java:91)
> >         at org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> SchemaBuilder.java:1496)
> >         at org.apache.ws.commons.schema.SchemaBuilder.handleSequence(
> SchemaBuilder.java:979)
> >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension(
> SchemaBuilder.java:895)
> >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent (
> SchemaBuilder.java:684)
> >         at org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(
> SchemaBuilder.java:592)
> >         at org.apache.ws.commons.schema.SchemaBuilder.handleElement(
> SchemaBuilder.java :1501)
> >         at
> org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(
> SchemaBuilder.java:107)
> >         at org.apache.ws.commons.schema.XmlSchemaCollection.read(
> XmlSchemaCollection.java:233)
> >         at
> org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(
> SimpleDBExtension.java:86)
> >         ... 3 more
> >
>
>
> --
> Davanum Srinivas : http://wso2.com/blogs/
>



--
Ajith Ranabahu

Re: [Axis2-0.94] Weird wsdl2java behaviour

Posted by Davanum Srinivas <da...@gmail.com>.
Rubén,

Please log a jira issue and upload your wsdl.

thanks,
dims

On 1/13/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
>   Hi all,
>
>   I've been using Axis2-0.94 wsdl2java this last two days and I've realized that "-p" and "-pn" options have no efect when compiling my wsdl. I mean, they have no effect.
>
>   But the real weird thing comes when I change the order of the parameters in wsdl2java call. With the following call:
>
> ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn MySecondPortType
>
>   I get the code generated (in default package) and this output:
>
> Warning - Multiple endpoints found - picking the first endpoint!
>
>
>   But with the following call (note that is the same call, but with the parameters's order canged):
>
> ./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o $HOME/project/ -p org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn MySecondPortType
>
>  I get the following exception with no code generated:
>
> Exception in thread "main" org.apache.axis2.wsdl.codegen.CodeGenerationException: java.lang.RuntimeException: java.lang.IllegalArgumentException: Local part not allowed to be null
>         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:118)
>         at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31)
>         at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: Local part not allowed to be null
>         at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:152)
>         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:80)
>         ... 2 more
> Caused by: java.lang.IllegalArgumentException: Local part not allowed to be null
>         at javax.xml.namespace.QName.<init>(QName.java:85)
>         at javax.xml.namespace.QName.<init>(QName.java:70)
>         at org.apache.ws.commons.schema.XmlSchemaType.getQName(XmlSchemaType.java:91)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java:1496)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleSequence(SchemaBuilder.java:979)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension(SchemaBuilder.java:895)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent(SchemaBuilder.java:684)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(SchemaBuilder.java:592)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java:1501)
>         at org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(SchemaBuilder.java:107)
>         at org.apache.ws.commons.schema.XmlSchemaCollection.read(XmlSchemaCollection.java:233)
>         at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:86)
>         ... 3 more
>


--
Davanum Srinivas : http://wso2.com/blogs/

[Axis2-0.94] Weird wsdl2java behaviour

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
  Hi all,

  I've been using Axis2-0.94 wsdl2java this last two days and I've realized that "-p" and "-pn" options have no efect when compiling my wsdl. I mean, they have no effect. 

  But the real weird thing comes when I change the order of the parameters in wsdl2java call. With the following call:

./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -ss -sd -t -d xmlbeans -o $HOME/project/ -p org.objectweb.service -sn MyService -pn MySecondPortType

  I get the code generated (in default package) and this output:

Warning - Multiple endpoints found - picking the first endpoint!


  But with the following call (note that is the same call, but with the parameters's order canged):

./WSDL2Java.sh -uri $HOME/project/wsdl/mywsdl.wsdl -o $HOME/project/ -p org.objectweb.service -t -ss -sd -d xmlbeans -sn MyService -pn MySecondPortType

 I get the following exception with no code generated: 

Exception in thread "main" org.apache.axis2.wsdl.codegen.CodeGenerationException: java.lang.RuntimeException: java.lang.IllegalArgumentException: Local part not allowed to be null
        at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:118)
        at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31)
        at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException: Local part not allowed to be null
        at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:152)
        at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:80)
        ... 2 more
Caused by: java.lang.IllegalArgumentException: Local part not allowed to be null
        at javax.xml.namespace.QName.<init>(QName.java:85)
        at javax.xml.namespace.QName.<init>(QName.java:70)
        at org.apache.ws.commons.schema.XmlSchemaType.getQName(XmlSchemaType.java:91)
        at org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java:1496)
        at org.apache.ws.commons.schema.SchemaBuilder.handleSequence(SchemaBuilder.java:979)
        at org.apache.ws.commons.schema.SchemaBuilder.handleComplexContentExtension(SchemaBuilder.java:895)
        at org.apache.ws.commons.schema.SchemaBuilder.handleComplexContent(SchemaBuilder.java:684)
        at org.apache.ws.commons.schema.SchemaBuilder.handleComplexType(SchemaBuilder.java:592)
        at org.apache.ws.commons.schema.SchemaBuilder.handleElement(SchemaBuilder.java:1501)
        at org.apache.ws.commons.schema.SchemaBuilder.handleXmlSchemaElement(SchemaBuilder.java:107)
        at org.apache.ws.commons.schema.XmlSchemaCollection.read(XmlSchemaCollection.java:233)
        at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:86)
        ... 3 more

Re: [Axis2-0.94] Unsupported content exception

Posted by Ajith Ranabahu <aj...@gmail.com>.
Hi all,
This is due to the latest change to the codegenerator. If the WSDL does not
provide a service (service element) the codegenerator switches to the
interface mode and avoids generating any concrete stuff. The earlier
WSDL2java actually acted wrong, in the sense that it generated all the
classes even when service information is absent.
As a workaround for Ruben's problem define a service element (with a dummy
soap address in the port) in the wsdl. that should correctly generate the
code

On 1/12/06, Davanum Srinivas <da...@gmail.com> wrote:
>
> Please define a service. Hmm...something to think about.
>
> thanks,
> dims
>
> On 1/12/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
> >   It worked!! Thank you so much Dims! But now I get the following
> warning:
> >
> > Warning -No services found - switched to the interface mode!
> > Warning - Found multiple porttypes - picking the first
> > - Interface mode is selected.The following items will not be generated
> > - 1. Message Receiver
> > - Interface mode is selected.The following items will not be generated
> > - 1. Stub
> > - 2. CallbackHandler
> > - 3. Test Classes
> > - 4. Databinding Supporters
> >
> >   As it can be seen, only the Skeleton class is generated. My wsdl file
> > doesn't define a service, but Axis2 0.93's wsdl2java generated all the
> code
> > in all manners.
> >
> >   Must I define a service? Or can I advise wsdl2java to avoid switching
> to
> > interface mode?
> >
> >   Thank you,
> >
> >     Rubén
> >
> > On Thursday 12 January 2006 16:55, Davanum Srinivas wrote:
> > > can you please try using "-d xmlbeans"?
> > >
> > > thanks,
> > > dims
> > >
> > > On 1/12/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
> > > >    Hi all,
> > > >
> > > >    I'm upgrading from Axis2 0.93 to Axis2 0.94. I'm using wsdl2java
> with
> > > > a wsdl file that compiled using Axis2 0.93's wsdl2java.
> > > >
> > > >    I import an external xsd file on my wsdl file with the following
> code:
> > > >
> > > >     <xs:import
> > > > namespace="
> http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecu
> > > >rity-utility-1.0.xsd"
> > > > schemaLocation="
> http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-w
> > > >ssecurity-utility-1.0.xsd"/>
> > > >
> > > >   Axis2 0.94 returns the following exception when I import that
> external
> > > > xsd. Can somebody tell me why I get that exception?
> > > >
> > > >   Thank you in advance,
> > > >
> > > >       Ruben Naranjo
> > > >
> > > > Retrieving schema at
> > > > '
> http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utili
> > > >ty-1.0.xsd', relative to
> > > > 'file:/home/rnaranjo/applications/axis2-std-0.94-bin/samples/wsdl/'.
> > > > Exception in thread "main"
> > > > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > > > java.lang.RuntimeException:
> > > > org.apache.axis2.schema.SchemaCompilationException:
> > > > java.lang.RuntimeException: Unsupported content! at
> > > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate
> (CodeGeneratio
> > > >nEngine.java:118) at
> > > > org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31) at
> > > > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21) Caused by:
> > > > java.lang.RuntimeException:
> > > > org.apache.axis2.schema.SchemaCompilationException:
> > > > java.lang.RuntimeException: Unsupported content! at
> > > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage
> (SimpleDB
> > > >Extension.java:152) at
> > > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate
> (CodeGeneratio
> > > >nEngine.java:80) ... 2 more
> > > > Caused by: org.apache.axis2.schema.SchemaCompilationException:
> > > > java.lang.RuntimeException: Unsupported content! at
> > > > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java
> :146)
> > > > at
> > > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage
> (SimpleDB
> > > >Extension.java:104) ... 3 more
> > > > Caused by: java.lang.RuntimeException: Unsupported content!
> > > >         at
> > > > org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType
> (Sche
> > > >maCompiler.java:436) at
> > > > org.apache.axis2.schema.SchemaCompiler.processSchema(
> SchemaCompiler.java:
> > > >350) at
> > > > org.apache.axis2.schema.SchemaCompiler.processElement(
> SchemaCompiler.java
> > > >:289) at
> > > > org.apache.axis2.schema.SchemaCompiler.processElement(
> SchemaCompiler.java
> > > >:267) at
> > > > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java
> :179)
> > > > at
> > > > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java
> :141)
> > > > ... 4 more
> > >
> > > --
> > > Davanum Srinivas : http://wso2.com/blogs/
> >
>
>
> --
> Davanum Srinivas : http://wso2.com/blogs/
>



--
Ajith Ranabahu

Re: [Axis2-0.94] Unsupported content exception

Posted by Davanum Srinivas <da...@gmail.com>.
Please define a service. Hmm...something to think about.

thanks,
dims

On 1/12/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
>   It worked!! Thank you so much Dims! But now I get the following warning:
>
> Warning -No services found - switched to the interface mode!
> Warning - Found multiple porttypes - picking the first
> - Interface mode is selected.The following items will not be generated
> - 1. Message Receiver
> - Interface mode is selected.The following items will not be generated
> - 1. Stub
> - 2. CallbackHandler
> - 3. Test Classes
> - 4. Databinding Supporters
>
>   As it can be seen, only the Skeleton class is generated. My wsdl file
> doesn't define a service, but Axis2 0.93's wsdl2java generated all the code
> in all manners.
>
>   Must I define a service? Or can I advise wsdl2java to avoid switching to
> interface mode?
>
>   Thank you,
>
>     Rubén
>
> On Thursday 12 January 2006 16:55, Davanum Srinivas wrote:
> > can you please try using "-d xmlbeans"?
> >
> > thanks,
> > dims
> >
> > On 1/12/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
> > >    Hi all,
> > >
> > >    I'm upgrading from Axis2 0.93 to Axis2 0.94. I'm using wsdl2java with
> > > a wsdl file that compiled using Axis2 0.93's wsdl2java.
> > >
> > >    I import an external xsd file on my wsdl file with the following code:
> > >
> > >     <xs:import
> > > namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecu
> > >rity-utility-1.0.xsd"
> > > schemaLocation="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-w
> > >ssecurity-utility-1.0.xsd"/>
> > >
> > >   Axis2 0.94 returns the following exception when I import that external
> > > xsd. Can somebody tell me why I get that exception?
> > >
> > >   Thank you in advance,
> > >
> > >       Ruben Naranjo
> > >
> > > Retrieving schema at
> > > 'http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utili
> > >ty-1.0.xsd', relative to
> > > 'file:/home/rnaranjo/applications/axis2-std-0.94-bin/samples/wsdl/'.
> > > Exception in thread "main"
> > > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > > java.lang.RuntimeException:
> > > org.apache.axis2.schema.SchemaCompilationException:
> > > java.lang.RuntimeException: Unsupported content! at
> > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGeneratio
> > >nEngine.java:118) at
> > > org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31) at
> > > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21) Caused by:
> > > java.lang.RuntimeException:
> > > org.apache.axis2.schema.SchemaCompilationException:
> > > java.lang.RuntimeException: Unsupported content! at
> > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDB
> > >Extension.java:152) at
> > > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGeneratio
> > >nEngine.java:80) ... 2 more
> > > Caused by: org.apache.axis2.schema.SchemaCompilationException:
> > > java.lang.RuntimeException: Unsupported content! at
> > > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:146)
> > > at
> > > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDB
> > >Extension.java:104) ... 3 more
> > > Caused by: java.lang.RuntimeException: Unsupported content!
> > >         at
> > > org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType(Sche
> > >maCompiler.java:436) at
> > > org.apache.axis2.schema.SchemaCompiler.processSchema(SchemaCompiler.java:
> > >350) at
> > > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java
> > >:289) at
> > > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java
> > >:267) at
> > > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:179)
> > > at
> > > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:141)
> > > ... 4 more
> >
> > --
> > Davanum Srinivas : http://wso2.com/blogs/
>


--
Davanum Srinivas : http://wso2.com/blogs/

Re: [Axis2-0.94] Unsupported content exception

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
  It worked!! Thank you so much Dims! But now I get the following warning:

Warning -No services found - switched to the interface mode!
Warning - Found multiple porttypes - picking the first
- Interface mode is selected.The following items will not be generated
- 1. Message Receiver
- Interface mode is selected.The following items will not be generated
- 1. Stub
- 2. CallbackHandler
- 3. Test Classes
- 4. Databinding Supporters

  As it can be seen, only the Skeleton class is generated. My wsdl file 
doesn't define a service, but Axis2 0.93's wsdl2java generated all the code 
in all manners. 

  Must I define a service? Or can I advise wsdl2java to avoid switching to 
interface mode?

  Thank you,

    Rubén

On Thursday 12 January 2006 16:55, Davanum Srinivas wrote:
> can you please try using "-d xmlbeans"?
>
> thanks,
> dims
>
> On 1/12/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
> >    Hi all,
> >
> >    I'm upgrading from Axis2 0.93 to Axis2 0.94. I'm using wsdl2java with
> > a wsdl file that compiled using Axis2 0.93's wsdl2java.
> >
> >    I import an external xsd file on my wsdl file with the following code:
> >
> >     <xs:import
> > namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecu
> >rity-utility-1.0.xsd"
> > schemaLocation="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-w
> >ssecurity-utility-1.0.xsd"/>
> >
> >   Axis2 0.94 returns the following exception when I import that external
> > xsd. Can somebody tell me why I get that exception?
> >
> >   Thank you in advance,
> >
> >       Ruben Naranjo
> >
> > Retrieving schema at
> > 'http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utili
> >ty-1.0.xsd', relative to
> > 'file:/home/rnaranjo/applications/axis2-std-0.94-bin/samples/wsdl/'.
> > Exception in thread "main"
> > org.apache.axis2.wsdl.codegen.CodeGenerationException:
> > java.lang.RuntimeException:
> > org.apache.axis2.schema.SchemaCompilationException:
> > java.lang.RuntimeException: Unsupported content! at
> > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGeneratio
> >nEngine.java:118) at
> > org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31) at
> > org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21) Caused by:
> > java.lang.RuntimeException:
> > org.apache.axis2.schema.SchemaCompilationException:
> > java.lang.RuntimeException: Unsupported content! at
> > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDB
> >Extension.java:152) at
> > org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGeneratio
> >nEngine.java:80) ... 2 more
> > Caused by: org.apache.axis2.schema.SchemaCompilationException:
> > java.lang.RuntimeException: Unsupported content! at
> > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:146)
> > at
> > org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDB
> >Extension.java:104) ... 3 more
> > Caused by: java.lang.RuntimeException: Unsupported content!
> >         at
> > org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType(Sche
> >maCompiler.java:436) at
> > org.apache.axis2.schema.SchemaCompiler.processSchema(SchemaCompiler.java:
> >350) at
> > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java
> >:289) at
> > org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java
> >:267) at
> > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:179)
> > at
> > org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:141)
> > ... 4 more
>
> --
> Davanum Srinivas : http://wso2.com/blogs/

Re: [Axis2-0.94] Unsupported content exception

Posted by Davanum Srinivas <da...@gmail.com>.
can you please try using "-d xmlbeans"?

thanks,
dims

On 1/12/06, Rubén Naranjo Izquierdo <rn...@alumnos.upm.es> wrote:
>    Hi all,
>
>    I'm upgrading from Axis2 0.93 to Axis2 0.94. I'm using wsdl2java with a wsdl file that compiled using Axis2 0.93's wsdl2java.
>
>    I import an external xsd file on my wsdl file with the following code:
>
>     <xs:import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
>                    schemaLocation="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"/>
>
>   Axis2 0.94 returns the following exception when I import that external xsd. Can somebody tell me why I get that exception?
>
>   Thank you in advance,
>
>       Ruben Naranjo
>
> Retrieving schema at 'http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd', relative to 'file:/home/rnaranjo/applications/axis2-std-0.94-bin/samples/wsdl/'.
> Exception in thread "main" org.apache.axis2.wsdl.codegen.CodeGenerationException: java.lang.RuntimeException: org.apache.axis2.schema.SchemaCompilationException: java.lang.RuntimeException: Unsupported content!
>         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:118)
>         at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31)
>         at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
> Caused by: java.lang.RuntimeException: org.apache.axis2.schema.SchemaCompilationException: java.lang.RuntimeException: Unsupported content!
>         at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:152)
>         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:80)
>         ... 2 more
> Caused by: org.apache.axis2.schema.SchemaCompilationException: java.lang.RuntimeException: Unsupported content!
>         at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:146)
>         at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:104)
>         ... 3 more
> Caused by: java.lang.RuntimeException: Unsupported content!
>         at org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType(SchemaCompiler.java:436)
>         at org.apache.axis2.schema.SchemaCompiler.processSchema(SchemaCompiler.java:350)
>         at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java:289)
>         at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java:267)
>         at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:179)
>         at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:141)
>         ... 4 more
>


--
Davanum Srinivas : http://wso2.com/blogs/

[Axis2-0.94] Unsupported content exception

Posted by Rubén Naranjo Izquierdo <rn...@alumnos.upm.es>.
   Hi all,

   I'm upgrading from Axis2 0.93 to Axis2 0.94. I'm using wsdl2java with a wsdl file that compiled using Axis2 0.93's wsdl2java. 

   I import an external xsd file on my wsdl file with the following code:

    <xs:import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
    		   schemaLocation="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"/>

  Axis2 0.94 returns the following exception when I import that external xsd. Can somebody tell me why I get that exception?

  Thank you in advance,

      Ruben Naranjo

Retrieving schema at 'http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd', relative to 'file:/home/rnaranjo/applications/axis2-std-0.94-bin/samples/wsdl/'.
Exception in thread "main" org.apache.axis2.wsdl.codegen.CodeGenerationException: java.lang.RuntimeException: org.apache.axis2.schema.SchemaCompilationException: java.lang.RuntimeException: Unsupported content!
        at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:118)
        at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:31)
        at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:21)
Caused by: java.lang.RuntimeException: org.apache.axis2.schema.SchemaCompilationException: java.lang.RuntimeException: Unsupported content!
        at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:152)
        at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(CodeGenerationEngine.java:80)
        ... 2 more
Caused by: org.apache.axis2.schema.SchemaCompilationException: java.lang.RuntimeException: Unsupported content!
        at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:146)
        at org.apache.axis2.wsdl.codegen.extension.SimpleDBExtension.engage(SimpleDBExtension.java:104)
        ... 3 more
Caused by: java.lang.RuntimeException: Unsupported content!
        at org.apache.axis2.schema.SchemaCompiler.processNamedComplexSchemaType(SchemaCompiler.java:436)
        at org.apache.axis2.schema.SchemaCompiler.processSchema(SchemaCompiler.java:350)
        at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java:289)
        at org.apache.axis2.schema.SchemaCompiler.processElement(SchemaCompiler.java:267)
        at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:179)
        at org.apache.axis2.schema.SchemaCompiler.compile(SchemaCompiler.java:141)
        ... 4 more

Re: [Axis2-0.94] Skeleton changes

Posted by Ajith Ranabahu <aj...@gmail.com>.
Hi Bram,
the reason is that now the default is ADB which generates a lot less
classes. Will post a sample soon.

On 1/12/06, Bram Biesbrouck <b...@beligum.org> wrote:
>
> Hi all,
>
> Could sombody write some sample code to use the generated Request/Response
> xsd-classes of Axis2 0.94, since I don't see any Factory-classes
> anymore...
> Btw, the API looks much cleaner now, thanks !
>
> Bram
>



--
Ajith Ranabahu