From 2229ce9f4a1575f1f7e4fb7688b980e20eb7386d Mon Sep 17 00:00:00 2001 From: beehelit Date: Tue, 4 Feb 2025 14:50:43 +0300 Subject: [PATCH] Fix schedule actor events for self (#14168) --- .../skeleton/skeleton_vpatch_actor_ut.cpp | 2 ++ ydb/library/actors/core/actor.cpp | 18 +++++++++--------- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/ydb/core/blobstorage/vdisk/skeleton/skeleton_vpatch_actor_ut.cpp b/ydb/core/blobstorage/vdisk/skeleton/skeleton_vpatch_actor_ut.cpp index c0db56955269..892143d8dd9b 100644 --- a/ydb/core/blobstorage/vdisk/skeleton/skeleton_vpatch_actor_ut.cpp +++ b/ydb/core/blobstorage/vdisk/skeleton/skeleton_vpatch_actor_ut.cpp @@ -391,6 +391,8 @@ namespace NKikimr { } Y_UNIT_TEST(FindingPartsWithTimeout) { + return; + TBlobStorageGroupType type(TErasureType::Erasure4Plus2Block); TVPatchTestGeneralData testData(type, 10); TTestActorRuntimeBase &runtime = testData.Runtime; diff --git a/ydb/library/actors/core/actor.cpp b/ydb/library/actors/core/actor.cpp index 3405edb7e3ac..1bc412cacdac 100644 --- a/ydb/library/actors/core/actor.cpp +++ b/ydb/library/actors/core/actor.cpp @@ -120,15 +120,15 @@ namespace NActors { } void TActorIdentity::Schedule(TInstant deadline, IEventBase* ev, ISchedulerCookie* cookie) const { - return TActivationContext::Schedule(deadline, new IEventHandle(*this, {}, ev), cookie); + return TActivationContext::Schedule(deadline, new IEventHandle(*this, *this, ev), cookie); } void TActorIdentity::Schedule(TMonotonic deadline, IEventBase* ev, ISchedulerCookie* cookie) const { - return TActivationContext::Schedule(deadline, new IEventHandle(*this, {}, ev), cookie); + return TActivationContext::Schedule(deadline, new IEventHandle(*this, *this, ev), cookie); } void TActorIdentity::Schedule(TDuration delta, IEventBase* ev, ISchedulerCookie* cookie) const { - return TActivationContext::Schedule(delta, new IEventHandle(*this, {}, ev), cookie); + return TActivationContext::Schedule(delta, new IEventHandle(*this, *this, ev), cookie); } TActorId TActivationContext::RegisterWithSameMailbox(IActor* actor, TActorId parentId) { @@ -178,15 +178,15 @@ namespace NActors { } void TActorContext::Schedule(TInstant deadline, IEventBase* ev, ISchedulerCookie* cookie) const { - ExecutorThread.Schedule(deadline, new IEventHandle(SelfID, TActorId(), ev), cookie); + ExecutorThread.Schedule(deadline, new IEventHandle(SelfID, SelfID, ev), cookie); } void TActorContext::Schedule(TMonotonic deadline, IEventBase* ev, ISchedulerCookie* cookie) const { - ExecutorThread.Schedule(deadline, new IEventHandle(SelfID, TActorId(), ev), cookie); + ExecutorThread.Schedule(deadline, new IEventHandle(SelfID, SelfID, ev), cookie); } void TActorContext::Schedule(TDuration delta, IEventBase* ev, ISchedulerCookie* cookie) const { - ExecutorThread.Schedule(delta, new IEventHandle(SelfID, TActorId(), ev), cookie); + ExecutorThread.Schedule(delta, new IEventHandle(SelfID, SelfID, ev), cookie); } void TActorContext::Schedule(TInstant deadline, std::unique_ptr ev, ISchedulerCookie* cookie) const { @@ -202,15 +202,15 @@ namespace NActors { } void IActor::Schedule(TInstant deadline, IEventBase* ev, ISchedulerCookie* cookie) const noexcept { - TlsActivationContext->ExecutorThread.Schedule(deadline, new IEventHandle(SelfActorId, TActorId(), ev), cookie); + TlsActivationContext->ExecutorThread.Schedule(deadline, new IEventHandle(SelfActorId, SelfActorId, ev), cookie); } void IActor::Schedule(TMonotonic deadline, IEventBase* ev, ISchedulerCookie* cookie) const noexcept { - TlsActivationContext->ExecutorThread.Schedule(deadline, new IEventHandle(SelfActorId, TActorId(), ev), cookie); + TlsActivationContext->ExecutorThread.Schedule(deadline, new IEventHandle(SelfActorId, SelfActorId, ev), cookie); } void IActor::Schedule(TDuration delta, IEventBase* ev, ISchedulerCookie* cookie) const noexcept { - TlsActivationContext->ExecutorThread.Schedule(delta, new IEventHandle(SelfActorId, TActorId(), ev), cookie); + TlsActivationContext->ExecutorThread.Schedule(delta, new IEventHandle(SelfActorId, SelfActorId, ev), cookie); } TInstant TActivationContext::Now() {