You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by Aaron Stromas <pa...@gmail.com> on 2012/08/07 23:51:26 UTC

How to replace the endpoint in WSDL

Hi,

I thought it should be simple but I'm really struggling with this one. The
WSDL I have received specifies one endpoint but in the client I need to use
a different one, essentially, a different hostname and port.

Can I do it programmatically, or do I have to edit the WSDL?

Thanks,

-- 
Aaron Stromas

Re: How to replace the endpoint in WSDL

Posted by Aaron Stromas <pa...@gmail.com>.
Thank you, Mark and Freeman.

On 7 August 2012 20:47, Freeman Fang <fr...@gmail.com> wrote:

> Hi,
> Yep,  client proxy can specify BindingProvider.ENDPOINT_ADDRESS_PROPERTY
> on the fly, some code like
>
> ((BindingProvider)
> port).getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, "
> http://whatever_address_you_want");
>
> Freeman
> -------------
> Freeman Fang
>
> FuseSource
> Email:ffang@fusesource.com
> Web: fusesource.com
> Twitter: freemanfang
> Blog: http://freemanfang.blogspot.com
> http://blog.sina.com.cn/u/1473905042
> weibo: http://weibo.com/u/1473905042
>
> On 2012-8-8, at 上午6:22, Mark Streit wrote:
>
> > Perhaps this thread, on what appears to be similar, will help:
> >
> >
> http://cxf.547215.n5.nabble.com/Connect-to-url-not-in-WSDL-tp5711974p5712059.html
> >
> >
> >
> > On Tue, Aug 7, 2012 at 5:51 PM, Aaron Stromas <pa...@gmail.com>
> wrote:
> >
> >> Hi,
> >>
> >> I thought it should be simple but I'm really struggling with this one.
> The
> >> WSDL I have received specifies one endpoint but in the client I need to
> use
> >> a different one, essentially, a different hostname and port.
> >>
> >> Can I do it programmatically, or do I have to edit the WSDL?
> >>
> >> Thanks,
> >>
> >> --
> >> Aaron Stromas
> >>
> >
> >
> >
> > Mark
>
>


-- 
Aaron Stromas
Mobile: +1 703 203 9169

Re: How to replace the endpoint in WSDL

Posted by Freeman Fang <fr...@gmail.com>.
Hi,
Yep,  client proxy can specify BindingProvider.ENDPOINT_ADDRESS_PROPERTY on the fly, some code like

((BindingProvider) port).getRequestContext().put(BindingProvider.ENDPOINT_ADDRESS_PROPERTY, "http://whatever_address_you_want");

Freeman
-------------
Freeman Fang

FuseSource
Email:ffang@fusesource.com
Web: fusesource.com
Twitter: freemanfang
Blog: http://freemanfang.blogspot.com
http://blog.sina.com.cn/u/1473905042
weibo: http://weibo.com/u/1473905042

On 2012-8-8, at 上午6:22, Mark Streit wrote:

> Perhaps this thread, on what appears to be similar, will help:
> 
> http://cxf.547215.n5.nabble.com/Connect-to-url-not-in-WSDL-tp5711974p5712059.html
> 
> 
> 
> On Tue, Aug 7, 2012 at 5:51 PM, Aaron Stromas <pa...@gmail.com> wrote:
> 
>> Hi,
>> 
>> I thought it should be simple but I'm really struggling with this one. The
>> WSDL I have received specifies one endpoint but in the client I need to use
>> a different one, essentially, a different hostname and port.
>> 
>> Can I do it programmatically, or do I have to edit the WSDL?
>> 
>> Thanks,
>> 
>> --
>> Aaron Stromas
>> 
> 
> 
> 
> Mark


Re: How to replace the endpoint in WSDL

Posted by Mark Streit <mc...@gmail.com>.
Perhaps this thread, on what appears to be similar, will help:

http://cxf.547215.n5.nabble.com/Connect-to-url-not-in-WSDL-tp5711974p5712059.html



On Tue, Aug 7, 2012 at 5:51 PM, Aaron Stromas <pa...@gmail.com> wrote:

> Hi,
>
> I thought it should be simple but I'm really struggling with this one. The
> WSDL I have received specifies one endpoint but in the client I need to use
> a different one, essentially, a different hostname and port.
>
> Can I do it programmatically, or do I have to edit the WSDL?
>
> Thanks,
>
> --
> Aaron Stromas
>



Mark