`

Unable to import maven project: See logs for details

 
阅读更多
更新JDK到1.8,不能引入和新建maven工程了。然后maven的Build Tools还是1.7,google了一下,stack上找的解决问题的所在。

java.lang.RuntimeException: Cannot reconnect.
	at org.jetbrains.idea.maven.server.RemoteObjectWrapper.perform(RemoteObjectWrapper.java:82)
	at org.jetbrains.idea.maven.server.MavenServerManager.applyProfiles(MavenServerManager.java:519)
	at org.jetbrains.idea.maven.project.MavenProjectReader.applyProfiles(MavenProjectReader.java:371)
	at org.jetbrains.idea.maven.project.MavenProjectReader.doReadProjectModel(MavenProjectReader.java:100)
	at org.jetbrains.idea.maven.project.MavenProjectReader.readProject(MavenProjectReader.java:55)
	at org.jetbrains.idea.maven.project.MavenProject.read(MavenProject.java:631)
	at org.jetbrains.idea.maven.wizards.MavenProjectBuilder.collectProfiles(MavenProjectBuilder.java:197)
	at org.jetbrains.idea.maven.wizards.MavenProjectBuilder.access$900(MavenProjectBuilder.java:47)
	at org.jetbrains.idea.maven.wizards.MavenProjectBuilder$1.run(MavenProjectBuilder.java:171)
	at org.jetbrains.idea.maven.utils.MavenUtil$6.run(MavenUtil.java:425)
	at com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:563)
	at com.intellij.openapi.progress.impl.CoreProgressManager$8.run(CoreProgressManager.java:357)
	at com.intellij.openapi.progress.impl.CoreProgressManager$2.run(CoreProgressManager.java:142)
	at com.intellij.openapi.progress.impl.CoreProgressManager.a(CoreProgressManager.java:446)
	at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:392)
	at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:54)
	at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:127)
	at com.intellij.openapi.application.impl.ApplicationImpl$13$1.run(ApplicationImpl.java:633)
	at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:369)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)
Caused by: java.rmi.RemoteException: Cannot start maven service; nested exception is: 
	com.intellij.execution.ExecutionException: 
	at org.jetbrains.idea.maven.server.MavenServerManager.create(MavenServerManager.java:168)
	at org.jetbrains.idea.maven.server.MavenServerManager.create(MavenServerManager.java:73)
	at org.jetbrains.idea.maven.server.RemoteObjectWrapper.getOrCreateWrappee(RemoteObjectWrapper.java:41)
	at org.jetbrains.idea.maven.server.MavenServerManager$8.execute(MavenServerManager.java:522)
	at org.jetbrains.idea.maven.server.MavenServerManager$8.execute(MavenServerManager.java:519)
	at org.jetbrains.idea.maven.server.RemoteObjectWrapper.perform(RemoteObjectWrapper.java:76)
	... 23 more
Caused by: com.intellij.execution.ExecutionException: 
	at com.intellij.execution.rmi.RemoteProcessSupport.acquire(RemoteProcessSupport.java:160)
	at org.jetbrains.idea.maven.server.MavenServerManager.create(MavenServerManager.java:165)
	... 28 more



I had this problem all of a sudden (after an update + Windows Update). I tried a lot of things, and in the end, set Settings > Build, Execution, Deployment > Build Tools > Maven > Importing > JDK for Importer to Use JAVA_HOME (which I've set up as an env var pointing to a JDK install). That seems to work.
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics