Class OpenStackConnector

  • All Implemented Interfaces:
    io.vertigo.core.node.component.Connector<org.openstack4j.api.OSClient.OSClientV3>, io.vertigo.core.node.component.CoreComponent

    public class OpenStackConnector
    extends Object
    implements io.vertigo.core.node.component.Connector<org.openstack4j.api.OSClient.OSClientV3>
    Component to handle the authentification and the connection to any OpenStack service.
    Author:
    mlaroche, tingargiola
    • Constructor Detail

      • OpenStackConnector

        @Inject
        public OpenStackConnector​(@Named("authenticationUrl")
                                  String authenticationUrl,
                                  @Named("userDomain")
                                  String userDomain,
                                  @Named("userName")
                                  String userName,
                                  @Named("userSecret")
                                  String userSecret,
                                  @Named("projectDomain")
                                  String projectDomain,
                                  @Named("projectName")
                                  String projectName,
                                  @Named("trustoreFile")
                                  Optional<String> trustoreFileOpt,
                                  @Named("trustorePswd")
                                  Optional<String> trustorePswdOpt,
                                  @Named("enableSSL")
                                  Optional<Boolean> enableSSLOpt,
                                  io.vertigo.core.resource.ResourceManager resourceManager)
        Inject constructor.
        Parameters:
        authenticationUrl - Url of the identity api (ex: https://keystone.openstack.klee.lan.net:5000/v3/)
        userDomain - Domain of the user.
        userName - Name of the user
        userSecret - Password of the user
        projectName - Name of the project
        projectDomain - DOmain of the project
    • Method Detail

      • getClient

        public org.openstack4j.api.OSClient.OSClientV3 getClient()
        Get an OSClientV3 from the connection pool
        Specified by:
        getClient in interface io.vertigo.core.node.component.Connector<org.openstack4j.api.OSClient.OSClientV3>
        Returns:
        the OpenStack client
      • authenticateClient

        protected org.openstack4j.api.OSClient.OSClientV3 authenticateClient​(String authenticationUrl,
                                                                             String domain,
                                                                             String user,
                                                                             String secret,
                                                                             String projectDomain,
                                                                             String projectName,
                                                                             org.openstack4j.core.transport.Config config)