Interface StashManager.StashAwareArtifactManager
- Enclosing class:
- StashManager
public static interface StashManager.StashAwareArtifactManager
Mixin interface for an
ArtifactManager which supports specialized stash behavior as well.
When implementing off-Jenkins artifact storage, you should NOT extend this directly but instead use the
JCloudsArtifactManager in the plugin currently named artifact-manager-s3.
This is dangerous to directly extend if using remote storage unless you write a very robust handling of network failures including at least a base timeout and retries.
The JCloudsArtifactManager implementation supports extensibility to various cloud providers and custom stores via the BlobStoreProvider ExtensionPoint.
It handles all aspects of making cloud artifact storage work smoothly in Jenkins
including the VirtualFile implementation, robust network error handling, overall configuration UI, and more.
Implement this interface directly at your own risk.
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidclearAllStashes(TaskListener listener) voidcopyAllArtifactsAndStashes(Run<?, ?> to, TaskListener listener) Copy all stashes and artifacts from one build to another.voidstash(String name, FilePath workspace, Launcher launcher, EnvVars env, TaskListener listener, String includes, String excludes, boolean useDefaultExcludes, boolean allowEmpty) void
-
Method Details
-
stash
void stash(@NonNull String name, @NonNull FilePath workspace, @NonNull Launcher launcher, @NonNull EnvVars env, @NonNull TaskListener listener, @CheckForNull String includes, @CheckForNull String excludes, boolean useDefaultExcludes, boolean allowEmpty) throws IOException, InterruptedException -
unstash
void unstash(@NonNull String name, @NonNull FilePath workspace, @NonNull Launcher launcher, @NonNull EnvVars env, @NonNull TaskListener listener) throws IOException, InterruptedException -
clearAllStashes
- Throws:
IOExceptionInterruptedException- See Also:
-
copyAllArtifactsAndStashes
void copyAllArtifactsAndStashes(@NonNull Run<?, ?> to, @NonNull TaskListener listener) throws IOException, InterruptedExceptionCopy all stashes and artifacts from one build to another. TheArtifactManagerconfiguration will be as of the origin build. If the implementation cannot handletofor whatever reason, it may throwAbortException.- Throws:
IOExceptionInterruptedException- See Also:
-