google / google/guice

welcome-file-list is ignored. 404 not found error returned

Open
#810 3 comments 0 reactions 0 assignees View on GitHub
imported
Dominant language
Java
Stars
12.7k
Forks
1.7k
Avg merge
11m
Merged PRs (30d)
2

Description

_From [DoctorMiguel](https://code.google.com/u/113590246987298759280/) on June 23, 2014 11:47:35_

Description of the issue: I am using Guice filter to wrap servlet declaration. I specified the welcome-file-list in this way:
<welcome-file-list>
        <welcome-file>home</welcome-file>
</welcome-file-list>

Here it is my web.xml:
<filter>
                <filter-name>guiceFilter</filter-name>
                <filter-class>com.google.inject.servlet.GuiceFilter</filter-class>
        </filter>

        <filter-mapping>
                <filter-name>guiceFilter</filter-name>
                <url-pattern>/*</url-pattern>
        </filter-mapping>

        <listener>
                <listener-class>it.micheleorsi.IoCConfiguration</listener-class>
        </listener>

In the IoCConfigration I have:
serve("/home").with(BrowserAuthentication.class);

Once I try to access the root path (/) I got 404 not found error.
If I specify the root in IoCConfiguration it works:
serve("/home", "/").with(BrowserAuthentication.class);

_Original issue: http://code.google.com/p/google-guice/issues/detail?id=810_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.