You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Tobias Soloschenko <to...@googlemail.com> on 2015/12/08 20:07:02 UTC

WicketFilter without web.xml

Hi guys,

I just wanted to ask if this approach is the one to go with if I don't use
the web.xml (<failOnMissingWebXml>false</failOnMissingWebXml>):

@WebFilter(displayName = "App", filterName = "app", urlPatterns = "/*",
initParams = {

@WebInitParam(name = "applicationClassName", value =
"com.app.web.WebApplication") })

public class WicketInitFilter extends WicketFilter

{

}


looks a bit empty. :-)

kind regards

Tobias

Re: WicketFilter without web.xml

Posted by Štefan Šimík <st...@gmail.com>.
I can send you my configuration, that works in my project with Wicket 7.1

It really is empty - because all configuration information is contained in
annotations above.


import org.apache.wicket.protocol.http.WicketFilter;

import javax.servlet.annotation.WebFilter;
import javax.servlet.annotation.WebInitParam;

@WebFilter(
filterName = "AppWicketFilter",
urlPatterns = {"/*"},
initParams = {
@WebInitParam(name = "applicationClassName", value =
"algoritmix.website.client.application.WicketApplication"),
@WebInitParam(name="configuration", value="development"),
@WebInitParam(name="filterMappingUrlPattern", value="/*"),
}
)
public class AppWicketFilter extends WicketFilter {
}

On Tue, Dec 8, 2015 at 8:07 PM, Tobias Soloschenko <
tobiassoloschenko@googlemail.com> wrote:

> Hi guys,
>
> I just wanted to ask if this approach is the one to go with if I don't use
> the web.xml (<failOnMissingWebXml>false</failOnMissingWebXml>):
>
> @WebFilter(displayName = "App", filterName = "app", urlPatterns = "/*",
> initParams = {
>
> @WebInitParam(name = "applicationClassName", value =
> "com.app.web.WebApplication") })
>
> public class WicketInitFilter extends WicketFilter
>
> {
>
> }
>
>
> looks a bit empty. :-)
>
> kind regards
>
> Tobias
>