OpenSearch/test
Boaz Leskes 2ee9ab25d9 Remove `RoutingAllocation.Result` (#20538)
Currently all the reroute-like methods of `AllocationService` return a result object of type `RoutingAllocation.Result`. The result object contains the new `RoutingTable` and `MetaData` plus an indication whether those were changed. The caller is then responsible of updating a cluster state with these. These means that things can easily go wrong and one can take one of these but not the other causing inconsistencies. We already have a utility method on the `ClusterState` builder that does but no one forces you to do so. Also 99% of the callers do the same thing: i.e., check if the result was changed and if so update the very same cluster state that was passed to `AllocationService`.  This PR folds this pattern into `AllocationService` and changes almost all it's methods to return a new cluster state (potentially the original one).  This saves some 500 lines of code.

The one exception here is the reroute API which executes allocation commands and potentially returns an explanation as well (next to the routing table and metadata). That API now returns a `CommandsResult` object which encapsulate a cluster state and the explanation.
2016-09-19 13:54:35 +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 `RoutingAllocation.Result` (#20538) 2016-09-19 13:54:35 +02:00
logger-usage Add empty test to ESLoggerUsageTests 2016-08-31 04:41:07 -04:00
build.gradle Add authentication to reindex-from-remote 2016-07-27 14:17:41 -04:00