mirror of
https://github.com/aljazceru/turso.git
synced 2026-02-18 14:35:14 +01:00
merge conflicts with atomics PRs
This commit is contained in:
@@ -1357,11 +1357,11 @@ impl<Clock: LogicalClock> MvStore<Clock> {
|
||||
}
|
||||
}
|
||||
|
||||
if connection.schema.borrow().schema_version
|
||||
if connection.schema.read().schema_version
|
||||
> connection.db.schema.lock().unwrap().schema_version
|
||||
{
|
||||
// Connection made schema changes during tx and rolled back -> revert connection-local schema.
|
||||
connection.schema.replace(connection.db.clone_schema()?);
|
||||
*connection.schema.write() = connection.db.clone_schema()?;
|
||||
}
|
||||
|
||||
let tx = tx_unlocked.value();
|
||||
|
||||
@@ -2282,14 +2282,6 @@ pub fn op_transaction_inner(
|
||||
// Programs can run Transaction twice, first with read flag and then with write flag. So a single txid is enough
|
||||
// for both.
|
||||
if program.connection.mv_tx.get().is_none() {
|
||||
// We allocate the first page lazily in the first transaction.
|
||||
// TODO: when we fix MVCC enable schema cookie detection for reprepare statements
|
||||
// let header_schema_cookie = pager
|
||||
// .io
|
||||
// .block(|| pager.with_header(|header| header.schema_cookie.get()))?;
|
||||
// if header_schema_cookie != *schema_cookie {
|
||||
// return Err(LimboError::SchemaUpdated);
|
||||
// }
|
||||
let tx_id = match tx_mode {
|
||||
TransactionMode::None
|
||||
| TransactionMode::Read
|
||||
|
||||
Reference in New Issue
Block a user