Maven spring boot pre-integration-test timeout error - spring

When I run the command install of my server's Lifecycle I get the following error:
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 34.507 s
[INFO] Finished at: 2017-03-10T15:32:41+01:00
[INFO] Final Memory: 69M/596M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:1.4.0.RELEASE:start (pre-integration-test) on project challenger-server-boot: Spring application did not start before the configured timeout (30000ms -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
It obviously comes from the timeout settings but I cannot find where I have to change this value...
Not sure if it can help but here's some of my pom.xml related to the unit and integration testings:
<!-- Unit testing -->
<plugin>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<skipTests>true</skipTests>
</configuration>
</plugin>
<!-- Integration testing -->
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.19.1</version>
<configuration>
<skipTests>false</skipTests>
</configuration>
</plugin>
Here's the debug log: http://pastebin.com/kUkufHFS

You are trying to start a spring boot app before in pre-integration-test phase.
The spring-boot-maven-plugin StartMojo class (org.springframework.boot.maven) is complaining because the app is not started within the default timeout, wich is defined by the attributes "wait" (defautl value: 500 ms) and "maxAttempts" (default: 60) -> 500 * 60.
/**
* The number of milli-seconds to wait between each attempt to check if the spring
* application is ready.
*/
#Parameter
private long wait = 500;
/**
* 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)
*/
#Parameter
private int maxAttempts = 60;
"wait" and "maxAttempts" are annotated #Parameter, which means you can change their value from within your pom file, in the plugin configuration like this:
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<wait>1000</wait>
<maxAttempts>180</maxAttempts>
</configuration>
<executions>
...
</executions>
</plugin>

Related

AssertJ custom Aspects doesn't work with maven-surefire-plugin

I have the maven project written on Kotlin.
pom.xml uses maven-surefire-plugin plugin:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.22.2</version>
<configuration>
<suiteXmlFiles>
<suiteName>${suiteName}</suiteName>
</suiteXmlFiles>
<testFailureIgnore>false</testFailureIgnore>
<argLine>
-javaagent:"${settings.localRepository}/org/aspectj/aspectjweaver/${aspectj.version}/aspectjweaver-${aspectj.version}.jar"
</argLine>
<systemPropertyVariables>
<env>${env}</env>
<deviceName>${deviceName}</deviceName>
</systemPropertyVariables>
</configuration>
<dependencies>
<dependency>
<groupId>org.aspectj</groupId>
<artifactId>aspectjweaver</artifactId>
<version>${aspectj.version}</version>
</dependency>
</dependencies>
</plugin>
I'd like to add additional aspect to my code, so I added another plugin:
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>aspectj-maven-plugin</artifactId>
<version>1.14.0</version>
<configuration>
<complianceLevel>1.8</complianceLevel>
<source>1.8</source>
<target>1.8</target>
<showWeaveInfo>true</showWeaveInfo>
<verbose>true</verbose>
<Xlint>ignore</Xlint>
<encoding>${project.build.sourceEncoding}</encoding>
<forceAjcCompile>true</forceAjcCompile>
<weaveDirectories>
<weaveDirectory>${project.build.outputDirectory}</weaveDirectory>
<weaveDirectory>${project.build.testOutputDirectory}</weaveDirectory>
</weaveDirectories>
</configuration>
<executions>
<execution>
<goals>
<goal>compile</goal>
<goal>test-compile</goal>
</goals>
</execution>
</executions>
</plugin>
with aspectjrt dependency.
In this state, my tests are working.
Next, I created a new class with #Aspect annotation - still working.
Now I am adding very simple code (just to check) in this class:
#Pointcut("execution(* *(..))")
fun method() {
}
#AfterReturning(pointcut = "method()")
fun afterMethod() {
println("After method")
}
This causes suite to fail with:
[ERROR] There was an error in the forked process
[ERROR] 'utils.Aspects utils.Aspects.aspectOf()'
[ERROR] org.apache.maven.surefire.booter.SurefireBooterForkException: There was an error in the forked process
[ERROR] 'utils.Aspects utils.Aspects.aspectOf()'
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.fork(ForkStarter.java:656)
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:282)
[ERROR] at org.apache.maven.plugin.surefire.booterclient.ForkStarter.run(ForkStarter.java:245)
[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeProvider(AbstractSurefireMojo.java:1183)
[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.executeAfterPreconditionsChecked(AbstractSurefireMojo.java:1011)
[ERROR] at org.apache.maven.plugin.surefire.AbstractSurefireMojo.execute(AbstractSurefireMojo.java:857)
[ERROR] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute(MojoExecutor.java:301)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:211)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:165)
[ERROR] at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:157)
[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:121)
[ERROR] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:81)
[ERROR] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:56)
[ERROR] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:127)
[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:294)
[ERROR] at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:192)
[ERROR] at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:105)
[ERROR] at org.apache.maven.cli.MavenCli.execute(MavenCli.java:960)
[ERROR] at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:293)
[ERROR] at org.apache.maven.cli.MavenCli.main(MavenCli.java:196)
[ERROR] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[ERROR] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64)
[ERROR] at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[ERROR] at java.base/java.lang.reflect.Method.invoke(Method.java:564)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:282)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:225)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:406)
[ERROR] at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:347)
I have created stand-alone project to check if understand AOP concept correctly here: https://github.com/heavy-razzer/AssertJ-Maven-Kotlin
It work.
So looks like there is something wrong with the configuration of my main project, but what?
I just cloned your sample project, which was verfy helpful. For me, the project works just fine in Maven:
[INFO] --- aspectj-maven-plugin:1.14.0:test-compile (default) # aop-project-kotlin ---
(...)
[INFO] Join point 'method-execution(void tests.NewTest.myTest())' in Type 'tests.NewTest' (NewTest.kt:12) advised by before advice from 'Aspects' (test-classes!Aspects.class(from Aspects.kt))
[INFO] Join point 'method-execution(void steps.Steps.printCaption())' in Type 'steps.Steps' (Steps.kt:7) advised by afterReturning advice from 'Aspects' (test-classes!Aspects.class(from Aspects.kt))
[INFO] Join point 'method-execution(void steps.Steps.printMessage())' in Type 'steps.Steps' (Steps.kt:11) advised by afterReturning advice from 'Aspects' (test-classes!Aspects.class(from Aspects.kt))
[INFO]
[INFO] --- maven-surefire-plugin:2.22.2:test (default-test) # aop-project-kotlin ---
[INFO]
[INFO] -------------------------------------------------------
[INFO] T E S T S
[INFO] -------------------------------------------------------
[INFO] Running tests.NewTest
Test started: Very simple test
This this a simple test
Test step performed: printCaption
Testing in progress
Test step performed: printMessage
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.592 s - in tests.NewTest
[INFO]
[INFO] Results:
[INFO]
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
In IntelliJ IDEA, it does not work out of the box, because doing post-compile weaving with Maven in a single module together with Kotlin compilation does not work out of the box. The test runs, but the aspect is not triggered. You need to delegate the build and run actions to Maven to be able to run the test directly from IDEA:
Test started: Very simple test
This this a simple test
Test step performed: printCaption
Testing in progress
Test step performed: printMessage
===============================================
Default Suite
Total tests run: 1, Failures: 0, Skips: 0
===============================================
Under no circumstances, however, can I reproduce your Maven problem.
The problem in my main project (not that sample project I shared here) lies in qase-testng library that I use to upload test run results to the Qase Test Management system.
me and Qase use AssertJ and have aspects logic implemented in some classes
Qase requires some additional configuration to SureFire maven plugin to upload all test data correctly.
SureFire uses AssertJ too
And when I run my project, SureFire got exceptions when trying to combine Aspects from my code and from Qase library.
Workaround is:
Remove argLine from SureFire config (from Qase testing docs)
Remove goal "compile" from aspectj-maven-plugin config - it is not needed for a project with tests.
The only drawback of these actions is that step names in the Qase dashboard will not have green/red icons next to them in the test run page. I have contacted Qase support, and they are thinking about this situation.

