Skip to content

Commit b20de39

Browse files
committed
style: formatting
1 parent ec24038 commit b20de39

File tree

5 files changed

+15
-11
lines changed

5 files changed

+15
-11
lines changed

storage/src/rocksdb_storage/storage.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,12 +48,12 @@ use super::{
4848
PrefixedRocksDbImmediateStorageContext, PrefixedRocksDbStorageContext,
4949
PrefixedRocksDbTransactionContext,
5050
};
51-
use crate::Error::StorageError;
5251
use crate::{
5352
error,
5453
error::Error::{CostError, RocksDBError},
5554
storage::AbstractBatchOperation,
5655
worst_case_costs::WorstKeyLength,
56+
Error::StorageError,
5757
Storage, StorageBatch,
5858
};
5959

@@ -512,10 +512,10 @@ impl RocksDbStorage {
512512
}
513513

514514
impl<'db> Storage<'db> for RocksDbStorage {
515-
type Transaction = Tx<'db>;
516515
type BatchStorageContext = PrefixedRocksDbStorageContext<'db>;
517516
type BatchTransactionalStorageContext = PrefixedRocksDbTransactionContext<'db>;
518517
type ImmediateStorageContext = PrefixedRocksDbImmediateStorageContext<'db>;
518+
type Transaction = Tx<'db>;
519519

520520
fn start_transaction(&'db self) -> Self::Transaction {
521521
match self {

storage/src/rocksdb_storage/storage_context/context_immediate.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,12 @@ use grovedb_costs::{
3636
use rocksdb::{ColumnFamily, OptimisticTransactionDB, WriteBatchWithTransaction};
3737

3838
use super::{make_prefixed_key, PrefixedRocksDbBatch, PrefixedRocksDbRawIterator};
39-
use crate::rocksdb_storage::storage::NonTransactionalDb;
4039
use crate::{
4140
error,
4241
error::Error::RocksDBError,
43-
rocksdb_storage::storage::{SubtreePrefix, Tx, AUX_CF_NAME, META_CF_NAME, ROOTS_CF_NAME},
42+
rocksdb_storage::storage::{
43+
NonTransactionalDb, SubtreePrefix, Tx, AUX_CF_NAME, META_CF_NAME, ROOTS_CF_NAME,
44+
},
4445
StorageContext,
4546
};
4647

storage/src/rocksdb_storage/storage_context/context_no_tx.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,12 @@ use grovedb_costs::{
3636
use rocksdb::{ColumnFamily, OptimisticTransactionDB};
3737

3838
use super::{batch::PrefixedMultiContextBatchPart, make_prefixed_key, PrefixedRocksDbRawIterator};
39-
use crate::rocksdb_storage::storage::NonTransactionalDb;
4039
use crate::{
4140
error,
4241
error::Error::RocksDBError,
43-
rocksdb_storage::storage::{SubtreePrefix, AUX_CF_NAME, META_CF_NAME, ROOTS_CF_NAME},
42+
rocksdb_storage::storage::{
43+
NonTransactionalDb, SubtreePrefix, AUX_CF_NAME, META_CF_NAME, ROOTS_CF_NAME,
44+
},
4445
StorageBatch, StorageContext,
4546
};
4647

storage/src/rocksdb_storage/storage_context/context_tx.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,15 @@ use grovedb_costs::{
3636
use rocksdb::{ColumnFamily, OptimisticTransactionDB};
3737

3838
use super::{batch::PrefixedMultiContextBatchPart, make_prefixed_key, PrefixedRocksDbRawIterator};
39-
use crate::rocksdb_storage::storage::NonTransactionalDb;
40-
use crate::rocksdb_storage::storage_context::context_no_tx::PrefixedSecondaryRocksDbStorageContext;
4139
use crate::{
4240
error,
4341
error::Error::RocksDBError,
44-
rocksdb_storage::storage::{SubtreePrefix, Tx, AUX_CF_NAME, META_CF_NAME, ROOTS_CF_NAME},
42+
rocksdb_storage::{
43+
storage::{
44+
NonTransactionalDb, SubtreePrefix, Tx, AUX_CF_NAME, META_CF_NAME, ROOTS_CF_NAME,
45+
},
46+
storage_context::context_no_tx::PrefixedSecondaryRocksDbStorageContext,
47+
},
4548
RawIterator, StorageBatch, StorageContext,
4649
};
4750

storage/src/rocksdb_storage/test_utils.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@
2828

2929
//! Useful utilities for testing.
3030
31-
use std::cell::RefCell;
32-
use std::ops::Deref;
31+
use std::{cell::RefCell, ops::Deref};
3332

3433
use tempfile::TempDir;
3534

0 commit comments

Comments
 (0)