我最近升级到了Juno的新版本(因为我的旧版本正在播放),现在我的Java EE应用程序不能在JBOSS 6.1.0上运行。我一直试图让JBOSS认识到项目有JSF页面,我在WEB-INF / lib中有以下内容 JSF的小面,1.1.15.jar RichFaces的-API 3.1.6.SR1.jar RichFaces的-API 3.3.3.Final.jar RichFaces的-IMPL-3.1.6.SR1.jar RichFaces的-IMPL-3.3.3.Final.jar RichFaces的-UI-3.1.6.SR1.jar RichFaces的-UI-3.3.3.Final.jar
昨天它显示的页面没有任何JSF标签。我今天尝试做了一些更改,现在它根本不起作用。请有人帮忙
它出现以下错误:
20:21:49,728 INFO [org.jboss.ejb3.proxy.impl.jndiregistrar.JndiSessionRegistrarBase] Binding the following Entries in Global JNDI:
ShoppingCart/remote - EJB3.x Default Remote Business Interface
ShoppingCart/remote-com.shop.cart.ShoppingCart - EJB3.x Remote Business Interface
ShoppingCart/local - EJB3.x Default Local Business Interface
ShoppingCart/local-com.shop.cart.ShoppingCartLocal - EJB3.x Local Business Interface
20:21:49,803 INFO [org.jboss.web.tomcat.service.deployers.TomcatDeployment] deploy, ctxPath=/Woody
20:21:50,074 INFO [javax.enterprise.resource.webcontainer.jsf.config] Initializing Mojarra 2.0.3 ( b05) for context '/Woody'
20:21:53,144 INFO [javax.enterprise.resource.webcontainer.jsf.config] Unsanitized stacktrace from failed start...: com.sun.faces.config.ConfigurationException: Factory 'javax.faces.render.RenderKitFactory' was not configured properly.
at com.sun.faces.config.processor.FactoryConfigProcessor.verifyFactoriesExist(FactoryConfigProcessor.java:292) [:2.0.3-]
at com.sun.faces.config.processor.FactoryConfigProcessor.process(FactoryConfigProcessor.java:209) [:2.0.3-]
at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:332) [:2.0.3-]
at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:220) [:2.0.3-]
at org.jboss.web.jsf.integration.config.JBossMojarraConfigureListener.contextInitialized(JBossMojarraConfigureListener.java:58) [:1.0.3]
at org.apache.catalina.core.StandardContext.contextListenerStart(StandardContext.java:3369) [:6.1.0.Final]
at org.apache.catalina.core.StandardContext.start(StandardContext.java:3828) [:6.1.0.Final]
at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeployInternal(TomcatDeployment.java:294) [:6.1.0.Final]
at org.jboss.web.tomcat.service.deployers.TomcatDeployment.performDeploy(TomcatDeployment.java:146) [:6.1.0.Final]
at org.jboss.web.deployers.AbstractWarDeployment.start(AbstractWarDeployment.java:476) [:6.1.0.Final]
at org.jboss.web.deployers.WebModule.startModule(WebModule.java:118) [:6.1.0.Final]
at org.jboss.web.deployers.WebModule.start(WebModule.java:95) [:6.1.0.Final]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.8.0_25]
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [:1.8.0_25]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [:1.8.0_25]
at java.lang.reflect.Method.invoke(Unknown Source) [:1.8.0_25]
at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:157) [:6.0.0.GA]
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:96) [:6.0.0.GA]
at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) [:6.0.0.GA]
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:271) [:6.0.0.GA]
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:670) [:6.0.0.GA]
at org.jboss.system.microcontainer.ServiceProxy.invoke(ServiceProxy.java:206) [:2.2.0.SP2]
at com.sun.proxy.$Proxy43.start(Unknown Source)
at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:53) [:2.2.0.SP2]
at org.jboss.system.microcontainer.StartStopLifecycleAction.installAction(StartStopLifecycleAction.java:41) [:2.2.0.SP2]
at org.jboss.dependency.plugins.action.SimpleControllerContextAction.simpleInstallAction(SimpleControllerContextAction.java:62) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.action.AccessControllerContextAction.install(AccessControllerContextAction.java:71) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractControllerContextActions.install(AbstractControllerContextActions.java:51) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:379) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.system.microcontainer.ServiceControllerContext.install(ServiceControllerContext.java:301) [:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2044) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1083) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1322) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1246) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1139) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:939) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:654) [jboss-dependency.jar:2.2.0.SP2]
at org.jboss.deployers.plugins.deployers.DeployersImpl.change(DeployersImpl.java:1983) [:2.2.2.GA]
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:1076) [:2.2.2.GA]
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:679) [:2.2.2.GA]
at org.jboss.system.server.profileservice.deployers.MainDeployerPlugin.process(MainDeployerPlugin.java:106) [:6.1.0.Final]
at org.jboss.profileservice.dependency.ProfileControllerContext$DelegateDeployer.process(ProfileControllerContext.java:143) [:0.2.2]
at org.jboss.profileservice.deployment.hotdeploy.HDScanner$HDScanAction.deploy(HDScanner.java:240) [:0.2.2]
at org.jboss.profileservice.deployment.hotdeploy.HDScanner$HDScanAction.complete(HDScanner.java:192) [:0.2.2]
at org.jboss.profileservice.management.TwoPCActionWrapper.doComplete(TwoPCActionWrapper.java:57) [:0.2.2]
at org.jboss.profileservice.management.actions.AbstractTwoPhaseModificationAction.complete(AbstractTwoPhaseModificationAction.java:74) [:0.2.2]
at org.jboss.profileservice.management.actions.AbstractTwoPhaseModificationAction.prepare(AbstractTwoPhaseModificationAction.java:95) [:0.2.2]
at org.jboss.profileservice.management.ModificationSession.prepare(ModificationSession.java:87) [:0.2.2]
at org.jboss.profileservice.management.AbstractActionController.internalPerfom(AbstractActionController.java:234) [:0.2.2]
at org.jboss.profileservice.management.AbstractActionController.performWrite(AbstractActionController.java:213) [:0.2.2]
at org.jboss.profileservice.management.AbstractActionController.perform(AbstractActionController.java:150) [:0.2.2]
at org.jboss.profileservice.management.AbstractActionController.perform(AbstractActionController.java:135) [:0.2.2]
at org.jboss.profileservice.deployment.hotdeploy.HDScanner.scan(HDScanner.java:146) [:0.2.2]
at org.jboss.profileservice.deployment.hotdeploy.HDScanner.run(HDScanner.java:90) [:0.2.2]
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [:1.8.0_25]
at java.util.concurrent.FutureTask.runAndReset(Unknown Source) [:1.8.0_25]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(Unknown Source) [:1.8.0_25]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source) [:1.8.0_25]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [:1.8.0_25]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [:1.8.0_25]
at java.lang.Thread.run(Unknown Source) [:1.8.0_25]
Caused by: javax.faces.FacesException: org.ajax4jsf.renderkit.ChameleonRenderKitFactory
at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:589) [:2.0.3-]
at javax.faces.FactoryFinder.getImplementationInstance(FactoryFinder.java:468) [:2.0.3-]
at javax.faces.FactoryFinder.access$400(FactoryFinder.java:135) [:2.0.3-]
at javax.faces.FactoryFinder$FactoryManager.getFactory(FactoryFinder.java:792) [:2.0.3-]
at javax.faces.FactoryFinder.getFactory(FactoryFinder.java:302) [:2.0.3-]
at com.sun.faces.config.processor.FactoryConfigProcessor.verifyFactoriesExist(FactoryConfigProcessor.java:290) [:2.0.3-]
... 60 more
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [:1.8.0_25]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source) [:1.8.0_25]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source) [:1.8.0_25]
at java.lang.reflect.Constructor.newInstance(Unknown Source) [:1.8.0_25]
at javax.faces.FactoryFinder.getImplGivenPreviousImpl(FactoryFinder.java:582) [:2.0.3-]
... 65 more
Caused by: java.lang.NoClassDefFoundError: org/apache/commons/digester/Digester
at org.ajax4jsf.resource.ResourceBuilderImpl.registerConfig(ResourceBuilderImpl.java:156) [:3.1.6.SR1]
at org.ajax4jsf.resource.ResourceBuilderImpl.registerResources(ResourceBuilderImpl.java:140) [:3.1.6.SR1]
at org.ajax4jsf.resource.ResourceBuilderImpl.init(ResourceBuilderImpl.java:211) [:3.1.6.SR1]
at org.ajax4jsf.renderkit.ChameleonRenderKitFactory.<init>(ChameleonRenderKitFactory.java:62) [:3.1.6.SR1]
... 70 more
Caused by: java.lang.ClassNotFoundException: org.apache.commons.digester.Digester from BaseClassLoader@7d0f7b64{vfs:///C:/Users/Lalin/workspace/.metadata/.plugins/org.jboss.ide.eclipse.as.core/jboss-6.1.0.Final_Runtime_Server1423085331251/deploy/Woody.war}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:480) [jboss-classloader.jar:2.2.1.GA]
at java.lang.ClassLoader.loadClass(Unknown Source) [:1.8.0_25]
... 74 more
Web.xml中
<?xml version="1.0" encoding="UTF-8"?>
<web-app version="3.0" xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
<display-name>Woody</display-name>
<context-param>
<param-name>facelets.REFRESH_PERIOD</param-name>
<param-value>2</param-value>
</context-param>
<context-param>
<param-name>javax.faces.DEFAULT_SUFFIX</param-name>
<param-value>.xhtml</param-value>
</context-param>
<servlet>
<servlet-name>Faces Servlet</servlet-name>
<servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
<init-param>
<param-name>basePath</param-name>
<param-value>/WEB-INF/resources</param-value>
</init-param>
<enabled>true</enabled>
</servlet>
<servlet-mapping>
<servlet-name>Faces Servlet</servlet-name>
<url-pattern>*.xhtml</url-pattern>
</servlet-mapping>
<session-config>
<session-timeout>30</session-timeout>
</session-config>
<welcome-file-list>
<welcome-file>welcome.xhtml</welcome-file>
</welcome-file-list>
</web-app>
答案 0 :(得分:0)
我通过将服务器升级到JBOSS AS 7来修复它,创建一个具有JSF功能的空白Java EE应用程序,并从旧项目传输文件。新项目正常运作。