Package io.dingodb.store
Class Store.TxnPrewriteResponse
java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
io.dingodb.store.Store.TxnPrewriteResponse
- All Implemented Interfaces:
com.google.protobuf.Message,com.google.protobuf.MessageLite,com.google.protobuf.MessageLiteOrBuilder,com.google.protobuf.MessageOrBuilder,Store.TxnPrewriteResponseOrBuilder,Serializable
- Enclosing class:
- Store
public static final class Store.TxnPrewriteResponse
extends com.google.protobuf.GeneratedMessageV3
implements Store.TxnPrewriteResponseOrBuilder
Protobuf type
dingodb.pb.store.TxnPrewriteResponse- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classProtobuf typedingodb.pb.store.TxnPrewriteResponseNested classes/interfaces inherited from class com.google.protobuf.GeneratedMessageV3
com.google.protobuf.GeneratedMessageV3.BuilderParent, com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>,BuilderT extends com.google.protobuf.GeneratedMessageV3.ExtendableBuilder<MessageT, BuilderT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.ExtendableMessageOrBuilder<MessageT extends com.google.protobuf.GeneratedMessageV3.ExtendableMessage<MessageT>>, com.google.protobuf.GeneratedMessageV3.FieldAccessorTable, com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter Nested classes/interfaces inherited from class com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessageLite.InternalOneOfEnum -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intFields inherited from class com.google.protobuf.GeneratedMessageV3
alwaysUseFieldBuilders, unknownFieldsFields inherited from class com.google.protobuf.AbstractMessage
memoizedSizeFields inherited from class com.google.protobuf.AbstractMessageLite
memoizedHashCode -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic Store.TxnPrewriteResponsestatic final com.google.protobuf.Descriptors.DescriptorgetError()error codeerror codegetKeysAlreadyExist(int index) if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returnedintif there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returnedif there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returnedgetKeysAlreadyExistOrBuilder(int index) if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returnedList<? extends Store.AlreadyExistOrBuilder>if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returnedlong0 if the min_commit_ts is not ready or any other reason that async commit cannot proceed.longWhen the transaction is successfully committed with 1PC protocol, this field will be set to the commit ts of the transaction.com.google.protobuf.Parser<Store.TxnPrewriteResponse>response inforesponse infointgetTxnResult(int index) for prewrite, txn_result will be one of the following: 1.intfor prewrite, txn_result will be one of the following: 1.for prewrite, txn_result will be one of the following: 1.getTxnResultOrBuilder(int index) for prewrite, txn_result will be one of the following: 1.List<? extends Store.TxnResultInfoOrBuilder>for prewrite, txn_result will be one of the following: 1.booleanhasError()error codeinthashCode()booleanresponse infoprotected com.google.protobuf.GeneratedMessageV3.FieldAccessorTablefinal booleannewBuilder(Store.TxnPrewriteResponse prototype) protected Store.TxnPrewriteResponse.BuildernewBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) protected ObjectnewInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused) static Store.TxnPrewriteResponseparseDelimitedFrom(InputStream input) static Store.TxnPrewriteResponseparseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Store.TxnPrewriteResponseparseFrom(byte[] data) static Store.TxnPrewriteResponseparseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Store.TxnPrewriteResponseparseFrom(com.google.protobuf.ByteString data) static Store.TxnPrewriteResponseparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Store.TxnPrewriteResponseparseFrom(com.google.protobuf.CodedInputStream input) static Store.TxnPrewriteResponseparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Store.TxnPrewriteResponseparseFrom(InputStream input) static Store.TxnPrewriteResponseparseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static Store.TxnPrewriteResponseparseFrom(ByteBuffer data) static Store.TxnPrewriteResponseparseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) static com.google.protobuf.Parser<Store.TxnPrewriteResponse>parser()voidwriteTo(com.google.protobuf.CodedOutputStream output) Methods inherited from class com.google.protobuf.GeneratedMessageV3
canUseUnsafe, computeStringSize, computeStringSizeNoTag, emptyBooleanList, emptyDoubleList, emptyFloatList, emptyIntList, emptyList, emptyLongList, getAllFields, getDescriptorForType, getField, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof, internalGetMapField, internalGetMapFieldReflection, isStringEmpty, makeExtensionsImmutable, makeMutableCopy, makeMutableCopy, mergeFromAndMakeImmutableInternal, mutableCopy, mutableCopy, mutableCopy, mutableCopy, mutableCopy, newBooleanList, newBuilderForType, newDoubleList, newFloatList, newIntList, newLongList, parseDelimitedWithIOException, parseDelimitedWithIOException, parseUnknownField, parseUnknownFieldProto3, parseWithIOException, parseWithIOException, parseWithIOException, parseWithIOException, serializeBooleanMapTo, serializeIntegerMapTo, serializeLongMapTo, serializeStringMapTo, writeReplace, writeString, writeStringNoTagMethods inherited from class com.google.protobuf.AbstractMessage
findInitializationErrors, getInitializationErrorString, hashBoolean, hashEnum, hashEnumList, hashFields, hashLong, toStringMethods inherited from class com.google.protobuf.AbstractMessageLite
addAll, addAll, checkByteStringIsUtf8, toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface com.google.protobuf.MessageLite
toByteArray, toByteString, writeDelimitedTo, writeToMethods inherited from interface com.google.protobuf.MessageOrBuilder
findInitializationErrors, getAllFields, getDescriptorForType, getField, getInitializationErrorString, getOneofFieldDescriptor, getRepeatedField, getRepeatedFieldCount, getUnknownFields, hasField, hasOneof
-
Field Details
-
RESPONSE_INFO_FIELD_NUMBER
public static final int RESPONSE_INFO_FIELD_NUMBER- See Also:
-
ERROR_FIELD_NUMBER
public static final int ERROR_FIELD_NUMBER- See Also:
-
TXN_RESULT_FIELD_NUMBER
public static final int TXN_RESULT_FIELD_NUMBER- See Also:
-
KEYS_ALREADY_EXIST_FIELD_NUMBER
public static final int KEYS_ALREADY_EXIST_FIELD_NUMBER- See Also:
-
ONE_PC_COMMIT_TS_FIELD_NUMBER
public static final int ONE_PC_COMMIT_TS_FIELD_NUMBER- See Also:
-
MIN_COMMIT_TS_FIELD_NUMBER
public static final int MIN_COMMIT_TS_FIELD_NUMBER- See Also:
-
-
Method Details
-
newInstance
- Overrides:
newInstancein classcom.google.protobuf.GeneratedMessageV3
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() -
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()- Specified by:
internalGetFieldAccessorTablein classcom.google.protobuf.GeneratedMessageV3
-
hasResponseInfo
public boolean hasResponseInfo()response info
.dingodb.pb.common.ResponseInfo response_info = 1;- Specified by:
hasResponseInfoin interfaceStore.TxnPrewriteResponseOrBuilder- Returns:
- Whether the responseInfo field is set.
-
getResponseInfo
response info
.dingodb.pb.common.ResponseInfo response_info = 1;- Specified by:
getResponseInfoin interfaceStore.TxnPrewriteResponseOrBuilder- Returns:
- The responseInfo.
-
getResponseInfoOrBuilder
response info
.dingodb.pb.common.ResponseInfo response_info = 1;- Specified by:
getResponseInfoOrBuilderin interfaceStore.TxnPrewriteResponseOrBuilder
-
hasError
public boolean hasError()error code
.dingodb.pb.error.Error error = 2;- Specified by:
hasErrorin interfaceStore.TxnPrewriteResponseOrBuilder- Returns:
- Whether the error field is set.
-
getError
error code
.dingodb.pb.error.Error error = 2;- Specified by:
getErrorin interfaceStore.TxnPrewriteResponseOrBuilder- Returns:
- The error.
-
getErrorOrBuilder
error code
.dingodb.pb.error.Error error = 2;- Specified by:
getErrorOrBuilderin interfaceStore.TxnPrewriteResponseOrBuilder
-
getTxnResultList
for prewrite, txn_result will be one of the following: 1. LockInfo: prewrite meet a lock and can't proceed, the lock is returned 2. WriteConflict: Write conflict with key which is already written after start_ts 2.1 Optimistic: in optimistic transactions. 2.2 SelfRolledBack: the transaction itself has been rolled back when it tries to prewrite. 3. otherwise, txn_result is empty for success prewrite, txn_result is empty for failure prewrite, txn_result is not empty if there is a WriteConflict in txn_result, client should backoff or cleanup the lock then retryrepeated .dingodb.pb.store.TxnResultInfo txn_result = 3;- Specified by:
getTxnResultListin interfaceStore.TxnPrewriteResponseOrBuilder
-
getTxnResultOrBuilderList
for prewrite, txn_result will be one of the following: 1. LockInfo: prewrite meet a lock and can't proceed, the lock is returned 2. WriteConflict: Write conflict with key which is already written after start_ts 2.1 Optimistic: in optimistic transactions. 2.2 SelfRolledBack: the transaction itself has been rolled back when it tries to prewrite. 3. otherwise, txn_result is empty for success prewrite, txn_result is empty for failure prewrite, txn_result is not empty if there is a WriteConflict in txn_result, client should backoff or cleanup the lock then retryrepeated .dingodb.pb.store.TxnResultInfo txn_result = 3;- Specified by:
getTxnResultOrBuilderListin interfaceStore.TxnPrewriteResponseOrBuilder
-
getTxnResultCount
public int getTxnResultCount()for prewrite, txn_result will be one of the following: 1. LockInfo: prewrite meet a lock and can't proceed, the lock is returned 2. WriteConflict: Write conflict with key which is already written after start_ts 2.1 Optimistic: in optimistic transactions. 2.2 SelfRolledBack: the transaction itself has been rolled back when it tries to prewrite. 3. otherwise, txn_result is empty for success prewrite, txn_result is empty for failure prewrite, txn_result is not empty if there is a WriteConflict in txn_result, client should backoff or cleanup the lock then retryrepeated .dingodb.pb.store.TxnResultInfo txn_result = 3;- Specified by:
getTxnResultCountin interfaceStore.TxnPrewriteResponseOrBuilder
-
getTxnResult
for prewrite, txn_result will be one of the following: 1. LockInfo: prewrite meet a lock and can't proceed, the lock is returned 2. WriteConflict: Write conflict with key which is already written after start_ts 2.1 Optimistic: in optimistic transactions. 2.2 SelfRolledBack: the transaction itself has been rolled back when it tries to prewrite. 3. otherwise, txn_result is empty for success prewrite, txn_result is empty for failure prewrite, txn_result is not empty if there is a WriteConflict in txn_result, client should backoff or cleanup the lock then retryrepeated .dingodb.pb.store.TxnResultInfo txn_result = 3;- Specified by:
getTxnResultin interfaceStore.TxnPrewriteResponseOrBuilder
-
getTxnResultOrBuilder
for prewrite, txn_result will be one of the following: 1. LockInfo: prewrite meet a lock and can't proceed, the lock is returned 2. WriteConflict: Write conflict with key which is already written after start_ts 2.1 Optimistic: in optimistic transactions. 2.2 SelfRolledBack: the transaction itself has been rolled back when it tries to prewrite. 3. otherwise, txn_result is empty for success prewrite, txn_result is empty for failure prewrite, txn_result is not empty if there is a WriteConflict in txn_result, client should backoff or cleanup the lock then retryrepeated .dingodb.pb.store.TxnResultInfo txn_result = 3;- Specified by:
getTxnResultOrBuilderin interfaceStore.TxnPrewriteResponseOrBuilder
-
getKeysAlreadyExistList
if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returned
repeated .dingodb.pb.store.AlreadyExist keys_already_exist = 4;- Specified by:
getKeysAlreadyExistListin interfaceStore.TxnPrewriteResponseOrBuilder
-
getKeysAlreadyExistOrBuilderList
if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returned
repeated .dingodb.pb.store.AlreadyExist keys_already_exist = 4;- Specified by:
getKeysAlreadyExistOrBuilderListin interfaceStore.TxnPrewriteResponseOrBuilder
-
getKeysAlreadyExistCount
public int getKeysAlreadyExistCount()if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returned
repeated .dingodb.pb.store.AlreadyExist keys_already_exist = 4;- Specified by:
getKeysAlreadyExistCountin interfaceStore.TxnPrewriteResponseOrBuilder
-
getKeysAlreadyExist
if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returned
repeated .dingodb.pb.store.AlreadyExist keys_already_exist = 4;- Specified by:
getKeysAlreadyExistin interfaceStore.TxnPrewriteResponseOrBuilder
-
getKeysAlreadyExistOrBuilder
if there is PutIfAbsent in mutation, and if there is key conflict, the conflict key will be returned
repeated .dingodb.pb.store.AlreadyExist keys_already_exist = 4;- Specified by:
getKeysAlreadyExistOrBuilderin interfaceStore.TxnPrewriteResponseOrBuilder
-
getOnePcCommitTs
public long getOnePcCommitTs()When the transaction is successfully committed with 1PC protocol, this field will be set to the commit ts of the transaction. Otherwise, if dingo-store failed to commit it with 1PC or the transaction is not 1PC, the value will be 0.
int64 one_pc_commit_ts = 5;- Specified by:
getOnePcCommitTsin interfaceStore.TxnPrewriteResponseOrBuilder- Returns:
- The onePcCommitTs.
-
getMinCommitTs
public long getMinCommitTs()0 if the min_commit_ts is not ready or any other reason that async commit cannot proceed. The client can then fallback to normal way to continue committing the transaction if prewrite are all finished.
uint64 min_commit_ts = 6;- Specified by:
getMinCommitTsin interfaceStore.TxnPrewriteResponseOrBuilder- Returns:
- The minCommitTs.
-
isInitialized
public final boolean isInitialized()- Specified by:
isInitializedin interfacecom.google.protobuf.MessageLiteOrBuilder- Overrides:
isInitializedin classcom.google.protobuf.GeneratedMessageV3
-
writeTo
- Specified by:
writeToin interfacecom.google.protobuf.MessageLite- Overrides:
writeToin classcom.google.protobuf.GeneratedMessageV3- Throws:
IOException
-
getSerializedSize
public int getSerializedSize()- Specified by:
getSerializedSizein interfacecom.google.protobuf.MessageLite- Overrides:
getSerializedSizein classcom.google.protobuf.GeneratedMessageV3
-
equals
- Specified by:
equalsin interfacecom.google.protobuf.Message- Overrides:
equalsin classcom.google.protobuf.AbstractMessage
-
hashCode
public int hashCode()- Specified by:
hashCodein interfacecom.google.protobuf.Message- Overrides:
hashCodein classcom.google.protobuf.AbstractMessage
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException - Throws:
com.google.protobuf.InvalidProtocolBufferException
-
parseFrom
- Throws:
IOException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseDelimitedFrom
- Throws:
IOException
-
parseDelimitedFrom
public static Store.TxnPrewriteResponse parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(com.google.protobuf.CodedInputStream input) throws IOException - Throws:
IOException
-
parseFrom
public static Store.TxnPrewriteResponse parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException - Throws:
IOException
-
newBuilderForType
- Specified by:
newBuilderForTypein interfacecom.google.protobuf.Message- Specified by:
newBuilderForTypein interfacecom.google.protobuf.MessageLite
-
newBuilder
-
newBuilder
-
toBuilder
- Specified by:
toBuilderin interfacecom.google.protobuf.Message- Specified by:
toBuilderin interfacecom.google.protobuf.MessageLite
-
newBuilderForType
protected Store.TxnPrewriteResponse.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) - Specified by:
newBuilderForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstance
-
parser
-
getParserForType
- Specified by:
getParserForTypein interfacecom.google.protobuf.Message- Specified by:
getParserForTypein interfacecom.google.protobuf.MessageLite- Overrides:
getParserForTypein classcom.google.protobuf.GeneratedMessageV3
-
getDefaultInstanceForType
- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageLiteOrBuilder- Specified by:
getDefaultInstanceForTypein interfacecom.google.protobuf.MessageOrBuilder
-