: > On 1/19/07, Chris Hostetter <[EMAIL PROTECTED]> wrote:
: > > whoa ... hold on a minute, even if we use a ServletFilter do do all of the
: > > dispatching instead of a Servlet we still need a base path right?

: > I thought that's what the filter gave you... the ability to filter any
: > URL to the /solr webapp, and Ryan was doing a lookup on the next
: > element for a request handler.

: yes, this is the beauty of a Filter.  It *can* process the request
: and/or it can pass it along.  There is no problem at all with mapping
: a filter to all requests and a servlet to some paths.  The filter will
: only handle paths declared in solrconfig.xml everything else will be
: handled however it is defined in web.xml

sorry ... i kow that a ServletFilter can look at a request, choose to
process it, or choose to ignore it ... my point was that if we use a
Filter, we still should put in that fiter logic to only look at requests
starting with a fixed prefix.

consider this URL...

  http://host:9999/solr/foo/

...where "solr" is the webapp name as usual.

if the filter matches on "/*" and then does a lookup in the solrconfig for
"foo" to find the Plugin to use for that request, and ignores the request
and passesit down the chain if one isn't configured with the name "foo"
then all is fine and dandy ... but what happens if someone tries to
configure a plugin with the name "admin" ... now all of the existing admin
pages break.

also: what happens a year from now when we add some completely new
Servlet/ServletFilter to Solr, and want to give it a unique URL...

  http://host:9999/solr/bar/

...we could put it earlier in the processing chain before the existing
ServletFilter, but then we break any users that have registered a plugin
with the name "bar".

more short term: if there is no prefix that the ervletFilter requires,
then supporting the legacy "http://host:9999/solr/update"; and
"http://host:9999/solr/select"; URLs becomes harder, because how do we
safely tell if the remote client is expecting the legacy behavior of those
URLs, or if we are trying to support some plugin configured using the
names "select" and "update" ?


-Hoss

Reply via email to