Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Servlet Filter extension point not instantiated.
Servlet Filter extension point not instantiated. [message #1034072] Fri, 05 April 2013 01:12 Go to next message
Erwin Hogeweg is currently offline Erwin Hogeweg
Messages: 32
Registered: July 2009
Member
Hi I am struggling with getting a redirect filter to work. I have created a RedirectServletFilter as below.

public class RedirectServletFilter implements Filter {

public RedirectServletFilter(){
super();
System.out.println("I am alive...");
}

@Override
public void doFilter(ServletRequest req, ServletResponse res, FilterChain chain) throws ServletException,
IOException {
...


In my plugin.xml I define the extension point as follows:

<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.7"?>
<plugin>
<extension point="org.eclipse.equinox.http.registry.filters">
<filter alias="/aap"
class="my.RedirectServletFilter"
load-on-startup="true">
</filter>
</extension>
</plugin>


As far as I can see, all the required bundles are loaded and running:

osgi> ss http
id State Bundle
36 ACTIVE org.eclipse.equinox.http.servlet_1.1.200.v20110502
37 ACTIVE org.eclipse.equinox.http.jetty_2.0.100.v20110502
38 ACTIVE org.eclipse.equinox.http.registry_1.1.100.v20110502

osgi> ss registry
id State Bundle
38 ACTIVE org.eclipse.equinox.http.registry_1.1.100.v20110502
39 ACTIVE org.eclipse.equinox.registry_3.5.200.v20110718-1559


But when I browser to the URL, the Filter class is never hit.

I must be missing something. Any suggestions are greatly appreciated.

Kind Regards,

Erwin
Re: Servlet Filter extension point not instantiated. [message #1034120 is a reply to message #1034072] Fri, 05 April 2013 03:06 Go to previous messageGo to next message
Erwin Hogeweg is currently offline Erwin Hogeweg
Messages: 32
Registered: July 2009
Member
Found and added the registry source bundle to include the schemas. Same result though. The Filter class is still not instantiated.

id State Bundle
36 ACTIVE org.eclipse.equinox.http.servlet_1.1.200.v20110502
37 ACTIVE org.eclipse.equinox.http.jetty_2.0.100.v20110502
38 ACTIVE org.eclipse.equinox.http.registry_1.1.100.v20110502
40 ACTIVE org.eclipse.equinox.http.registry.source_1.1.100.v20110502


Regards,

Erwin
Re: Servlet Filter extension point not instantiated. [message #1037176 is a reply to message #1034120] Tue, 09 April 2013 08:43 Go to previous message
Ralf Sternberg is currently offline Ralf Sternberg
Messages: 1291
Registered: July 2009
Senior Member

Erwin, this looks like a question for the Equinox forum.

Regards, Ralf

--
Ralf Sternberg

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
Previous Topic:Single-Sourcing RAP and RCP in Juno SR2
Next Topic:SWT Tree: Multi-line label
Goto Forum:
  


Current Time: Sat Oct 25 17:48:51 GMT 2014

Powered by FUDForum. Page generated in 0.07552 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software