Package com.uipath.uipathpackage
Class UiPathRunJob
java.lang.Object
hudson.tasks.BuildStepCompatibilityLayer
hudson.tasks.Publisher
hudson.tasks.Recorder
com.uipath.uipathpackage.UiPathRunJob
- All Implemented Interfaces:
ExtensionPoint,Describable<Publisher>,BuildStep,SimpleBuildStep
Class responsible for running a job in orchestrator
instance provided by the user.
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class hudson.tasks.Publisher
Publisher.DescriptorExtensionListImplNested classes/interfaces inherited from interface hudson.tasks.BuildStep
BuildStep.PublisherListNested classes/interfaces inherited from interface hudson.ExtensionPoint
ExtensionPoint.LegacyInstancesAreScopedToHudsonNested classes/interfaces inherited from interface jenkins.tasks.SimpleBuildStep
SimpleBuildStep.LastBuildAction, SimpleBuildStep.LastBuildActionFactory -
Field Summary
Fields inherited from interface hudson.tasks.BuildStep
BUILDERS, PUBLISHERS -
Constructor Summary
ConstructorsConstructorDescriptionUiPathRunJob(String processName, String parametersFilePath, StartProcessDtoJobPriority priority, SelectEntry strategy, SelectEntry jobType, String resultFilePath, Integer timeout, Boolean failWhenJobFails, Boolean waitForJobCompletion, TraceLevel traceLevel, String orchestratorAddress, String orchestratorTenant, String folderName, SelectEntry credentials) Data bound constructor which is responsible for setting/saving of the values provided by the user -
Method Summary
Modifier and TypeMethodDescriptionCredentials ID, appearing as choice and will be responsible to extract credentials and use for orchestrator connectionOrchestrator FolderBase orchestrator URLOrchestrator Tenantparameterspriorityprocess nameDeclares the scope of the synchronization monitor thisBuildStepexpects from outside.traceLevelvoidRun this step.voidsetFailWhenJobFails(Boolean failWhenJobFails) voidsetParametersFilePath(String parametersFilePath) voidsetPriority(StartProcessDtoJobPriority priority) voidsetProcessName(String processName) voidsetResultFilePath(String resultFilePath) voidsetStrategy(SelectEntry strategy) voidsetTimeout(Integer timeout) voidsetTraceLevel(TraceLevel traceLevel) voidsetWaitForJobCompletion(Boolean waitForJobCompletion) Methods inherited from class hudson.tasks.Recorder
getDescriptorMethods inherited from class hudson.tasks.Publisher
all, getProjectAction, needsToRunAfterFinalized, prebuildMethods inherited from class hudson.tasks.BuildStepCompatibilityLayer
getProjectAction, getProjectActions, perform, perform, prebuildMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface hudson.tasks.BuildStep
getProjectAction, getProjectActions, perform, prebuildMethods inherited from interface jenkins.tasks.SimpleBuildStep
perform, perform, requiresWorkspace
-
Constructor Details
-
UiPathRunJob
@DataBoundConstructor public UiPathRunJob(String processName, String parametersFilePath, StartProcessDtoJobPriority priority, SelectEntry strategy, SelectEntry jobType, String resultFilePath, Integer timeout, Boolean failWhenJobFails, Boolean waitForJobCompletion, TraceLevel traceLevel, String orchestratorAddress, String orchestratorTenant, String folderName, SelectEntry credentials) Data bound constructor which is responsible for setting/saving of the values provided by the user- Parameters:
processName- Process NameparametersFilePath- The full path to a json input file.priority- The priority of job runs. One of the following values: Low, Normal, High. (default Normal)strategy- StrategyjobType- Type of job which needs to runresultFilePath- The full path to a json file or a folder where the result json file will be created.timeout- The timeout for job executions in seconds. (default 1800)failWhenJobFails- The command fails when at least one job fails. (default true)waitForJobCompletion- Wait for job runs completion. (default true)traceLevel- The trace logging level. One of the following values: None, Critical, Error, Warning, Information, Verbose. (default None)orchestratorAddress- Orchestrator base URLorchestratorTenant- Orchestrator tenantfolderName- Orchestrator foldercredentials- Orchestrator credentials
-
-
Method Details
-
getJobType
-
setStrategy
-
getStrategy
- Returns:
- SelectEntry strategy
-
getCredentials
Credentials ID, appearing as choice and will be responsible to extract credentials and use for orchestrator connection- Returns:
- SelectEntry credentials
-
setProcessName
-
getProcessName
process name- Returns:
- String processName
-
setPriority
-
getPriority
priority- Returns:
- StartProcessDtoJobPriority priority
-
setParametersFilePath
-
getParametersFilePath
parameters- Returns:
- String parameters
-
getOrchestratorAddress
Base orchestrator URL- Returns:
- String orchestratorAddress
-
getOrchestratorTenant
Orchestrator Tenant- Returns:
- String orchestratorTenant
-
getFolderName
Orchestrator Folder- Returns:
- String folderName
-
setFailWhenJobFails
-
getFailWhenJobFails
-
setWaitForJobCompletion
-
getWaitForJobCompletion
-
setResultFilePath
-
setTraceLevel
-
getTraceLevel
traceLevel- Returns:
- TraceLevel traceLevel
-
getResultFilePath
-
setTimeout
-
getTimeout
-
getRequiredMonitorService
Declares the scope of the synchronization monitor thisBuildStepexpects from outside.BuildStepMonitor.NONENo external synchronization is performed on this build step. This is the most efficient, and thus the recommended value for newer plugins. Wherever necessary, you can directly useCheckPoints to perform necessary synchronizations.- Specified by:
getRequiredMonitorServicein interfaceBuildStep- Returns:
- BuildStepMonitor BuildStepMonitor.NONE
-
perform
public void perform(@Nonnull Run<?, ?> run, @Nonnull FilePath workspace, @Nonnull EnvVars env, @Nonnull Launcher launcher, @Nonnull TaskListener listener) throws InterruptedException, IOExceptionRun this step.- Specified by:
performin interfaceSimpleBuildStep- Parameters:
run- a build this is running as a part ofworkspace- a workspace to use for any file operationslauncher- a way to start processeslistener- a place to send output- Throws:
InterruptedException- if the step is interruptedIOException- if something goes wrong
-