Interface CloudInstanceManager
-
- All Known Subinterfaces:
CloudManager
- All Known Implementing Classes:
CloudManagerFacade
,SecuredCloudManager
public interface CloudInstanceManager
- Author:
- Eugene Petrenko Created: 30.09.2009 19:05:12
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description CanStartNewInstanceResult
canStartNewInstance(CloudProfile profile, CloudImage image)
Indicates whether it's possible to start a new instance of a certain image in particular cloud profilevoid
iterateInstances(CloudInstancesProviderCallback callback)
Deprecated.void
iterateInstances(CloudInstancesProviderExtendedCallback callback)
Iterates through all running instances of all profiles.void
iterateProfileInstances(CloudProfile profile, CloudInstancesProviderExtendedCallback callback)
Iterates through all running instances of all profiles.CloudInstance
startInstance(String projectId, String profileId, String imageId, StartInstanceReason reason)
Starts new agent instance for given profile and imageCloudInstance
startInstance(String profileId, String imageId, StartInstanceReason reason)
Deprecated.void
terminateInstance(String projectId, String profileId, String imageId, String instanceId, TerminateInstanceReason reason)
Schedules termination a running instancevoid
terminateInstance(String profileId, String imageId, String instanceId, TerminateInstanceReason reason)
Deprecated.use $instead
void
terminateProfileInstances(String projectId, String profileId, TerminateInstanceReason reason)
Terminate all running instance for the profilevoid
terminateProfileInstances(String profileId, TerminateInstanceReason reason)
Deprecated.use $instead
void
terminateProjectInstances(String projectId, TerminateInstanceReason reason, boolean subProjectsOnly)
Terminate all running instance
-
-
-
Method Detail
-
startInstance
@NotNull CloudInstance startInstance(@NotNull String projectId, @NotNull String profileId, @NotNull String imageId, @NotNull StartInstanceReason reason) throws StartAgentQuotaExceededException, FailedToStartInstanceException
Starts new agent instance for given profile and image- Parameters:
projectId
- projectIdprofileId
- profileIdimageId
- imageIdreason
- reason why instance is stared. Used for logging- Throws:
StartAgentQuotaExceededException
- if there is not enough quotaFailedToStartInstanceException
- if image or profile was not found
-
startInstance
@NotNull @Deprecated CloudInstance startInstance(@NotNull String profileId, @NotNull String imageId, @NotNull StartInstanceReason reason) throws StartAgentQuotaExceededException, FailedToStartInstanceException
Deprecated.
-
terminateInstance
@Deprecated void terminateInstance(@NotNull String profileId, @NotNull String imageId, @NotNull String instanceId, @NotNull TerminateInstanceReason reason)
Deprecated.use $instead
-
terminateInstance
void terminateInstance(@NotNull String projectId, @NotNull String profileId, @NotNull String imageId, @NotNull String instanceId, @NotNull TerminateInstanceReason reason)
Schedules termination a running instance- Parameters:
projectId
- projectIdprofileId
- profileIdimageId
- imageIdinstanceId
- instanceIdreason
- reason why instance is terminated. Used for logging- Throws:
FailedToStopInstanceException
- if image, profile, or instance was not found
-
terminateProfileInstances
@Deprecated void terminateProfileInstances(@NotNull String profileId, @NotNull TerminateInstanceReason reason)
Deprecated.use $instead
-
terminateProfileInstances
void terminateProfileInstances(@NotNull String projectId, @NotNull String profileId, @NotNull TerminateInstanceReason reason)
Terminate all running instance for the profile- Parameters:
projectId
- projectIdprofileId
- profileIdreason
- reason of temination
-
terminateProjectInstances
void terminateProjectInstances(@NotNull String projectId, @NotNull TerminateInstanceReason reason, boolean subProjectsOnly)
Terminate all running instance- Parameters:
projectId
-reason
- reason of terminationsubProjectsOnly
-
-
iterateInstances
@Deprecated void iterateInstances(@NotNull CloudInstancesProviderCallback callback)
Deprecated.Iterates through all running instances of all profiles.- Parameters:
callback
- uses this interface to notify next instance
-
iterateInstances
void iterateInstances(@NotNull CloudInstancesProviderExtendedCallback callback)
Iterates through all running instances of all profiles.- Parameters:
callback
- uses this interface to notify next instance
-
iterateProfileInstances
void iterateProfileInstances(@NotNull CloudProfile profile, @NotNull CloudInstancesProviderExtendedCallback callback)
Iterates through all running instances of all profiles.- Parameters:
callback
- uses this interface to notify next instance- Since:
- 2019.2
-
canStartNewInstance
@NotNull CanStartNewInstanceResult canStartNewInstance(@NotNull CloudProfile profile, @NotNull CloudImage image)
Indicates whether it's possible to start a new instance of a certain image in particular cloud profile- Parameters:
profile
-image
-- Returns:
- see above
- Since:
- 2019.2
-
-