Hello:

I'm using Apache CXF 2.7.3 to invoke a WS from a servlet instance.
So I defined a proxy client with <jaxws:client> and I injected it to that
servlet instance.


I need to set Host HTTP header when invoking remote WS.
And it always will be the same value ( the remote host )

I would like to define under <http-conduit> configuration but i don't know
if this is possible
Another option is to create a outgoing interceptor and define this header,
but I would prefer to define it in XML context file.

Other question is about thread-safe behaviour:
as I told you , I inject that client ( proxy ) to servlet instance.
Can I add HTTP header by code in a thread-safe way ?

I've read about

((BindingProvider)proxy).getRequestContext().put("thread.local.request.context",
"true");

and I could execute this code when I inject the proxy client ( if you say
to me that to modify HTTP headers can be a problem )
Or can I define this property in XML context ?


Thanks and regards

Reply via email to