MSC000001:无法启动服务 jboss.web.deployment.default-host./scWeb ..... JBAS018040:无法启动上下文
Posted
技术标签:
【中文标题】MSC000001:无法启动服务 jboss.web.deployment.default-host./scWeb ..... JBAS018040:无法启动上下文【英文标题】:MSC000001: Failed to start service jboss.web.deployment.default-host./scWeb ..... JBAS018040: Failed to start context 【发布时间】:2015-08-07 15:05:18 【问题描述】:作为部署的一部分,我收到以下错误。实际上我正在 JBoss 中部署 Websphere 应用程序。我正在一一整理问题。
如果有人知道此错误,请指导我。如果您需要任何其他配置详细信息,我可以提供。
12:01:36,228 ERROR [org.apache.catalina.core] (ServerService Thread Pool -- 111) JBWEB001103: Error detected during context /scWeb start, will stop it
12:01:36,228 INFO [stdout] (ServerService Thread Pool -- 111) ERROR [ServerService Thread Pool -- 111] (StandardContext.java:3841) - JBWEB001103: Error detected during context /scWeb start, will stop it
12:01:36,228 DEBUG [org.jboss.as.web.session.DistributableSessionManager.scWeb] (ServerService Thread Pool -- 111) Stopping
12:01:36,228 INFO [stdout] (ServerService Thread Pool -- 111) DEBUG [ServerService Thread Pool -- 111] (DistributableSessionManager.java:396) - Stopping
12:01:36,228 DEBUG [org.jboss.as.web.session.DistributableSessionManager.scWeb] (ServerService Thread Pool -- 111) Closing off LockingValve
12:01:36,228 INFO [stdout] (ServerService Thread Pool -- 111) DEBUG [ServerService Thread Pool -- 111] (DistributableSessionManager.java:415) - Closing off LockingValve
12:01:36,228 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 111) MSC000001: Failed to start service jboss.web.deployment.default-host./scWeb: org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./scWeb: org.jboss.msc.service.StartException in anonymous service: JBAS018040: Failed to start context
at org.jboss.as.web.deployment.WebDeploymentService$1.run(WebDeploymentService.java:99)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [rt.jar:1.8.0_45]
at java.util.concurrent.FutureTask.run(Unknown Source) [rt.jar:1.8.0_45]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [rt.jar:1.8.0_45]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [rt.jar:1.8.0_45]
at java.lang.Thread.run(Unknown Source) [rt.jar:1.8.0_45]
at org.jboss.threads.JBossThread.run(JBossThread.java:122)
Caused by: org.jboss.msc.service.StartException in anonymous service: JBAS018040: Failed to start context
at org.jboss.as.web.deployment.WebDeploymentService.doStart(WebDeploymentService.java:168)
at org.jboss.as.web.deployment.WebDeploymentService.access$000(WebDeploymentService.java:61)
at org.jboss.as.web.deployment.WebDeploymentService$1.run(WebDeploymentService.java:96)
... 6 more
【问题讨论】:
这个错误的实际原因,-JBAS018040: Failed to start
会因情况而异,但是,它明确指出问题是Spring Application Context
意味着我们通过容器进行的任何注入。
【参考方案1】:
web.xml
具有以下用于依赖注入的 spring 配置......
<context-param>
<param-name>contextConfigLocation</param-name>
<param-value>/WEB-INF/applicationContext-*.xml</param-value>
</context-param>
和web.xml
中的 Struts 上下文加载器侦听器...
<listener>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
并且ApplicationContext-config.xml
具有以下 bean 引用...
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN 2.0//EN" "http://www.springframework.org/dtd/spring-beans-2.0.dtd">
<beans>
<bean id="userRoleService" class="com.singtel.pcb.sam.dto.UserRoleService">
<property name="dataSource" ref="dataSource"></property>
</bean>
</beans>
其中这个特定的 bean 是其他 .war 的一部分......我已经从 scWeb.war\WEB-INF\lib
中删除了已编译的服务器端类,-samWeb.jar
......这导致了上述错误......
因此发生了这个错误....
JBAS018040:无法启动上下文 在 org.jboss.as.web.deployment.WebDeploymentService$1.run(WebDeploymentService.java:99)
当我重做构建活动时,这已经消失了......所以我知道这是问题所在......基本上我正在将我的应用程序从 Websphere 移植到 JBoss......我正在尝试混合和匹配活动....
【讨论】:
这里是 IOC 容器......依赖注入与 IOC 容器不同......这里web.xml
有 IOC 容器配置......依赖注入是 IOC 的进步概念......以上是关于MSC000001:无法启动服务 jboss.web.deployment.default-host./scWeb ..... JBAS018040:无法启动上下文的主要内容,如果未能解决你的问题,请参考以下文章
Wildfly/JBOSS 持久性错误 MSC000001:无法启动服务 jboss.persistenceunit
org.jboss.msc.service.StartException in service jboss.web.deployment.default-host./: 无法启动服务
c:\windows\system32\service.msc指定的服务未安装怎么办
vmware下启动CentOS虚拟机报错虚拟机无法找到CentOS-000001.vmdk文件是啥情况
JBOSS启动报错Failed to start service jboss.web.deployment.default-host.