Hi,

 

I debugged this issue further and found that it is failing in the
loggingPhase (LogHandler.java invoke method).

 

As I told in my earlier email it was working before and not now and I
didn't change any Axis2 libraries, now I remember that I added
loggingPhase to the axis2.xml and added LogHandler & LoggingModule
classes to my webservice project to log the SOAP requests & responses.

 

I started getting the exception after I added the loggingPhase, before
that it was working fine.

 

When I debugged further, I found that an exception is being thrown in
LogHandler.java invoke method.

 

The LogHandler.java invoke method has the following line in it.

 

log.info(msgContext.getEnvelope().toString());

 

And when I see the value for msgContext.getEnvelope(), I'm getting this
exception com.sun.jdi.InvocationException occurred invoking method.

 

Any help on this is appreciated....

 

Thanks

Raghu

________________________________

From: Raghu Upadhyayula [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 04, 2008 3:42 PM
To: axis-user@ws.apache.org
Subject: [Axis2] Getting an exception when returning OMElement
Importance: High

 

Hi,

 

I have a webservice which returns a complexType (ObjectResult).

 

Here is the definition of the complexType (ObjectResult).

 

<complexType name="ObjectResult">

    <sequence>

        <element name="createdBy" nillable="true" type="xsd:string" /> 

        <element name="createdDate" nillable="true" type="xsd:dateTime"
/> 

        <element name="lastModifiedBy" nillable="true" type="xsd:string"
/> 

        <element name="lastModifiedDate" nillable="true"
type="xsd:dateTime" /> 

        <element name="exceptionCode" nillable="true"
type="fns:ExceptionCode" /> 

        <element name="errorMessage" nillable="true" type="xsd:string"
/> 

        <element maxOccurs="unbounded" name="fields" nillable="true"
type="tns:Field" /> 

        <element name="objectType" nillable="true" type="tns:ObjectType"
/> 

        <any minOccurs="0" namespace="##targetNamespace"
processContents="lax" /> 

    </sequence>

</complexType>

 

The any element in the WSDL is converted to OMElement when we run
WSDL2Java.

 

Now, in the code when I create an OMElement object and set it to the
ObjectResult and return in the response, I'm getting the below exception

 

"java.lang.RuntimeException: Error obtaining parser from data source:the
prefix ==>  Already exists for namespace ==>"

 

It used to work before, but suddenly started getting this exception,
nothing has changed regarding the Axis2 libraries in my repository.

 

Please help me regarding this issue.

 

Thanks

Raghu

Reply via email to