WebSphere 7+中的JSF 2 Mojarra和Primefaces [英] JSF 2 Mojarra and Primefaces in WebSphere 7+

查看:101
本文介绍了WebSphere 7+中的JSF 2 Mojarra和Primefaces的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在与WebSphere 7+和Mojarra 2.0.4的邪恶联盟作斗争,并且遇到了麻烦.

I have been struggling with the unholy alliance that is WebSphere 7+ and Mojarra 2.0.4 and have run into something of a showstopper.

我按照此论坛帖子上指定的指示进行操作,并正确初始化了Mojarra 2.0.4: http://forum.primefaces.org/viewtopic.php?f=3&t=6860

I followed the directions as specified at this forum post and got Mojarra 2.0.4 initializing properly: http://forum.primefaces.org/viewtopic.php?f=3&t=6860

基本上,我创建了一个隔离的类加载器共享库,该库从外部引用了Mojarra和Primefaces jars,将该共享库添加到了webapp中,并将类加载器反转为PARENT_LAST.所有这些都有效.

Basically I created an isolated classloader shared library that refers externally to the Mojarra and Primefaces jars, added the shared library to the webapp and reversed the classloader to go PARENT_LAST. All of that works.

当我尝试访问Web应用程序http://server:port/context/index.xhtml时,它正确地击中了FacesServlet,但随后请求分发器立即重定向到index.jsp ???

When I attempt to access my web app http://server:port/context/index.xhtml it is hitting the FacesServlet correctly but then instantly the Request Dispatcher is redirecting to index.jsp???

我在代码,应用程序,web.xml中都没有指定任何JSP,实际上我将DEFAULT-SUFFIX指定为.xhtml,但这没有帮助.我所有的网页都是.xhtml扩展名,并且FacesServlet已正确映射到*.xhtml.

I don't have any JSP specified ANYWHERE in my code, my app, my web.xml, and in fact I specified DEFAULT-SUFFIX to be .xhtml and that didn't help. All my web pages are .xhtml extension and FacesServlet is mapped correctly to *.xhtml.

我尝试将XHTML作为mime类型添加到WebSphere,从而禁用了Request Dispatcher,但无济于事.我已经能够使它在Tomcat 6-7,JBoss 6和Glassfish 3上正常运行,没有问题,但是由于某种原因,WebSphere坚持使用JSP文件扩展名?

I have tried adding XHTML as a mime type to WebSphere, disabling the Request Dispatcher, all to no avail. I have been able to get this running correctly on Tomcat 6-7, JBoss 6 and Glassfish 3 with no problems but for some reason WebSphere insists on a JSP file extension?

感谢您的帮助.

推荐答案

WAS7有时不能正确地取消部署Web应用程序.清除WAS_PROFILE_HOME/temp和WAS_PROFILE_HOME/wstemp可能会有所帮助.

WAS7 sometimes does not undeploy the web applications properly. Clearing WAS_PROFILE_HOME/temp and WAS_PROFILE_HOME/wstemp may help.

这篇关于WebSphere 7+中的JSF 2 Mojarra和Primefaces的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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