Buggy code:
public class OverseerCollectionProcessor implements Runnable , ClosableThread { public static final String NUM_SLICES = "numShards" ; public static final String REPLICATION_FACTOR = "replicationFactor" ; public static final String MAX_SHARDS_PER_NODE = "maxShardsPerNode" ; public static final String CREATE_NODE_SET = "createNodeSet" ; public static final String DELETECOLLECTION = "deletecollection" ; public static final String CREATECOLLECTION = "createcollection" ; public static final String RELOADCOLLECTION = "reloadcollection" ; public static final String CREATEALIAS = "createalias" ; public static final String DELETEALIAS = "deletealias" ; public static final String SPLITSHARD = "splitshard" ; public static final String DELETESHARD = "deleteshard" ; public static final String ROUTER = "router" ; public static final String SHARDS_PROP = "shards" ; public static final String CREATESHARD = "createshard" ; public static final String DELETEREPLICA = "deletereplica" ; public static final String MIGRATE = "migrate" ; public static final String COLL_CONF = "collection.configName" ; public static final String COLL_PROP_PREFIX = "property." ; public static final Map < String , Object > COLL_PROPS = ZkNodeProps . makeMap ( OverseerCollectionProcessor . ROUTER , DEFAULT_NAME , OverseerCollectionProcessor . REPLICATION_FACTOR , "1" , OverseerCollectionProcessor . MAX_SHARDS_PER_NODE , "1" ) ; private static final String QUEUE_OPERATION = "operation" ; private static Logger log = LoggerFactory . getLogger ( OverseerCollectionProcessor . class ) ; private DistributedQueue workQueue ; private String myId ; private ShardHandler shardHandler ; private String adminPath ; private ZkStateReader zkStateReader ; private boolean isClosed ; public OverseerCollectionProcessor ( ZkStateReader zkStateReader , String myId , ShardHandler shardHandler , String adminPath ) { } protected OverseerCollectionProcessor ( ZkStateReader zkStateReader , String myId , ShardHandler shardHandler , String adminPath , DistributedQueue workQueue ) { } @ Override public void run ( ) { } public void close ( ) { } protected LeaderStatus amILeader ( ) { } protected SolrResponse processMessage ( ZkNodeProps message , String operation ) { } private void deleteReplica ( ClusterState clusterState , ZkNodeProps message , NamedList results ) throws InterruptedException , KeeperException { } private boolean waitForCoreNodeGone ( String collectionName , String shard , String replicaName ) throws InterruptedException { } private void deleteCoreNode ( String collectionName , String replicaName , Replica replica , String core ) throws InterruptedException , KeeperException { } private void checkRequired ( ZkNodeProps message , String ... props ) { } private void deleteCollection ( ZkNodeProps message , NamedList results ) throws InterruptedException , KeeperException { } private void createAlias ( Aliases aliases , ZkNodeProps message ) { } private void checkForAlias ( String name , String value ) { } private void checkForAliasAbsence ( String name ) { } private void deleteAlias ( Aliases aliases , ZkNodeProps message ) { } private boolean createShard ( ClusterState clusterState , ZkNodeProps message , NamedList results ) throws InterruptedException , KeeperException { } private boolean splitShard ( ClusterState clusterState , ZkNodeProps message , NamedList results ) { } private void commit ( NamedList results , String slice , Replica parentShardLeader ) { } static UpdateResponse softCommit ( String url ) throws IOException , SolrServerException { } private String waitForCoreNodeName ( DocCollection collection , String msgBaseUrl , String msgCore ) { } private void collectShardResponses ( NamedList results , boolean abortOnError , String msgOnError ) { } private void deleteShard ( ClusterState clusterState , ZkNodeProps message , NamedList results ) { } private void migrate ( ClusterState clusterState , ZkNodeProps message , NamedList results ) throws InterruptedException , KeeperException { } private void migrateKey ( ClusterState clusterState , DocCollection sourceCollection , Slice sourceSlice , DocCollection targetCollection , Slice targetSlice , String splitKey , int timeout , NamedList results ) throws InterruptedException , KeeperException { } private Range intersect ( DocRouter . Range a , DocRouter . Range b ) { } private void sendShardRequest ( String nodeName , ModifiableSolrParams params ) { } private void addPropertyParams ( ZkNodeProps message , ModifiableSolrParams params ) { for ( String key : message . keySet ( ) ) { <START_BUG> if ( ( key . indexOf ( OverseerCollectionProcessor . COLL_PROP_PREFIX ) ) != ( - 1 ) ) { <END_BUG> params . set ( key , message . getStr ( key ) ) ; } } } private void createCollection ( ClusterState clusterState , ZkNodeProps message , NamedList results ) throws InterruptedException , KeeperException { } private void collectionCmd ( ClusterState clusterState , ZkNodeProps message , ModifiableSolrParams params , NamedList results , String stateMatcher ) { } private void sliceCmd ( ClusterState clusterState , ModifiableSolrParams params , String stateMatcher , Slice slice ) { } private void processResponse ( NamedList results , ShardResponse srsp ) { } private void processResponse ( NamedList results , Throwable e , String nodeName , SolrResponse solrResponse , String shard ) { } @ Override public boolean isClosed ( ) { } }

Fix:
if ( key . startsWith ( OverseerCollectionProcessor . COLL_PROP_PREFIX ) ) {