All services registered in the OSGi service registry provide the whole bundle header dictionary as vendor property value.
Contributed by Christoph Fiehe <christoph.fiehe at materna.de> git-svn-id: https://svn.apache.org/repos/asf/httpcomponents/httpclient/trunk@1756280 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
1b9c13afa9
commit
1d6d8ae8c2
|
@ -95,14 +95,14 @@ public final class HttpProxyConfigurationActivator implements BundleActivator, M
|
|||
// ensure we receive configurations for the proxy selector
|
||||
final Hashtable<String, Object> props = new Hashtable<>();
|
||||
props.put(Constants.SERVICE_PID, getName());
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders().get(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_DESCRIPTION, PROXY_SERVICE_FACTORY_NAME);
|
||||
|
||||
configurator = context.registerService(ManagedServiceFactory.class, this, props);
|
||||
|
||||
props.clear();
|
||||
props.put(Constants.SERVICE_PID, TRUSTED_HOSTS_PID);
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders().get(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_DESCRIPTION, TRUSTED_HOSTS_SERVICE_NAME);
|
||||
trustedHostConfiguration = context.registerService(ManagedService.class,
|
||||
new OSGiTrustedHostsConfiguration(),
|
||||
|
@ -110,7 +110,7 @@ public final class HttpProxyConfigurationActivator implements BundleActivator, M
|
|||
|
||||
props.clear();
|
||||
props.put(Constants.SERVICE_PID, BUILDER_FACTORY_SERVICE_PID);
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders().get(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_DESCRIPTION, BUILDER_FACTORY_SERVICE_NAME);
|
||||
clientFactory = context.registerService(HttpClientBuilderFactory.class,
|
||||
new OSGiClientBuilderFactory(context,
|
||||
|
@ -121,7 +121,7 @@ public final class HttpProxyConfigurationActivator implements BundleActivator, M
|
|||
|
||||
props.clear();
|
||||
props.put(Constants.SERVICE_PID, CACHEABLE_BUILDER_FACTORY_SERVICE_PID);
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_VENDOR, context.getBundle().getHeaders().get(Constants.BUNDLE_VENDOR));
|
||||
props.put(Constants.SERVICE_DESCRIPTION, CACHEABLE_BUILDER_FACTORY_SERVICE_NAME);
|
||||
cachingClientFactory = context.registerService(CachingHttpClientBuilderFactory.class,
|
||||
new OSGiCachingClientBuilderFactory(context,
|
||||
|
|
Loading…
Reference in New Issue