Gemfire JavaDocs_test
Class MembershipAttributes
- java.lang.Object
-
- org.apache.geode.cache.MembershipAttributes
-
- All Implemented Interfaces:
java.io.Externalizable
,java.io.Serializable
,DataSerializable
@Deprecated public class MembershipAttributes extends java.lang.Object implements DataSerializable, java.io.Externalizable
Deprecated.this feature is scheduled to be removedConfiguration attributes for defining reliability requirements and behavior for aRegion
.MembershipAttributes
provides options for configuring aRegion
to require one or more membership roles to be present in the system for reliable access to theRegion
. EachRole
is a user defined string name, such as Producer or Backup or FooProducer.The
LossAction
defines the behavior when one or more required roles are missing.The
ResumptionAction
specifies the action to be taken when reliability resumes.MembershipAttributes
have no effect unless one or more required roles are specified. These attributes are immutable after theRegion
has been created.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.geode.DataSerializable
DataSerializable.Replaceable
-
-
Constructor Summary
Constructors Constructor Description MembershipAttributes()
Deprecated.Creates a newMembershipAttributes
with the default configuration of no required roles.MembershipAttributes(java.lang.String[] requiredRoles)
Deprecated.Creates a newMembershipAttributes
with the specified required role names.MembershipAttributes(java.lang.String[] requiredRoles, LossAction lossAction, ResumptionAction resumptionAction)
Deprecated.Creates a newMembershipAttributes
with the specified required role names, reliability policy, and resumption action.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description boolean
equals(java.lang.Object other)
Deprecated.Indicates whether some other object is "equal to" this one.void
fromData(java.io.DataInput in)
Deprecated.Reads the state of this object as primitive data from the givenDataInput
.LossAction
getLossAction()
Deprecated.Returns the reliability policy that describes behavior if any required roles are missing.java.util.Set<Role>
getRequiredRoles()
Deprecated.Returns the set of Roles that are required for the reliability of this region.ResumptionAction
getResumptionAction()
Deprecated.Returns the resumption action that describes behavior when missing required roles return to the systemint
hashCode()
Deprecated.Returns a hash code for the object.boolean
hasRequiredRoles()
Deprecated.Returns true if there are one or more required roles specified.void
readExternal(java.io.ObjectInput in)
Deprecated.void
toData(java.io.DataOutput out)
Deprecated.Writes the state of this object as primitive data to the givenDataOutput
.java.lang.String
toString()
Deprecated.Returns a string representation of the object.void
writeExternal(java.io.ObjectOutput out)
Deprecated.
-
-
-
Constructor Detail
-
MembershipAttributes
public MembershipAttributes()
Deprecated.Creates a newMembershipAttributes
with the default configuration of no required roles.
-
MembershipAttributes
public MembershipAttributes(java.lang.String[] requiredRoles)
Deprecated.Creates a newMembershipAttributes
with the specified required role names. Reliability policy will default to NO_ACCESS, and resumption action will default to REINITIALIZE.- Parameters:
requiredRoles
- array of role names required by this process for reliable access to the region- Throws:
java.lang.IllegalArgumentException
- if no requiredRoles are specified
-
MembershipAttributes
public MembershipAttributes(java.lang.String[] requiredRoles, LossAction lossAction, ResumptionAction resumptionAction)
Deprecated.Creates a newMembershipAttributes
with the specified required role names, reliability policy, and resumption action.- Parameters:
requiredRoles
- array of role names required by this process for reliable access to the regionlossAction
- the configuration defining how this process behaves when there are missing required rolesresumptionAction
- the action to take when missing required roles return to the system- Throws:
java.lang.IllegalArgumentException
- if the resumptionAction is incompatible with the lossAction or if no requiredRoles are specified
-
-
Method Detail
-
getRequiredRoles
public java.util.Set<Role> getRequiredRoles()
Deprecated.Returns the set of Roles that are required for the reliability of this region.- Returns:
- the set of Roles that are required for the reliability of this region
-
hasRequiredRoles
public boolean hasRequiredRoles()
Deprecated.Returns true if there are one or more required roles specified.- Returns:
- whether there are one or more required roles specified
-
getLossAction
public LossAction getLossAction()
Deprecated.Returns the reliability policy that describes behavior if any required roles are missing.- Returns:
- the reliability policy that describes behavior if any required roles are missing
-
getResumptionAction
public ResumptionAction getResumptionAction()
Deprecated.Returns the resumption action that describes behavior when missing required roles return to the system- Returns:
- the resumption action that describes behavior when missing required roles return to the system
-
equals
public boolean equals(java.lang.Object other)
Deprecated.Indicates whether some other object is "equal to" this one.- Overrides:
equals
in classjava.lang.Object
- Parameters:
other
- the reference object with which to compare.- Returns:
- true if this object is the same as the obj argument; false otherwise.
-
hashCode
public int hashCode()
Deprecated.Returns a hash code for the object. This method is supported for the benefit of hashtables such as those provided by java.util.Hashtable.- Overrides:
hashCode
in classjava.lang.Object
- Returns:
- the integer 0 if description is null; otherwise a unique integer.
-
toString
public java.lang.String toString()
Deprecated.Returns a string representation of the object.- Overrides:
toString
in classjava.lang.Object
- Returns:
- a string representation of the object
-
toData
public void toData(java.io.DataOutput out) throws java.io.IOException
Deprecated.Description copied from interface:DataSerializable
Writes the state of this object as primitive data to the givenDataOutput
.Since 5.7 it is possible for any method call to the specified
DataOutput
to throwGemFireRethrowable
. It should not be caught by user code. If it is it must be rethrown.- Specified by:
toData
in interfaceDataSerializable
- Parameters:
out
- theDataOutput
to write to- Throws:
java.io.IOException
- A problem occurs while writing toout
-
fromData
public void fromData(java.io.DataInput in) throws java.io.IOException, java.lang.ClassNotFoundException
Deprecated.Description copied from interface:DataSerializable
Reads the state of this object as primitive data from the givenDataInput
.- Specified by:
fromData
in interfaceDataSerializable
- Parameters:
in
- theDataInput
to read from- Throws:
java.io.IOException
- A problem occurs while reading fromin
java.lang.ClassNotFoundException
- A class could not be loaded while reading fromin
-
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
Deprecated.- Specified by:
writeExternal
in interfacejava.io.Externalizable
- Throws:
java.io.IOException
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
Deprecated.- Specified by:
readExternal
in interfacejava.io.Externalizable
- Throws:
java.io.IOException
java.lang.ClassNotFoundException
-
-