How to set up pom.xml for RichFaces 4.5.17.kcc5 and Primefaces 7.0.RC3 working together on the JSF 2.3 project

Originally my project is set up for RichFaces 4.5.17.kcc5 and it works fine.
After I added the PrimeFace 7.0.RC3 library to the project, my build stop installing (mvn clean install) and I start getting the errors in the log:
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:34 min
[INFO] Finished at: 2021-01-21T13:55:53+01:00
[INFO] Final Memory: 73M/1206M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.richfaces:richfaces-resource-optimizer-maven-plugin:4.5.17.kcc5:process (packed-resources) on project uifaces-resources: Exception caught when scanning class org.primefaces.component.schedule.Schedule:
[ERROR] collection: [primefaces:schedule/schedule.css, primefaces:components.css, primefaces:moment/moment.js, primefaces:jquery/jquery.js, primefaces:jquery/jquery-plugins.js, primefaces:core.js, primefaces:components.js, primefaces:schedule/schedule.js]
[ERROR] PartialOrder[primefaces:jquery/jquery.js, primefaces:core.js, primefaces:components.js, primefaces:moment/moment.js, primefaces:chartjs/chartjs.js]
[ERROR] -> [Help 1]
It happens during the execution this step:
org.richfaces:richfaces-resource-optimizer-maven-plugin
(packed-resources)
<!-- Packed -->
<execution>
<id>packed-resources</id>
<goals>
<goal>process</goal>
</goals>
<configuration>
<pack>packed</pack>
<compress>false</compress>
<resourcesOutputDir>
${faces.resources.dir}/org.richfaces.staticResource/${version.org.richfaces}/Packed/
</resourcesOutputDir>
<staticResourceMappingFile>
${resource.mappings.dir}/optimizedResourcesMapping/Packed.properties
</staticResourceMappingFile>
<staticResourcePrefix>org.richfaces.staticResource/${version.org.richfaces}/Packed/
</staticResourcePrefix>
<excludedFiles>
<exclude>^javax.faces</exclude>
<exclude>^jquery.js$</exclude>
<exclude>^jquery.*.js$</exclude>
<exclude>^flot</exclude>
<exclude>^net.my.uifaces\:css/page.*</exclude>
<exclude>^net.my.uifaces\:css/button.css</exclude>
<exclude>^net.my.uifaces\:script/page.*</exclude>
<exclude>^net.my.uifaces\:script/jquery.*</exclude>
<exclude>^net.my.uifaces\:theme.*</exclude>
<exclude>^\Qorg.richfaces.renderkit.html.images.\E.*</exclude>
<exclude>^\Qorg.richfaces.renderkit.html.iconimages.\E.*</exclude>
<exclude>^\Qorg.richfaces.ckeditor\E</exclude>
<exclude>^\Qorg.richfaces.staticResource\E</exclude>
<exclude>^org\.richfaces:jquery\.js$</exclude>
</excludedFiles>
</configuration>
</execution>
Maybe someone has seen this error before. Any guess how to avoid it?

