public void setDowngradeAllowed(boolean canDowngrade) {
    downgradeAllowed = (!canDowngrade ? (short) 0 : (short) 1);
  }
@param canDowngrade {@code true} to allow downgrade, {@code false} to disallow downgrade
ambari-server/src/main/java/org/apache/ambari/server/orm/entities/UpgradeEntity.java