Skip to content

Commit d0b3d1f

Browse files
CR: fail responses as well
1 parent ad79758 commit d0b3d1f

File tree

1 file changed

+12
-2
lines changed

1 file changed

+12
-2
lines changed

test/framework/src/main/java/org/elasticsearch/test/disruption/DisruptableMockTransport.java

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,8 +205,12 @@ public void run() {
205205
break;
206206

207207
case BLACK_HOLE:
208+
logger.trace("blackholed during response to {}: channel is {}", requestDescription, connectionStatus);
209+
onBlackholedDuringSend(requestId, action, destinationTransport);
210+
break;
208211
case DISCONNECTED:
209-
logger.trace("dropping response to {}: channel is {}", requestDescription, connectionStatus);
212+
logger.trace("disconnected during response to {}: channel is {}", requestDescription, connectionStatus);
213+
onDisconnectedDuringSend(requestId, action, destinationTransport);
210214
break;
211215

212216
default:
@@ -235,8 +239,14 @@ public void run() {
235239
break;
236240

237241
case BLACK_HOLE:
242+
logger.trace("blackholed during exception response to {}: channel is {}",
243+
requestDescription, connectionStatus);
244+
onBlackholedDuringSend(requestId, action, destinationTransport);
245+
break;
238246
case DISCONNECTED:
239-
logger.trace("dropping exception response to {}: channel is {}", requestDescription, connectionStatus);
247+
logger.trace("disconnected during exception response to {}: channel is {}",
248+
requestDescription, connectionStatus);
249+
onDisconnectedDuringSend(requestId, action, destinationTransport);
240250
break;
241251

242252
default:

0 commit comments

Comments
 (0)