【发布时间】:2021-04-05 13:17:52
【问题描述】:
我使用父 pom 项目和几个模块开发 Java EE 应用程序。我有 2 个 EJB 模块、1 个 web (war) 模块和 1 个 EAR 模块。当我尝试将 ear 模块部署到 Wildfy 21.0.0 时,服务器出现错误: 错误 [org.jboss.msc.service.fail](MSC 服务线程 1-5)MSC000001:无法启动服务 jboss.module.service。“deployment.LeqadoviProjekt-ear-1.1.ear”.main:org.jboss。服务 jboss.module.service 中的 msc.service.StartException。“deployment.LeqadoviProjekt-ear-1.1.ear”.main:WFLYSRV0179:无法加载模块:deployment.LeqadoviProjekt-ear-1.1.ear 在 org.jboss.as.server.moduleservice.ModuleLoadService.start(ModuleLoadService.java:116) 在 org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1739) 在 org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1701)
我使用的 IDE 是 Eclipse。项目结构: here 。 如果我有父pom项目或者我必须部署父项目,部署ear模块是否正确?
The context of parent pom was next:
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.efd.hsostaric.svi</groupId>
<artifactId>LeadoviProjekt_svi</artifactId>
<version>0.0.1</version>
<url>http://www.wildfly.org</url>
<packaging>pom</packaging>
<name>LeadoviProjekt_svi</name>
<properties>
<maven.compiler.source>1.8</maven.compiler.source>
<maven.compiler.target>1.8</maven.compiler.target>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<version.wildfly.maven.plugin>2.0.1.Final</version.wildfly.maven.plugin>
</properties>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.wildfly.bom</groupId>
<artifactId>wildfly-javaee8-with-tools</artifactId>
<version>17.0.1.Final</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<build>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.wildfly.plugins</groupId>
<artifactId>wildfly-maven-plugin</artifactId>
<version>2.0.1.Final</version>
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>
<modules>
<module>LeadoviProjekt-war</module>
<module>LeadoviProjekt-ejb</module>
<module>LeadoviProjekt-ejb-bll</module>
<module>LeqadoviProjekt-ear</module>
</modules>
</project>
如果您有任何帮助或建议,我将不胜感激。
【问题讨论】:
-
这是整个错误信息吗?我期待一个“引起:”。您粘贴的内容仅说明尝试部署时出现问题,但没有提供任何原因。如果您的 IDE 没有提供更多信息,我会查看 wildfly 的日志,那里肯定会出现显式错误