You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@camel.apache.org by "Willem Jiang (JIRA)" <ji...@apache.org> on 2010/08/20 13:07:48 UTC

[jira] Resolved: (CAMEL-3059) HTTP Proxy Mulitpart Requests

     [ https://issues.apache.org/activemq/browse/CAMEL-3059?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Willem Jiang resolved CAMEL-3059.
---------------------------------

    Resolution: Fixed

Applied patch with thanks to Chris.

> HTTP Proxy Mulitpart Requests
> -----------------------------
>
>                 Key: CAMEL-3059
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-3059
>             Project: Apache Camel
>          Issue Type: Improvement
>          Components: camel-jetty
>    Affects Versions: 2.4.0
>            Reporter: Chris Nelson
>            Assignee: Willem Jiang
>             Fix For: 2.5.0
>
>         Attachments: HttpBridgeMultipartRouteTest.java, JettyHttpComponent.patch, JettyHttpEndpoint.patch
>
>
> I am trying to create an HTTP proxy that will support mulitpart requests. I was hoping I could do something like below, but the attachments do not get sent out. The attachments are parsed by the Jetty MultiPart filter and put into the in message, but they do not get sent out by the HTTP client.
> from("jetty:http://xxx?bridgeEndpoint=true").to("http://xxx?bridgeEndpoint=true");
> To workaround this problem, I modified the JettyHttpComponent and JettyHttpEndpoint classes to use a new enableMultipartFilter flag. If this is set to false it will not enable the Jetty multipart filter, and thus the entire request will be proxied through. In the case of the bridgeEndpoint it seems like this should be the default, but I wasn't sure what else this might break. I have attached patches against the 2.5.0 codebase for these two classes and a test case that shows how it can be used. In the test case you will notice I have to override the the outbound filter strategy so that it passes the original headers (i.e. content type). Again this seems like something that would be the default for the bridged endpoint.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.