Error Maven with mvn test

I am using this tool for first time, and I can't build a project correctly.
when i try the life cycle commands it builds succesfully with clean validate and compile. but when i try mvn test, it gives me this error :
[INFO] ---------------------------------------------------------------------
---
[INFO] BUILD FAILURE
[INFO] ---------------------------------------------------------------------
---
[INFO] Total time: 4.410 s
[INFO] Finished at: 2018-05-25T11:33:07+02:00
[INFO] ---------------------------------------------------------------------
---
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-surefire-
plugin:2.20.1:test (default-test) on project gdp: Execution default-test of
goal org.apache.maven.plugins:maven-surefire-plugin:2.20.1:test failed.
:NullPointerException
-> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e
switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please
read the following articles:
[ERROR] [Help 1]
http://cwiki.apache.org/confluence/display/MAVEN/PluginExecutionException
mvn -v 3.5.3
i am using a proxy and i did configure settings.xml file
Please help.
thank you
Change the version of maven-surefire-plugin via:
<project>
.
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.21.0</version>
</plugin>
</plugins>
</pluginManagement>
</build>
</project>

How do I prevent Maven from assmebling my WAR if my integration tests fail?

I’m using Maven 3.3.3 with Java 8 on Mac Yosemite. I have a bunch of integration tests and I have my failsafe plugin (v 2.18.1) set up as such …
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.18.1</version>
<configuration>
<reuseForks>true</reuseForks>
<argLine>-Xmx4096m -XX:MaxPermSize=512M -noverify -XX:-UseSplitVerifier ${itCoverageAgent}</argLine>
<skipTests>${skipAllTests}</skipTests>
</configuration>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
However, when I run the command “mvn clean install,” even when I have failed unit tests, the build continues on to assembling the war. How do I prevent further Maven activity if I have failed integration tests? Below is example output of what I’m seeing. Note that the WAR plugin continues to run even after the tests have failed.
Results :
Failed tests:
MyProjectInstantLoginControllerIT.testInstantLoginSuccessNoCredentailsObj:245 View name is not equal to 'redirect:http://localhost:80/authenticate' but was 'redirect:http://localhost:80/home'
MyProjectInstantLoginControllerIT.testInstantLoginSuccessStudent:153 View name is not equal to 'redirect:http://localhost:80/authenticate' but was 'redirect:http://localhost:80/home'
MyProjectInstantLoginControllerIT.testInstantLoginSuccessTeacher:125 View name is not equal to 'redirect:http://localhost:80/authenticate' but was 'redirect:http://localhost:80/home'
MyProjectInstantLoginControllerIT.testInstantLoginSuccessWithApacheHeader:187 View name is not equal to 'redirect:http://localhost:80/authenticate' but was 'redirect:http://localhost:80/home'
Tests in error:
ClassController2IT.testUpdateClassWoSchedule:478->AbstractClassControllerTest.submitCreateClassForm:514 » LazyInitialization
Tests run: 157, Failures: 4, Errors: 1, Skipped: 4
[INFO]
[INFO] --- maven-war-plugin:2.6:war (default-war) # my-module ---
[INFO] Packaging webapp
[INFO] Assembling webapp [my-module] in [/Users/davea/Documents/my_workspace/my-module/target/my-module]
[INFO] Dependency [Dependency {groupId=org.mainco.subco, artifactId=second-module, version=87.0.0-SNAPSHOT, type=jar}] has changed (was Dependency {groupId=org.mainco.subco, artifactId=second-module, version=87.0.0-SNAPSHOT, type=jar}).
[WARNING] File to remove [/Users/davea/Documents/my_workspace/my-module/target/my-module/WEB-INF/lib/second-module-87.0.0-SNAPSHOT.jar] has not been found
[INFO] Dependency [Dependency {groupId=org.springframework, artifactId=spring-core, version=3.2.11.RELEASE, type=jar}] has changed (was Dependency {groupId=org.springframework, artifactId=spring-core, version=3.2.11.RELEASE, type=jar}).
[WARNING] File to remove [/Users/davea/Documents/my_workspace/my-module/target/my-module/WEB-INF/lib/spring-core-3.2.11.RELEASE.jar] has not been found
[INFO] Dependency [Dependency {groupId=org.springframework.security.extensions, artifactId=spring-security-saml2-core, version=1.0.0.RC2, type=jar}] has changed (was Dependency {groupId=org.springframework.security.extensions, artifactId=spring-security-saml2-core, version=1.0.0.RC2, type=jar}).
[WARNING] File to remove [/Users/davea/Documents/my_workspace/my-module/target/my-module/WEB-INF/lib/spring-security-saml2-core-1.0.0.RC2.jar] has not been found
[INFO] Dependency [Dependency {groupId=org.opensaml, artifactId=opensaml, version=2.6.1, type=jar}] has changed (was Dependency {groupId=org.opensaml, artifactId=opensaml, version=2.6.1, type=jar}).
[WARNING] File to remove [/Users/davea/Documents/my_workspace/my-module/target/my-module/WEB-INF/lib/opensaml-2.6.1.jar] has not been found
[INFO] Processing war project
[INFO] Copying webapp resources [/Users/davea/Documents/my_workspace/my-module/src/main/webapp]
[INFO] Webapp assembled in [5454 msecs]
[INFO] Building war: /Users/davea/Documents/my_workspace/my-module/target/my-module.war
[INFO]
[INFO] --- maven-failsafe-plugin:2.18.1:verify (default) # my-module ---
[INFO] Failsafe report directory: /Users/davea/Documents/my_workspace/my-module/target/failsafe-reports
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 02:17 min
[INFO] Finished at: 2015-11-09T11:23:47-06:00
[INFO] Final Memory: 48M/792M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-failsafe-plugin:2.18.1:verify (default) on project my-module: There are test failures.
[ERROR]
[ERROR] Please refer to /Users/davea/Documents/my_workspace/my-module/target/failsafe-reports for the individual test results.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
You haven't specified any phase(s) you want failsafe plugin to run its goals on. By default, the goals integration-test and verify are bound to the integration-test and verify phases of the default life cycle.
Recall that these phases occur after the package phase is complete (refer the life cycle references), so with the configuration you have, you are not impacting the package phase in any way - your goals run after the package phase (i.e the goals set to run in that phase - the maven-war-plugin:2.6:war being one) is complete.
You could try running the integration tests and verifying them before the package phase if that's what you really want by specifying the appropriate phase(s) for your goals in the <execution> you've shown in your OP.
Unrelated to the problem, the maven-failsafe-plugin plugin is intended to target integration tests and decouple the build failures from the actual integration test results. You get around it by verifying your integration test results.
Here's a quote from the FAQ:
What is the difference between maven-failsafe-plugin and
maven-surefire-plugin?
maven-surefire-plugin is designed for running unit tests and if any of the tests fail then it will fail the build immediately.
maven-failsafe-plugin is designed for running integration tests, and decouples failing the build if there are test failures from
actually running the tests.
Further notes on this subject:
If you use the Surefire Plugin for running tests, then when you have a
test failure, the build will stop at the integration-test phase and
your integration test environment will not have been torn down
correctly.
The Failsafe Plugin is used during the integration-test and verify
phases of the build lifecycle to execute the integration tests of an
application. The Failsafe Plugin will not fail the build during the
integration-test phase, thus enabling the post-integration-test phase
to execute.

