Class CircuitBreakerRetryTest
java.lang.Object
org.jboss.arquillian.testng.Arquillian
org.eclipse.microprofile.fault.tolerance.tck.CircuitBreakerRetryTest
- All Implemented Interfaces:
org.testng.IHookable
,org.testng.ITestNGListener
public class CircuitBreakerRetryTest
extends org.jboss.arquillian.testng.Arquillian
Test CircuitBreaker Thresholds and delays with Retries.
- Author:
- Neil Young, Andrew Rouse
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jboss.arquillian.testng.Arquillian
org.jboss.arquillian.testng.Arquillian.UpdateResultListener
-
Field Summary
Fields inherited from class org.jboss.arquillian.testng.Arquillian
ARQUILLIAN_DATA_PROVIDER
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic org.jboss.shrinkwrap.api.spec.WebArchive
deploy()
void
A test to exercise Circuit Breaker thresholds with insufficient retries to open the Circuit so that the Circuit remains closed and a TestException is caught.void
A test to exercise Circuit Breaker thresholds with insufficient retries to open the Circuit so that the Circuit remains closed and a TestException is caught when using an Asynchronous call.void
A test to exercise Circuit Breaker thresholds with sufficient retries to open the Circuit and result in a CircuitBreakerOpenException.void
A test to exercise Circuit Breaker thresholds with sufficient retries to open the Circuit and result in a CircuitBreakerOpenException using an Asynchronous call.void
Analogous to testCircuitOpenWithMoreRetries but execution failures are caused by timeouts.void
Analogous to testCircuitOpenWithMoreRetriesAsync but execution failures are caused by timeouts.void
Analogous to testCircuitOpenWithFewRetries with Class level @CircuitBreaker and @Retry annotations that are overridden by serviceB.void
Analogous to testCircuitOpenWithMoreRetries with Class level @CircuitBreaker and @Retry annotations that are inherited by serviceAvoid
Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is included in the abortOn attribute of the Retry annotationvoid
Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is included in the abortOn attribute of the Retry annotationvoid
Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is not included in the retryOn attribute of the Retry annotationvoid
Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is not included in the retryOn attribute of the Retry annotationvoid
Test that we retry around an open circuit breakervoid
Test that we retry around an open circuit breakerMethods inherited from class org.jboss.arquillian.testng.Arquillian
arquillianAfterClass, arquillianAfterSuite, arquillianAfterTest, arquillianArgumentProvider, arquillianBeforeClass, arquillianBeforeSuite, arquillianBeforeTest, run
-
Constructor Details
-
CircuitBreakerRetryTest
public CircuitBreakerRetryTest()
-
-
Method Details
-
deploy
@Deployment public static org.jboss.shrinkwrap.api.spec.WebArchive deploy() -
testCircuitOpenWithMoreRetries
public void testCircuitOpenWithMoreRetries()A test to exercise Circuit Breaker thresholds with sufficient retries to open the Circuit and result in a CircuitBreakerOpenException. -
testCircuitOpenWithFewRetries
public void testCircuitOpenWithFewRetries()A test to exercise Circuit Breaker thresholds with insufficient retries to open the Circuit so that the Circuit remains closed and a TestException is caught. -
testClassLevelCircuitOpenWithMoreRetries
public void testClassLevelCircuitOpenWithMoreRetries()Analogous to testCircuitOpenWithMoreRetries with Class level @CircuitBreaker and @Retry annotations that are inherited by serviceA -
testClassLevelCircuitOpenWithFewRetries
public void testClassLevelCircuitOpenWithFewRetries()Analogous to testCircuitOpenWithFewRetries with Class level @CircuitBreaker and @Retry annotations that are overridden by serviceB. -
testCircuitOpenWithMultiTimeouts
public void testCircuitOpenWithMultiTimeouts()Analogous to testCircuitOpenWithMoreRetries but execution failures are caused by timeouts. -
testRetriesSucceedWhenCircuitCloses
public void testRetriesSucceedWhenCircuitCloses()Test that we retry around an open circuit breakerTest that when retries are configured with sufficient delay, a call to an open circuit can retry until the circuit half-closes, allowing the call to succeed.
-
testNoRetriesIfNotRetryOn
public void testNoRetriesIfNotRetryOn()Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is not included in the retryOn attribute of the Retry annotationThis test calls a method which only retries on TimeoutException
-
testNoRetriesIfAbortOn
public void testNoRetriesIfAbortOn()Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is included in the abortOn attribute of the Retry annotation -
testCircuitOpenWithMoreRetriesAsync
public void testCircuitOpenWithMoreRetriesAsync()A test to exercise Circuit Breaker thresholds with sufficient retries to open the Circuit and result in a CircuitBreakerOpenException using an Asynchronous call. -
testCircuitOpenWithFewRetriesAsync
public void testCircuitOpenWithFewRetriesAsync()A test to exercise Circuit Breaker thresholds with insufficient retries to open the Circuit so that the Circuit remains closed and a TestException is caught when using an Asynchronous call. -
testCircuitOpenWithMultiTimeoutsAsync
public void testCircuitOpenWithMultiTimeoutsAsync()Analogous to testCircuitOpenWithMoreRetriesAsync but execution failures are caused by timeouts. -
testRetriesSucceedWhenCircuitClosesAsync
public void testRetriesSucceedWhenCircuitClosesAsync()Test that we retry around an open circuit breakerTest that when retries are configured with sufficient delay, a call to an open circuit can retry until the circuit half-closes, allowing the call to succeed.
-
testNoRetriesIfNotRetryOnAsync
public void testNoRetriesIfNotRetryOnAsync()Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is not included in the retryOn attribute of the Retry annotationThis test calls a method which only retries on TimeoutException
-
testNoRetriesIfAbortOnAsync
public void testNoRetriesIfAbortOnAsync()Test that we don't retry around an open circuit breaker if CircuitBreakerOpenException is included in the abortOn attribute of the Retry annotation
-