Actually you should add the following section to your axis2.xml. In 1.3 we
have made the builders and formatters pluggable so that the user can
register a builder/formatter for a specific content-type. The SOAPBuilders
are added by default. Please add this section to your axis2.xml and you
should get both REST and SOAP to work. In 1.3 you dont have to change
anything to get REST to work (Please revert your changes).

<!-- ================================================= -->
    <!-- Message Formatter -->
    <!-- ================================================= -->
    <!--Following content type to message formatter mapping can be used to
implement support for different message -->
    <!--format  serialization in Axis2. These message formats are expected
to be resolved based on the content type. -->
    <messageFormatters>
        <messageFormatter contentType="application/x-www-form-urlencoded"
                         class="
org.apache.axis2.transport.http.XFormURLEncodedFormatter"/>
        <messageFormatter contentType="multipart/form-data"
                         class="
org.apache.axis2.transport.http.MultipartFormDataFormatter"/>
        <messageFormatter contentType="application/xml"
                         class="
org.apache.axis2.transport.http.ApplicationXMLFormatter"/>
    </messageFormatters>

    <!-- ================================================= -->
    <!-- Message Builders -->
    <!-- ================================================= -->
    <!--Following content type to builder mapping can be used to implement
support for different message -->
    <!--formats in Axis2. These message formats are expected to be resolved
based on the content type. -->
    <messageBuilders>
        <messageBuilder contentType="application/xml"
                         class="
org.apache.axis2.builder.ApplicationXMLBuilder"/>
        <messageBuilder contentType="application/x-www-form-urlencoded"
                         class="
org.apache.axis2.builder.XFormURLEncodedBuilder"/>
        <!--Left commented because it adds the depandancy of servlet-api to
other modules.
        Please uncomment to Receive messages in multipart/form-data
format-->
        <!--<messageBuilder contentType="multipart/form-data"-->
                         <!--class="
org.apache.axis2.builder.MultipartFormDataBuilder"/>-->
    </messageBuilders>

Thanks,
Keith.

On Nov 21, 2007 11:44 PM, John Pfeifer <[EMAIL PROTECTED]>
wrote:

>  I modified the axis2.xml accordingly...
>
>         <!--messageFormatter contentType="application/xml"
>                          class="
> org.apache.axis2.transport.http.ApplicationXMLFormatter"/-->
>         <messageFormatter contentType="application/xml"
>                          class="
> org.apache.axis2.transport.http.SOAPMessageFormatter"/>
>
> That seems to have fixed the issue.  If I want to enable REST, will this
> cause the service to return a SOAP message?
>
>
>
> -----Original Message-----
> From: John Pfeifer [mailto:[EMAIL PROTECTED]<[EMAIL PROTECTED]>
> ]
> Sent: Wed 11/21/2007 1:06 PM
> To: [email protected]
> Subject: Issue upgrading from 1.1 to 1.3
>
> I just upgraded to axis2 version 1.3 from 1.1.  I am using the
> <messageReceiver class="
> org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/>.  I can read the
> incoming SOAP request just fine, but my client now receives the XML response
> without the SOAP Envelope.  Is there anything special that I have to do with
> version 1.3?  I turned on logging in case that helps troubleshoot the
> issue.  Below is what I see after I have returned from my POJO web service.
>
> <11/21/07
> 12:54:46:290>|http-10002-1|DEBUG|engine.AxisEngine|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] send:null|
> <11/21/07 12:54:46:290>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking pre-condition for
> Phase "soapmonitorPhase"|
> <11/21/07 12:54:46:290>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking phase
> "soapmonitorPhase"|
> <11/21/07 12:54:46:290>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking post-conditions for
> phase "soapmonitorPhase"|
> <11/21/07 12:54:46:290>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking pre-condition for
> Phase "OperationOutPhase"|
> <11/21/07 12:54:46:290>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking phase
> "OperationOutPhase"|
> <11/21/07 12:54:46:290>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking post-conditions for
> phase "OperationOutPhase"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking pre-condition for
> Phase "RMPhase"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking phase "RMPhase"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking post-conditions for
> phase "RMPhase"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking pre-condition for
> Phase "PolicyDetermination"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking phase
> "PolicyDetermination"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking post-conditions for
> phase "PolicyDetermination"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking pre-condition for
> Phase "MessageOut"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking phase "MessageOut"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking Handler
> 'AddressingOutHandler' in Phase 'MessageOut'|
> <11/21/07
> 12:54:46:291>|http-10002-1|DEBUG|addressing.AddressingOutHandler|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Addressing is disabled. Not
> adding WS-Addressing headers.|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking post-conditions for
> phase "MessageOut"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking pre-condition for
> Phase "Security"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking phase "Security"|
> <11/21/07 12:54:46:291>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Checking post-conditions for
> phase "Security"|
> <11/21/07
> 12:54:46:291>|http-10002-1|DEBUG|addressing.EndpointReference|hasAnonymousAddress:
> http://www.w3.org/2005/08/addressing/anonymous is Anonymous: true|
> <11/21/07
> 12:54:46:291>|http-10002-1|DEBUG|http.ApplicationXMLFormatter|contentType
> set from messageContext =null|
> <11/21/07
> 12:54:46:291>|http-10002-1|DEBUG|http.ApplicationXMLFormatter|(NOTE)
> contentType from format is=text/xml|
> <11/21/07
> 12:54:46:291>|http-10002-1|DEBUG|http.ApplicationXMLFormatter|contentType
> returned =application/xml; charset=UTF-8|
> <11/21/07
> 12:54:46:291>|http-10002-1|DEBUG|http.ApplicationXMLFormatter|start
> writeTo()|
> <11/21/07
> 12:54:46:292>|http-10002-1|DEBUG|http.ApplicationXMLFormatter|end writeTo()|
> <11/21/07 12:54:46:292>|http-10002-1|DEBUG|transport.TransportUtils|Found
> RequestResponseTransport setting response written|
> <11/21/07 12:54:46:292>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() in
> Phase "Security"|
> <11/21/07 12:54:46:292>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() in
> Phase "MessageOut"|
> <11/21/07 12:54:46:292>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() for
> Handler 'AddressingOutHandler' in Phase 'MessageOut'|
> <11/21/07 12:54:46:292>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() in
> Phase "PolicyDetermination"|
> <11/21/07 12:54:46:292>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() in
> Phase "RMPhase"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() in
> Phase "OperationOutPhase"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667686315] Invoking flowComplete() in
> Phase "soapmonitorPhase"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() in
> Phase "soapmonitorPhase"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() in
> Phase "OperationInPhase"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() in
> Phase "RMPhase"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() in
> Phase "Dispatch"|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() for
> Handler 'HTTPLocationBasedDispatcher' in Phase 'Dispatch'|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() for
> Handler 'SOAPMessageBodyBasedDispatcher' in Phase 'Dispatch'|
> <11/21/07 12:54:46:293>|http-10002-1|DEBUG|engine.Phase|[MessageContext:
> logID=urn:uuid:0E497A5ABC7CF1F9E11195667685968] Invoking flowComplete() for
> Handler 'RequestURIOperationDispatcher' in Phase 'Dispatch'|
>
> 2618317,1    100%
>
> Thanks,
>
> John
>
>


-- 
Keith Chapman
WSO2 Inc.
Oxygen for Web Services Developers.
http://wso2.org/

Reply via email to