Class UpdateInstancesCollectionTaskImpl
- java.lang.Object
-
- jetbrains.buildServer.clouds.server.impl.instances.UpdateInstancesCollectionTaskImpl
-
- All Implemented Interfaces:
CloudInstancesProviderCallback
,CloudInstancesProviderExtendedCallback
,UpdateInstancesCollectionTask
public class UpdateInstancesCollectionTaskImpl extends Object implements UpdateInstancesCollectionTask
- Author:
- Eugene Petrenko Created: 09.11.2009 20:38:14
-
-
Constructor Summary
Constructors Constructor Description UpdateInstancesCollectionTaskImpl(Map<Pair<String,String>,InstanceUpdateTask> tasks, InstanceUpdateTaskFactory factory, BuildAgentManager agents)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
finished()
Notifies process is finishedMap<Pair<String,String>,InstanceUpdateTask>
getNewTasks()
void
processClient(CloudProfile profile)
process clientvoid
processClientError(CloudProfile profile, CloudErrorInfo cloudErrorInfo)
Called if - client error occouredboolean
processImage(CloudProfile profile, CloudImage image)
Indicates whether to process this particular image.void
processImageError(CloudProfile profile, CloudImage image)
Called if - image error occouredboolean
processInstance(CloudProfile profile, CloudInstance instance)
Processes instance and indicates whether to process next allocated instancevoid
processInstanceError(CloudProfile profile, CloudInstance instance)
Called if - instance error occouredvoid
processInstanceExpired(CloudProfile profile, CloudClientEx cli, CloudInstance instance)
Called if - instance is expired and should be terminated waiting if necessary for the current build to finishvoid
processNotReady(CloudProfile profile)
Called if - client is still connecting - client error occoured - image error occoured - instance error occoured-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface jetbrains.buildServer.clouds.server.CloudInstancesProviderExtendedCallback
processInstanceMaintained
-
-
-
-
Constructor Detail
-
UpdateInstancesCollectionTaskImpl
public UpdateInstancesCollectionTaskImpl(Map<Pair<String,String>,InstanceUpdateTask> tasks, InstanceUpdateTaskFactory factory, BuildAgentManager agents)
-
-
Method Detail
-
processInstance
public boolean processInstance(@NotNull CloudProfile profile, @NotNull CloudInstance instance)
Description copied from interface:CloudInstancesProviderCallback
Processes instance and indicates whether to process next allocated instance- Specified by:
processInstance
in interfaceCloudInstancesProviderCallback
- Parameters:
profile
- profileinstance
- instance- Returns:
- true to continue iteration and false otherwise
-
processImage
public boolean processImage(@NotNull CloudProfile profile, @NotNull CloudImage image)
Description copied from interface:CloudInstancesProviderCallback
Indicates whether to process this particular image. UnlikeCloudInstancesProviderCallback.processInstance(CloudProfile, CloudInstance)
returning false will skip just this image and continue further processing- Specified by:
processImage
in interfaceCloudInstancesProviderCallback
- Returns:
- true to process this image
-
finished
public void finished()
Description copied from interface:UpdateInstancesCollectionTask
Notifies process is finished- Specified by:
finished
in interfaceUpdateInstancesCollectionTask
-
getNewTasks
@NotNull public Map<Pair<String,String>,InstanceUpdateTask> getNewTasks()
- Specified by:
getNewTasks
in interfaceUpdateInstancesCollectionTask
- Returns:
- New tasks to monitor
-
processNotReady
public void processNotReady(@NotNull CloudProfile profile)
Description copied from interface:CloudInstancesProviderExtendedCallback
Called if - client is still connecting - client error occoured - image error occoured - instance error occoured- Specified by:
processNotReady
in interfaceCloudInstancesProviderExtendedCallback
- Parameters:
profile
- profile
-
processClientError
public void processClientError(@NotNull CloudProfile profile, @NotNull CloudErrorInfo cloudErrorInfo)
Description copied from interface:CloudInstancesProviderExtendedCallback
Called if - client error occoured- Specified by:
processClientError
in interfaceCloudInstancesProviderExtendedCallback
- Parameters:
profile
- profile
-
processClient
public void processClient(@NotNull CloudProfile profile)
Description copied from interface:CloudInstancesProviderExtendedCallback
process client- Specified by:
processClient
in interfaceCloudInstancesProviderExtendedCallback
-
processImageError
public void processImageError(@NotNull CloudProfile profile, @NotNull CloudImage image)
Description copied from interface:CloudInstancesProviderExtendedCallback
Called if - image error occoured- Specified by:
processImageError
in interfaceCloudInstancesProviderExtendedCallback
- Parameters:
profile
- profileimage
- errorneous image
-
processInstanceError
public void processInstanceError(@NotNull CloudProfile profile, @NotNull CloudInstance instance)
Description copied from interface:CloudInstancesProviderExtendedCallback
Called if - instance error occoured- Specified by:
processInstanceError
in interfaceCloudInstancesProviderExtendedCallback
- Parameters:
profile
- profileinstance
- errorneous instance
-
processInstanceExpired
public void processInstanceExpired(@NotNull CloudProfile profile, @NotNull CloudClientEx cli, @NotNull CloudInstance instance)
Description copied from interface:CloudInstancesProviderExtendedCallback
Called if - instance is expired and should be terminated waiting if necessary for the current build to finish- Specified by:
processInstanceExpired
in interfaceCloudInstancesProviderExtendedCallback
- Parameters:
profile
- profileinstance
- expired instance
-
-