Skip to content
This repository was archived by the owner on Sep 27, 2019. It is now read-only.

Commit e0a9348

Browse files
committed
formatting
1 parent e506f17 commit e0a9348

File tree

1 file changed

+15
-14
lines changed

1 file changed

+15
-14
lines changed

src/concurrency/timestamp_ordering_transaction_manager.cpp

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -171,10 +171,9 @@ void TimestampOrderingTransactionManager::YieldOwnership(
171171
tile_group_header->SetTransactionId(tuple_id, INITIAL_TXN_ID);
172172
}
173173

174-
bool TimestampOrderingTransactionManager::PerformRead(TransactionContext *const current_txn,
175-
const ItemPointer &read_location,
176-
storage::TileGroupHeader *tile_group_header,
177-
bool acquire_ownership) {
174+
bool TimestampOrderingTransactionManager::PerformRead(
175+
TransactionContext *const current_txn, const ItemPointer &read_location,
176+
storage::TileGroupHeader *tile_group_header, bool acquire_ownership) {
178177
ItemPointer location = read_location;
179178

180179
//////////////////////////////////////////////////////////
@@ -374,7 +373,8 @@ void TimestampOrderingTransactionManager::PerformInsert(
374373
oid_t tuple_id = location.offset;
375374

376375
auto storage_manager = storage::StorageManager::GetInstance();
377-
auto tile_group_header = storage_manager->GetTileGroup(tile_group_id)->GetHeader();
376+
auto tile_group_header =
377+
storage_manager->GetTileGroup(tile_group_id)->GetHeader();
378378
auto transaction_id = current_txn->GetTransactionId();
379379

380380
// check MVCC info
@@ -420,9 +420,8 @@ void TimestampOrderingTransactionManager::PerformUpdate(
420420
// version.
421421
PELOTON_ASSERT(tile_group_header->GetTransactionId(old_location.offset) ==
422422
transaction_id);
423-
PELOTON_ASSERT(
424-
tile_group_header->GetPrevItemPointer(old_location.offset).IsNull() ==
425-
true);
423+
PELOTON_ASSERT(tile_group_header->GetPrevItemPointer(old_location.offset)
424+
.IsNull() == true);
426425

427426
// check whether the new version is empty.
428427
PELOTON_ASSERT(new_tile_group_header->GetTransactionId(new_location.offset) ==
@@ -529,9 +528,8 @@ void TimestampOrderingTransactionManager::PerformDelete(
529528
PELOTON_ASSERT(tile_group_header->GetTransactionId(old_location.offset) ==
530529
transaction_id);
531530
// we must be deleting the latest version.
532-
PELOTON_ASSERT(
533-
tile_group_header->GetPrevItemPointer(old_location.offset).IsNull() ==
534-
true);
531+
PELOTON_ASSERT(tile_group_header->GetPrevItemPointer(old_location.offset)
532+
.IsNull() == true);
535533

536534
// check whether the new version is empty.
537535
PELOTON_ASSERT(new_tile_group_header->GetTransactionId(new_location.offset) ==
@@ -588,7 +586,8 @@ void TimestampOrderingTransactionManager::PerformDelete(
588586
oid_t tuple_id = location.offset;
589587

590588
auto storage_manager = storage::StorageManager::GetInstance();
591-
auto tile_group_header = storage_manager->GetTileGroup(tile_group_id)->GetHeader();
589+
auto tile_group_header =
590+
storage_manager->GetTileGroup(tile_group_id)->GetHeader();
592591

593592
PELOTON_ASSERT(tile_group_header->GetTransactionId(tuple_id) ==
594593
current_txn->GetTransactionId());
@@ -660,7 +659,8 @@ ResultType TimestampOrderingTransactionManager::CommitTransaction(
660659
oid_t tile_group_id = item_ptr.block;
661660
oid_t tuple_slot = item_ptr.offset;
662661

663-
auto tile_group_header = storage_manager->GetTileGroup(tile_group_id)->GetHeader();
662+
auto tile_group_header =
663+
storage_manager->GetTileGroup(tile_group_id)->GetHeader();
664664

665665
if (tuple_entry.second == RWType::READ_OWN) {
666666
// A read operation has acquired ownership but hasn't done any further
@@ -811,7 +811,8 @@ ResultType TimestampOrderingTransactionManager::AbortTransaction(
811811
ItemPointer item_ptr = tuple_entry.first;
812812
oid_t tile_group_id = item_ptr.block;
813813
oid_t tuple_slot = item_ptr.offset;
814-
auto tile_group_header = storage_manager->GetTileGroup(tile_group_id)->GetHeader();
814+
auto tile_group_header =
815+
storage_manager->GetTileGroup(tile_group_id)->GetHeader();
815816

816817
if (tuple_entry.second == RWType::READ_OWN) {
817818
// A read operation has acquired ownership but hasn't done any further

0 commit comments

Comments
 (0)