@NotMutable @ThreadSafety(level=COMPLETELY_THREADSAFE) public final class TransactionSettingsRequestControl extends Control
NOTE: This class, and other classes within the
com.unboundid.ldap.sdk.unboundidds
package structure, are only
supported for use against Ping Identity, UnboundID, and
Nokia/Alcatel-Lucent 8661 server products. These classes provide support
for proprietary functionality or for external specifications that are not
considered stable or mature enough to be guaranteed to work in an
interoperable way with other types of LDAP servers.
true
(in which case the server will reject the
associated operation if this control is not recognized) or false
(in
which case the server will ignore this control if it is not recognized). It
must have a value with the following encoding:
TransactionSettingsRequestValue ::= SEQUENCE { transactionName [0] OCTET STRING OPTIONAL, commitDurability [1] ENUMERATED { nonSynchronous (0), partiallySynchronous (1), fullySynchronous (2), ... } OPTIONAL, backendLockBehavior [2] ENUMERATED { doNotAcquire (0), acquireAfterRetries (1), acquireBeforeRetries (2), acquireBeforeInitialAttempt (3), ... } OPTIONAL, backendLockTimeoutMillis [3] INTEGER OPTIONAL, retryAttempts [4] INTEGER OPTIONAL, txnLockTimeout [5] SEQUENCE { minTimeoutMillis INTEGER, maxTimeoutMillis INTEGER, ... } OPTIONAL, returnResponseControl [6] BOOLEAN DEFAULT FALSE, ... }
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
TRANSACTION_SETTINGS_REQUEST_OID
The OID (1.3.6.1.4.1.30221.2.5.38) for the undelete request control.
|
Constructor and Description |
---|
TransactionSettingsRequestControl(boolean isCritical,
java.lang.String transactionName,
TransactionSettingsCommitDurability commitDurability,
TransactionSettingsBackendLockBehavior backendLockBehavior,
java.lang.Long backendLockTimeoutMillis,
java.lang.Integer retryAttempts,
java.lang.Long minTxnLockTimeoutMillis,
java.lang.Long maxTxnLockTimeoutMillis)
Creates a new transaction settings request control with the provided
information.
|
TransactionSettingsRequestControl(boolean isCritical,
java.lang.String transactionName,
TransactionSettingsCommitDurability commitDurability,
TransactionSettingsBackendLockBehavior backendLockBehavior,
java.lang.Long backendLockTimeoutMillis,
java.lang.Integer retryAttempts,
java.lang.Long minTxnLockTimeoutMillis,
java.lang.Long maxTxnLockTimeoutMillis,
boolean returnResponseControl)
Creates a new transaction settings request control with the provided
information.
|
TransactionSettingsRequestControl(Control c)
Creates a new transaction settings request control that is decoded from the
provided generic control.
|
Modifier and Type | Method and Description |
---|---|
TransactionSettingsBackendLockBehavior |
getBackendLockBehavior()
Retrieves the backend lock behavior that should be used for the associated
transaction, if specified.
|
java.lang.Long |
getBackendLockTimeoutMillis()
Retrieves the backend lock timeout (in milliseconds) that should be used
for the associated transaction, if specified.
|
TransactionSettingsCommitDurability |
getCommitDurability()
Retrieves the commit durability that should be used for the associated
transaction, if specified.
|
java.lang.String |
getControlName()
Retrieves the user-friendly name for this control, if available.
|
java.lang.Long |
getMaxTxnLockTimeoutMillis()
Retrieves the maximum transaction lock timeout (in milliseconds) that
should be used for the associated transaction, if specified.
|
java.lang.Long |
getMinTxnLockTimeoutMillis()
Retrieves the minimum transaction lock timeout (in milliseconds) that
should be used for the associated transaction, if specified.
|
java.lang.Integer |
getRetryAttempts()
Retrieves the maximum number of times that the transaction may be retried
if the initial attempt fails due to a lock conflict, if specified.
|
java.lang.String |
getTransactionName()
Retrieves the name to assign to the associated transaction, if specified.
|
boolean |
returnResponseControl()
Indicates whether to return a response control with transaction-related
information collected over the course of processing the associated
operation.
|
void |
toString(java.lang.StringBuilder buffer)
Appends a string representation of this LDAP control to the provided
buffer.
|
decode, decode, decodeControls, decodeJSONControl, deregisterDecodeableControl, encode, encodeControls, equals, getOID, getValue, hashCode, hasValue, isCritical, readFrom, registerDecodeableControl, registerDecodeableControl, toJSONControl, toString, writeTo
@NotNull public static final java.lang.String TRANSACTION_SETTINGS_REQUEST_OID
public TransactionSettingsRequestControl(boolean isCritical, @Nullable java.lang.String transactionName, @Nullable TransactionSettingsCommitDurability commitDurability, @Nullable TransactionSettingsBackendLockBehavior backendLockBehavior, @Nullable java.lang.Long backendLockTimeoutMillis, @Nullable java.lang.Integer retryAttempts, @Nullable java.lang.Long minTxnLockTimeoutMillis, @Nullable java.lang.Long maxTxnLockTimeoutMillis)
isCritical
- Indicates whether the control should be
considered critical.transactionName
- The name to use for the transaction. It
may be null
if no
client-specified transaction name is
needed. If a transaction name is
provided, it will be used purely for
informational and/or troubleshooting
purposes.commitDurability
- The durability level that should be used
when committing the associated
transaction. It may be null
if
the server-default durability level
should be used.backendLockBehavior
- The behavior that should be used with
regard to acquiring an exclusive lock for
processing in the target backend. It may
be null
if the server-default
backend lock behavior should be used.backendLockTimeoutMillis
- The maximum length of time in
milliseconds to spend attempting to
acquire an exclusive backend lock if it
is needed during any part of the
processing. A value that of zero
indicates that no timeout should be
enforced. It may be null
if the
server will determine the backend lock
timeout that should be used.retryAttempts
- The number of times to retry the
associated operations in a new
transaction if the initial attempt fails.
If this is null
, then the server
will determine the number of retry
attempts to make. Note that depending on
the backend lock behavior, the server may
make one additional retry attempt if
necessary after acquiring an exclusive
backend lock.minTxnLockTimeoutMillis
- The minimum database lock timeout that
should be used for the associated
transaction. If this is specified, then
the first attempt will use this lock
timeout, and subsequent attempts will use
a timeout value between this and the
maximum database lock timeout (which must
also be specified). If this is
null
, then the server will
determine the database lock timeout
settings to use.maxTxnLockTimeoutMillis
- The maximum database lock timeout that
should be used for the associated
transaction. If this is specified, then
the minimum database lock timeout must
also be specified, and this value must be
greater than or equal to the minimum lock
timeout. If this is null
, then
the server will determine the database
lock timeout settings to use.public TransactionSettingsRequestControl(boolean isCritical, @Nullable java.lang.String transactionName, @Nullable TransactionSettingsCommitDurability commitDurability, @Nullable TransactionSettingsBackendLockBehavior backendLockBehavior, @Nullable java.lang.Long backendLockTimeoutMillis, @Nullable java.lang.Integer retryAttempts, @Nullable java.lang.Long minTxnLockTimeoutMillis, @Nullable java.lang.Long maxTxnLockTimeoutMillis, boolean returnResponseControl)
isCritical
- Indicates whether the control should be
considered critical.transactionName
- The name to use for the transaction. It
may be null
if no
client-specified transaction name is
needed. If a transaction name is
provided, it will be used purely for
informational and/or troubleshooting
purposes.commitDurability
- The durability level that should be used
when committing the associated
transaction. It may be null
if
the server-default durability level
should be used.backendLockBehavior
- The behavior that should be used with
regard to acquiring an exclusive lock for
processing in the target backend. It may
be null
if the server-default
backend lock behavior should be used.backendLockTimeoutMillis
- The maximum length of time in
milliseconds to spend attempting to
acquire an exclusive backend lock if it
is needed during any part of the
processing. A value that of zero
indicates that no timeout should be
enforced. It may be null
if the
server will determine the backend lock
timeout that should be used.retryAttempts
- The number of times to retry the
associated operations in a new
transaction if the initial attempt fails.
If this is null
, then the server
will determine the number of retry
attempts to make. Note that depending on
the backend lock behavior, the server may
make one additional retry attempt if
necessary after acquiring an exclusive
backend lock.minTxnLockTimeoutMillis
- The minimum database lock timeout that
should be used for the associated
transaction. If this is specified, then
the first attempt will use this lock
timeout, and subsequent attempts will use
a timeout value between this and the
maximum database lock timeout (which must
also be specified). If this is
null
, then the server will
determine the database lock timeout
settings to use.maxTxnLockTimeoutMillis
- The maximum database lock timeout that
should be used for the associated
transaction. If this is specified, then
the minimum database lock timeout must
also be specified, and this value must be
greater than or equal to the minimum lock
timeout. If this is null
, then
the server will determine the database
lock timeout settings to use.returnResponseControl
- Indicates whether to return a response
control with transaction-related
information collected over the course of
processing the associated operation.public TransactionSettingsRequestControl(@NotNull Control c) throws LDAPException
c
- The generic control to decode as a transaction settings request
control.LDAPException
- If a problem is encountered while attempting to
decode the provided control as a transaction
settings request control.@Nullable public java.lang.String getTransactionName()
null
if none has been specified.@Nullable public TransactionSettingsCommitDurability getCommitDurability()
null
if none has been specified and the
server should determine the commit durability.@Nullable public TransactionSettingsBackendLockBehavior getBackendLockBehavior()
null
if none has been specified and the
server should determine the backend lock behavior.@Nullable public java.lang.Long getBackendLockTimeoutMillis()
null
if none has been
specified and the server should determine the backend lock
timeout.@Nullable public java.lang.Integer getRetryAttempts()
null
if none has been specified and the server should determine the
number of retry attempts.@Nullable public java.lang.Long getMinTxnLockTimeoutMillis()
null
if none
has been specified and the server should determine the minimum
transaction lock timeout.@Nullable public java.lang.Long getMaxTxnLockTimeoutMillis()
null
if none
has been specified and the server should determine the maximum
transaction lock timeout.public boolean returnResponseControl()
true
if the server should return a response control with
transaction-related information, or false
if not.@NotNull public java.lang.String getControlName()
getControlName
in class Control