These are chat archives for akkadotnet/

Dec 2016
Tamir Dresher
Dec 17 2016 09:16
Hi, I have a weird situation where an application uses Ask() to reach an actor over remoting. the first call works fine but the second one causes an exception on the remote actor system. [ERROR][17/12/2016 09:12:56][Thread 0014][Akka.Remote.Transport.Helios.TcpServerHandler] Error caught channel [[::ffff:]:8092->[::ffff:]:65321](Id=ChannelId(714342544)) Cause: System.Net.Sockets.SocketException (0x80004005): The I/O operation has been aborted because of either a thread exit or an application request at Helios.Channels.Sockets.SocketChannelAsyncOperation.Validate() at Helios.Channels.Sockets.AbstractSocketByteChannel.SocketByteChannelUnsafe.FinishRead(SocketChannelAsyncOperation operation)
i can't figure out why. i tried using Tell() instead of Ask() but it still fails
Martin Helmer
Dec 17 2016 16:40

Hi. I have problems with the synchronized-dispatcher. I want to create UI actors dynamically from a background thread. However the TaskSchedulerExecutor uses the TaskScheduler.FromCurrentSynchronizationContext() which is not available in the background thread and causes a "The current SynchronizationContext may not be used as a TaskScheduler." exception.

I tried to create my own Dispatcher implementation, so that I can just safe the TaskScheduler at startup. However, it seems like the necessary stuff is internal and I can not do what I want.

Any suggestions, how I can set the TaskScheduler at startup?