public abstract class JenkinsLauncher extends JenkinsEmbedder
| Modifier and Type | Field and Description |
|---|---|
protected Bootstrap |
bootstrap |
contextPath, env, homeLoader, jenkins, localPort, MIME_TYPES, NO_PROPERTIES, recipes, server, tearDowns| Constructor and Description |
|---|
JenkinsLauncher(Bootstrap bootstrap) |
| Modifier and Type | Method and Description |
|---|---|
void |
after()
Skips the clean up.
|
void |
before()
Override to set up your specific external resource.
|
protected org.eclipse.jetty.security.LoginService |
configureUserRealm()
Supply a dummy
LoginService that allows nobody. |
protected javax.servlet.ServletContext |
createWebServer()
Sets up Jetty without any actual TCP port serving HTTP.
|
protected abstract int |
doLaunch()
Actually launches the Jenkins instance, without any time out or output message.
|
protected abstract String |
getThreadName() |
int |
launch() |
void |
recipe() |
protected void |
setupHome(File home)
Prepare the newly allocated home with additional files.
|
configureUpdateCenter, createLocalLauncher, createTaskListener, createUniqueProjectName, getDisplayName, getIconFileName, getInstance, getPluginManager, getURL, getUrlName, getWebAppRoot, interactiveBreak, isSomethingHappening, newJenkins, pause, setPluginManager, setQuietPeriod, waitUntilNoActivity, waitUntilNoActivityUpTo, with, with, withExistingHome, withNewHome, withPresetDataprotected final Bootstrap bootstrap
public JenkinsLauncher(Bootstrap bootstrap)
protected javax.servlet.ServletContext createWebServer()
throws Exception
createWebServer in class JenkinsEmbedderExceptionprotected abstract String getThreadName()
protected abstract int doLaunch()
throws Exception
Exceptionpublic void recipe()
recipe in class JenkinsEmbedderprotected org.eclipse.jetty.security.LoginService configureUserRealm()
LoginService that allows nobody.configureUserRealm in class JenkinsEmbedderpublic void before()
throws Throwable
JenkinsEmbedderbefore in class JenkinsEmbedderThrowable - if setup fails (which will disable afterpublic void after()
throws Exception
after in class JenkinsEmbedderExceptionprotected void setupHome(File home) throws IOException
JenkinsEmbeddersetupHome in class JenkinsEmbedderhome - the target home directory (freshly allocated)IOException - any issue during the copy should interrupt the executionCopyright © 2004–2020. All rights reserved.