我正在使用 WSO2 api manager 1.10.0.我在使用 multipart/form-data 时遇到问题,实际上我注意到 content type 标头没有传播到我的后端服务,因此我收到了不受支持的媒体类型 415 HTTP 错误.请知道如何解决这个问题?
I'm using WSO2 api manager 1.10.0. I have a problem when using multipart/form-data , in fact i noticed that content type header isn't propagated to my back end service and so I'm getting unsupported media type 415 HTTP error. Please any idea how to fix this?
将以下属性添加到 repository/conf/passthru-http.properties 文件中.http.headers.preserve=内容类型
Add the following property to repository/conf/passthru-http.properties file. http.headers.preserve=Content-Type
这将保留您随请求发送的内容类型标头并将其发送到后端.如果你想保留更多这样的标题,你可以将它们添加到同一行,用逗号分隔.
This will preserve the content type header you send with the request and send it to the backend. If you want to preserve more such headers, you can add them to the same line with comma separated.
这篇关于WSO2 api 管理器不传播多部分表单数据的内容类型标头的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!