use of com.hotels.styx.client.connectionpool.MaxPendingConnectionsExceededException in project styx by ExpediaGroup.
the class HttpErrorStatusMetricsTest method backendFaultArgs.
private static Stream<Arguments> backendFaultArgs() {
Id appId = Id.id("fakeApp");
Id originId = Id.id("fakeApp1");
Origin origin = Origin.newOriginBuilder("fakeHost", 9999).applicationId(appId).id(originId.toString()).build();
Exception cause = new Exception();
return Stream.of(Arguments.of(new NoAvailableHostsException(appId), "noHostsLiveForApplication"), Arguments.of(new OriginUnreachableException(origin, cause), "cannotConnect"), Arguments.of(new BadHttpResponseException(origin, cause), "badHttpResponse"), Arguments.of(new MaxPendingConnectionTimeoutException(origin, 1), "connectionsHeldTooLong"), Arguments.of(new MaxPendingConnectionsExceededException(origin, 1, 1), "tooManyConnections"), Arguments.of(new ResponseTimeoutException(origin, "test", 1, 1, 1, 1), "responseTooSlow"));
}
Aggregations