Examples of BackOffContext


Examples of org.springframework.retry.backoff.BackOffContext

        throw new TerminatedRetryException(
            "Retry terminated abnormally by interceptor before first attempt");
      }

      // Get or Start the backoff context...
      BackOffContext backOffContext = null;
      Object resource = context.getAttribute("backOffContext");

      if (resource instanceof BackOffContext) {
        backOffContext = (BackOffContext) resource;
      }
View Full Code Here

Examples of org.springframework.retry.backoff.BackOffContext

    tested.setRetryPolicy(new SimpleRetryPolicy(1,
        Collections.<Class<? extends Throwable>, Boolean> singletonMap(
            Exception.class, true)));

    BackOffPolicy bop = createStrictMock(BackOffPolicy.class);
    BackOffContext backOffContext = new BackOffContext() {
    };
    tested.setBackOffPolicy(bop);

    expect(bop.start(isA(RetryContext.class))).andReturn(backOffContext);
    replay(bop);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.