I also faced this problem. In my case, the filter is mapped on a servlet (instead of an Url).The portlet is also a struts application port. The filter is never invoked in a portlet context in Liferay 4.2 but when the application is invoqued as standalone (I mean with the application context name into the URL) the filter works.
I finally gave up trying to use a filter in the portlet context because of this article (http://ml.osdir.com/jakarta.pluto.user/2004-07/msg00062.html) that explains that, even if portlets are packaged as complete J2EE with a web.xml descriptor, filters are not garanteed to work in a portlet context bacause it is not mentionned in the JSR168 specification. It may depend on the portlet container. Regards. -----Message d'origine----- De : at [mailto:[EMAIL PROTECTED] Envoyé : mardi 29 janvier 2008 12:49 À : [email protected] Objet : Servlet Filter Problem Hello, I have converted a struts application in portlet using portlet bridge for integration in liferay portal. The application filter path using the javax.servlet.Filter <filter-mapping> <filter-name>SecurityFilter</filter-name> <url-pattern>/customers/*</url-pattern> </filter-mapping> But with this configurazione the filter don't work if my application is in a portlet context. Trying this configuration <filter-mapping> <filter-name>SecurityFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> The filter work but intercept all request. How I can make it to work with the path that start with customers? -- Antonio Talarico --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
