SolrDispatchFilter bug or wrong default parameter
-------------------------------------------------
Key: SOLR-459
URL: https://issues.apache.org/jira/browse/SOLR-459
Project: Solr
Issue Type: Bug
Affects Versions: 1.3
Environment: latest solr version from repository
Reporter: Sergey Dryganets
String path = req.getServletPath();
suggest what we have handler named highlight and solr running on
http://localhost:8080/solr
we request url
http://localhost:8080/solr/highlight
so path == "/highlight";
if( pathPrefix != null && path.startsWith( pathPrefix ) ) {
path = path.substring( pathPrefix.length() );
}
default pathPrefix == null
so path == "/highlight";
int idx = path.indexOf( ':' );
if( idx > 0 ) {
// save the portion after the ':' for a 'handler' path parameter
path = path.substring( 0, idx );
}
not change path too
so we try to request handler by name "/highlight" but real handler name is
"highlight"
(There are normalization inside getRequestHandler method but it's remove slash
in the end of path)
handler = core.getRequestHandler( path );
After change default value of pathPrefix to "/" (in web.xml) all work's fine
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.