public class OSClientFactory extends Object
OSClient objects ready for use.| Constructor and Description |
|---|
OSClientFactory(OpenStackPoolDriverConfig apiAccessConfig)
Creates an
OSClientFactory with a StandardOSClientCreator
creating clients according to the given configuration. |
OSClientFactory(OpenStackPoolDriverConfig apiAccessConfig,
com.elastisys.scale.cloudpool.openstack.driver.client.OSClientFactory.OSClientCreator creator)
Creates an
OSClientFactory with a custom OSClientCreator. |
| Modifier and Type | Method and Description |
|---|---|
org.openstack4j.api.OSClient |
authenticatedClient()
Returns an OpenStack API client, authenticated and configured according
to the
OpenStackPoolDriverConfig provided at construction-time. |
OpenStackPoolDriverConfig |
getApiAccessConfig()
Returns the API access configuration that describes how to authenticate
with and communicate over the OpenStack API.
|
public OSClientFactory(OpenStackPoolDriverConfig apiAccessConfig)
OSClientFactory with a StandardOSClientCreator
creating clients according to the given configuration.apiAccessConfig - API access configuration that describes how to authenticate
with and communicate over the OpenStack API.public OSClientFactory(OpenStackPoolDriverConfig apiAccessConfig, com.elastisys.scale.cloudpool.openstack.driver.client.OSClientFactory.OSClientCreator creator)
OSClientFactory with a custom OSClientCreator.apiAccessConfig - API access configuration that describes how to authenticate
with and communicate over the OpenStack API.public org.openstack4j.api.OSClient authenticatedClient()
OpenStackPoolDriverConfig provided at construction-time.
Note: the returned OSClient is bound to the calling thread
(since Openstack4j uses thread-scoped sessions) and should therefore
never be used by a different thread. If another thread needs to make use
of an OSClient, pass the OSClientFactory to that thread
and make a new call to authenticatedClient().OSClient ready for use.public OpenStackPoolDriverConfig getApiAccessConfig()
Copyright © 2011–2016 elastisys. All rights reserved.