Github user madrob commented on a diff in the pull request:

    https://github.com/apache/lucene-solr/pull/121#discussion_r22362948
  
    --- Diff: 
solr/test-framework/src/java/org/apache/solr/BaseDistributedSearchTestCase.java 
---
    @@ -173,16 +179,25 @@ protected BaseDistributedSearchTestCase(final String 
context) {
                                          "[ff01::213]:33332" + context};
       }
     
    -  protected int shardCount = 4;      // the actual number of solr cores 
that will be created in the cluster
    +  private final static int DEFAULT_MAX_SHARD_COUNT = 3;
    +
    +  private int shardCount = -1;      // the actual number of solr cores 
that will be created in the cluster
    +  public int getShardCount() {
    +    return shardCount;
    +  }
    +
    +  private boolean isShardCountFixed = false;
     
       /**
    -   * Sub classes can set this flag in their constructor to true if they
    -   * want to fix the number of shards to 'shardCount'
    +   * Sub classes can call this in their constructor to fix the number of 
shards
        *
    -   * The default is false which means that test will be executed with
    -   * 1, 2, 3, ....shardCount number of shards repeatedly
    +   * By default, the test will be executed with
    +   * 1, 2, ... DEFAULT_MAX_SHARD_COUNT number of shards repeatedly
        */
    -  protected boolean fixShardCount = false;
    +  public void fixShardCount(int count) {
    --- End diff --
    
    Maybe add a reference to the annotations and explain why one is preferred 
over the other for the benefit of future test writers.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to