use of com.navercorp.pinpoint.web.alarm.checker.ResponseCountChecker in project pinpoint by naver.
the class ResponseCountCheckerTest method checkTest2.
/*
* alert conditions not satisfied
*/
@Test
public void checkTest2() {
Application application = new Application(SERVICE_NAME, ServiceType.STAND_ALONE);
ResponseTimeDataCollector collector = new ResponseTimeDataCollector(DataCollectorCategory.RESPONSE_TIME, application, mockMapResponseDAO, System.currentTimeMillis(), 300000);
Rule rule = new Rule(SERVICE_NAME, SERVICE_TYPE, CheckerCategory.TOTAL_COUNT.getName(), 126, "testGroup", false, false, "");
ResponseCountChecker filter = new ResponseCountChecker(collector, rule);
filter.check();
assertFalse(filter.isDetected());
}
use of com.navercorp.pinpoint.web.alarm.checker.ResponseCountChecker in project pinpoint by naver.
the class ResponseCountCheckerTest method checkTest1.
/*
* alert conditions not satisfied
*/
@Test
public void checkTest1() {
Application application = new Application(SERVICE_NAME, ServiceType.STAND_ALONE);
ResponseTimeDataCollector collector = new ResponseTimeDataCollector(DataCollectorCategory.RESPONSE_TIME, application, mockMapResponseDAO, System.currentTimeMillis(), DataCollectorFactory.SLOT_INTERVAL_FIVE_MIN);
Rule rule = new Rule(SERVICE_NAME, SERVICE_TYPE, CheckerCategory.TOTAL_COUNT.getName(), 125, "testGroup", false, false, "");
ResponseCountChecker filter = new ResponseCountChecker(collector, rule);
filter.check();
assertTrue(filter.isDetected());
}
Aggregations