You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cause:[akka://test/user/b#653027469]: Akka.Actor.ActorInitializationException: Exception during creation---> System.InvalidOperationException:Worker in invalid state:1
at Akka.Actor.HashedWheelTimerScheduler.Start()
at Akka.Actor.HashedWheelTimerScheduler.InternalSchedule(TimeSpandelay,TimeSpaninterval,IRunnableaction,ICancelablecancelable)
at Akka.Actor.HashedWheelTimerScheduler.InternalScheduleTellOnce(TimeSpandelay,ICanTellreceiver,Objectmessage,IActorRefsender,ICancelablecancelable)
at Akka.Actor.SchedulerBase.Akka.Actor.ITellScheduler.ScheduleTellOnce(TimeSpandelay,ICanTellreceiver,Objectmessage,IActorRefsender,ICancelablecancelable)
at Akka.Actor.SchedulerExtensions.ScheduleTellOnceCancelable(ISchedulerscheduler,TimeSpandelay,ICanTellreceiver,Objectmessage,IActorRefsender)
at Akka.Actor.Scheduler.TimerScheduler.StartTimer(Objectkey,Objectmsg,TimeSpantimeout,TimeSpaninitialDelay,Booleanrepeat)
at Akka.Actor.Scheduler.TimerScheduler.StartSingleTimer(Objectkey,Objectmsg,TimeSpantimeout)
Version Information
Version of Akka.NET?
1.5.13
Which Akka.NET Modules?
Akka.Actor.Scheduler.TimerScheduler
Akka.Actor.HashedWheelTimerScheduler
Describe the bug
I am running my tests. I am using the "Run Until Failure" menu item in the test explorer menu.
The tests always fail. Usually only after a few iterations (at around 70 iterations).
Last test log:
Test run finished: 119 Tests (118 Passed, 1 Failed, 0 Skipped) run in 15.9 min. Finished at iteration 127
To Reproduce
Steps to reproduce the behavior:
In my app, many things happen, but the essence of the bug (i did not write a separate test for this - so take it as an unproved theory):
create actor and start timer in prestart
"Run Until Failure" menu item in the test explorer menu
See error after many iterations
Expected behavior
I expect this exception to NOT happen. And for the tests iterations to continue.
Actual behavior
Test stops after a few iterations.
Environment
running on Windows.
Which version of .NET?
"Welcome to .NET 7.0!
SDK Version: 7.0.403"
The text was updated successfully, but these errors were encountered:
asyncTaskMain(){// Initialize Actor Systemvarsystem=ActorSystem.Create("MySystem");// Create Props for the EchoActorvarprops=Props.Create<EchoActor>();// Create the EchoActorvarechoActor=system.ActorOf(props,"echoActor");// Send 10 messages to the EchoActorfor(inti=0;i<10;i++){echoActor.Tell($"Message {i+1}");}// Allow some time for messages to process before shutting downawaitsystem.WhenTerminated;}// Define the EchoActor classpublicclassEchoActor:ReceiveActor,IWithTimers{privatereadonlyILoggingAdapter_log=Context.GetLogger();privateint_msgCount=0;publicITimerSchedulerTimers{get;set;}publicEchoActor(){NormalBehavior();}privatevoidNormalBehavior(){ReceiveAny(message =>{_log.Info("Hit {0}",_msgCount++);if(_msgCount>=10){Context.System.Terminate();}});}privateclassRecoverMarker{}protectedoverridevoidPreRestart(Exceptionex,objectmessage){Timers.StartPeriodicTimer("foo","bar",TimeSpan.FromMilliseconds(100));}}
Version Information
Version of Akka.NET?
1.5.13
Which Akka.NET Modules?
Akka.Actor.Scheduler.TimerScheduler
Akka.Actor.HashedWheelTimerScheduler
Describe the bug
I am running my tests. I am using the "Run Until Failure" menu item in the test explorer menu.
The tests always fail. Usually only after a few iterations (at around 70 iterations).
Last test log:
Test run finished: 119 Tests (118 Passed, 1 Failed, 0 Skipped) run in 15.9 min. Finished at iteration 127
To Reproduce
Steps to reproduce the behavior:
In my app, many things happen, but the essence of the bug (i did not write a separate test for this - so take it as an unproved theory):
Expected behavior
I expect this exception to NOT happen. And for the tests iterations to continue.
Actual behavior
Test stops after a few iterations.
Environment
running on Windows.
Which version of .NET?
"Welcome to .NET 7.0!
SDK Version: 7.0.403"
The text was updated successfully, but these errors were encountered: