public class RemoteBuildConfiguration
extends hudson.tasks.Builder
| Modifier and Type | Class and Description |
|---|---|
static class |
RemoteBuildConfiguration.DescriptorImpl |
| Constructor and Description |
|---|
RemoteBuildConfiguration(String remoteJenkinsName,
boolean shouldNotFailBuild,
boolean preventRemoteBuildQueue,
boolean blockBuildUntilComplete,
int pollInterval,
String job,
String token,
String parameters,
boolean enhancedLogging) |
RemoteBuildConfiguration(String remoteJenkinsName,
boolean shouldNotFailBuild,
String job,
String token,
String parameters,
boolean enhancedLogging,
net.sf.json.JSONObject overrideAuth,
net.sf.json.JSONObject loadParamsFromFile,
boolean preventRemoteBuildQueue,
boolean blockBuildUntilComplete,
int pollInterval) |
| Modifier and Type | Method and Description |
|---|---|
RemoteJenkinsServer |
findRemoteHost(String displayName)
Lookup up a Remote Jenkins Server based on display name
|
Auth[] |
getAuth() |
boolean |
getBlockBuildUntilComplete() |
String |
getBuildStatus(String buildUrlString,
hudson.model.AbstractBuild build,
hudson.model.BuildListener listener) |
String |
getBuildUrl(String buildUrlString,
hudson.model.AbstractBuild build,
hudson.model.BuildListener listener) |
int |
getConnectionRetryLimit() |
String |
getConsoleOutput(String urlString,
String requestType,
hudson.model.AbstractBuild build,
hudson.model.BuildListener listener) |
String |
getConsoleOutput(String urlString,
String requestType,
hudson.model.AbstractBuild build,
hudson.model.BuildListener listener,
int numberOfAttempts) |
RemoteBuildConfiguration.DescriptorImpl |
getDescriptor() |
boolean |
getEnhancedLogging() |
String |
getJob() |
boolean |
getLoadParamsFromFile() |
boolean |
getOverrideAuth() |
String |
getParameterFile() |
String |
getParameters() |
int |
getPollInterval() |
boolean |
getPreventRemoteBuildQueue() |
String |
getQueryString() |
String |
getRemoteJenkinsName() |
boolean |
getShouldNotFailBuild() |
String |
getToken() |
boolean |
perform(hudson.model.AbstractBuild build,
hudson.Launcher launcher,
hudson.model.BuildListener listener) |
net.sf.json.JSONObject |
sendHTTPCall(String urlString,
String requestType,
hudson.model.AbstractBuild build,
hudson.model.BuildListener listener)
Orchestrates all calls to the remote server.
|
net.sf.json.JSONObject |
sendHTTPCall(String urlString,
String requestType,
hudson.model.AbstractBuild build,
hudson.model.BuildListener listener,
int numberOfAttempts)
Same as sendHTTPCall, but keeps track of the number of failed connection attempts (aka: the number of times this
method has been called).
|
@DataBoundConstructor public RemoteBuildConfiguration(String remoteJenkinsName, boolean shouldNotFailBuild, String job, String token, String parameters, boolean enhancedLogging, net.sf.json.JSONObject overrideAuth, net.sf.json.JSONObject loadParamsFromFile, boolean preventRemoteBuildQueue, boolean blockBuildUntilComplete, int pollInterval) throws MalformedURLException
MalformedURLExceptionpublic RemoteBuildConfiguration(String remoteJenkinsName, boolean shouldNotFailBuild, boolean preventRemoteBuildQueue, boolean blockBuildUntilComplete, int pollInterval, String job, String token, String parameters, boolean enhancedLogging) throws MalformedURLException
MalformedURLExceptionpublic RemoteJenkinsServer findRemoteHost(String displayName)
displayName - Name of the configuration you are looking forpublic boolean perform(hudson.model.AbstractBuild build,
hudson.Launcher launcher,
hudson.model.BuildListener listener)
throws InterruptedException,
IOException,
IllegalArgumentException
perform in interface hudson.tasks.BuildStepperform in class hudson.tasks.BuildStepCompatibilityLayerInterruptedExceptionIOExceptionIllegalArgumentExceptionpublic String getBuildStatus(String buildUrlString, hudson.model.AbstractBuild build, hudson.model.BuildListener listener) throws IOException
IOExceptionpublic String getBuildUrl(String buildUrlString, hudson.model.AbstractBuild build, hudson.model.BuildListener listener) throws IOException
IOExceptionpublic String getConsoleOutput(String urlString, String requestType, hudson.model.AbstractBuild build, hudson.model.BuildListener listener) throws IOException
IOExceptionpublic net.sf.json.JSONObject sendHTTPCall(String urlString, String requestType, hudson.model.AbstractBuild build, hudson.model.BuildListener listener) throws IOException
urlString - the URL that needs to be calledrequestType - the type of request (GET, POST, etc)build - the build that is being triggeredlistener - build listenerIOExceptionpublic String getConsoleOutput(String urlString, String requestType, hudson.model.AbstractBuild build, hudson.model.BuildListener listener, int numberOfAttempts) throws IOException
IOExceptionpublic net.sf.json.JSONObject sendHTTPCall(String urlString, String requestType, hudson.model.AbstractBuild build, hudson.model.BuildListener listener, int numberOfAttempts) throws IOException
numberOfAttempts - number of time that the connection has been attemptedIOExceptionsendHTTPCallpublic String getRemoteJenkinsName()
public String getJob()
public boolean getShouldNotFailBuild()
public boolean getEnhancedLogging()
public boolean getPreventRemoteBuildQueue()
public boolean getBlockBuildUntilComplete()
public int getPollInterval()
public int getConnectionRetryLimit()
public String getToken()
public boolean getLoadParamsFromFile()
public String getParameterFile()
public boolean getOverrideAuth()
public Auth[] getAuth()
public String getParameters()
public String getQueryString()
public RemoteBuildConfiguration.DescriptorImpl getDescriptor()
getDescriptor in interface hudson.model.Describable<hudson.tasks.Builder>getDescriptor in class hudson.tasks.BuilderCopyright © 2004–2015. All rights reserved.