public static final class Kvrpcpb.PessimisticLockRequest.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder> implements Kvrpcpb.PessimisticLockRequestOrBuilder
Lock a set of keys to prepare to write to them.Protobuf type
kvrpcpb.PessimisticLockRequest
Modifier and Type | Method and Description |
---|---|
Kvrpcpb.PessimisticLockRequest.Builder |
addAllMutations(Iterable<? extends Kvrpcpb.Mutation> values)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
addMutations(int index,
Kvrpcpb.Mutation.Builder builderForValue)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
addMutations(int index,
Kvrpcpb.Mutation value)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
addMutations(Kvrpcpb.Mutation.Builder builderForValue)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
addMutations(Kvrpcpb.Mutation value)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.Mutation.Builder |
addMutationsBuilder()
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.Mutation.Builder |
addMutationsBuilder(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
Kvrpcpb.PessimisticLockRequest |
build() |
Kvrpcpb.PessimisticLockRequest |
buildPartial() |
Kvrpcpb.PessimisticLockRequest.Builder |
clear() |
Kvrpcpb.PessimisticLockRequest.Builder |
clearCheckExistence()
If set to true, it means TiKV need to check if the key exists, and return the result in
the `not_founds` feild in the response.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearContext()
.kvrpcpb.Context context = 1; |
Kvrpcpb.PessimisticLockRequest.Builder |
clearField(com.google.protobuf.Descriptors.FieldDescriptor field) |
Kvrpcpb.PessimisticLockRequest.Builder |
clearForce()
Deprecated.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearForUpdateTs()
Each locking command in a pessimistic transaction has its own timestamp.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearIsFirstLock()
If the request is the first lock request, we don't need to detect deadlock.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearLockTtl()
uint64 lock_ttl = 5; |
Kvrpcpb.PessimisticLockRequest.Builder |
clearMinCommitTs()
If min_commit_ts > 0, this is large transaction proto, the final commit_ts
would be infered from min_commit_ts.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearMutations()
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) |
Kvrpcpb.PessimisticLockRequest.Builder |
clearPrimaryLock()
bytes primary_lock = 3; |
Kvrpcpb.PessimisticLockRequest.Builder |
clearReturnValues()
If it is true, TiKV will return values of the keys if no error, so TiDB can cache the values for
later read in the same transaction.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clearStartVersion()
uint64 start_version = 4; |
Kvrpcpb.PessimisticLockRequest.Builder |
clearWaitTimeout()
Time to wait for lock released in milliseconds when encountering locks.
|
Kvrpcpb.PessimisticLockRequest.Builder |
clone() |
boolean |
getCheckExistence()
If set to true, it means TiKV need to check if the key exists, and return the result in
the `not_founds` feild in the response.
|
Kvrpcpb.Context |
getContext()
.kvrpcpb.Context context = 1; |
Kvrpcpb.Context.Builder |
getContextBuilder()
.kvrpcpb.Context context = 1; |
Kvrpcpb.ContextOrBuilder |
getContextOrBuilder()
.kvrpcpb.Context context = 1; |
Kvrpcpb.PessimisticLockRequest |
getDefaultInstanceForType() |
static com.google.protobuf.Descriptors.Descriptor |
getDescriptor() |
com.google.protobuf.Descriptors.Descriptor |
getDescriptorForType() |
boolean |
getForce()
Deprecated.
|
long |
getForUpdateTs()
Each locking command in a pessimistic transaction has its own timestamp.
|
boolean |
getIsFirstLock()
If the request is the first lock request, we don't need to detect deadlock.
|
long |
getLockTtl()
uint64 lock_ttl = 5; |
long |
getMinCommitTs()
If min_commit_ts > 0, this is large transaction proto, the final commit_ts
would be infered from min_commit_ts.
|
Kvrpcpb.Mutation |
getMutations(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.Mutation.Builder |
getMutationsBuilder(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
List<Kvrpcpb.Mutation.Builder> |
getMutationsBuilderList()
In this case every `Op` of the mutations must be `PessimisticLock`.
|
int |
getMutationsCount()
In this case every `Op` of the mutations must be `PessimisticLock`.
|
List<Kvrpcpb.Mutation> |
getMutationsList()
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.MutationOrBuilder |
getMutationsOrBuilder(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
List<? extends Kvrpcpb.MutationOrBuilder> |
getMutationsOrBuilderList()
In this case every `Op` of the mutations must be `PessimisticLock`.
|
com.google.protobuf.ByteString |
getPrimaryLock()
bytes primary_lock = 3; |
boolean |
getReturnValues()
If it is true, TiKV will return values of the keys if no error, so TiDB can cache the values for
later read in the same transaction.
|
long |
getStartVersion()
uint64 start_version = 4; |
long |
getWaitTimeout()
Time to wait for lock released in milliseconds when encountering locks.
|
boolean |
hasContext()
.kvrpcpb.Context context = 1; |
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable |
internalGetFieldAccessorTable() |
boolean |
isInitialized() |
Kvrpcpb.PessimisticLockRequest.Builder |
mergeContext(Kvrpcpb.Context value)
.kvrpcpb.Context context = 1; |
Kvrpcpb.PessimisticLockRequest.Builder |
mergeFrom(com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry) |
Kvrpcpb.PessimisticLockRequest.Builder |
mergeFrom(Kvrpcpb.PessimisticLockRequest other) |
Kvrpcpb.PessimisticLockRequest.Builder |
mergeFrom(com.google.protobuf.Message other) |
Kvrpcpb.PessimisticLockRequest.Builder |
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
Kvrpcpb.PessimisticLockRequest.Builder |
removeMutations(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setCheckExistence(boolean value)
If set to true, it means TiKV need to check if the key exists, and return the result in
the `not_founds` feild in the response.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setContext(Kvrpcpb.Context.Builder builderForValue)
.kvrpcpb.Context context = 1; |
Kvrpcpb.PessimisticLockRequest.Builder |
setContext(Kvrpcpb.Context value)
.kvrpcpb.Context context = 1; |
Kvrpcpb.PessimisticLockRequest.Builder |
setField(com.google.protobuf.Descriptors.FieldDescriptor field,
Object value) |
Kvrpcpb.PessimisticLockRequest.Builder |
setForce(boolean value)
Deprecated.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setForUpdateTs(long value)
Each locking command in a pessimistic transaction has its own timestamp.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setIsFirstLock(boolean value)
If the request is the first lock request, we don't need to detect deadlock.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setLockTtl(long value)
uint64 lock_ttl = 5; |
Kvrpcpb.PessimisticLockRequest.Builder |
setMinCommitTs(long value)
If min_commit_ts > 0, this is large transaction proto, the final commit_ts
would be infered from min_commit_ts.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setMutations(int index,
Kvrpcpb.Mutation.Builder builderForValue)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setMutations(int index,
Kvrpcpb.Mutation value)
In this case every `Op` of the mutations must be `PessimisticLock`.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setPrimaryLock(com.google.protobuf.ByteString value)
bytes primary_lock = 3; |
Kvrpcpb.PessimisticLockRequest.Builder |
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field,
int index,
Object value) |
Kvrpcpb.PessimisticLockRequest.Builder |
setReturnValues(boolean value)
If it is true, TiKV will return values of the keys if no error, so TiDB can cache the values for
later read in the same transaction.
|
Kvrpcpb.PessimisticLockRequest.Builder |
setStartVersion(long value)
uint64 start_version = 4; |
Kvrpcpb.PessimisticLockRequest.Builder |
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields) |
Kvrpcpb.PessimisticLockRequest.Builder |
setWaitTimeout(long value)
Time to wait for lock released in milliseconds when encountering locks.
|
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, internalGetMapField, internalGetMutableMapField, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
addAll, addAll, mergeFrom, newUninitializedMessageException
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
internalGetFieldAccessorTable
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder clear()
clear
in interface com.google.protobuf.Message.Builder
clear
in interface com.google.protobuf.MessageLite.Builder
clear
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
getDescriptorForType
in interface com.google.protobuf.Message.Builder
getDescriptorForType
in interface com.google.protobuf.MessageOrBuilder
getDescriptorForType
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest getDefaultInstanceForType()
getDefaultInstanceForType
in interface com.google.protobuf.MessageLiteOrBuilder
getDefaultInstanceForType
in interface com.google.protobuf.MessageOrBuilder
public Kvrpcpb.PessimisticLockRequest build()
build
in interface com.google.protobuf.Message.Builder
build
in interface com.google.protobuf.MessageLite.Builder
public Kvrpcpb.PessimisticLockRequest buildPartial()
buildPartial
in interface com.google.protobuf.Message.Builder
buildPartial
in interface com.google.protobuf.MessageLite.Builder
public Kvrpcpb.PessimisticLockRequest.Builder clone()
clone
in interface com.google.protobuf.Message.Builder
clone
in interface com.google.protobuf.MessageLite.Builder
clone
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
setField
in interface com.google.protobuf.Message.Builder
setField
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
clearField
in interface com.google.protobuf.Message.Builder
clearField
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
clearOneof
in interface com.google.protobuf.Message.Builder
clearOneof
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
setRepeatedField
in interface com.google.protobuf.Message.Builder
setRepeatedField
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
addRepeatedField
in interface com.google.protobuf.Message.Builder
addRepeatedField
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder mergeFrom(com.google.protobuf.Message other)
mergeFrom
in interface com.google.protobuf.Message.Builder
mergeFrom
in class com.google.protobuf.AbstractMessage.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder mergeFrom(Kvrpcpb.PessimisticLockRequest other)
public final boolean isInitialized()
isInitialized
in interface com.google.protobuf.MessageLiteOrBuilder
isInitialized
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public Kvrpcpb.PessimisticLockRequest.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
mergeFrom
in interface com.google.protobuf.Message.Builder
mergeFrom
in interface com.google.protobuf.MessageLite.Builder
mergeFrom
in class com.google.protobuf.AbstractMessage.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
IOException
public boolean hasContext()
.kvrpcpb.Context context = 1;
hasContext
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.Context getContext()
.kvrpcpb.Context context = 1;
getContext
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setContext(Kvrpcpb.Context value)
.kvrpcpb.Context context = 1;
public Kvrpcpb.PessimisticLockRequest.Builder setContext(Kvrpcpb.Context.Builder builderForValue)
.kvrpcpb.Context context = 1;
public Kvrpcpb.PessimisticLockRequest.Builder mergeContext(Kvrpcpb.Context value)
.kvrpcpb.Context context = 1;
public Kvrpcpb.PessimisticLockRequest.Builder clearContext()
.kvrpcpb.Context context = 1;
public Kvrpcpb.Context.Builder getContextBuilder()
.kvrpcpb.Context context = 1;
public Kvrpcpb.ContextOrBuilder getContextOrBuilder()
.kvrpcpb.Context context = 1;
getContextOrBuilder
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public List<Kvrpcpb.Mutation> getMutationsList()
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
getMutationsList
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public int getMutationsCount()
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
getMutationsCount
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.Mutation getMutations(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
getMutations
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setMutations(int index, Kvrpcpb.Mutation value)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder setMutations(int index, Kvrpcpb.Mutation.Builder builderForValue)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder addMutations(Kvrpcpb.Mutation value)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder addMutations(int index, Kvrpcpb.Mutation value)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder addMutations(Kvrpcpb.Mutation.Builder builderForValue)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder addMutations(int index, Kvrpcpb.Mutation.Builder builderForValue)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder addAllMutations(Iterable<? extends Kvrpcpb.Mutation> values)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder clearMutations()
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.PessimisticLockRequest.Builder removeMutations(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.Mutation.Builder getMutationsBuilder(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.MutationOrBuilder getMutationsOrBuilder(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
getMutationsOrBuilder
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public List<? extends Kvrpcpb.MutationOrBuilder> getMutationsOrBuilderList()
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
getMutationsOrBuilderList
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.Mutation.Builder addMutationsBuilder()
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public Kvrpcpb.Mutation.Builder addMutationsBuilder(int index)
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public List<Kvrpcpb.Mutation.Builder> getMutationsBuilderList()
In this case every `Op` of the mutations must be `PessimisticLock`.
repeated .kvrpcpb.Mutation mutations = 2;
public com.google.protobuf.ByteString getPrimaryLock()
bytes primary_lock = 3;
getPrimaryLock
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setPrimaryLock(com.google.protobuf.ByteString value)
bytes primary_lock = 3;
value
- The primaryLock to set.public Kvrpcpb.PessimisticLockRequest.Builder clearPrimaryLock()
bytes primary_lock = 3;
public long getStartVersion()
uint64 start_version = 4;
getStartVersion
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setStartVersion(long value)
uint64 start_version = 4;
value
- The startVersion to set.public Kvrpcpb.PessimisticLockRequest.Builder clearStartVersion()
uint64 start_version = 4;
public long getLockTtl()
uint64 lock_ttl = 5;
getLockTtl
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setLockTtl(long value)
uint64 lock_ttl = 5;
value
- The lockTtl to set.public Kvrpcpb.PessimisticLockRequest.Builder clearLockTtl()
uint64 lock_ttl = 5;
public long getForUpdateTs()
Each locking command in a pessimistic transaction has its own timestamp. If locking fails, then the corresponding SQL statement can be retried with a later timestamp, TiDB does not need to retry the whole transaction. The name comes from the `SELECT ... FOR UPDATE` SQL statement which is a locking read. Each `SELECT ... FOR UPDATE` in a transaction will be assigned its own timestamp.
uint64 for_update_ts = 6;
getForUpdateTs
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setForUpdateTs(long value)
Each locking command in a pessimistic transaction has its own timestamp. If locking fails, then the corresponding SQL statement can be retried with a later timestamp, TiDB does not need to retry the whole transaction. The name comes from the `SELECT ... FOR UPDATE` SQL statement which is a locking read. Each `SELECT ... FOR UPDATE` in a transaction will be assigned its own timestamp.
uint64 for_update_ts = 6;
value
- The forUpdateTs to set.public Kvrpcpb.PessimisticLockRequest.Builder clearForUpdateTs()
Each locking command in a pessimistic transaction has its own timestamp. If locking fails, then the corresponding SQL statement can be retried with a later timestamp, TiDB does not need to retry the whole transaction. The name comes from the `SELECT ... FOR UPDATE` SQL statement which is a locking read. Each `SELECT ... FOR UPDATE` in a transaction will be assigned its own timestamp.
uint64 for_update_ts = 6;
public boolean getIsFirstLock()
If the request is the first lock request, we don't need to detect deadlock.
bool is_first_lock = 7;
getIsFirstLock
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setIsFirstLock(boolean value)
If the request is the first lock request, we don't need to detect deadlock.
bool is_first_lock = 7;
value
- The isFirstLock to set.public Kvrpcpb.PessimisticLockRequest.Builder clearIsFirstLock()
If the request is the first lock request, we don't need to detect deadlock.
bool is_first_lock = 7;
public long getWaitTimeout()
Time to wait for lock released in milliseconds when encountering locks. 0 means using default timeout in TiKV. Negative means no wait.
int64 wait_timeout = 8;
getWaitTimeout
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setWaitTimeout(long value)
Time to wait for lock released in milliseconds when encountering locks. 0 means using default timeout in TiKV. Negative means no wait.
int64 wait_timeout = 8;
value
- The waitTimeout to set.public Kvrpcpb.PessimisticLockRequest.Builder clearWaitTimeout()
Time to wait for lock released in milliseconds when encountering locks. 0 means using default timeout in TiKV. Negative means no wait.
int64 wait_timeout = 8;
@Deprecated public boolean getForce()
If it is true, TiKV will acquire the pessimistic lock regardless of write conflict and return the latest value. It's only supported for single mutation.
bool force = 9 [deprecated = true];
getForce
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
@Deprecated public Kvrpcpb.PessimisticLockRequest.Builder setForce(boolean value)
If it is true, TiKV will acquire the pessimistic lock regardless of write conflict and return the latest value. It's only supported for single mutation.
bool force = 9 [deprecated = true];
value
- The force to set.@Deprecated public Kvrpcpb.PessimisticLockRequest.Builder clearForce()
If it is true, TiKV will acquire the pessimistic lock regardless of write conflict and return the latest value. It's only supported for single mutation.
bool force = 9 [deprecated = true];
public boolean getReturnValues()
If it is true, TiKV will return values of the keys if no error, so TiDB can cache the values for later read in the same transaction. When 'force' is set to true, this field is ignored.
bool return_values = 10;
getReturnValues
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setReturnValues(boolean value)
If it is true, TiKV will return values of the keys if no error, so TiDB can cache the values for later read in the same transaction. When 'force' is set to true, this field is ignored.
bool return_values = 10;
value
- The returnValues to set.public Kvrpcpb.PessimisticLockRequest.Builder clearReturnValues()
If it is true, TiKV will return values of the keys if no error, so TiDB can cache the values for later read in the same transaction. When 'force' is set to true, this field is ignored.
bool return_values = 10;
public long getMinCommitTs()
If min_commit_ts > 0, this is large transaction proto, the final commit_ts would be infered from min_commit_ts.
uint64 min_commit_ts = 11;
getMinCommitTs
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setMinCommitTs(long value)
If min_commit_ts > 0, this is large transaction proto, the final commit_ts would be infered from min_commit_ts.
uint64 min_commit_ts = 11;
value
- The minCommitTs to set.public Kvrpcpb.PessimisticLockRequest.Builder clearMinCommitTs()
If min_commit_ts > 0, this is large transaction proto, the final commit_ts would be infered from min_commit_ts.
uint64 min_commit_ts = 11;
public boolean getCheckExistence()
If set to true, it means TiKV need to check if the key exists, and return the result in the `not_founds` feild in the response. This works no matter if `return_values` is set. If `return_values` is set, it simply makes no difference; otherwise, the `value` field of the repsonse will be empty while the `not_founds` field still indicates the keys' existence.
bool check_existence = 12;
getCheckExistence
in interface Kvrpcpb.PessimisticLockRequestOrBuilder
public Kvrpcpb.PessimisticLockRequest.Builder setCheckExistence(boolean value)
If set to true, it means TiKV need to check if the key exists, and return the result in the `not_founds` feild in the response. This works no matter if `return_values` is set. If `return_values` is set, it simply makes no difference; otherwise, the `value` field of the repsonse will be empty while the `not_founds` field still indicates the keys' existence.
bool check_existence = 12;
value
- The checkExistence to set.public Kvrpcpb.PessimisticLockRequest.Builder clearCheckExistence()
If set to true, it means TiKV need to check if the key exists, and return the result in the `not_founds` feild in the response. This works no matter if `return_values` is set. If `return_values` is set, it simply makes no difference; otherwise, the `value` field of the repsonse will be empty while the `not_founds` field still indicates the keys' existence.
bool check_existence = 12;
public final Kvrpcpb.PessimisticLockRequest.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
setUnknownFields
in interface com.google.protobuf.Message.Builder
setUnknownFields
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
public final Kvrpcpb.PessimisticLockRequest.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
mergeUnknownFields
in interface com.google.protobuf.Message.Builder
mergeUnknownFields
in class com.google.protobuf.GeneratedMessageV3.Builder<Kvrpcpb.PessimisticLockRequest.Builder>
Copyright © 2024 PingCAP. All rights reserved.