ESIndexLevelReplicationTestCase.ReplicationAction#execute should send exceptions to it's listener rather than bubble them up
This is how TRA works as well.
This commit is contained in:
parent
fb8c767737
commit
d20cd6afcb
|
@ -421,7 +421,8 @@ public abstract class ESIndexLevelReplicationTestCase extends IndexShardTestCase
|
|||
this.opType = opType;
|
||||
}
|
||||
|
||||
public void execute() throws Exception {
|
||||
public void execute() {
|
||||
try {
|
||||
new ReplicationOperation<Request, ReplicaRequest, PrimaryResult>(request, new PrimaryRef(),
|
||||
new ActionListener<PrimaryResult>() {
|
||||
@Override
|
||||
|
@ -451,6 +452,9 @@ public abstract class ESIndexLevelReplicationTestCase extends IndexShardTestCase
|
|||
.collect(Collectors.toSet());
|
||||
}
|
||||
}.execute();
|
||||
} catch (Exception e) {
|
||||
listener.onFailure(e);
|
||||
}
|
||||
}
|
||||
|
||||
protected abstract PrimaryResult performOnPrimary(IndexShard primary, Request request) throws Exception;
|
||||
|
|
Loading…
Reference in New Issue