I have a simple servlet filter that just prints to the console during init(), destroy() and doFilter(). I register the filter via a blueprint (see below) and I can see the printout from the init() method, and when I undeploy the blueprint I can see the printout from the destroy() method, so registration seems to work. However, when I try to access the servlet I do not get any printout from the doFilter() method, i.e. the filter does not seem to be activated in the request chain.
Anyone have an idea what the problem might be? [code] <blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"> <service interface="javax.servlet.Filter"> <service-properties> <entry key="filter-name" value="wsr.auth.filter"/> <entry key="servletNames"> <array value-type="java.lang.String"> <value>cxf-osgi-transport-servlet</value> </array> </entry> <entry key="urlPatterns"> <array value-type="java.lang.String"> <value>/wsr</value> </array> </entry> </service-properties> <bean class="wsr.security.AuthenticationFilter"/> </service> </blueprint> [/code] >From the webconsole: [code] 316 [javax.servlet.Filter] filter-name wsr.auth.filter urlPatterns /wsr servletNames cxf-osgi-transport-servlet 242 [javax.servlet.Servlet] alias /wsr base-address disable-address-updates false hide-service-list-page false osgi.service.blueprint.compname osgiServlet redirect-servlet-name redirect-servlet-path redirects-list service-list-all-contexts service-list-path servlet-name cxf-osgi-transport-servlet static-resources-list [/code] Thanks Lars -- View this message in context: http://karaf.922171.n3.nabble.com/Problem-getting-servlet-filter-to-activate-tp4027868.html Sent from the Karaf - User mailing list archive at Nabble.com.
