@Deprecated public class JettyRun extends AbstractJettyRunTask
Deploys an exploded web application to an embedded Jetty web container. Does not require that the web application be assembled into a war, saving time during the development cycle.
Once started, the web container can be configured to run continuously, scanning for changes in the project and automatically performing a hot redeploy when necessary. This allows the developer to concentrate on coding changes to the project using their IDE of choice and have those changes immediately and transparently reflected in the running web container, eliminating development time that is wasted on rebuilding, reassembling and redeploying.
Task.Namer
consoleScanner, PORT_SYSPROPERTY, reload, scannerListeners
TASK_ACTION, TASK_DEPENDS_ON, TASK_DESCRIPTION, TASK_GROUP, TASK_NAME, TASK_OVERWRITE, TASK_TYPE
Constructor and Description |
---|
JettyRun()
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
void |
applyJettyXml()
Deprecated.
|
void |
configureScanner()
Deprecated.
|
void |
configureWebApplication()
Deprecated.
Subclasses should invoke this to setup basic info on the webapp.
|
org.gradle.api.plugins.jetty.internal.JettyPluginServer |
createServer()
Deprecated.
create a proxy that wraps a particular jetty version Server object.
|
void |
finishConfigurationBeforeStart()
Deprecated.
|
FileCollection |
getClasspath()
Deprecated.
Returns the classpath for the web application.
|
java.util.List<java.io.File> |
getClassPathFiles()
Deprecated.
|
org.eclipse.jetty.server.handler.ContextHandler[] |
getConfiguredContextHandlers()
Deprecated.
|
java.util.Set<java.io.File> |
getExtraScanTargets()
Deprecated.
|
java.io.File |
getJettyEnvXml()
Deprecated.
|
java.io.File |
getJettyEnvXmlFile()
Deprecated.
|
ScanTargetPattern[] |
getScanTargetPatterns()
Deprecated.
|
java.io.File[] |
getScanTargets()
Deprecated.
|
java.io.File |
getWebAppSourceDirectory()
Deprecated.
Returns the directory containing the web application source files.
|
java.io.File |
getWebXml()
Deprecated.
Returns the
web.xml file to use. |
protected java.io.File |
getWebXmlIfExists()
Deprecated.
|
void |
restartWebApp(boolean reconfigureScanner)
Deprecated.
|
void |
setClasspath(FileCollection classpath)
Deprecated.
Set the classpath for the web application.
|
void |
setClassPathFiles(java.util.List<java.io.File> classPathFiles)
Deprecated.
|
void |
setContextHandlers(org.eclipse.jetty.server.handler.ContextHandler[] contextHandlers)
Deprecated.
|
void |
setExtraScanTargets(java.lang.Iterable<java.io.File> extraScanTargets)
Deprecated.
|
void |
setJettyEnvXml(java.io.File jettyEnvXml)
Deprecated.
|
void |
setJettyEnvXmlFile(java.io.File jettyEnvXmlFile)
Deprecated.
|
void |
setScanTargetPatterns(ScanTargetPattern[] scanTargetPatterns)
Deprecated.
|
void |
setScanTargets(java.io.File[] scanTargets)
Deprecated.
|
void |
setWebAppSourceDirectory(java.io.File webAppSourceDirectory)
Deprecated.
|
void |
setWebXml(java.io.File webXml)
Deprecated.
|
void |
validateConfiguration()
Deprecated.
|
findJettyWebXmlFile, getAdditionalRuntimeJars, getConnectors, getContextPath, getHttpPort, getJettyConfig, getOverrideWebXml, getReload, getRequestLog, getScanIntervalSeconds, getScanner, getScannerListeners, getServer, getStopKey, getStopPort, getUserRealms, getWebAppConfig, getWebDefaultXml, isDaemon, setAdditionalRuntimeJars, setConnectors, setContextPath, setDaemon, setHttpPort, setJettyConfig, setOverrideWebXml, setReload, setRequestLog, setScanIntervalSeconds, setScannerListeners, setServer, setStopKey, setStopPort, setUserRealms, setWebAppConfig, setWebDefaultXml, start, startConsoleScanner, startJetty, startJettyInternal
conventionMapping, conventionMapping, getConventionMapping
addValidator, appendParallelSafeAction, compareTo, configure, deleteAllActions, dependsOn, dependsOnTaskDidWork, doFirst, doFirst, doLast, doLast, execute, finalizedBy, getActionClassLoaders, getActions, getAnt, getAsDynamicObject, getConvention, getDependsOn, getDescription, getDidWork, getEnabled, getExecuter, getExtensions, getFinalizedBy, getGroup, getImpliesSubProjects, getInputs, getLogger, getLogging, getMustRunAfter, getName, getOnlyIf, getOutputs, getPath, getProject, getServices, getShouldRunAfter, getStandardOutputCapture, getState, getTaskActions, getTaskDependencies, getTemporaryDir, getTemporaryDirFactory, getValidators, hasProperty, injectIntoNewInstance, isEnabled, isHasCustomActions, leftShift, mustRunAfter, onlyIf, onlyIf, prependParallelSafeAction, property, setActions, setDependsOn, setDescription, setDidWork, setEnabled, setExecuter, setFinalizedBy, setGroup, setImpliesSubProjects, setMustRunAfter, setOnlyIf, setOnlyIf, setProperty, setShouldRunAfter, shouldRunAfter, toString
public void validateConfiguration()
validateConfiguration
in class AbstractJettyRunTask
public void configureWebApplication() throws java.lang.Exception
AbstractJettyRunTask
configureWebApplication
in class AbstractJettyRunTask
java.lang.Exception
public void configureScanner()
configureScanner
in class AbstractJettyRunTask
public void restartWebApp(boolean reconfigureScanner) throws java.lang.Exception
restartWebApp
in class AbstractJettyRunTask
java.lang.Exception
public void finishConfigurationBeforeStart() throws java.lang.Exception
finishConfigurationBeforeStart
in class AbstractJettyRunTask
java.lang.Exception
public void applyJettyXml() throws java.lang.Exception
applyJettyXml
in class AbstractJettyRunTask
java.lang.Exception
public org.gradle.api.plugins.jetty.internal.JettyPluginServer createServer()
AbstractJettyRunTask
createServer
in class AbstractJettyRunTask
@InputFile @Optional public java.io.File getJettyEnvXml()
public void setJettyEnvXml(java.io.File jettyEnvXml)
@Internal(value="See webXmlIfExists") public java.io.File getWebXml()
web.xml
file to use. When null
, no web.xml
file is used.@Optional @InputFile protected java.io.File getWebXmlIfExists()
public void setWebXml(java.io.File webXml)
@InputDirectory public java.io.File getWebAppSourceDirectory()
public void setWebAppSourceDirectory(java.io.File webAppSourceDirectory)
@Internal public java.io.File[] getScanTargets()
public void setScanTargets(java.io.File[] scanTargets)
@Internal public java.util.Set<java.io.File> getExtraScanTargets()
public void setExtraScanTargets(java.lang.Iterable<java.io.File> extraScanTargets)
@InputFile @Optional public java.io.File getJettyEnvXmlFile()
public void setJettyEnvXmlFile(java.io.File jettyEnvXmlFile)
@Internal public java.util.List<java.io.File> getClassPathFiles()
public void setClassPathFiles(java.util.List<java.io.File> classPathFiles)
@Internal public ScanTargetPattern[] getScanTargetPatterns()
public void setScanTargetPatterns(ScanTargetPattern[] scanTargetPatterns)
@Internal public org.eclipse.jetty.server.handler.ContextHandler[] getConfiguredContextHandlers()
public void setContextHandlers(org.eclipse.jetty.server.handler.ContextHandler[] contextHandlers)
@Classpath public FileCollection getClasspath()
public void setClasspath(FileCollection classpath)