[[integration-tests.start-goal]] = `spring-boot:start` `org.springframework.boot:spring-boot-maven-plugin:3.3.0-SNAPSHOT` Start a spring application. Contrary to the `run` goal, this does not block and allows other goals to operate on the application. This goal is typically used in integration test scenario where the application is started before a test suite and stopped after. [[integration-tests.start-goal.required-parameters]] == Required parameters [cols="3,2,3"] |=== | Name | Type | Default | xref:#integration-tests.start-goal.parameter-details.classes-directory[classesDirectory] | `File` | `${project.build.outputDirectory}` |=== [[integration-tests.start-goal.optional-parameters]] == Optional parameters [cols="3,2,3"] |=== | Name | Type | Default | xref:#integration-tests.start-goal.parameter-details.add-resources[addResources] | `boolean` | `false` | xref:#integration-tests.start-goal.parameter-details.additional-classpath-elements[additionalClasspathElements] | `String[]` | | xref:#integration-tests.start-goal.parameter-details.agents[agents] | `File[]` | | xref:#integration-tests.start-goal.parameter-details.arguments[arguments] | `String[]` | | xref:#integration-tests.start-goal.parameter-details.commandline-arguments[commandlineArguments] | `String` | | xref:#integration-tests.start-goal.parameter-details.directories[directories] | `String[]` | | xref:#integration-tests.start-goal.parameter-details.environment-variables[environmentVariables] | `Map` | | xref:#integration-tests.start-goal.parameter-details.exclude-group-ids[excludeGroupIds] | `String` | | xref:#integration-tests.start-goal.parameter-details.excludes[excludes] | `List` | | xref:#integration-tests.start-goal.parameter-details.includes[includes] | `List` | | xref:#integration-tests.start-goal.parameter-details.jmx-name[jmxName] | `String` | `org.springframework.boot:type=Admin,name=SpringApplication` | xref:#integration-tests.start-goal.parameter-details.jmx-port[jmxPort] | `int` | `9001` | xref:#integration-tests.start-goal.parameter-details.jvm-arguments[jvmArguments] | `String` | | xref:#integration-tests.start-goal.parameter-details.main-class[mainClass] | `String` | | xref:#integration-tests.start-goal.parameter-details.max-attempts[maxAttempts] | `int` | `60` | xref:#integration-tests.start-goal.parameter-details.noverify[noverify] | `boolean` | | xref:#integration-tests.start-goal.parameter-details.profiles[profiles] | `String[]` | | xref:#integration-tests.start-goal.parameter-details.skip[skip] | `boolean` | `false` | xref:#integration-tests.start-goal.parameter-details.system-property-variables[systemPropertyVariables] | `Map` | | xref:#integration-tests.start-goal.parameter-details.use-test-classpath[useTestClasspath] | `Boolean` | `false` | xref:#integration-tests.start-goal.parameter-details.wait[wait] | `long` | `500` | xref:#integration-tests.start-goal.parameter-details.working-directory[workingDirectory] | `File` | |=== [[integration-tests.start-goal.parameter-details]] == Parameter details [[integration-tests.start-goal.parameter-details.add-resources]] === `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 from appearing twice if `ClassLoader.getResources()` is called. Please consider adding `spring-boot-devtools` to your project instead as it provides this feature and many more. [cols="10h,90"] |=== | Name | `addResources` | Type | `boolean` | Default value | `false` | User property | ``spring-boot.run.addResources`` | Since | `1.0.0` |=== [[integration-tests.start-goal.parameter-details.additional-classpath-elements]] === `additionalClasspathElements` Additional classpath elements that should be added to the classpath. An element can be a directory with classes and resources or a jar file. [cols="10h,90"] |=== | Name | `additionalClasspathElements` | Type | `java.lang.String[]` | Default value | | User property | ``spring-boot.run.additional-classpath-elements`` | Since | `3.2.0` |=== [[integration-tests.start-goal.parameter-details.agents]] === `agents` Path to agent jars. [cols="10h,90"] |=== | Name | `agents` | Type | `java.io.File[]` | Default value | | User property | ``spring-boot.run.agents`` | Since | `2.2.0` |=== [[integration-tests.start-goal.parameter-details.arguments]] === `arguments` Arguments that should be passed to the application. [cols="10h,90"] |=== | Name | `arguments` | Type | `java.lang.String[]` | Default value | | User property | | Since | `1.0.0` |=== [[integration-tests.start-goal.parameter-details.classes-directory]] === `classesDirectory` Directory containing the classes and resource files that should be used to run the application. [cols="10h,90"] |=== | Name | `classesDirectory` | Type | `java.io.File` | Default value | `${project.build.outputDirectory}` | User property | | Since | `1.0.0` |=== [[integration-tests.start-goal.parameter-details.commandline-arguments]] === `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`. [cols="10h,90"] |=== | Name | `commandlineArguments` | Type | `java.lang.String` | Default value | | User property | ``spring-boot.run.arguments`` | Since | `2.2.3` |=== [[integration-tests.start-goal.parameter-details.directories]] === `directories` Additional directories containing classes or resources that should be added to the classpath. [cols="10h,90"] |=== | Name | `directories` | Type | `java.lang.String[]` | Default value | | User property | ``spring-boot.run.directories`` | Since | `1.0.0` |=== [[integration-tests.start-goal.parameter-details.environment-variables]] === `environmentVariables` List of Environment variables that should be associated with the forked process used to run the application. [cols="10h,90"] |=== | Name | `environmentVariables` | Type | `java.util.Map` | Default value | | User property | | Since | `2.1.0` |=== [[integration-tests.start-goal.parameter-details.exclude-group-ids]] === `excludeGroupIds` Comma separated list of groupId names to exclude (exact match). [cols="10h,90"] |=== | Name | `excludeGroupIds` | Type | `java.lang.String` | Default value | | User property | ``spring-boot.excludeGroupIds`` | Since | `1.1.0` |=== [[integration-tests.start-goal.parameter-details.excludes]] === `excludes` Collection of artifact definitions to exclude. The `Exclude` element defines mandatory `groupId` and `artifactId` components and an optional `classifier` component. When configured as a property, values should be comma-separated with colon-separated components: `groupId:artifactId,groupId:artifactId:classifier` [cols="10h,90"] |=== | Name | `excludes` | Type | `java.util.List` | Default value | | User property | ``spring-boot.excludes`` | Since | `1.1.0` |=== [[integration-tests.start-goal.parameter-details.includes]] === `includes` Collection of artifact definitions to include. The `Include` element defines mandatory `groupId` and `artifactId` components and an optional `classifier` component. When configured as a property, values should be comma-separated with colon-separated components: `groupId:artifactId,groupId:artifactId:classifier` [cols="10h,90"] |=== | Name | `includes` | Type | `java.util.List` | Default value | | User property | ``spring-boot.includes`` | Since | `1.2.0` |=== [[integration-tests.start-goal.parameter-details.jmx-name]] === `jmxName` The JMX name of the automatically deployed MBean managing the lifecycle of the spring application. [cols="10h,90"] |=== | Name | `jmxName` | Type | `java.lang.String` | Default value | `org.springframework.boot:type=Admin,name=SpringApplication` | User property | | Since | |=== [[integration-tests.start-goal.parameter-details.jmx-port]] === `jmxPort` The port to use to expose the platform MBeanServer. [cols="10h,90"] |=== | Name | `jmxPort` | Type | `int` | Default value | `9001` | User property | | Since | |=== [[integration-tests.start-goal.parameter-details.jvm-arguments]] === `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. [cols="10h,90"] |=== | Name | `jvmArguments` | Type | `java.lang.String` | Default value | | User property | ``spring-boot.run.jvmArguments`` | Since | `1.1.0` |=== [[integration-tests.start-goal.parameter-details.main-class]] === `mainClass` The name of the main class. If not specified the first compiled class found that contains a 'main' method will be used. [cols="10h,90"] |=== | Name | `mainClass` | Type | `java.lang.String` | Default value | | User property | ``spring-boot.run.main-class`` | Since | `1.0.0` |=== [[integration-tests.start-goal.parameter-details.max-attempts]] === `maxAttempts` The maximum number of attempts to check if the spring application is ready. Combined with the "wait" argument, this gives a global timeout value (30 sec by default) [cols="10h,90"] |=== | Name | `maxAttempts` | Type | `int` | Default value | `60` | User property | ``spring-boot.start.maxAttempts`` | Since | |=== [[integration-tests.start-goal.parameter-details.noverify]] === `noverify` Flag to say that the agent requires -noverify. [cols="10h,90"] |=== | Name | `noverify` | Type | `boolean` | Default value | | User property | ``spring-boot.run.noverify`` | Since | `1.0.0` |=== [[integration-tests.start-goal.parameter-details.profiles]] === `profiles` The spring profiles to activate. Convenience shortcut of specifying the 'spring.profiles.active' argument. On command line use commas to separate multiple profiles. [cols="10h,90"] |=== | Name | `profiles` | Type | `java.lang.String[]` | Default value | | User property | ``spring-boot.run.profiles`` | Since | `1.3.0` |=== [[integration-tests.start-goal.parameter-details.skip]] === `skip` Skip the execution. [cols="10h,90"] |=== | Name | `skip` | Type | `boolean` | Default value | `false` | User property | ``spring-boot.run.skip`` | Since | `1.3.2` |=== [[integration-tests.start-goal.parameter-details.system-property-variables]] === `systemPropertyVariables` List of JVM system properties to pass to the process. [cols="10h,90"] |=== | Name | `systemPropertyVariables` | Type | `java.util.Map` | Default value | | User property | | Since | `2.1.0` |=== [[integration-tests.start-goal.parameter-details.use-test-classpath]] === `useTestClasspath` Flag to include the test classpath when running. [cols="10h,90"] |=== | Name | `useTestClasspath` | Type | `java.lang.Boolean` | Default value | `false` | User property | ``spring-boot.run.useTestClasspath`` | Since | |=== [[integration-tests.start-goal.parameter-details.wait]] === `wait` The number of milliseconds to wait between each attempt to check if the spring application is ready. [cols="10h,90"] |=== | Name | `wait` | Type | `long` | Default value | `500` | User property | ``spring-boot.start.wait`` | Since | |=== [[integration-tests.start-goal.parameter-details.working-directory]] === `workingDirectory` Current working directory to use for the application. If not specified, basedir will be used. [cols="10h,90"] |=== | Name | `workingDirectory` | Type | `java.io.File` | Default value | | User property | ``spring-boot.run.workingDirectory`` | Since | `1.5.0` |===