class EmailNotifier implements Notifier, TransportListener {

    public void messageDelivered(TransportEvent event) {
        LOG.debug("Got messageDelivered event {}", event);
        String notificationId = msgNotificationMap.remove(event.getMessage());
        if (notificationId != null) {
            ctx.ack(notificationId);
        }
    }

}