@Override
public void run() {
try {
System.out.print("Firing " + config.getMessageCount() + " ticks... ");
for (int i = 0; i < config.getMessageCount(); i++) {
tickEvent.fire(new TickEvent(nextEventId.getAndIncrement(), System.currentTimeMillis(), payload));
}
} catch (Throwable t) {
t.printStackTrace(System.out);
} finally {
System.out.println("done. (interrupted=" + Thread.currentThread().isInterrupted() + ")");