org.apache.hadoop.yarn.server.federation.store.utils

## Class FederationPolicyStoreInputValidator

- java.lang.Object
- - org.apache.hadoop.yarn.server.federation.store.utils.FederationPolicyStoreInputValidator

-     public final class FederationPolicyStoreInputValidator
      extends Object

  Utility class to validate the inputs to `FederationPolicyStore`, allows a fail fast mechanism for invalid user inputs.

- - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static void` | `validate(GetSubClusterPolicyConfigurationRequest request)` Quick validation on the input to check some obvious fail conditions (fail fast).
    `static void` | `validate(SetSubClusterPolicyConfigurationRequest request)` Quick validation on the input to check some obvious fail conditions (fail fast).

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### validate

          public static void validate(GetSubClusterPolicyConfigurationRequest request)
                               throws FederationStateStoreInvalidInputException

      Quick validation on the input to check some obvious fail conditions (fail fast). Check if the provided `GetSubClusterPolicyConfigurationRequest` for querying policy's information is valid or not.
      Parameters:
        `request` - the `GetSubClusterPolicyConfigurationRequest` to validate against
      Throws:
        `FederationStateStoreInvalidInputException` - if the request is invalid

    - #### validate

          public static void validate(SetSubClusterPolicyConfigurationRequest request)
                               throws FederationStateStoreInvalidInputException

      Quick validation on the input to check some obvious fail conditions (fail fast). Check if the provided `SetSubClusterPolicyConfigurationRequest` for adding a new policy is valid or not.
      Parameters:
        `request` - the `SetSubClusterPolicyConfigurationRequest` to validate against
      Throws:
        `FederationStateStoreInvalidInputException` - if the request is invalid

Copyright © 2008–2022 Apache Software Foundation. All rights reserved.