org.apache.sling.testing.tools.http

## Class RetryingContentChecker

- java.lang.Object
- - org.apache.sling.testing.tools.http.RetryingContentChecker

    public class RetryingContentChecker
    extends Object

Retry a GET on an URL until it returns 200 or until this times out.

### Constructor Summary

Constructors
Constructor and Description
`RetryingContentChecker(RequestExecutor executor, RequestBuilder builder)`
`RetryingContentChecker(RequestExecutor executor, RequestBuilder builder, String username, String password)`

### Method Summary

All Methods Instance Methods Concrete Methods
`protected boolean` `assertMore(RequestExecutor executor)` Optionally perform additional tests in retry condition
`void` `check(String path, int expectedStatus, int timeoutSeconds, int intervalBetweenrequestsMsec)` Check specified path for expected status, or timeout
`protected void` `onTimeout()` Called if a timeout occurs

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Constructor Detail

#### RetryingContentChecker

    public RetryingContentChecker(RequestExecutor executor,
                                  RequestBuilder builder)

#### RetryingContentChecker

    public RetryingContentChecker(RequestExecutor executor,
                                  RequestBuilder builder,
                                  String username,
                                  String password)

### Method Detail

#### check

    public void check(String path,
                      int expectedStatus,
                      int timeoutSeconds,
                      int intervalBetweenrequestsMsec)

Check specified path for expected status, or timeout

#### assertMore

    protected boolean assertMore(RequestExecutor executor)
                          throws Exception

Optionally perform additional tests in retry condition

Throws:
  `Exception`

#### onTimeout

    protected void onTimeout()

Called if a timeout occurs