lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Chris Hostetter <hossman_luc...@fucit.org>
Subject Re: Inserting shards in overridden SearchComponent prepare method yields null pointer
Date Tue, 01 Jun 2010 22:47:17 GMT

Wild shot in the dark: if the list of shards is changed between prepare 
method and hte process method of the QueryComponent that could tickle some 
code path that was never expected, and maybe trigger an NPE (ie: looking 
up some IDs in a map keyed off of shard and now the shard is something 
that never had a value put in that map) ... so it really dpeends where 
your component is registered in the component list.

like i said: wild shot i nthe dark.  you ahven't posted a lot of details 
(for instance: i assume that stack trace is coming from the shard, not the 
collator -- but again that's just a guess)

: Date: Tue, 1 Jun 2010 13:20:20 -0700
: From: Jason Rutherglen <jason.rutherglen@gmail.com>
: Reply-To: solr-user@lucene.apache.org
: To: solr-user@lucene.apache.org
: Subject: Inserting shards in overridden SearchComponent prepare method yields 
:      null pointer
: 
: The insert shards code is as follows:
: 
: ModifiableSolrParams modParams = new ModifiableSolrParams(params);
: modParams.set("shards", shards);
: rb.req.setParams(modParams);
: 
: Where shards is a valid single shard pseudo URL.
: 
: Stacktrace:
: 
: HTTP Status 500 - null java.lang.NullPointerException at
: org.apache.solr.handler.component.QueryComponent.createRetrieveDocs(QueryComponent.java:497)
: at org.apache.solr.handler.component.QueryComponent.distributedProcess(QueryComponent.java:298)
: at org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:234)
: at org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:131)
: at org.apache.solr.core.SolrCore.execute(SolrCore.java:1316) at
: org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:342)
: at org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:245)
: at
: 



-Hoss


Mime
View raw message