Pierre Salagnac created SOLR-17581:
--------------------------------------
Summary: Less Zookeeper watches in tests
Key: SOLR-17581
URL: https://issues.apache.org/jira/browse/SOLR-17581
Project: Solr
Issue Type: Improvement
Security Level: Public (Default Security Level. Issues are Public)
Reporter: Pierre Salagnac
This is a follow-up item of SOLR-17453.
Production code has two variants of {{waitForState()}} method. First one only
checks a collection {{{}state.json{}}}, while the second also checks the list
of live nodes in addition to the collection state. When expected condition is
not found immediately, Zookeeper watches are set on both collection state and
live node list.
In test utilities, only a variant that checks both the collection state and
list of live nodes exists. Quite often, this method is used when the test wants
to check a condition on the collection state only. It means a useless watch is
set on the list of live nodes.
The proposal is to introduce a test variant of {{waitForState()}} that accepts
only a condition on collection state, and uses it in all tests that don't want
to check live nodes. Goal is to reduce complexity of test for slightly faster
execution and maybe catch some issues.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]