码迷,mobileinhere.cn
首页 > web开发 > 详细

使用 idea 创建 maven web 项目 (异常)- disconnected from the target vm, address: '127.0.0.1:59770', transport: 'socket'

时间:2016-05-08 23:59:45      阅读:32578      评论:0      收藏:0      [点我收藏+]

标签:

运行环境:

jdk 版本:1.8

maven 版本:apache-maven-3.3.3

idea 版本:14

maven-jetty-plugin 配置:

<plugin>
    <groupid>org.eclipse.jetty</groupid>
    <artifactid>jetty-maven-plugin</artifactid>
    <configuration>
        <webappsourcedirectory>${project.basedir}/web</webappsourcedirectory>
        <scanintervalseconds>10</scanintervalseconds>
        <httpconnector>
            <port>8081</port>
        </httpconnector>
        <stopkey>shutdown</stopkey>
        <stopport>9966</stopport>
        <webapp>
            <contextpath>/${project.artifactid}</contextpath>
        </webapp>
    </configuration>
</plugin>

控制台输出异常信息:

"c:\program files\java\jdk1.8.0_65\bin\java" -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:59770,suspend=y,server=n -dmaven.home=d:\apache-maven-3.3.3 -dclassworlds.conf=d:\apache-maven-3.3.3\bin\m2.conf -dfile.encoding=utf-8 -classpath "d:\apache-maven-3.3.3\boot\plexus-classworlds-2.5.2.jar;c:\program files (x86)\jetbrains\intellij idea 14.0.2\lib\idea_rt.jar" org.codehaus.classworlds.launcher -didea.version=14.0.2 jetty:run
connected to the target vm, address: ‘127.0.0.1:59770‘, transport: ‘socket‘
disconnected from the target vm, address: ‘127.0.0.1:59770‘, transport: ‘socket‘
-dmaven.multimoduleprojectdirectory system propery is not set. check $m2_home environment variable and mvn script match.
process finished with exit code 1

解决方法:

网上说是由于 idea 与 maven 的版本不兼容造成的上述问题(原文地址:bbs.51cto.com/thread-1147659-1.html),把 maven 改成 apache-maven-3.1.1-bin ,上述问题就成功解决了。

使用 idea 创建 maven web 项目 (异常)- disconnected from the target vm, address: '127.0.0.1:59770', transport: 'socket'

标签:

原文地址:www.cnblogs.com/longying2008/p/5472027.html

(52)
(8)
   
举报
评论 一句话评论(0
0条  
登录后才能评论!
2014 mobileinhere.cn 版权所有 京icp备13008772号-2
华人娱乐注册