您好我尝试在jboss上部署jboss sar文件。我的问题是他可以认出结束jboss-sar。
<plugin>
<groupId>org.jboss.as.plugins</groupId>
<artifactId>jboss-as-maven-plugin</artifactId>
<version>7.0.2.Final</version>
<executions>
<execution>
<phase>install</phase>
<goals>
<goal>deploy</goal>
</goals>
</execution>
</executions>
</plugin>
使用此部署插件我收到此错误
[INFO] Could not execute goal deploy on dts.jboss-sar. Reason: D:\Workspace Liferay\DTS_TRUNK\code\dts\dts-sar\target\dts.jboss-sar (The system cannot find the file specified)
问题是我怎么能告诉他看dts.sar而不是dts.jboss-sar couse这个文件dts.sar在那里但是他看不到它。
Okey我找到了解决方案,并在
上更改了插件 <plugin>
<groupId>org.jboss.as.plugins</groupId>
<artifactId>jboss-as-maven-plugin</artifactId>
<version>7.0.2.Final</version>
<configuration>
<filename>dts.sar</filename>
<artifactTypeMappings>
<artifactTypeMapping type="jboss-sar" mapping="sar"/>
</artifactTypeMappings>
</configuration>
<executions>
<execution>
<phase>install</phase>
<goals>
<goal>deploy</goal>
</goals>
</execution>
</executions>
</plugin>
现在看起来它正在运作,但还有其他问题:
16:50:14,298 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC00001: Failed to start service jboss.deployment.unit."dts.sar".PARSE: org.jboss.msc.service.StartException in service jboss.deployment.unit."dts.sar".PARSE: Failed to process phase PARSE of deployment "dts.sar"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:121) [jboss-as-server-7.0.2.Final.jar:7.0.2.Final]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1824) [jboss-msc-1.0.1.GA.jar:1.0.1.GA]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1759) [jboss-msc-1.0.1.GA.jar:1.0.1.GA]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [:1.6.0_15]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [:1.6.0_15]
at java.lang.Thread.run(Thread.java:619) [:1.6.0_15]
Caused by: org.jboss.as.server.deployment.DeploymentUnitProcessingException: Failed to parse service xml ["/D:/liferay-portal-6.1.0-ce-ga1/jboss-7.0.2/bin/content/dts.sar/META-INF/jboss-service.xml"]
at org.jboss.as.service.ServiceDeploymentParsingProcessor.deploy(ServiceDeploymentParsingProcessor.java:94)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:115) [jboss-as-server-7.0.2.Final.jar:7.0.2.Final]
... 5 more
Caused by: javax.xml.stream.XMLStreamException: ParseError at [row,col]:[2,1]
Message: Unexpected element 'server'
at org.jboss.staxmapper.XMLMapperImpl.processNested(XMLMapperImpl.java:98) [staxmapper-1.0.0.Final.jar:1.0.0.Final]
at org.jboss.staxmapper.XMLMapperImpl.parseDocument(XMLMapperImpl.java:59) [staxmapper-1.0.0.Final.jar:1.0.0.Final]
at org.jboss.as.service.ServiceDeploymentParsingProcessor.deploy(ServiceDeploymentParsingProcessor.java:87)
... 6 more
16:50:14,301 INFO [org.jboss.as.server.controller] (pool-1-thread-3) Deployment of "dts.sar" was rolled back with failure message {"Failed services" => {"jboss.deployment.unit.\"dts.sar\".PARSE" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"dts.sar\".PARSE: Failed to process phase PARSE of deployment \"dts.sar\""}}
16:50:14,304 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) Stopped deployment dts.sar in 3ms
当我尝试部署其他war文件并且我不知道该怎么做时,我有类似的问题。
答案 0 :(得分:1)
从jboss-service.xml中删除Mbean很简单