brooklyn.test.WebAppMonitor Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of brooklyn-test-support Show documentation
Show all versions of brooklyn-test-support Show documentation
Test support dependencies and classes
package brooklyn.test;
import java.util.concurrent.atomic.AtomicBoolean;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicLong;
import java.util.concurrent.atomic.AtomicReference;
import org.slf4j.Logger;
import org.testng.Assert;
/**
* Repeatedly polls a given URL, to check if it is always available.
*
* @author Alex, Aled
*/
public class WebAppMonitor implements Runnable {
final AtomicBoolean shouldBeActive = new AtomicBoolean(true);
final AtomicBoolean isActive = new AtomicBoolean(false);
final AtomicInteger successes = new AtomicInteger(0);
final AtomicInteger failures = new AtomicInteger(0);
final AtomicLong lastTime = new AtomicLong(-1);
final AtomicReference
© 2015 - 2025 Weber Informatics LLC | Privacy Policy