Content-type: charset when using wsdl-cxf

View: New views
6 Messages — Rating Filter:   Alert me  

Content-type: charset when using wsdl-cxf

by Richard Swart :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi.
I'm trying to set up a wsdl-cxf endpoint connecting to a .net WS, but the service doesn't seem to understand my request.
I have a feeling that it is related to jira issue MULE-4011.
I see there is a patch for mule 3.x code, but what do I do for Mule 2.2.1?
Here is my configuration:
        <service name="toDotNet">
    <inbound>
    <file:inbound-endpoint path="C:/toDotNet" connector-ref="inboundFileConnector" synchronous="true" transformer-refs="ObjectToString" />    
    </inbound>
    <outbound>
    <multicasting-router>
    <outbound-endpoint address="wsdl-cxf:http://192.168.106.79/MyTest.asmx?WSDL&method=MyMethod" synchronous="true" />    
   
    </multicasting-router>
    </outbound>
    </service>

Using Wireshark I see that the content-type is text/xml. When I try to connect to the web service using SoapUI the content-type is set to: text/xml;charset=UTF-8

How do I connect to a .Net web service using wsdl-cxf in Mule 2.2.1

Thanks
Trond.
/Trond

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



Re: Content-type: charset when using wsdl-cxf

by Richard Swart :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I've also tried using axis, but I think there is a problem with xml encoding. (<) ??
When sending my message using an axis end-point in Mule I get an error.
If I send the same message using SoapUI, but replacing the < and > and " with <, > and " it works fine.

What is the best way of connecting to a .net web service?


Regards

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



Re: Content-type: charset when using wsdl-cxf

by yyamano :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Wed, 04 Nov 2009 06:27:35 -0800 (PST), Trond Kvarenes <mule.user.relay@...> wrote:

> I'm trying to set up a wsdl-cxf endpoint connecting to a .net WS, but the service doesn't seem to understand my request.
> I have a feeling that it is related to jira issue MULE-4011.

I don't think it's directly related. MULE-4011 mentioned the responses
problem, not the requests problem.

> I see there is a patch for mule 3.x code, but what do I do for Mule 2.2.1?

Could you try the following transformer on the outbound?
I've never used it, so I'm not sure if it works.

<message-properties-transformer name="fix-content-type-header" overwrite="true">
    <add-message-property key="Content-type" value="text/xml; charset=UTF-8"/>
</message-properties-transformer>

--
Yuji Yamano
OGIS International, Inc.

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



Parent Message unknown RE: Re: Content-type: charset when using wsdl-cxf

by Farrell, Kevin (ICTL_eCust_05) :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Not sure if you have already solved your problem but I used a custom
interceptor to set the content type. I use it on all requests and responses
to set the content type to: text/xml;charset=UTF-8


-----Original Message-----
From: Trond Kvarenes [mailto:mule.user.relay@...]
Sent: 05 November 2009 11:48
To: user@...
Subject: [mule-user] Re: Content-type: charset when using wsdl-cxf


*************************************

This e-mail has been received by the Revenue Internet e-mail service. (IP)

*************************************

I've also tried using axis, but I think there is a problem with xml encoding.
(<) ??
When sending my message using an axis end-point in Mule I get an error.
If I send the same message using SoapUI, but replacing the < and > and
" with <, > and " it works fine.

What is the best way of connecting to a .net web service?


Regards

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email




*********************************************************************

Please note that Revenue cannot guarantee that any personal
and sensitive data, sent in plain text via standard email,
is fully secure. Customers who choose to use this channel
are deemed to have accepted any risk involved. The alternative
communication methods offered by Revenue include standard post
and the option to register for our (encrypted) secure email service.
http://www.revenue.ie/en/practitioner/secure-email.html

*********************************************************************

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



Re: Content-type: charset when using wsdl-cxf

by Richard Swart :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi.
I tried it, and I got an other error back saying
HTTP/1.1 415 Unsupported Media Type

Why is Mule exchanging the <, > and " ?
SoapUI does not, and can communicate with the .net web service just fine.
How do I use Mule to communicate with a .Net webservice using xml in the payload??
Anyone?


Regards
Trond

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email



Parent Message unknown RE: Content-type: charset when using wsdl-cxf

by Farrell, Kevin (ICTL_eCust_05) :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Hi Trond,

As I understand it the fact that it's a .Net service shouldn't make a
difference to the message Mule sends out.

Something to try would be to change your endpoint:

<outbound-endpoint
address="wsdl-cxf:http://192.168.106.79/MyTest.asmx?WSDL&method=MyMethod"
synchronous="true" />    

to:

<cxf:outbounf-endpoint address="same address you use in SoapUI"
synchronous="true" proxy="true"/>

My Mule has no problem sending out '<' and '>'

Regards,
Kevin.




-----Original Message-----
From: Trond Kvarenes [mailto:mule.user.relay@...]
Sent: 09 November 2009 13:19
To: user@...
Subject: Re: [mule-user] Content-type: charset when using wsdl-cxf


*************************************

This e-mail has been received by the Revenue Internet e-mail service. (IP)

*************************************

Hi.
I tried it, and I got an other error back saying
HTTP/1.1 415 Unsupported Media Type

Why is Mule exchanging the <, > and " ?
SoapUI does not, and can communicate with the .net web service just fine.
How do I use Mule to communicate with a .Net webservice using xml in the
payload??
Anyone?


Regards
Trond

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email




*********************************************************************

Please note that Revenue cannot guarantee that any personal
and sensitive data, sent in plain text via standard email,
is fully secure. Customers who choose to use this channel
are deemed to have accepted any risk involved. The alternative
communication methods offered by Revenue include standard post
and the option to register for our (encrypted) secure email service.
http://www.revenue.ie/en/practitioner/secure-email.html

*********************************************************************

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email