Skip to content

Commit

Permalink
memory markup for detect leak from flat_executor (ydb-platform#3711)
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanmorozov333 authored Apr 13, 2024
1 parent 3684d50 commit edb94a2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ydb/core/tx/columnshard/blobs_action/transaction/tx_write.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ bool TTxWrite::InsertOneBlob(TTransactionContext& txc, const NOlap::TWideSeriali
}

bool TTxWrite::Execute(TTransactionContext& txc, const TActorContext&) {
TMemoryProfileGuard mpg("TTxWrite::Execute");
NActors::TLogContextGuard logGuard = NActors::TLogContextBuilder::Build(NKikimrServices::TX_COLUMNSHARD)("tablet_id", Self->TabletID())("tx_state", "execute");
ACFL_DEBUG("event", "start_execute");
const NOlap::TWritingBuffer& buffer = PutBlobResult->Get()->MutableWritesBuffer();
Expand Down Expand Up @@ -114,6 +115,7 @@ void TTxWrite::OnProposeError(TTxController::TProposeResult& proposeResult, cons
}

void TTxWrite::Complete(const TActorContext& ctx) {
TMemoryProfileGuard mpg("TTxWrite::Complete");
NActors::TLogContextGuard logGuard = NActors::TLogContextBuilder::Build(NKikimrServices::TX_COLUMNSHARD)("tablet_id", Self->TabletID())("tx_state", "complete");
const auto now = TMonotonic::Now();
const NOlap::TWritingBuffer& buffer = PutBlobResult->Get()->MutableWritesBuffer();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ namespace NKikimr::NColumnShard {

bool TTxWriteIndex::Execute(TTransactionContext& txc, const TActorContext& ctx) {
auto changes = Ev->Get()->IndexChanges;
TMemoryProfileGuard mpg("TTxWriteIndex::Execute::" + changes->TypeString());
TLogContextGuard gLogging = NActors::TLogContextBuilder::Build(NKikimrServices::TX_COLUMNSHARD)("tablet_id", Self->TabletID())("external_task_id", changes->GetTaskIdentifier());
Y_ABORT_UNLESS(Self->InsertTable);
Y_ABORT_UNLESS(Self->TablesManager.HasPrimaryIndex());
Expand Down Expand Up @@ -52,6 +53,7 @@ void TTxWriteIndex::Complete(const TActorContext& ctx) {
TLogContextGuard gLogging(NActors::TLogContextBuilder::Build(NKikimrServices::TX_COLUMNSHARD)("tablet_id", Self->TabletID()));
CompleteReady = true;
auto changes = Ev->Get()->IndexChanges;
TMemoryProfileGuard mpg("TTxWriteIndex::Complete::" + changes->TypeString());
ACFL_DEBUG("event", "TTxWriteIndex::Complete")("change_type", changes->TypeString())("details", changes->DebugString());

const ui64 blobsWritten = changes->GetBlobsAction().GetWritingBlobsCount();
Expand Down

0 comments on commit edb94a2

Please sign in to comment.