Class AbstractOpenstackRequest<R>

    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      R call()  
      abstract R doRequest​(org.openstack4j.api.OSClient api)
      Carries out the request and returns the response.
      com.elastisys.scale.commons.openstack.ApiAccessConfig getApiAccessConfig()
      Returns the API access configuration that describes how to authenticate with and communicate over the OpenStack API.
      com.elastisys.scale.commons.openstack.OSClientFactory getClientFactory()
      Returns the OpenStack API client factory.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AbstractOpenstackRequest

        public AbstractOpenstackRequest​(com.elastisys.scale.commons.openstack.OSClientFactory clientFactory)
        Constructs a new AbstractOpenstackRequest with a given OSClientFactory.
        Parameters:
        clientFactory - OpenStack API client factory
    • Method Detail

      • call

        public R call()
               throws org.openstack4j.api.exceptions.ResponseException
        Specified by:
        call in interface java.util.concurrent.Callable<R>
        Throws:
        org.openstack4j.api.exceptions.ResponseException
      • getClientFactory

        public com.elastisys.scale.commons.openstack.OSClientFactory getClientFactory()
        Returns the OpenStack API client factory.
        Returns:
      • getApiAccessConfig

        public com.elastisys.scale.commons.openstack.ApiAccessConfig getApiAccessConfig()
        Returns the API access configuration that describes how to authenticate with and communicate over the OpenStack API.
        Returns:
      • doRequest

        public abstract R doRequest​(org.openstack4j.api.OSClient api)
                             throws org.openstack4j.api.exceptions.ResponseException
        Carries out the request and returns the response.
        Parameters:
        api - An authenticated OpenStack API client that is instructed to operate against the configured region.
        Returns:
        The response.
        Throws:
        org.openstack4j.api.exceptions.ResponseException - if the request failed.