Package io.sentry
Class TransactionOptions
java.lang.Object
io.sentry.SpanOptions
io.sentry.TransactionOptions
Sentry Transaction options
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@Nullable CustomSamplingContextGets the customSamplingContext@Nullable LongGets the deadlineTimeout@Nullable LongGets the idleTimeout@Nullable SentryDateGets the startTimestamp@Nullable TransactionFinishedCallbackGets the transactionFinishedCallback callbackbooleanbooleanChecks if bindToScope is enabledbooleanChecks if waitForChildren is enabledvoidsetAppStartTransaction(boolean appStartTransaction) voidsetBindToScope(boolean bindToScope) Sets bindToScope to enabled or disabledvoidsetCustomSamplingContext(@Nullable CustomSamplingContext customSamplingContext) Sets the customSamplingContextvoidsetDeadlineTimeout(@Nullable Long deadlineTimeoutMs) Sets the deadlineTimeout.voidsetIdleTimeout(@Nullable Long idleTimeout) Sets the idleTimeoutvoidsetStartTimestamp(@Nullable SentryDate startTimestamp) Sets the startTimestampvoidsetTransactionFinishedCallback(@Nullable TransactionFinishedCallback transactionFinishedCallback) Sets the transactionFinishedCallback callbackvoidsetWaitForChildren(boolean waitForChildren) Sets waitForChildren to enabled or disabledMethods inherited from class io.sentry.SpanOptions
isIdle, isTrimEnd, isTrimStart, setIdle, setTrimEnd, setTrimStart
-
Field Details
-
DEFAULT_DEADLINE_TIMEOUT_AUTO_TRANSACTION
@Internal public static final long DEFAULT_DEADLINE_TIMEOUT_AUTO_TRANSACTION- See Also:
-
-
Constructor Details
-
TransactionOptions
public TransactionOptions()
-
-
Method Details
-
getCustomSamplingContext
Gets the customSamplingContext- Returns:
- customSamplingContext - the customSamplingContext
-
setCustomSamplingContext
public void setCustomSamplingContext(@Nullable @Nullable CustomSamplingContext customSamplingContext) Sets the customSamplingContext- Parameters:
customSamplingContext- - the customSamplingContext
-
isBindToScope
public boolean isBindToScope()Checks if bindToScope is enabled- Returns:
- true if enabled or false otherwise
-
setBindToScope
public void setBindToScope(boolean bindToScope) Sets bindToScope to enabled or disabled- Parameters:
bindToScope- true if enabled or false otherwise
-
getStartTimestamp
Gets the startTimestamp- Returns:
- startTimestamp - the startTimestamp
-
setStartTimestamp
Sets the startTimestamp- Parameters:
startTimestamp- - the startTimestamp
-
isWaitForChildren
public boolean isWaitForChildren()Checks if waitForChildren is enabled- Returns:
- true if enabled or false otherwise
-
setWaitForChildren
public void setWaitForChildren(boolean waitForChildren) Sets waitForChildren to enabled or disabled- Parameters:
waitForChildren- true if enabled or false otherwise
-
getIdleTimeout
Gets the idleTimeout- Returns:
- idleTimeout - the idleTimeout
-
setDeadlineTimeout
Sets the deadlineTimeout. If set, an transaction and it's child spans will be force-finished with statusSpanStatus.DEADLINE_EXCEEDEDin case the transaction isn't finished in time.- Parameters:
deadlineTimeoutMs- - the deadlineTimeout, in ms - or null if no deadline should be set
-
getDeadlineTimeout
Gets the deadlineTimeout- Returns:
- deadlineTimeout - the deadlineTimeout, in ms - or null if no deadline is set
-
setIdleTimeout
Sets the idleTimeout- Parameters:
idleTimeout- - the idleTimeout
-
getTransactionFinishedCallback
Gets the transactionFinishedCallback callback- Returns:
- transactionFinishedCallback - the transactionFinishedCallback callback
-
setTransactionFinishedCallback
public void setTransactionFinishedCallback(@Nullable @Nullable TransactionFinishedCallback transactionFinishedCallback) Sets the transactionFinishedCallback callback- Parameters:
transactionFinishedCallback- - the transactionFinishedCallback callback
-
setAppStartTransaction
@Internal public void setAppStartTransaction(boolean appStartTransaction) -
isAppStartTransaction
@Internal public boolean isAppStartTransaction()
-