The cleanest way to add authorization or any other technical capability like logging is to add a CXF feature to the client. If you are lucky then there is already a suitable feature. If not then you have to create your own feature and interceptor for adding the header.
How do you create the client? Christian 2018-03-01 19:43 GMT+01:00 Michael Wirth via osgi-dev < osgi-dev@mail.osgi.org>: > I’m using Apache CXF in an OSGi-Application to call REST-Services provided > from another (spring) application. > I give the path-interface (generated with swagger) to my > osgi-client-appliation. While runtime, Apache CXF generates the client > proxy interface, calls the REST-Service and deserialize the returned json > to the swagger generated objects. All works fine :-) > Now I miss one thing. For Authorization I have to add a header. Because I > do not have the ‚Client‘-Instanze (WebTarget for instance) I’m not able to > add an header. Is there some property, configuration or a service which can > be used? > > Best Regards, > Michael > _______________________________________________ > OSGi Developer Mail List > osgi-dev@mail.osgi.org > https://mail.osgi.org/mailman/listinfo/osgi-dev -- -- Christian Schneider http://www.liquid-reality.de Computer Scientist http://www.adobe.com
_______________________________________________ OSGi Developer Mail List osgi-dev@mail.osgi.org https://mail.osgi.org/mailman/listinfo/osgi-dev