OpenSearch/test
Boaz Leskes ee76c1a5c9 Remove NoopGatewayAllocator in favor of a more realistic mock (#20637)
Many of our unit tests instantiate an `AllocationService`, which requires having a `GatewayAllocator`. Today almost all of our test use a class called `NoopGatewayAllocator` which does nothing, effectively leaving all shard assignments to the balanced allocator. This is sad as it means we test a system that behaves differently than our production logic in very basic things. For example, a started primary that is lost will be assigned to a node that didn't use to have it.

This PR removes `NoopGatewayAllocator` in favor of a new `TestGatewayAllocator` that inherits the standard `GatewayAllocator` and overrides shard information fetching to return information based on historical assignments the allocator has done. The only exception is `BalanceConfigurationTests` which does test only the balancer and I opted to not have it work around the `GatewayAllocator` being in it's way.
2016-09-25 20:15:30 +02:00
..
fixtures in the plugin: guard against HADOOP_HOME in environment on any platform. 2015-12-21 02:21:53 -05:00
framework Remove NoopGatewayAllocator in favor of a more realistic mock (#20637) 2016-09-25 20:15:30 +02:00
logger-usage Fix logger usage checker for Log4j 2 2016-09-21 14:44:14 +02:00
build.gradle Add authentication to reindex-from-remote 2016-07-27 14:17:41 -04:00