Package org.eclipse.jetty.maven.plugin
Class JettyStartMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.eclipse.jetty.maven.plugin.AbstractWebAppMojo
org.eclipse.jetty.maven.plugin.AbstractUnassembledWebAppMojo
org.eclipse.jetty.maven.plugin.JettyStartMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
@Mojo(name="start",
requiresDependencyResolution=TEST)
@Execute(phase=VALIDATE)
public class JettyStartMojo
extends AbstractUnassembledWebAppMojo
This goal is similar to the jetty:run goal in that it it starts jetty on an unassembled webapp, EXCEPT that it is designed to be bound to an execution inside your pom. Thus, this goal does NOT run a parallel build cycle, so you must be careful to ensure that you bind it to a phase in which all necessary generated files and classes for the webapp have been created.
This goal will NOT scan for changes in either the webapp project or any scanTargets or scanTargetPatterns.
You can configure this goal to run your webapp either in-process with maven, or forked into a new process, or deployed into a jetty distribution.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.eclipse.jetty.maven.plugin.AbstractWebAppMojo
AbstractWebAppMojo.DeploymentMode
-
Field Summary
Fields inherited from class org.eclipse.jetty.maven.plugin.AbstractUnassembledWebAppMojo
classesDirectory, scanClassesPattern, scanTestClassesPattern, testClassesDirectory, webAppSourceDirectory, webXml
Fields inherited from class org.eclipse.jetty.maven.plugin.AbstractWebAppMojo
contextHandlers, contextXml, deployMode, env, excludedGoals, execution, FAKE_WEBAPP, forkWebXml, httpConnector, JETTY_HOME_ARTIFACTID, JETTY_HOME_GROUPID, jettyBase, jettyHome, jettyOptions, jettyProperties, jettyXmls, jvmArgs, loginServices, mavenProjectHelper, maxChildStartCheckMs, maxChildStartChecks, mergedSystemProperties, modules, originalBaseResource, plugin, pluginArtifacts, project, projectArtifacts, providedJars, reactorProjects, requestLog, scanTargetPatterns, server, skip, stopKey, stopPort, supportedPackagings, systemProperties, systemPropertiesFile, target, useProvidedScope, useTestScope, warArtifacts, webApp
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Starts the webapp - without first compiling the classes - in the same process as maven.void
Start the webapp in a forked jetty process.void
Start the webapp in a forked jetty distribution.Methods inherited from class org.eclipse.jetty.maven.plugin.AbstractUnassembledWebAppMojo
configureUnassembledWebApp, configureWebApp, getWebInfLibArtifacts, verifyPomConfiguration
Methods inherited from class org.eclipse.jetty.maven.plugin.AbstractWebAppMojo
augmentPluginClasspath, configureScanTargetPatterns, configureSystemProperties, execute, findJettyWebXmlFile, getContainerClassPath, getJettyOutputFile, getProjectName, getProvidedJars, isExcludedGoal, isPackagingSupported, isPluginArtifact, mergeSystemProperties, newJettyEmbedder, newJettyForker, newJettyHomeForker, startJetty
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Constructor Details
-
JettyStartMojo
public JettyStartMojo()
-
-
Method Details
-
startJettyEmbedded
public void startJettyEmbedded() throws org.apache.maven.plugin.MojoExecutionExceptionStarts the webapp - without first compiling the classes - in the same process as maven.- Specified by:
startJettyEmbedded
in classAbstractWebAppMojo
- Throws:
org.apache.maven.plugin.MojoExecutionException
-
startJettyForked
public void startJettyForked() throws org.apache.maven.plugin.MojoExecutionExceptionStart the webapp in a forked jetty process. Use the jetty:stop goal to terminate.- Specified by:
startJettyForked
in classAbstractWebAppMojo
- Throws:
org.apache.maven.plugin.MojoExecutionException
-
startJettyHome
public void startJettyHome() throws org.apache.maven.plugin.MojoExecutionExceptionStart the webapp in a forked jetty distribution. Use the jetty:stop goal to terminate- Specified by:
startJettyHome
in classAbstractWebAppMojo
- Throws:
org.apache.maven.plugin.MojoExecutionException
-