class NotificationBus {

    protected void addHandler(Object handler) {
        List<Class<?>> newNotifications = collectSubscribingTypes(handler);
        pointToPointValidator.validate(handler, newNotifications);
        Lock lock = rwLock.writeLock();
        try {
            lock.lock();
            newNotifications.forEach(type -> registeredNotifications.put(type, type));
            clearCache();

            // Not sure that eventBus is thread-safe, so we'll include it in our lock
            eventBus.register(handler);
        } finally {
            lock.unlock();
        }
    }

    protected  NotificationBus(Class<N> notificationClass);

}