@Deprecated public class MembershipAttributes extends Object implements DataSerializable, Externalizable
Region.
MembershipAttributes provides options for configuring a Region to
require one or more membership roles to be present in the system for reliable access to the
Region. Each Role 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 the Region has been created.
DataSerializable.Replaceable| Constructor and Description |
|---|
MembershipAttributes()
Deprecated.
Creates a new
MembershipAttributes with the default configuration of no required
roles. |
MembershipAttributes(String[] requiredRoles)
Deprecated.
Creates a new
MembershipAttributes with the specified required role names. |
MembershipAttributes(String[] requiredRoles,
LossAction lossAction,
ResumptionAction resumptionAction)
Deprecated.
Creates a new
MembershipAttributes with the specified required role names,
reliability policy, and resumption action. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object other)
Deprecated.
Indicates whether some other object is "equal to" this one.
|
void |
fromData(DataInput in)
Deprecated.
Reads the state of this object as primitive data from the given
DataInput. |
LossAction |
getLossAction()
Deprecated.
Returns the reliability policy that describes behavior if any required roles are missing.
|
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
system
|
int |
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(ObjectInput in)
Deprecated.
|
void |
toData(DataOutput out)
Deprecated.
Writes the state of this object as primitive data to the given
DataOutput. |
String |
toString()
Deprecated.
Returns a string representation of the object.
|
void |
writeExternal(ObjectOutput out)
Deprecated.
|
public MembershipAttributes()
MembershipAttributes with the default configuration of no required
roles.public MembershipAttributes(String[] requiredRoles)
MembershipAttributes with the specified required role names.
Reliability policy will default to NO_ACCESS, and resumption
action will default to REINITIALIZE.requiredRoles - array of role names required by this process for reliable access to the
regionIllegalArgumentException - if no requiredRoles are specifiedpublic MembershipAttributes(String[] requiredRoles, LossAction lossAction, ResumptionAction resumptionAction)
MembershipAttributes with the specified required role names,
reliability policy, and resumption action.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 systemIllegalArgumentException - if the resumptionAction is incompatible with the lossAction or
if no requiredRoles are specifiedpublic Set<Role> getRequiredRoles()
public boolean hasRequiredRoles()
public LossAction getLossAction()
public ResumptionAction getResumptionAction()
public boolean equals(Object other)
public int hashCode()
public String toString()
public void toData(DataOutput out) throws IOException
DataSerializableDataOutput.
Since 5.7 it is possible for any method call to the specified DataOutput to throw
GemFireRethrowable. It should not be caught by user code. If it is it
must be rethrown.
toData in interface DataSerializableout - the DataOutput to write toIOException - A problem occurs while writing to outpublic void fromData(DataInput in) throws IOException, ClassNotFoundException
DataSerializableDataInput.fromData in interface DataSerializablein - the DataInput to read fromIOException - A problem occurs while reading from inClassNotFoundException - A class could not be loaded while reading from inpublic void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizableIOExceptionpublic void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal in interface ExternalizableIOExceptionClassNotFoundException