pub struct Options<'a> {
pub skip_journal_checks: bool,
pub borrow_metadata_space: bool,
pub allocator_reservation: Option<&'a Reservation>,
pub txn_guard: Option<&'a TxnGuard<'a>>,
}
Expand description
This allows for special handling of certain transactions such as deletes and the
extension of Journal extents. For most other use cases it is appropriate to use
default()
here.
Fields§
§skip_journal_checks: bool
If true, don’t check for low journal space. This should be true for any transactions that might alleviate journal space (i.e. compaction).
borrow_metadata_space: bool
If true, borrow metadata space from the metadata reservation. This setting should be set to true for any transaction that will either not affect space usage after compaction (e.g. setting attributes), or reduce space usage (e.g. unlinking). Otherwise, a transaction might fail with an out-of-space error.
allocator_reservation: Option<&'a Reservation>
If specified, a reservation to be used with the transaction. If not set, any allocations that are part of this transaction will have to take their chances, and will fail if there is no free space. The intention is that this should be used for things like the journal which require guaranteed space.
txn_guard: Option<&'a TxnGuard<'a>>
An existing transaction guard to be used.
Trait Implementations§
impl<'a> Copy for Options<'a>
Auto Trait Implementations§
impl<'a> Freeze for Options<'a>
impl<'a> !RefUnwindSafe for Options<'a>
impl<'a> Send for Options<'a>
impl<'a> Sync for Options<'a>
impl<'a> Unpin for Options<'a>
impl<'a> !UnwindSafe for Options<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous1, D> for Twhere
D: ResourceDialect,
Source§impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
impl<T, D> Encode<Ambiguous2, D> for Twhere
D: ResourceDialect,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more