Buggy code:
public class SearchHandler extends RequestHandlerBase implements PluginInfoInitialized , SolrCoreAware { static final String INIT_COMPONENTS = "components" ; static final String INIT_FIRST_COMPONENTS = "first-components" ; static final String INIT_LAST_COMPONENTS = "last-components" ; protected static Logger log = LoggerFactory . getLogger ( SearchHandler . class ) ; protected List < SearchComponent > components = null ; private ShardHandlerFactory shardHandlerFactory ; private PluginInfo shfInfo ; protected List < String > getDefaultComponents ( ) { } public void init ( PluginInfo info ) { } @ SuppressWarnings ( "unchecked" ) public void inform ( SolrCore core ) { } public List < SearchComponent > getComponents ( ) { } @ Override public void handleRequestBody ( SolrQueryRequest req , SolrQueryResponse rsp ) throws Exception , IllegalAccessException , InstantiationException , ParseException { ResponseBuilder rb = new ResponseBuilder ( req , rsp , components ) ; if ( ( rb . requestInfo ) != null ) { rb . requestInfo . setResponseBuilder ( rb ) ; } boolean dbg = req . getParams ( ) . getBool ( DEBUG_QUERY , false ) ; rb . setDebug ( dbg ) ; if ( dbg == false ) { SolrPluginUtils . getDebugInterests ( req . getParams ( ) . getParams ( DEBUG ) , rb ) ; } final RTimer timer = ( rb . isDebug ( ) ) ? new RTimer ( ) : null ; ShardHandler shardHandler1 = shardHandlerFactory . getShardHandler ( ) ; shardHandler1 . checkDistributed ( rb ) ; if ( timer == null ) { for ( SearchComponent c : components ) { c . prepare ( rb ) ; } } else { RTimer subt = timer . sub ( "prepare" ) ; for ( SearchComponent c : components ) { rb . setTimer ( subt . sub ( c . getName ( ) ) ) ; c . prepare ( rb ) ; rb . getTimer ( ) . stop ( ) ; } subt . stop ( ) ; } if ( ! ( rb . isDistrib ) ) { if ( ! ( rb . isDebug ( ) ) ) { for ( SearchComponent c : components ) { c . process ( rb ) ; } } else { RTimer subt = timer . sub ( "process" ) ; for ( SearchComponent c : components ) { rb . setTimer ( subt . sub ( c . getName ( ) ) ) ; c . process ( rb ) ; rb . getTimer ( ) . stop ( ) ; } subt . stop ( ) ; timer . stop ( ) ; if ( rb . isDebugTimings ( ) ) { rb . addDebugInfo ( "timing" , timer . asNamedList ( ) ) ; } } } else { if ( ( rb . outgoing ) == null ) { rb . outgoing = new LinkedList < ShardRequest > ( ) ; } rb . finished = new ArrayList < ShardRequest > ( ) ; int nextStage = 0 ; do { rb . stage = nextStage ; nextStage = ResponseBuilder . STAGE_DONE ; for ( SearchComponent c : components ) { nextStage = Math . min ( nextStage , c . distributedProcess ( rb ) ) ; } while ( ( rb . outgoing . size ( ) ) > 0 ) { while ( ( rb . outgoing . size ( ) ) > 0 ) { ShardRequest sreq = rb . outgoing . remove ( 0 ) ; sreq . actualShards = sreq . shards ; if ( ( sreq . actualShards ) == ( ShardRequest . ALL_SHARDS ) ) { sreq . actualShards = rb . shards ; } sreq . responses = new ArrayList < ShardResponse > ( ) ; for ( String shard : sreq . actualShards ) { ModifiableSolrParams params = new ModifiableSolrParams ( sreq . params ) ; params . remove ( SHARDS ) ; <START_BUG> params . remove ( "distrib" ) ; <END_BUG> params . remove ( "indent" ) ; params . remove ( HEADER_ECHO_PARAMS ) ; params . set ( IS_SHARD , true ) ; params . set ( SHARD_URL , shard ) ; if ( ( rb . requestInfo ) != null ) { params . set ( "NOW" , Long . toString ( rb . requestInfo . getNOW ( ) . getTime ( ) ) ) ; } String shardQt = req . getParams ( ) . get ( SHARDS_QT ) ; if ( shardQt == null ) { params . remove ( QT ) ; } else { params . set ( QT , shardQt ) ; } shardHandler1 . submit ( sreq , shard , params ) ; } } while ( ( rb . outgoing . size ( ) ) == 0 ) { ShardResponse srsp = shardHandler1 . takeCompletedOrError ( ) ; if ( srsp == null ) break ; if ( ( srsp . getException ( ) ) != null ) { shardHandler1 . cancelAll ( ) ; if ( ( srsp . getException ( ) ) instanceof SolrException ) { throw ( ( SolrException ) ( srsp . getException ( ) ) ) ; } else { throw new SolrException ( ErrorCode . SERVER_ERROR , srsp . getException ( ) ) ; } } rb . finished . add ( srsp . getShardRequest ( ) ) ; for ( SearchComponent c : components ) { c . handleResponses ( rb , srsp . getShardRequest ( ) ) ; } } } for ( SearchComponent c : components ) { c . finishStage ( rb ) ; } } while ( nextStage != ( Integer . MAX_VALUE ) ) ; } } @ Override public String getDescription ( ) { } @ Override public String getVersion ( ) { } @ Override public String getSourceId ( ) { } @ Override public String getSource ( ) { } }

Fix:
params . set ( "distrib" , "false" ) ;