Enum DistributionAffinity
- All Implemented Interfaces:
Serializable
,Comparable<DistributionAffinity>
Describes an operator's endpoint assignment requirements. Ordering is from no
assignment requirement to mandatory assignment requirements. Changes/new
addition should keep the order of increasing restrictive assignment
requirement.
-
Enum Constant Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
isLessRestrictiveThan
(DistributionAffinity distributionAffinity) Is the current DistributionAffinity less restrictive than the given DistributionAffinity?static DistributionAffinity
Returns the enum constant of this type with the specified name.static DistributionAffinity[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
NONE
No affinity to any endpoints. Operator can run on any endpoint. -
SOFT
Operator has soft distribution affinity to one or more endpoints. Operator performs better when fragments are assigned to the endpoints with affinity, but not a mandatory requirement. -
HARD
Hard distribution affinity to one or more endpoints. Fragments having the operator must be scheduled on the nodes with affinity.
-
-
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
-
getFragmentParallelizer
- Returns:
FragmentParallelizer
implementation.
-
isLessRestrictiveThan
Is the current DistributionAffinity less restrictive than the given DistributionAffinity?- Parameters:
distributionAffinity
-- Returns:
- True if the current DistributionAffinity less restrictive than the given DistributionAffinity. False otherwise.
-