private static void assertNounnamedConstraint(String tableName, String definition) {
    if (tableName.contains("qrtz")) {
      LOG.debug("Skipp checking quartz table: {}", tableName);
    }
    else {
      for (Pattern unnamedConstraint: CheckedUnnamedConstraints) {
        if (unnamedConstraint.matcher(definition).matches()) {
          throw new IllegalStateException(
              String.format("Found invalid (unnamed) constraint in table %s: %s", tableName, definition));
        }
      }
      for (Pattern unnamedConstraint: UncheckedUnnamedConstraints) {
        if (unnamedConstraint.matcher(definition).matches()) {
          LOG.info("Found unnamed constraint in table {}: {}", tableName, definition);
        }
      }
    }
  }
Currently we only fail on unnamed primary keys.
@param tableName
@param definition
ambari-server/src/test/java/org/apache/ambari/server/orm/db/DDLTestUtils.java