Character encoding 从WSO2 ESB中的内容类型中删除字符集
我得到了一个需要调用的RESTful服务Character encoding 从WSO2 ESB中的内容类型中删除字符集,character-encoding,wso2,content-type,Character Encoding,Wso2,Content Type,我得到了一个需要调用的RESTful服务 Content-Type: application/xml 问题在于WSO2 ESB会自动添加一个字符集: Content-Type: application/xml; charset=UTF-8 该服务不支持的 在WSO2 ESB中,服务的调用方式如下: <header action="set" expression="get-property('PhysicalAddress')" name=
Content-Type: application/xml
问题在于WSO2 ESB会自动添加一个字符集:
Content-Type: application/xml; charset=UTF-8
该服务不支持的
在WSO2 ESB中,服务的调用方式如下:
<header action="set"
expression="get-property('PhysicalAddress')" name="To"/>
<property action="set" name="HTTP_METHOD" scope="axis2"
type="STRING" value="PUT"/>
<property action="set"
expression="concat('Basic ', base64Encode(concat(get-property('LOGIN'),':',get-property('PASSWORD'))))"
name="Authorization" scope="transport" type="STRING"/>
<property action="set" name="messageType" scope="axis2"
type="STRING" value="application/xml"/>
<call>
<endpoint>
<default format="rest">
<timeout>
<duration>120000</duration>
<responseAction>fault</responseAction>
</timeout>
</default>
</endpoint>
</call>
120000
过错
如何从内容类型标头中删除字符集
谢谢您可以使用下面的属性并更改ContentType标题
<property name="ContentType" value="application/xml" scope="axis2" type="STRING"/>
将属性
setCharacterEncoding
设置为false
此属性不会从内容类型标题中删除charset=UTF-8