Yes, servlets have to be public to be loaded from web.xml.

These servlets are not meant to load from web.xml, but instead are loaded by the RepositoryRouter filter.  Applications would map RepositoryRouter into their namespace by some means, one of which can be by adding the filter in their web.xml.  Another possibility is to directly create the RepositoryRouter filter in their own Filter, delegating where necessary.  This is the approach any Guice based web application (like Gerrit Code Review) would prefer to use.