Class AbstractProvisionProvider

    • Constructor Detail

      • AbstractProvisionProvider

        public AbstractProvisionProvider()
    • Method Detail

      • hasComputeZonePools

        public java.lang.Boolean hasComputeZonePools()
        Description copied from interface: ProvisioningProvider
        Determines if this provision type has ComputeZonePools that can be selected or not.
        Specified by:
        hasComputeZonePools in interface ProvisioningProvider
        Returns:
        Boolean representation of whether or not this provision type has ComputeZonePools
      • canCustomizeRootVolume

        public java.lang.Boolean canCustomizeRootVolume()
        Description copied from interface: ProvisioningProvider
        Indicates if the root volume may be customized during provisioning. For example, the size changed
        Specified by:
        canCustomizeRootVolume in interface ProvisioningProvider
        Returns:
        Boolean
      • canCustomizeDataVolumes

        public java.lang.Boolean canCustomizeDataVolumes()
        Description copied from interface: ProvisioningProvider
        Indicates if data volumes may be customized during provisioning. For example, the size changed
        Specified by:
        canCustomizeDataVolumes in interface ProvisioningProvider
        Returns:
        Boolean
      • networksScopedToPools

        public java.lang.Boolean networksScopedToPools()
        Description copied from interface: ProvisioningProvider
        Indicates if Network selection should be scoped to the ComputeZonePool selected during provisioning
        Specified by:
        networksScopedToPools in interface ProvisioningProvider
        Returns:
        Boolean
      • hasConfigurableSockets

        public java.lang.Boolean hasConfigurableSockets()
        Description copied from interface: ProvisioningProvider
        Indicates if the sockets are configurable when deploying a ComputeServer via a custom plan
        Specified by:
        hasConfigurableSockets in interface ProvisioningProvider
        Returns:
        Boolean
      • prepareWorkload

        public ServiceResponse prepareWorkload​(Workload workload,
                                               WorkloadRequest workloadRequest,
                                               java.util.Map opts)
        Description copied from interface: ProvisioningProvider
        This method is called before runWorkload and provides an opportunity to perform action or obtain configuration that will be needed in runWorkload. At the end of this method, if deploying a ComputeServer with a VirtualImage, the sourceImage on ComputeServer should be determined and saved.
        Specified by:
        prepareWorkload in interface ProvisioningProvider
        Parameters:
        workload - the Workload object we intend to provision along with some of the associated data needed to determine how best to provision the workload
        workloadRequest - the RunWorkloadRequest object containing the various configurations that may be needed in running the Workload. This will be passed along into runWorkload
        opts - additional configuration options that may have been passed during provisioning
        Returns:
        Response from API
      • prepareHost

        public ServiceResponse prepareHost​(ComputeServer server,
                                           HostRequest hostRequest,
                                           java.util.Map opts)
        Description copied from interface: ProvisioningProvider
        This method is called before runHost and provides an opportunity to perform action or obtain configuration that will be needed in runHost. At the end of this method, if deploying a ComputeServer with a VirtualImage, the sourceImage on ComputeServer should be determined and saved.
        Specified by:
        prepareHost in interface ProvisioningProvider
        Parameters:
        server - the ComputeServer object we intend to provision along with some of the associated data needed to determine how best to provision the server
        hostRequest - the HostRequest object containing the various configurations that may be needed in running the server. This will be passed along into runHost
        opts - additional configuration options that may have been passed during provisioning
        Returns:
        Response from API
      • runHost

        public ServiceResponse<HostResponse> runHost​(ComputeServer server,
                                                     HostRequest hostRequest,
                                                     java.util.Map opts)
        Description copied from interface: ProvisioningProvider
        This method is called to provision a Host (i.e. Docker host). Information associated with the passed ComputeServer object is used to kick off the provision request. Implementations of this method should populate HostResponse as complete as possible and as quickly as possible. Implementations may choose to save the externalId on the ComputeServer or pass it back in HostResponse.
        Specified by:
        runHost in interface ProvisioningProvider
        Parameters:
        server - the ComputeServer object we intend to provision along with some of the associated data needed to determine how best to provision the server
        hostRequest - the HostRequest object containing the various configurations that may be needed in running the server.
        opts - additional configuration options that may have been passed during provisioning
        Returns:
        Response from API
      • waitForHost

        public ServiceResponse<HostResponse> waitForHost​(ComputeServer server)
        Description copied from interface: ProvisioningProvider
        This method is called after runHost returns successfully and provides implementations a mechanism to wait for the ComputeServer to finish the creation process in the underlying Cloud. HostResponse should be filled out as complete as possible.
        Specified by:
        waitForHost in interface ProvisioningProvider
        Parameters:
        server - the ComputeServer object to wait for
        Returns:
      • finalizeHost

        public ServiceResponse finalizeHost​(ComputeServer server)
        Description copied from interface: ProvisioningProvider
        This method is called after successful completion of runHost and successful completion of waitForHost and provides an opportunity to perform some final actions during the provisioning process. For example, ejected CDs, cleanup actions, etc
        Specified by:
        finalizeHost in interface ProvisioningProvider
        Parameters:
        server - the ComputeServer object that has been provisioned
        Returns:
        Response from the API
      • finalizeWorkload

        public ServiceResponse finalizeWorkload​(Workload workload)
        Description copied from interface: ProvisioningProvider
        This method is called after successful completion of runWorkload and provides an opportunity to perform some final actions during the provisioning process. For example, ejected CDs, cleanup actions, etc
        Specified by:
        finalizeWorkload in interface ProvisioningProvider
        Parameters:
        workload - the Workload object that has been provisioned
        Returns:
        Response from the API
      • findVmNodeServerTypeForCloud

        public ComputeServerType findVmNodeServerTypeForCloud​(java.lang.Long cloudId,
                                                              java.lang.String platform,
                                                              java.lang.String provisionTypeCode)
      • getRootSize

        public java.lang.Long getRootSize​(Workload workload)