Class WindowsBatchScript
java.lang.Object
hudson.model.AbstractDescribableImpl<DurableTask>
org.jenkinsci.plugins.durabletask.DurableTask
org.jenkinsci.plugins.durabletask.FileMonitoringTask
org.jenkinsci.plugins.durabletask.WindowsBatchScript
- All Implemented Interfaces:
ExtensionPoint,Describable<DurableTask>
Runs a Windows batch script.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.jenkinsci.plugins.durabletask.FileMonitoringTask
FileMonitoringTask.FileMonitoringControllerNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudson -
Field Summary
FieldsFields inherited from class org.jenkinsci.plugins.durabletask.FileMonitoringTask
BINARY_RESOURCE_PREFIX, COOKIE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidRequests that standard output of the task be captured rather than streamed.doLaunch(FilePath ws, Launcher launcher, TaskListener listener, EnvVars envVars) Should start a process which sends output to log file in the workspace and finally writes its exit code to result file.Methods inherited from class org.jenkinsci.plugins.durabletask.FileMonitoringTask
charset, defaultCharset, escape, getAgentInfo, getNodeRoot, launch, launchWithCookie, requestBinary, requestBinaryMethods inherited from class org.jenkinsci.plugins.durabletask.DurableTask
getDescriptor
-
Field Details
-
USE_BINARY_WRAPPER
@Restricted(org.kohsuke.accmod.restrictions.NoExternalUse.class) public static boolean USE_BINARY_WRAPPER
-
-
Constructor Details
-
WindowsBatchScript
-
-
Method Details
-
getScript
-
captureOutput
public void captureOutput()Description copied from class:DurableTaskRequests that standard output of the task be captured rather than streamed. If you useController.watch(hudson.FilePath, org.jenkinsci.plugins.durabletask.Handler, hudson.model.TaskListener), standard output will not be sent toHandler.output(java.io.InputStream); it will be included inHandler.exited(int, byte[])instead. Otherwise (using polling mode), standard output will not be sent toController.writeLog(hudson.FilePath, java.io.OutputStream); callController.getOutput(hudson.FilePath, hudson.Launcher)to collect. Standard error should still be streamed to the log. Should be called prior toDurableTask.launch(hudson.EnvVars, hudson.FilePath, hudson.Launcher, hudson.model.TaskListener)to take effect.- Overrides:
captureOutputin classDurableTask
-
doLaunch
protected FileMonitoringTask.FileMonitoringController doLaunch(FilePath ws, Launcher launcher, TaskListener listener, EnvVars envVars) throws IOException, InterruptedException Description copied from class:FileMonitoringTaskShould start a process which sends output to log file in the workspace and finally writes its exit code to result file.- Overrides:
doLaunchin classFileMonitoringTask- Parameters:
ws- the workspace to uselauncher- a way to launch processeslistener- build console logenvVars- recommended environment for the subprocess- Returns:
- a specialized controller
- Throws:
IOExceptionInterruptedException
-