@Override
  public void addNotificationEvent(NotificationEvent entry) throws MetaException {
    if (addNotificationEventModifier != null) {
      Boolean success = addNotificationEventModifier.apply(entry);
      if ((success != null) && !success) {
        throw new MetaException("InjectableBehaviourObjectStore: Invalid addNotificationEvent operation on DB: "
                + entry.getDbName() + " table: " + entry.getTableName() + " event : " + entry.getEventType());
      }
    }
    super.addNotificationEvent(entry);
  }
A utility class to pass the arguments of the caller to the stub method.
standalone-metastore/metastore-server/src/test/java/org/apache/hadoop/hive/metastore/InjectableBehaviourObjectStore.java