Hi

See this FAQ
http://camel.apache.org/how-do-i-use-dynamic-uri-in-to.html

On Thu, Oct 25, 2012 at 5:24 PM, rouble <r.ou...@gmail.com> wrote:
> Actually, there was a configuration issue on my side. The to endpoints
> url was not complete. The WSDL does get proxied fine.
>
> Can someone help with my other question, how do I dynamically set the
> hostname and port of the to endpoint in this cxf proxy case. My camel
> route looks like this:
>


> from("servlet:///proxyWebService/api/?matchOnUriPrefix=true")
> .process (
>     //Do something here to override hostname and port of the realWebService
> )
> .to("https4://realWebService:8443/api/?bridgeEndpoint=true&throwExceptionOnFailure=false");
>
> tia,
> rouble
>
> On Thu, Oct 25, 2012 at 3:30 AM, Willem jiang <willem.ji...@gmail.com> wrote:
>> Hi,
>>
>> Which version of camel are you using?
>> I just did some test against the camel trunk ( camel-2.11-SNAPSHOT). I 
>> cannot reproduce the error.
>>
>> BTW, you should be able to get the message header "CamelHttpQuery" with 
>> value of "wsdl". Hope you can find workaround with this message header.
>>
>> --
>> Willem Jiang
>>
>> Red Hat, Inc.
>> FuseSource is now part of Red Hat
>> Web: http://www.fusesource.com | http://www.redhat.com
>> Blog: http://willemjiang.blogspot.com (http://willemjiang.blogspot.com/) 
>> (English)
>>           http://jnn.javaeye.com (http://jnn.javaeye.com/) (Chinese)
>> Twitter: willemjiang
>> Weibo: willemjiang
>>
>>
>>
>>
>>
>> On Wednesday, October 24, 2012 at 9:29 PM, rouble wrote:
>>
>>> Camel Gurus,
>>>
>>> I have setup DSL in Java to proxy a web service. However I am having
>>> trouble proxying the actual WSDL.
>>>
>>> To proxy the web service I do the following:
>>> from("servlet:///proxyWebService/api/?matchOnUriPrefix=true")
>>> .to("https4://realWebService:8443/api/?bridgeEndpoint=true&throwExceptionOnFailure=false");
>>>
>>> The above DSL proxies the service fine, but does not proxy a WSDL
>>> request properly.
>>>
>>> So, for instance if the WSDL lives here:
>>> http://remote-host/realWebService/api/FooService?wsdl Any request to
>>> http://proxy-host/proxyWebService/api/FooService?wsdl should get
>>> proxied, but i think since I have bridgeEndpoint set to true, the
>>> Exchange.HTTP_URI gets overridden by the "to endpoint" - so it
>>> probably drops the FooService?wsdl portion when routing the GET
>>> request. Any ideas on how to get this to work? I tried some things in
>>> an intermediate process() leg, but nothing took.
>>>
>>> Also - what is the right way to dynamically set the hostname and port
>>> of the "to endpoint"?
>>>
>>> tia,
>>> rouble
>>
>>
>>



-- 
Claus Ibsen
-----------------
Red Hat, Inc.
FuseSource is now part of Red Hat
Email: cib...@redhat.com
Web: http://fusesource.com
Twitter: davsclaus
Blog: http://davsclaus.com
Author of Camel in Action: http://www.manning.com/ibsen

Reply via email to