繁体   English   中英

Maven WildFly插件:无法执行目标部署

[英]Maven WildFly Plugin: Could not execute goal deploy

我想用maven wildfly-plugin部署我的war文件。 我使用wildfly-8.2.0.Final -version,我强迫将管理控制台的端口更改为http://127.0.0.1:9990

这是我的maven配置:

             <plugin>
                <groupId>org.wildfly.plugins</groupId>
                <artifactId>wildfly-maven-plugin</artifactId>
                <version>1.0.2.Final</version>
                <configuration>
                    <jbossHome>C:\wildfly-8.2.0.Final</jbossHome>
                    <hostname>127.0.0.1</hostname>
                    <port>8080</port>
                    <serverConfig>standalone-full.xml</serverConfig>
                </configuration>
            </plugin>

我收到以下错误:

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 2.705 s
[INFO] Finished at: 2016-02-01T22:46:43+01:00
[INFO] Final Memory: 21M/171M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.wildfly.plugins:wildfly-maven-plugin:1.0.2.Final:deploy (default-cli) on project wildfly: Could not execute goal deploy on C:\Users\laudatio\Documents\Java\wildfly\target\wildfly.war. Reason: I/O Error could not execute operation '{
[ERROR] "operation" => "read-attribute",
[ERROR] "address" => [],
[ERROR] "name" => "launch-type"
[ERROR] }': java.io.IOException: Unknown service name
[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/MojoExecutionException

有什么建议?

错误消息不是很好,它已在上游修复 ,但问题是你已经定义了错误的端口。 该插件使用管理端口,默认为9990 如果将配置更改为<port>9990</port>或将其保持关闭,则应该可以正常工作。

请注意,您不需要大多数配置。 只有runstart目标才需要jbossHomeserverConfig 如果您只是部署,则不需要定义任何配置。 默认值应该是正确的。

问题的原因可能是以下之一:

  • 通过wildfly-maven-plugin插件部署任何存档(jar,war,ear)只有在WildFly正在监听其管理端口(默认为9990)时才会发生。 因此,请确保WildFly正在侦听其管理端口。
  • 如果WildFly正在侦听其管理端口,请检查位于%SYSTEM_ROOT%\\ System32 \\ drivers \\ etc的主机文件是否正确配置。 即您的本地主机已正确映射IPv4和IPv6。

    127.0.0.1 localhost
    :: 1 localhost

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM