Search in sources :

Example 1 with MissionStatisticsCollector

use of com.github.nagyesta.abortmission.core.healthcheck.impl.MissionStatisticsCollector in project abort-mission by nagyesta.

the class MissionOutlineDefinition method callableConfig.

private static void callableConfig(final AbortMissionCommandOps ops) {
    final MissionHealthCheckMatcher simpleMatcher = MissionHealthCheckMatcherBuilder.builder().classNamePattern(SimpleCallableMissionTemplateSupportTest.class.getName()).build();
    ops.registerHealthCheck(PercentageBasedMissionHealthCheckEvaluator.builder(simpleMatcher, new MissionStatisticsCollector(simpleMatcher)).build());
    final MissionHealthCheckMatcher matcher = MissionHealthCheckMatcherBuilder.builder().classNamePattern(CallableMissionTemplateSupportTest.class.getName()).build();
    ops.registerHealthCheck(PercentageBasedMissionHealthCheckEvaluator.builder(matcher, new MissionStatisticsCollector(matcher)).build());
}
Also used : MissionStatisticsCollector(com.github.nagyesta.abortmission.core.healthcheck.impl.MissionStatisticsCollector) MissionHealthCheckMatcher(com.github.nagyesta.abortmission.core.matcher.MissionHealthCheckMatcher)

Example 2 with MissionStatisticsCollector

use of com.github.nagyesta.abortmission.core.healthcheck.impl.MissionStatisticsCollector in project abort-mission by nagyesta.

the class MissionOutlineDefinition method runnableConfig.

private static void runnableConfig(final AbortMissionCommandOps ops) {
    final MissionHealthCheckMatcher simpleMatcher = MissionHealthCheckMatcherBuilder.builder().classNamePattern(SimpleRunnableMissionTemplateSupportTest.class.getName()).build();
    ops.registerHealthCheck(PercentageBasedMissionHealthCheckEvaluator.builder(simpleMatcher, new MissionStatisticsCollector(simpleMatcher)).build());
    final MissionHealthCheckMatcher matcher = MissionHealthCheckMatcherBuilder.builder().classNamePattern(RunnableMissionTemplateSupportTest.class.getName()).build();
    ops.registerHealthCheck(PercentageBasedMissionHealthCheckEvaluator.builder(matcher, new MissionStatisticsCollector(matcher)).build());
}
Also used : MissionStatisticsCollector(com.github.nagyesta.abortmission.core.healthcheck.impl.MissionStatisticsCollector) MissionHealthCheckMatcher(com.github.nagyesta.abortmission.core.matcher.MissionHealthCheckMatcher)

Aggregations

MissionStatisticsCollector (com.github.nagyesta.abortmission.core.healthcheck.impl.MissionStatisticsCollector)2 MissionHealthCheckMatcher (com.github.nagyesta.abortmission.core.matcher.MissionHealthCheckMatcher)2