public final class Group extends GeneratedMessage implements GroupOrBuilder
A Group represents a paxos group in a database. A group is a set of
tablets that are replicated across multiple servers. Groups may have a leader
tablet. Groups store one (or sometimes more) ranges of keys.
Protobuf type google.spanner.v1.Group
Inherited Members
com.google.protobuf.GeneratedMessage.<ContainingT,T>newFileScopedGeneratedExtension(java.lang.Class<?>,com.google.protobuf.Message)
com.google.protobuf.GeneratedMessage.<ContainingT,T>newMessageScopedGeneratedExtension(com.google.protobuf.Message,int,java.lang.Class<?>,com.google.protobuf.Message)
com.google.protobuf.GeneratedMessage.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessage.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessage.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessage.<V>serializeBooleanMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Boolean,V>,com.google.protobuf.MapEntry<java.lang.Boolean,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeIntegerMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Integer,V>,com.google.protobuf.MapEntry<java.lang.Integer,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeLongMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.Long,V>,com.google.protobuf.MapEntry<java.lang.Long,V>,int)
com.google.protobuf.GeneratedMessage.<V>serializeStringMapTo(com.google.protobuf.CodedOutputStream,com.google.protobuf.MapField<java.lang.String,V>,com.google.protobuf.MapEntry<java.lang.String,V>,int)
com.google.protobuf.GeneratedMessage.canUseUnsafe()
com.google.protobuf.GeneratedMessage.emptyBooleanList()
com.google.protobuf.GeneratedMessage.emptyDoubleList()
com.google.protobuf.GeneratedMessage.emptyFloatList()
com.google.protobuf.GeneratedMessage.emptyIntList()
com.google.protobuf.GeneratedMessage.emptyLongList()
com.google.protobuf.GeneratedMessage.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessage.isStringEmpty(java.lang.Object)
com.google.protobuf.GeneratedMessage.mergeFromAndMakeImmutableInternal(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite)
com.google.protobuf.GeneratedMessage.newInstance(com.google.protobuf.GeneratedMessage.UnusedPrivateParameter)
com.google.protobuf.GeneratedMessage.parseUnknownFieldProto3(com.google.protobuf.CodedInputStream,com.google.protobuf.UnknownFieldSet.Builder,com.google.protobuf.ExtensionRegistryLite,int)
Static Fields
GENERATION_FIELD_NUMBER
public static final int GENERATION_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
GROUP_UID_FIELD_NUMBER
public static final int GROUP_UID_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
LEADER_INDEX_FIELD_NUMBER
public static final int LEADER_INDEX_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
TABLETS_FIELD_NUMBER
public static final int TABLETS_FIELD_NUMBER
| Field Value |
| Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static Group getDefaultInstance()
| Returns |
| Type |
Description |
Group |
|
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static Group.Builder newBuilder()
newBuilder(Group prototype)
public static Group.Builder newBuilder(Group prototype)
| Parameter |
| Name |
Description |
prototype |
Group
|
public static Group parseDelimitedFrom(InputStream input)
| Returns |
| Type |
Description |
Group |
|
public static Group parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Group |
|
parseFrom(byte[] data)
public static Group parseFrom(byte[] data)
| Parameter |
| Name |
Description |
data |
byte[]
|
| Returns |
| Type |
Description |
Group |
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static Group parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Group |
|
parseFrom(ByteString data)
public static Group parseFrom(ByteString data)
| Returns |
| Type |
Description |
Group |
|
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static Group parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Group |
|
public static Group parseFrom(CodedInputStream input)
| Returns |
| Type |
Description |
Group |
|
public static Group parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Group |
|
public static Group parseFrom(InputStream input)
| Returns |
| Type |
Description |
Group |
|
public static Group parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Group |
|
parseFrom(ByteBuffer data)
public static Group parseFrom(ByteBuffer data)
| Returns |
| Type |
Description |
Group |
|
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static Group parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
| Returns |
| Type |
Description |
Group |
|
parser()
public static Parser<Group> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
| Parameter |
| Name |
Description |
obj |
Object
|
Overrides
getDefaultInstanceForType()
public Group getDefaultInstanceForType()
| Returns |
| Type |
Description |
Group |
|
getGeneration()
public ByteString getGeneration()
generation indicates the freshness of the group information (including
leader information) contained in this proto. Generations can be compared
lexicographically; if generation A is greater than generation B, then the
Group corresponding to A is newer than the Group corresponding to B,
and should be used preferentially.
bytes generation = 4;
| Returns |
| Type |
Description |
ByteString |
The generation.
|
getGroupUid()
public long getGroupUid()
The UID of the paxos group, unique within the database. Matches the
group_uid field in Range.
uint64 group_uid = 1;
| Returns |
| Type |
Description |
long |
The groupUid.
|
getLeaderIndex()
public int getLeaderIndex()
The last known leader tablet of the group as an index into tablets. May
be negative if the group has no known leader.
int32 leader_index = 3;
| Returns |
| Type |
Description |
int |
The leaderIndex.
|
getParserForType()
public Parser<Group> getParserForType()
Overrides
getSerializedSize()
public int getSerializedSize()
| Returns |
| Type |
Description |
int |
|
Overrides
getTablets(int index)
public Tablet getTablets(int index)
A list of tablets that are part of the group. Note that this list may not
be exhaustive; it will only include tablets the server considers useful
to the client. The returned list is ordered ascending by distance.
Tablet UIDs reference Tablet.tablet_uid.
repeated .google.spanner.v1.Tablet tablets = 2;
| Parameter |
| Name |
Description |
index |
int
|
| Returns |
| Type |
Description |
Tablet |
|
getTabletsCount()
public int getTabletsCount()
A list of tablets that are part of the group. Note that this list may not
be exhaustive; it will only include tablets the server considers useful
to the client. The returned list is ordered ascending by distance.
Tablet UIDs reference Tablet.tablet_uid.
repeated .google.spanner.v1.Tablet tablets = 2;
| Returns |
| Type |
Description |
int |
|
getTabletsList()
public List<Tablet> getTabletsList()
A list of tablets that are part of the group. Note that this list may not
be exhaustive; it will only include tablets the server considers useful
to the client. The returned list is ordered ascending by distance.
Tablet UIDs reference Tablet.tablet_uid.
repeated .google.spanner.v1.Tablet tablets = 2;
getTabletsOrBuilder(int index)
public TabletOrBuilder getTabletsOrBuilder(int index)
A list of tablets that are part of the group. Note that this list may not
be exhaustive; it will only include tablets the server considers useful
to the client. The returned list is ordered ascending by distance.
Tablet UIDs reference Tablet.tablet_uid.
repeated .google.spanner.v1.Tablet tablets = 2;
| Parameter |
| Name |
Description |
index |
int
|
getTabletsOrBuilderList()
public List<? extends TabletOrBuilder> getTabletsOrBuilderList()
A list of tablets that are part of the group. Note that this list may not
be exhaustive; it will only include tablets the server considers useful
to the client. The returned list is ordered ascending by distance.
Tablet UIDs reference Tablet.tablet_uid.
repeated .google.spanner.v1.Tablet tablets = 2;
| Returns |
| Type |
Description |
List<? extends com.google.spanner.v1.TabletOrBuilder> |
|
hashCode()
| Returns |
| Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public Group.Builder newBuilderForType()
newBuilderForType(AbstractMessage.BuilderParent parent)
protected Group.Builder newBuilderForType(AbstractMessage.BuilderParent parent)
Overrides
toBuilder()
public Group.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides