spring-boot:run

Full name:

org.springframework.boot:spring-boot-maven-plugin:2.2.5.RELEASE:run

Description:

Run an executable archive application.

Attributes:

  • Requires a Maven project to be executed.
  • Requires dependency resolution of artifacts in scope: test.
  • Since version: 1.0.0.
  • Binds by default to the lifecycle phase: validate.
  • Invokes the execution of the lifecycle phase test-compile prior to executing itself.

Required Parameters

Name Type Since Description
<classesDirectory> File 1.0.0 Directory containing the classes and resource files that should be packaged into the archive.
Default value is: ${project.build.outputDirectory}.

Optional Parameters

Name Type Since Description
<addResources> boolean 1.0.0 Add maven resources to the classpath directly, this allows live in-place editing of resources. Duplicate resources are removed from target/classes to prevent them to appear twice if ClassLoader.getResources() is called. Please consider adding spring-boot-devtools to your project instead as it provides this feature and many more.
Default value is: false.
User property is: spring-boot.run.addResources.
<agent> File[] 1.0.0 Deprecated. since 2.2.0 in favor of agents
User property is: spring-boot.run.agent.
<agents> File[] 2.2.0 Path to agent jars. NOTE: a forked process is required to use this feature.
User property is: spring-boot.run.agents.
<arguments> String[] 1.0.0 Arguments that should be passed to the application.
<commandlineArguments> String 2.2.3 Arguments from the command line that should be passed to the application. Use spaces to separate multiple arguments and make sure to wrap multiple values between quotes. When specified, takes precedence over arguments.
User property is: spring-boot.run.arguments.
<environmentVariables> Map 2.1.0 List of Environment variables that should be associated with the forked process used to run the application. NOTE: a forked process is required to use this feature.
<excludeGroupIds> String 1.1.0 Comma separated list of groupId names to exclude (exact match).
User property is: spring-boot.excludeGroupIds.
<excludes> List 1.1.0 Collection of artifact definitions to exclude. The Exclude element defines a groupId and artifactId mandatory properties and an optional classifier property.
User property is: spring-boot.excludes.
<folders> String[] 1.0.0 Additional folders besides the classes directory that should be added to the classpath.
User property is: spring-boot.run.folders.
<fork> boolean 1.2.0 Flag to indicate if the run processes should be forked. Disabling forking will disable some features such as an agent, custom JVM arguments, devtools or specifying the working directory to use.
Default value is: true.
User property is: spring-boot.run.fork.
<includes> List 1.2.0 Collection of artifact definitions to include. The Include element defines a groupId and artifactId mandatory properties and an optional classifier property.
User property is: spring-boot.includes.
<jvmArguments> String 1.1.0 JVM arguments that should be associated with the forked process used to run the application. On command line, make sure to wrap multiple values between quotes. NOTE: a forked process is required to use this feature.
User property is: spring-boot.run.jvmArguments.
<mainClass> String 1.0.0 The name of the main class. If not specified the first compiled class found that contains a 'main' method will be used.
User property is: spring-boot.run.main-class.
<noverify> boolean 1.0.0 Flag to say that the agent requires -noverify.
User property is: spring-boot.run.noverify.
<optimizedLaunch> boolean 2.2.0 Whether the JVM's launch should be optimized.
Default value is: true.
User property is: spring-boot.run.optimizedLaunch.
<profiles> String[] 1.3.0 The spring profiles to activate. Convenience shortcut of specifying the 'spring.profiles.active' argument. On command line use commas to separate multiple profiles.
User property is: spring-boot.run.profiles.
<skip> boolean 1.3.2 Skip the execution.
Default value is: false.
User property is: spring-boot.run.skip.
<systemPropertyVariables> Map 2.1.0 List of JVM system properties to pass to the process. NOTE: a forked process is required to use this feature.
<useTestClasspath> Boolean 1.3.0 Flag to include the test classpath when running.
Default value is: false.
User property is: spring-boot.run.useTestClasspath.
<workingDirectory> File 1.5.0 Current working directory to use for the application. If not specified, basedir will be used. NOTE: a forked process is required to use this feature.
User property is: spring-boot.run.workingDirectory.

Parameter Details

<addResources>

Add maven resources to the classpath directly, this allows live in-place editing of resources. Duplicate resources are removed from target/classes to prevent them to appear twice if ClassLoader.getResources() is called. Please consider adding spring-boot-devtools to your project instead as it provides this feature and many more.
  • Type: boolean
  • Since: 1.0.0
  • Required: No
  • User Property: spring-boot.run.addResources
  • Default: false

<agent>

Deprecated. since 2.2.0 in favor of agents
Path to agent jar. NOTE: a forked process is required to use this feature.
  • Type: java.io.File[]
  • Since: 1.0.0
  • Required: No
  • User Property: spring-boot.run.agent

<agents>

Path to agent jars. NOTE: a forked process is required to use this feature.
  • Type: java.io.File[]
  • Since: 2.2.0
  • Required: No
  • User Property: spring-boot.run.agents

<arguments>

Arguments that should be passed to the application.
  • Type: java.lang.String[]
  • Since: 1.0.0
  • Required: No

<classesDirectory>

Directory containing the classes and resource files that should be packaged into the archive.
  • Type: java.io.File
  • Since: 1.0.0
  • Required: Yes
  • Default: ${project.build.outputDirectory}

<commandlineArguments>

Arguments from the command line that should be passed to the application. Use spaces to separate multiple arguments and make sure to wrap multiple values between quotes. When specified, takes precedence over arguments.
  • Type: java.lang.String
  • Since: 2.2.3
  • Required: No
  • User Property: spring-boot.run.arguments

<environmentVariables>

List of Environment variables that should be associated with the forked process used to run the application. NOTE: a forked process is required to use this feature.
  • Type: java.util.Map
  • Since: 2.1.0
  • Required: No

<excludeGroupIds>

Comma separated list of groupId names to exclude (exact match).
  • Type: java.lang.String
  • Since: 1.1.0
  • Required: No
  • User Property: spring-boot.excludeGroupIds

<excludes>

Collection of artifact definitions to exclude. The Exclude element defines a groupId and artifactId mandatory properties and an optional classifier property.
  • Type: java.util.List
  • Since: 1.1.0
  • Required: No
  • User Property: spring-boot.excludes

<folders>

Additional folders besides the classes directory that should be added to the classpath.
  • Type: java.lang.String[]
  • Since: 1.0.0
  • Required: No
  • User Property: spring-boot.run.folders

<fork>

Flag to indicate if the run processes should be forked. Disabling forking will disable some features such as an agent, custom JVM arguments, devtools or specifying the working directory to use.
  • Type: boolean
  • Since: 1.2.0
  • Required: No
  • User Property: spring-boot.run.fork
  • Default: true

<includes>

Collection of artifact definitions to include. The Include element defines a groupId and artifactId mandatory properties and an optional classifier property.
  • Type: java.util.List
  • Since: 1.2.0
  • Required: No
  • User Property: spring-boot.includes

<jvmArguments>

JVM arguments that should be associated with the forked process used to run the application. On command line, make sure to wrap multiple values between quotes. NOTE: a forked process is required to use this feature.
  • Type: java.lang.String
  • Since: 1.1.0
  • Required: No
  • User Property: spring-boot.run.jvmArguments

<mainClass>

The name of the main class. If not specified the first compiled class found that contains a 'main' method will be used.
  • Type: java.lang.String
  • Since: 1.0.0
  • Required: No
  • User Property: spring-boot.run.main-class

<noverify>

Flag to say that the agent requires -noverify.
  • Type: boolean
  • Since: 1.0.0
  • Required: No
  • User Property: spring-boot.run.noverify

<optimizedLaunch>

Whether the JVM's launch should be optimized.
  • Type: boolean
  • Since: 2.2.0
  • Required: No
  • User Property: spring-boot.run.optimizedLaunch
  • Default: true

<profiles>

The spring profiles to activate. Convenience shortcut of specifying the 'spring.profiles.active' argument. On command line use commas to separate multiple profiles.
  • Type: java.lang.String[]
  • Since: 1.3.0
  • Required: No
  • User Property: spring-boot.run.profiles

<skip>

Skip the execution.
  • Type: boolean
  • Since: 1.3.2
  • Required: No
  • User Property: spring-boot.run.skip
  • Default: false

<systemPropertyVariables>

List of JVM system properties to pass to the process. NOTE: a forked process is required to use this feature.
  • Type: java.util.Map
  • Since: 2.1.0
  • Required: No

<useTestClasspath>

Flag to include the test classpath when running.
  • Type: java.lang.Boolean
  • Since: 1.3.0
  • Required: No
  • User Property: spring-boot.run.useTestClasspath
  • Default: false

<workingDirectory>

Current working directory to use for the application. If not specified, basedir will be used. NOTE: a forked process is required to use this feature.
  • Type: java.io.File
  • Since: 1.5.0
  • Required: No
  • User Property: spring-boot.run.workingDirectory