hi,

you have not specified the name of the wsdl:fault element.
it should be something like this

<wsdl:fault name="fault">
                <soap:fault name="fault" use="literal"/>
            </wsdl:fault>

I added proper exceptions to throw for this case.

Amila.

On Nov 9, 2007 8:40 AM, Pantvaidya, Vishwajit <[EMAIL PROTECTED]> wrote:
> I added the fault specifications in the binding as well and now I get "Error 
> parsing WSDL". Here is the stack trace. I am also attaching wsdl.
>
>      [java]     at 
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.<init>(CodeGenerationEngine.java:160)
>      [java]     at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35)
>      [java]     at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24)
>      [java] Caused by: org.apache.axis2.AxisFault
>      [java]     at org.apache.axis2.AxisFault.makeFault(AxisFault.java:417)
>      [java]     at 
> org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateService(WSDL11ToAxisServiceBuilder.java:367)
>      [java]     at 
> org.apache.axis2.description.WSDL11ToAllAxisServicesBuilder.populateAllServices(WSDL11ToAllAxisServicesBuilder.java:109)
>      [java]     at 
> org.apache.axis2.wsdl.codegen.CodeGenerationEngine.<init>(CodeGenerationEngine.java:154)
>      [java]     ... 2 more
>      [java] Caused by: java.lang.NullPointerException
>      [java]     at 
> org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateBinding(WSDL11ToAxisServiceBuilder.java:693)
>      [java]     at 
> org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateEndpoint(WSDL11ToAxisServiceBuilder.java:508)
>      [java]     at 
> org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateEndpoints(WSDL11ToAxisServiceBuilder.java:459)
>      [java]     at 
> org.apache.axis2.description.WSDL11ToAxisServiceBuilder.populateService(WSDL11ToAxisServiceBuilder.java:337)
>
> >-----Original Message-----
> >From: Pantvaidya, Vishwajit [mailto:[EMAIL PROTECTED]
> >Sent: Wednesday, November 07, 2007 7:20 PM
> >To: axis-user@ws.apache.org
> >Subject: RE: [Axis2] 1.3 wsdl2java generates code with missing methods
> >
> >I looked into the code generate and the missing methods issue is fixed.
> >Thanks for the fix.
> >
> >Now I added a wsdl:fault specification in the wsdl - and I get the
> >exception:
> >
> >     [java] Caused by: java.lang.RuntimeException: Element QName is null
> >for ECMServiceExceptionMessage!
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >getFaultParamElements(AxisServiceBasedMultiLanguageEmitter.java:2795)
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >getFaultElement(AxisServiceBasedMultiLanguageEmitter.java:2714)
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >generateMethodElement(AxisServiceBasedMultiLanguageEmitter.java:2237)
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >loadOperations(AxisServiceBasedMultiLanguageEmitter.java:2119)
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >createDOMDocumentForSkeletonInterface(AxisServiceBasedMultiLanguageEmitter.
> >java:2076)
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >writeSkeletonInterface(AxisServiceBasedMultiLanguageEmitter.java:1985)
> >     [java]     at
> >org.apache.axis2.wsdl.codegen.emitter.AxisServiceBasedMultiLanguageEmitter.
> >emitSkeleton(AxisServiceBasedMultiLanguageEmitter.java:1311)
> >
> >Seems like this was a bug earlier in Axis2 - has that reappeared again in
> >this nightly build?
> >A more basic question I have asked earlier - Axis1 used to generate
> >skeleton interface methods that threw java.lang.RemoteException by default
> >- that no longer happens in Axis2. Is that a bug or by design? If that ia a
> >bug and can be fixed - I no longer have to define a custom fault in wsdl.
> >
> >
> >Please let me know.
> >
> >
> >Thanks,
> >
> >Vish.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>



-- 
Amila Suriarachchi,
WSO2 Inc.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to