POM for org.springframework:springloaded:jar:1.2.0.BUILD-SNAPSHOT is missing

I followed the directions listed on the jHipster website under
http://jhipster.github.io/creating_an_app.html
yo jhipster
mvn spring-boot:run
Downloading: http://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml
Downloading: http://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml
Downloaded: http://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-metadata.xml (13 KB at 53.3 KB/sec)
Downloaded: http://repo.maven.apache.org/maven2/org/codehaus/mojo/maven-metadata.xml (22 KB at 93.3 KB/sec)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.382 s
[INFO] Finished at: 2014-05-03T21:45:53-05:00
[INFO] Final Memory: 8M/81M
[INFO] ------------------------------------------------------------------------
[ERROR] No plugin found for prefix 'spring-boot' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (/Users/jgs/.m2/repository), central (http://repo.maven.apache.org/maven2)] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/NoPluginFoundForPrefixException
This is the reference for springloaded in the pom.xml
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<argLine>-XX:MaxPermSize=128m -Xmx256m</argLine>
<forkCount>1</forkCount>
<reuseForks>false</reuseForks>
<!-- Force alphabetical order to have a reproducible build -->
<runOrder>alphabetical</runOrder>
<classpathDependencyExcludes>
<classpathDependencyExclude>org.springsource.loaded:springloaded</classpathDependencyExclude>
</classpathDependencyExcludes>
</configuration>
</plugin>
I think there is a bug in the current yeoman generator. I was able to resolve this by using the plugin in the jhipster sample project.
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<arguments>
<argument>--spring.profiles.active=prod</argument>
</arguments>
</configuration>
</plugin>
I have simply doubts that you will use SNAPSHOT as you required by using in your example.
org.springframework:springloaded:jar:1.2.0.BUILD-SNAPSHOT
You should use this:
org.springframework:springloaded:jar:1.2.0.RELEASE
instead. So you need to change the version entries in your pom file accordingly.
You must just choose you folder project:
Go to run → debug configuration → build maven → browser workspace.
Finally choose your project folder.
The same message is also displayed when you chose to use gradle during the jhipster setup phase (kinda obvious). Maven is not complaining about the missing pom.xml but generates this obscure message.
For gradle based builds the command is
gradlew bootRun
then get some coffe cause its gonna download loads! of stuff

Resources