Configure test server classes before starting MAC #4811
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Update a few ITs that were stopping a normal server instance and starting up a test impl by taking advantage of changes in #4643 to set the server instance type before start up. This simplifies the tests and also prevents weird behavior by having servers start up and be shut down quickly.
I took a look around the tests and I didn't see too many tests that could be updated to use the new method as some required keeping the original servers around but these were the ones I found.
This closes #4644
Note: Another nice side effect of this is that the changes here actually fix the hanging
ExternalCompacttion_2_IT
test I was having issues with and mentioned in the gRPC prototype in this comment.The issue for the hanging wasn't related specifically to gRPC but was directly related to starting up and immediately stopping the first compactor procesess and how the new async future and long polling works from the compaction queue. Before the changes here, the test would kill the original compactors and start up new ones of the type
ExternalDoNothingCompactor
. Because of the long polling change, there is a race condition where the job is assigned to a future when the original compactor requests a job. Then when the compactor dies, the new one that starts up won't get a job assigned as the previous future never times out from the dead compactor even though the job was cleaned up by the dead compaction detector. Making sure the future will timeout is something that still needs to be fixed as well, but the test change here fixes the root cause by only starting up theDoNothingCompactor
in the first place.