Struct scylla::statement::batch::Batch [−][src]
pub struct Batch {
pub statements: Vec<BatchStatement>,
// some fields omitted
}
Expand description
CQL batch statement.
This represents a CQL batch that can be executed on a server.
Fields
statements: Vec<BatchStatement>
Implementations
Creates a new, empty Batch
of batch_type
type with the provided statements.
Appends a new statement to the batch.
Sets the consistency to be used when executing this batch.
Gets the consistency to be used when executing this batch if it is filled. If this is empty, the default_consistency of the session will be used.
Sets the serial consistency to be used when executing this batch. (Ignored unless the batch is an LWT)
Gets the serial consistency to be used when executing this batch. (Ignored unless the batch is an LWT)
Sets the idempotence of this batch
A query is idempotent if it can be applied multiple times without changing the result of the initial application
If set to true
we can be sure that it is idempotent
If set to false
it is unknown whether it is idempotent
This is used in RetryPolicy
to decide if retrying a query is safe
Gets the idempotence of this batch
Sets a custom RetryPolicy
to be used with this batch
By default Session’s retry policy is used, this allows to use a custom retry policy
Gets custom RetryPolicy
used by this batch
Enable or disable CQL Tracing for this batch If enabled session.batch() will return a BatchResult containing tracing_id which can be used to query tracing information about the execution of this query
Gets whether tracing is enabled for this batch
Sets the default timestamp for this batch in microseconds. If not None, it will replace the server side assigned timestamp as default timestamp for all the statements contained in the batch.
Gets the default timestamp for this batch in microseconds.
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for Batch
impl !UnwindSafe for Batch
Blanket Implementations
Mutably borrows from an owned value. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more