Struct qldb::Transaction [−][src]
pub struct Transaction { /* fields omitted */ }
Expand description
Every query in QLDB is within a transaction. Ideally you will interact with this object via the method QLDBClient::transaction_within.
Implementations
Sends a query to QLDB. It will return an Array of IonValues already decoded. Parameters need to be provided using IonValue.
Cancels the transaction. Once rollback is called the transaction becomes invalid. Subsequent calls to rollback or commit (internally) won’t have any effect.
It fails is the transaction is already committed. For
a rollback that doesn’t fail when already committed you can
check the silent_rollback
method.
Cancels the transaction but it doesn’t fails is the transaction was already committed. This is useful for auto-closing scenarios where you just want to rollback always when there is a drop or something similar.
Once rollback is called the transaction becomes invalid. Subsequent calls to rollback or commit (internally) won’t have any effect.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Transaction
impl Send for Transaction
impl Sync for Transaction
impl Unpin for Transaction
impl !UnwindSafe for Transaction
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Output = T
type Output = T
Should always be Self