@Mojo(name="run", requiresDependencyResolution=COMPILE_PLUS_RUNTIME, defaultPhase=PREPARE_PACKAGE) @Execute(phase=PROCESS_CLASSES) public class RunMojo extends AbstractTestResourcesMojo
Executes a Micronaut application in development mode.
It watches for changes in the project tree. If there are changes in the pom.xml
file, dependencies will be reloaded. If
the changes are anywhere underneath src/main
, it will recompile the project and restart the application.
The plugin can handle changes in all the languages supported by Micronaut: Java, Kotlin and Groovy.
Modifier and Type | Field and Description |
---|---|
static String |
EXEC_MAIN_CLASS |
static String |
MN_APP_ARGS |
static String |
RESOURCES_DIR |
static String |
THIS_PLUGIN |
buildDirectory, classpathInference, clientTimeout, explicitPort, log, pluginContext, testResourcesDependencies, testResourcesVersion
CONFIG_PROPERTY_PREFIX, DISABLED, keepAlive, shared, sharedServerNamespace, testResourcesEnabled
Constructor and Description |
---|
RunMojo(org.apache.maven.project.MavenProject mavenProject,
org.apache.maven.execution.MavenSession mavenSession,
org.apache.maven.plugin.BuildPluginManager pluginManager,
org.apache.maven.project.ProjectBuilder projectBuilder,
org.apache.maven.toolchain.ToolchainManager toolchainManager,
CompilerService compilerService,
ExecutorService executorService,
DependencyResolutionService dependencyResolutionService) |
Modifier and Type | Method and Description |
---|---|
void |
execute() |
getLog, getPluginContext, serverSettingsDirectoryOf, setLog, setPluginContext
getSharedServerNamespace, isKeepAlive, isShared, isTestResourcesEnabled
public static final String MN_APP_ARGS
public static final String EXEC_MAIN_CLASS
public static final String RESOURCES_DIR
public static final String THIS_PLUGIN
@Inject public RunMojo(org.apache.maven.project.MavenProject mavenProject, org.apache.maven.execution.MavenSession mavenSession, org.apache.maven.plugin.BuildPluginManager pluginManager, org.apache.maven.project.ProjectBuilder projectBuilder, org.apache.maven.toolchain.ToolchainManager toolchainManager, CompilerService compilerService, ExecutorService executorService, DependencyResolutionService dependencyResolutionService)
Copyright © 2020–2023 Micronaut. All rights reserved.