diff --git a/crates/core/src/db/datastore/locking_tx_datastore/datastore.rs b/crates/core/src/db/datastore/locking_tx_datastore/datastore.rs index 51daae1976..31aa01df83 100644 --- a/crates/core/src/db/datastore/locking_tx_datastore/datastore.rs +++ b/crates/core/src/db/datastore/locking_tx_datastore/datastore.rs @@ -1179,19 +1179,6 @@ mod tests { .collect() } - //TODO(shub), begin_tx is not yet implemented for Tx, creating this utility for tests. - fn begin_tx(db: &Locking) -> TxId { - let timer = Instant::now(); - - let committed_state_shared_lock = db.committed_state.read_arc(); - let lock_wait_time = timer.elapsed(); - TxId { - committed_state_shared_lock, - lock_wait_time, - timer, - } - } - fn all_rows_tx(tx: &TxId, table_id: TableId) -> Vec { tx.iter(&ExecutionContext::default(), table_id) .unwrap() @@ -1837,8 +1824,8 @@ mod tests { datastore.commit_mut_tx_for_test(tx)?; // create multiple read only tx, and use them together. - let read_tx_1 = begin_tx(&datastore); - let read_tx_2 = begin_tx(&datastore); + let read_tx_1 = datastore.begin_tx(); + let read_tx_2 = datastore.begin_tx(); let rows = &[row1, row2]; assert_eq!(&all_rows_tx(&read_tx_2, table_id), rows); assert_eq!(&all_rows_tx(&read_tx_1, table_id), rows); diff --git a/crates/core/src/subscription/module_subscription_actor.rs b/crates/core/src/subscription/module_subscription_actor.rs index e8b7dfca51..2dc9786b15 100644 --- a/crates/core/src/subscription/module_subscription_actor.rs +++ b/crates/core/src/subscription/module_subscription_actor.rs @@ -53,7 +53,6 @@ impl ModuleSubscriptions { let tx = scopeguard::guard(self.relational_db.begin_tx(), |tx| { self.relational_db.release_tx(&ctx, tx); }); - // check for backward comp. let request_id = subscription.request_id; let auth = AuthCtx::new(self.owner_identity, sender.id.identity); let mut queries = vec![];