Class ArtifactProcessor
- java.lang.Object
-
- jetbrains.buildServer.agent.impl.artifacts.ArtifactProcessor
-
- All Implemented Interfaces:
ArtifactsWatcher,ArtifactsWatcherEx
public class ArtifactProcessor extends Object implements ArtifactsWatcherEx
-
-
Field Summary
Fields Modifier and Type Field Description static StringDISABLE_FILECACHE_PUBLISHINGstatic StringSYMBOLIC_LINKS_TYPE_PARAMETER
-
Constructor Summary
Constructors Constructor Description ArtifactProcessor(ExtensionHolder extensionsLocator, EventDispatcher<AgentLifeCycleListener> agentDispatcher, ArtifactsPublisherProvider publishersProvider, BuildCacheHolder buildCacheHolder)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description List<ArtifactsCollection>addBuildCachePath(String cacheName, String path)Adds givenpathto the cache with namecacheNamevoidaddInternalArtifactsPath(String artifactsPath)voidaddNewArtifactsPath(String artifactsPath)Notifies agent about new path where build artifacts residevoidinit(BuildProgressLogger logger, AgentLogProxy logProxy)voidinterruptPublishing()static booleanisPublishingStopped(AgentRunningBuild build)voidsetArtifactsPublishingPreconditions(Collection<ArtifactsPublishingPrecondition> artifactsPublishingPreconditions)voidsetBuilderListeners(Collection<ArtifactsBuilderListener> builderListeners)voidsetPreprocessors(Collection<ArtifactsPreprocessor> artifactsPreprocessors)voidwaitForPublishingFinish()Wait for publishing is finish.
-
-
-
Field Detail
-
DISABLE_FILECACHE_PUBLISHING
public static final String DISABLE_FILECACHE_PUBLISHING
- See Also:
- Constant Field Values
-
SYMBOLIC_LINKS_TYPE_PARAMETER
public static final String SYMBOLIC_LINKS_TYPE_PARAMETER
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ArtifactProcessor
public ArtifactProcessor(@NotNull ExtensionHolder extensionsLocator, @NotNull EventDispatcher<AgentLifeCycleListener> agentDispatcher, @NotNull ArtifactsPublisherProvider publishersProvider, @NotNull BuildCacheHolder buildCacheHolder)
-
-
Method Detail
-
init
public void init(@NotNull BuildProgressLogger logger, @NotNull AgentLogProxy logProxy)
-
setPreprocessors
public void setPreprocessors(@NotNull Collection<ArtifactsPreprocessor> artifactsPreprocessors)
-
setBuilderListeners
public void setBuilderListeners(@NotNull Collection<ArtifactsBuilderListener> builderListeners)
-
setArtifactsPublishingPreconditions
public void setArtifactsPublishingPreconditions(@NotNull Collection<ArtifactsPublishingPrecondition> artifactsPublishingPreconditions)
-
addInternalArtifactsPath
public void addInternalArtifactsPath(@NotNull String artifactsPath)- Specified by:
addInternalArtifactsPathin interfaceArtifactsWatcherEx
-
addBuildCachePath
public List<ArtifactsCollection> addBuildCachePath(@NotNull String cacheName, @NotNull String path)
Description copied from interface:ArtifactsWatcherExAdds givenpathto the cache with namecacheName- Specified by:
addBuildCachePathin interfaceArtifactsWatcherEx- Parameters:
cacheName- cache namepath- path to add- Returns:
- a collection of artifacts that was supposed to be published (but might not have been published)
-
addNewArtifactsPath
public void addNewArtifactsPath(@NotNull String artifactsPath)Description copied from interface:ArtifactsWatcherNotifies agent about new path where build artifacts reside- Specified by:
addNewArtifactsPathin interfaceArtifactsWatcher- Parameters:
artifactsPath- artifacts path in TeamCity format
-
waitForPublishingFinish
public void waitForPublishingFinish()
Description copied from interface:ArtifactsWatcherWait for publishing is finish. SinceArtifactsWatcher.addNewArtifactsPath(String)only schedules artifacts publishing if client code should wait for publication finishing it should invoke this method. The method will block until publication is finished, failed or cancelled (for example in case of build interruption)- Specified by:
waitForPublishingFinishin interfaceArtifactsWatcher
-
interruptPublishing
public void interruptPublishing()
- Specified by:
interruptPublishingin interfaceArtifactsWatcherEx
-
isPublishingStopped
public static boolean isPublishingStopped(@NotNull AgentRunningBuild build)
-
-