Enum ValidationCondition
java.lang.Object
java.lang.Enum<ValidationCondition>
org.apache.hadoop.ozone.om.request.validation.ValidationCondition
- All Implemented Interfaces:
Serializable,Comparable<ValidationCondition>
Defines conditions for which validators can be assigned to.
These conditions describe a situation where special request handling might
be necessary. In these cases we do not override the actual request handling
code, but based on certain request properties we might reject a request
early, or we might modify the request, or the response received/sent from/to
the client.
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionClassifies validations that has to run after an upgrade until the cluster is in a pre-finalized state.Classifies validations that has to run, when the client uses an older protocol version than the server. -
Method Summary
Modifier and TypeMethodDescriptionabstract booleanshouldApply(org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest req, ValidationContext ctx) static ValidationConditionReturns the enum constant of this type with the specified name.static ValidationCondition[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
CLUSTER_NEEDS_FINALIZATION
Classifies validations that has to run after an upgrade until the cluster is in a pre-finalized state. -
OLDER_CLIENT_REQUESTS
Classifies validations that has to run, when the client uses an older protocol version than the server.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-
shouldApply
public abstract boolean shouldApply(org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest req, ValidationContext ctx)
-