Package org.apache.zookeeper.server
Enum EphemeralTypeEmulate353
- All Implemented Interfaces:
Serializable
,Comparable<EphemeralTypeEmulate353>
See https://issues.apache.org/jira/browse/ZOOKEEPER-2901
version 3.5.3 introduced bugs associated with how TTL nodes were implemented. version 3.5.4
fixes the problems but makes TTL nodes created in 3.5.3 invalid. EphemeralTypeEmulate353 is a copy
of the old - bad - implementation that is provided as a workaround.
EphemeralType.TTL_3_5_3_EMULATION_PROPERTY
can be used to emulate support of the badly specified TTL nodes.-
Enum Constant Summary
Enum Constants -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final long
static final long
static final long
-
Method Summary
Modifier and TypeMethodDescriptionstatic EphemeralTypeEmulate353
get
(long ephemeralOwner) static long
ttlToEphemeralOwner
(long ttl) static EphemeralTypeEmulate353
Returns the enum constant of this type with the specified name.static EphemeralTypeEmulate353[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
VOID
Not ephemeral -
NORMAL
Standard, pre-3.5.x EPHEMERAL -
CONTAINER
Container node -
TTL
TTL node
-
-
Field Details
-
CONTAINER_EPHEMERAL_OWNER
public static final long CONTAINER_EPHEMERAL_OWNER- See Also:
-
MAX_TTL
public static final long MAX_TTL- See Also:
-
TTL_MASK
public static final long TTL_MASK- See Also:
-
-
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
-
get
-
ttlToEphemeralOwner
public static long ttlToEphemeralOwner(long ttl)
-