/** * waitFor * * @param session a {@link org.opennms.sms.monitor.MobileSequenceSession} object. * @param execution a {@link org.opennms.sms.monitor.internal.MobileSequenceExecution} object. * @throws java.lang.InterruptedException if any. * @throws java.util.concurrent.ExecutionException if any. * @throws java.lang.Throwable if any. */ public void waitFor(MobileSequenceSession session, MobileSequenceExecution execution) throws InterruptedException, ExecutionException, Throwable { execution.waitFor(); execution.updateResults(session); }
/** * executeSequence * * @param session a {@link org.opennms.sms.monitor.MobileSequenceSession} object. * @param coordinator a {@link org.opennms.core.tasks.DefaultTaskCoordinator} object. * @return a {@link java.util.Map} object. * @throws org.opennms.sms.monitor.SequencerException if any. * @throws java.lang.Throwable if any. */ public Map<String, Number> executeSequence( MobileSequenceSession session, DefaultTaskCoordinator coordinator) throws SequencerException, Throwable { MobileSequenceExecution execution = start(session, coordinator); waitFor(session, execution); return execution.getResponseTimes(); }
/** * start * * @param session a {@link org.opennms.sms.monitor.MobileSequenceSession} object. * @param coordinator a {@link org.opennms.core.tasks.DefaultTaskCoordinator} object. * @return a {@link org.opennms.sms.monitor.internal.MobileSequenceExecution} object. * @throws org.opennms.sms.monitor.SequencerException if any. */ public MobileSequenceExecution start( MobileSequenceSession session, DefaultTaskCoordinator coordinator) throws SequencerException { Assert.notNull(coordinator); computeDefaultGateways(); MobileSequenceExecution execution = createExecution(); execution.start(session, coordinator); return execution; }