From: Chris B. <cbr...@re...> - 2011-08-17 19:40:17
|
On 08/17/2011 03:32 PM, Xavier Vanderstukken wrote: > I am using ProxyFactory on the client-side to made request and it is > working like a charm. > > i.e. according to the documentation: > > MyInterface proxy = ProxyFactory.create(MyInterface.class, "http://localhost:8081"); > ClientResponse response = (ClientResponse)proxy.getMyListOfJAXBObjects(); > > > I have added server side security and now I don't find how I can add > request header to let the user authentificate himself. We use an Executor for this. Specifically, we implement ApacheHttpClientExecutor and that gives access to all the HTTP bits we need to modify. Then we use ProxyFactory.create(Class, String, Executor) to use that executor when it is needed. HTH, Chris |