Fórumok
OpenSessionInViewFilter is an unknown filter name in version 6.1.1
Florencia Hernández, módosítva 11 év-val korábban
OpenSessionInViewFilter is an unknown filter name in version 6.1.1
Regular Member Bejegyzések: 146 Csatlakozás dátuma: 2012.03.27. Legújabb bejegyzések
Hi Everyone,
I developed a portlet with the Liferay IDE for LR 6.1.0 CE GA1. I now try to deploy it with LR 6.1.1 CE GA2 and I get the following exception:
Here is my web.xml:
Why is OpenSessionInViewFilter an unknown filter name?
How do I fix this?
TIA,
Flor.
I developed a portlet with the Liferay IDE for LR 6.1.0 CE GA1. I now try to deploy it with LR 6.1.1 CE GA2 and I get the following exception:
Oct 10, 2012 1:50:39 PM org.apache.catalina.core.ContainerBase addChildInternal
SEVERE: ContainerBase.addChild: start:
org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/VideoChat-portlet]]
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:679)
Caused by: java.lang.IllegalArgumentException: Filter mapping specifies an unknown filter name OpenSessionInViewFilter
at org.apache.catalina.core.StandardContext.validateFilterMap(StandardContext.java:3003)
at org.apache.catalina.core.StandardContext.addFilterMap(StandardContext.java:2968)
at org.apache.catalina.deploy.WebXml.configureContext(WebXml.java:1207)
at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1357)
at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:855)
at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:345)
at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5161)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 11 more
Oct 10, 2012 1:50:39 PM org.apache.catalina.startup.HostConfig deployDirectory
SEVERE: Error deploying web application directory /opt/liferay/test-611/liferay-portal-6.1.1-ce-ga2/tomcat-7.0.27/webapps/VideoChat-portlet
java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/VideoChat-portlet]]
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:898)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1099)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1621)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
at java.util.concurrent.FutureTask.run(FutureTask.java:166)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:679)
Here is my web.xml:
<!--?xml version="1.0" encoding="UTF-8"?-->
<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemalocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
<!-- load the spring context -->
<listener>
<description>Spring framework global application context.</description>
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>
<!-- listener to let spring know about the web scopes -->
<listener>
<listener-class>org.springframework.web.context.request.RequestContextListener</listener-class>
</listener>
<filter-mapping>
<filter-name>OpenSessionInViewFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<servlet>
<servlet-name>ViewRendererServlet</servlet-name>
<servlet-class>org.springframework.web.servlet.ViewRendererServlet</servlet-class>
<load-on-startup>1</load-on-startup>
</servlet>
<servlet-mapping>
<servlet-name>ViewRendererServlet</servlet-name>
<url-pattern>/WEB-INF/servlet/view</url-pattern>
</servlet-mapping>
</web-app>
Why is OpenSessionInViewFilter an unknown filter name?
How do I fix this?
TIA,
Flor.
Juan Gonzalez P, módosítva 11 év-val korábban
RE: OpenSessionInViewFilter is an unknown filter name in version 6.1.1
Liferay Legend Bejegyzések: 3089 Csatlakozás dátuma: 2008.10.28. Legújabb bejegyzések
It is a good practice to recompile your portlet to use it in newer versions.
So rebuild your portlet again using 6.1.1 SDK and retry.
So rebuild your portlet again using 6.1.1 SDK and retry.
Mika Koivisto, módosítva 11 év-val korábban
RE: OpenSessionInViewFilter is an unknown filter name in version 6.1.1
Liferay Legend Bejegyzések: 1519 Csatlakozás dátuma: 2006.08.07. Legújabb bejegyzések
Your web.xml is missing filter declaration for OpenSessionInView that's why it's unknown.
Florencia Hernández, módosítva 11 év-val korábban
RE: OpenSessionInViewFilter is an unknown filter name in version 6.1.1
Regular Member Bejegyzések: 146 Csatlakozás dátuma: 2012.03.27. Legújabb bejegyzések
Hi Mika,
Thanks for the answer. That fixed the issue. But after fixing that I get a huge amount of different exceptions. So I'd better redevelop everything for Liferay 6.1.1.
Regards,
Flor.
Thanks for the answer. That fixed the issue. But after fixing that I get a huge amount of different exceptions. So I'd better redevelop everything for Liferay 6.1.1.
Regards,
Flor.