如何使用Cargo maven插件将EAR远程部署到JBoss 5.1.0.GA? [英] How to deploy remotely EAR to JBoss 5.1.0.GA using Cargo maven plugin?

查看:177
本文介绍了如何使用Cargo maven插件将EAR远程部署到JBoss 5.1.0.GA?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有人成功将EAR远程部署到JBoss 5.1.0.GA?我的pom.xml配置如下:

Has someone successfully deployed EAR remotely to JBoss 5.1.0.GA? My pom.xml configuration is as follows:

<plugin>
    <groupId>org.codehaus.cargo</groupId>
    <artifactId>cargo-maven2-plugin</artifactId>
    <version>1.0.1-SNAPSHOT</version>

    <configuration>
        <container>
            <containerId>jboss51x</containerId>
            <type>remote</type>
            <timeout>600000</timeout>
        </container>

        <configuration>
            <type>runtime</type>
            <properties>
                <cargo.remote.username>username</cargo.remote.username>
                <cargo.remote.password>password</cargo.remote.password>
                <cargo.hostname>myserver</cargo.hostname>
                <cargo.servlet.port>8888</cargo.servlet.port>
            </properties>
        </configuration>

        <deployer>
            <type>remote</type>
            <deployables>
                <deployable>
                </deployable>
            </deployables>
        </deployer>
    </configuration>
</plugin>

这导致以下错误消息:

java.io.IOException: Server returned HTTP response code: 500 for URL:
 http://myserver:8888/jmx-console/HtmlAdaptor?action=invokeOpByName&name=jboss.system:service%3DMainDeployer&methodName=deploy&argType=java.net.URL&arg0=file:d%3A%5Cear%5Cmy-ear-1.0-SNAPSHOT.ear


推荐答案

据我所知,使用JBoss进行远程部署并不是开箱即用的(问题是要部署的文件必须在JBoss服务器上本地存在)。此问题在 CARGO-416 中有详细说明,该问题仍然有效(我不知道是否补丁仍然可以顺利应用)。

To my knowledge, remote deployment with JBoss doesn't work out of the box (the problem being that the file to be deployed must exist locally on the JBoss server). This issue is detailed in CARGO-416 which is still open (I have no idea if the patch can still be applied smoothly).

有人在此帖子中提到了一个肮脏的解决方法(简而言之,首先将你的可展开部署到远程机器上),但这似乎并不令人满意。

Someone is mentioning a dirty workaround in this thread (in short, ftping your deployable to the remote machine first) but it doesn't seem very satisfying.

更新: CARGO-416 已在Cargo 1.0中修复.3和JBoss AS上的远程部署现在支持并记录在专用的 JBoss Remote Deployer 维基页面。

这篇关于如何使用Cargo maven插件将EAR远程部署到JBoss 5.1.0.GA?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