my previous commit added waitForState calls to doIntegrationTest that forgot to take into account initial repFactor when createShard was called
as a result, the test could only pass if wather was called after a initial leader went live, before other replicas became live
this commit fixes this mistake, and hardens the assertions about the location of those replicas given the rule in use
also adds new expecation that trying to add additional replicas that would violate rule will cause request ot fail
These fixes all relate to testWatcher + testMultipleWatchers:
* add additional asserts to the test methods to assert the expected property values are found
* mark Watcher.props volatile to prevent stale read by test thread
* add some randomization to Watcher.props to either come from the onStateChanged() input or
from an explicit call to ZkStateReader.getCollectionProperties
- previuosly, for reasons i don't understand, the test only consulted
ZkStateReader.getCollectionProperties inside the Watcher, and ignored the onStateChanged()
input
- now the test validates both
* move all Watcher.triggered access into the existing synchronization blocks to prevent
waitForTrigger() from returning prematurely due to gaining synch lock _after_
Watcher.triggered was incremented in onStateChanged(), but _before_ onStateChanged() updated
Watcher.props
* add detailed logging to provide additional info to help debug any additional jenkins failures
that might pop up in the future if these fixes aren't sufficient
* ensure all collections/replicas are active
* use waitForState or waitForActiveCollection before checking rules/snitch to prevent false failures on stale state
* ensure cluster policy is cleared after each test method
Some of these changes should also help ensure we don't get (more) spurious failures due to SOLR-13616
* SOLR-13565: initial commit
* SOLR-13565: updated with testcase
* SOLR-13565: removed unused methods
* SOLR-13565: better logging
* SOLR-13565: disable SSL
* SOLR-13565: more tests
* SOLR-13565: syncing with master
* SOLR-13565: fixing tests
* SOLR-13565: fixing tests
* SOLR-13534: Fix test
Remove buggy 'port roulette' code that can easily fail if OS gives the selected port to a different process just before creating the server
Use jetty's built in support for listining on an OS selected port instead
Also increase timeouts to better account for slow/heavily loaded (ie:jenkins) VMs where SolrCore reloading may take longer then 10 seconds
* SOLR-13565: set proper permission name
* SOLR-13565: syncing with master
* SOLR-13565: syncing with master
* SOLR-13565: removed accidental change
* SOLR-13565: removed accidental change
* SOLR-13565: removed accidental change
* SOLR-13565: more tests
* SOLR-13565: Tests with key signing tests
* SOLR-13565: fixing concurrency issues in tests
* SOLR-13565: add tests with 512 bit RSA
* SOLR-13565: fixing concurrency issues
* SOLR-13565: remove unused code
this point in the test since the collections available are changing due
to deletions and we might try to communicate with a collection
that was (correctly) deleted.
remove flakey dependency on sleep (to wait for cache expiration) w/explicit instruction to ignore cache
sleep is not garunteed to sleep the exact amount (based on limitations of the system clock)