public void validateAttributes() {
    if ((totalNumBuckets <= 0)) {
      throw new IllegalStateException(
          String.format(
              "TotalNumBuckets %s is an illegal value, please choose a value greater than 0",
              totalNumBuckets));
    }
    if ((redundancy < 0) || (redundancy >= 4)) {
      throw new IllegalStateException(
          String.format(
              "RedundantCopies %s is an illegal value, please choose a value between 0 and 3",
              redundancy));
    }
    for (final Object value : getLocalProperties().keySet()) {
      String propName = (String) value;
      if (!PartitionAttributesFactory.LOCAL_MAX_MEMORY_PROPERTY.equals(propName)) {
        throw new IllegalStateException(
            String.format("Unknown local property: '%s'",
                propName));
      }
    }
    for (final Object o : getGlobalProperties().keySet()) {
      String propName = (String) o;
      if (!PartitionAttributesFactory.GLOBAL_MAX_BUCKETS_PROPERTY.equals(propName)
          && !PartitionAttributesFactory.GLOBAL_MAX_MEMORY_PROPERTY.equals(propName)) {
        throw new IllegalStateException(
            String.format("Unknown global property: '%s'",
                propName));
      }
    }
    if (recoveryDelay < -1) {
      throw new IllegalStateException("RecoveryDelay " + recoveryDelay
          + " is an illegal value, please choose a value that is greater than or equal to -1");
    }
    if (startupRecoveryDelay < -1) {
      throw new IllegalStateException("StartupRecoveryDelay " + startupRecoveryDelay
          + " is an illegal value, please choose a value that is greater than or equal to -1");
    }
    if (fixedPAttrs != null) {
      List<FixedPartitionAttributesImpl> duplicateFPAattrsList =
          new ArrayList<>();
      Set<FixedPartitionAttributes> fpAttrsSet = new HashSet<>();
      for (FixedPartitionAttributesImpl fpa : fixedPAttrs) {
        if (fpa == null || fpa.getPartitionName() == null) {
          throw new IllegalStateException(
              "Fixed partition name cannot be null");
        }
        if (fpAttrsSet.contains(fpa)) {
          duplicateFPAattrsList.add(fpa);
        } else {
          fpAttrsSet.add(fpa);
        }
      }
      if (duplicateFPAattrsList.size() != 0) {
        throw new IllegalStateException(
            String.format("Partition name %s can be added only once in FixedPartitionAttributes",
                duplicateFPAattrsList));
      }
    }
  }
Validates that the attributes are consistent with each other. The following rules are checked
and enforced:
<ul>
<li>Redundancy should be between 1 and 4</li>
<li>Scope should be either DIST_ACK or DIST_NO_ACK</li>
</ul>
NOTE: validation that depends on more than one attribute can not be done in this method. That
validation needs to be done in validateWhenAllAttributesAreSet

@throws IllegalStateException if the attributes are not consistent with each other.
geode-core/src/main/java/org/apache/geode/internal/cache/PartitionAttributesImpl.java