These are chat archives for akkadotnet/

Jun 2016
Jun 03 2016 00:35
@Horusiath thanks!
Jun 03 2016 00:43
Firstly, I use myActor.Tell(msg);
Then, I got a XPTOException, this type of Expection is treated in my Supervisor/decider to Directive.Restart.
When occurs XPTOException, as I put Directive.Restart, this should works as I was calling: myActor.Tell(msg) again?
Because it isn't passing in Receive, as it happened in the first call.
Bartosz Sypytkowski
Jun 03 2016 06:08
@mkanker I'm not sure if I follow, but you're asking if the same message, which caused exception, will be received again after actor restarts? In that case no.
Bartosz Sypytkowski
Jun 03 2016 06:15

If you need something like message processing retries, you could i.e.

  • override PreRestart(exception, message) method and put that message (which caused an exception to occur) at the end of the actor mailbox i.e. Self.Forward(message), so it will be processed later on.
  • Make sender apply at-least-once delivery semantics (i.e. use AtLeastOnceDeliveryActor from Akka.Persistence module). This actor will try to redeliver a message in time intervals until it gets confirmed. So if your actor will crash during message processing, it just won't send a confirmation, and message will be send after some time.

Second option is safer (and more complex) as it can handle scenarios like crash of the machine, actors are working on.

But in both cases you must ensure that your actor processes messages in indempotent manner. This means, no matter how many times an actor receives the same message, the result must be the same as if it was only received once.

@knorrus I'm not sure, but I think, that monitoring clients are hidden behind an actor internally, so they should be thread safe
Peter Bergman
Jun 03 2016 06:34
I have some issues with the remote.helios.tcp configuration when deploying a cluster over multiple machines, especially the hostname and public-hostname properties. I'm trying out how I can deploy an Akka.NET cluster into Azure cloud services (worker/web roles). The thing is that I'm not sure if I should populate the hostname property with the private IP of the machine that the cluster node will be deployed on. Or, if I can set it to to make it bind to any interface?
The cluster nodes does not need to be reachable from outside of the cluster so I guess I shouln't touch the public -hostname property?
Bart de Boer
Jun 03 2016 07:44
the way I understand it, @peter-bannerflow , is that hostname is actually the binding address ( so for localhost, for all adapters), and public-hostname the hostname that the others will use to connect to you. @Aaronontheweb is that correct?
Jun 03 2016 07:48
This is not a problem with Akka probably resharpers testrunner, but asking to see if anyone has had the same problem and fixed it. When running xunit tests with akka testkit the runner it is extremely slow, 160ish tests takes 7:30 mins (all tough xunit runs them parallel so actual time is much less). But when running with tests with dotcover in the test runner the tests only takes 17secs. Any ideas? Mstest runner is also as fast as it should be.
Peter Bergman
Jun 03 2016 08:07
@boekabart Hmm ok, so hostname should perhaps be and public-hostname should maybe be the private cloud service IP that the other services in the cloud service can connect to...
Kevin McFarlane
Jun 03 2016 11:13

@corneliutusnea I set up Visualizer according to the doc file but don't seem to get a Web site on localhost:8085 (I created URL reservation for that).

I had the same problem when I tried some time back.

Jun 03 2016 11:25
@object @kevinmcfarlane The docs forgot to tell you to start it. Sorry. code should be
var webVisualizer = new WebApiVisualizer();
ActorVisualizeExtension.InstallVisualizer(_system, webVisualizer);
Vagif Abilov
Jun 03 2016 11:25
Thanks, will give it a try!
Chris G. Stevens
Jun 03 2016 13:37
Has anyone else ran into DateTime issue where the DateTimeKind gets dropped off.
If the message is created on my website member my date is correct and the Date contains the Z, 2016-06-03T12:57:26.5728911Z
If the message is created on my service member my date is missing the DateTimeKind = 2016-06-03T12:57:26.5728911
The thing that is driving me crazy is it is the same code in both ActorSystems.
I am even explicitly setting the Kind when I create the immutable message - DateTime.SpecifyKind(messageDateTime, DateTimeKind.Utc);
I put in a check for the DateTimeKind before I send the message to the client from the SignalR Hub and it is Unspecified for the messages that come from the Service.
Vagif Abilov
Jun 03 2016 13:48
@corneliutusnea works now!
Vagif Abilov
Jun 03 2016 13:55
@corneliutusnea your project is very inspiring. Are you open for suggestions/collaboration?
Kevin McFarlane
Jun 03 2016 14:44
@corneliutusnea @object I can now display the actor system, i.e., "PersistenceActorSystem" below but not the actors. What am I doing wrong?
var actorSystem = ActorSystem.Create("PersistenceActorSystem");
var actor = actorSystem.ActorOf(Props.Create<ParentActor>(), "ParentActor");

var webVisualizer = new WebApiVisualizer();
ActorVisualizeExtension.InstallVisualizer(actorSystem, webVisualizer);


Console.WriteLine("Actor system shutdown...");
Arjen Smits
Jun 03 2016 14:45
@cgstevens its a bug in Wire
  var now = DateTime.UtcNow;
            //has Kind UTC here
            var source = new MemoryStream();
            var w = new StreamWriter(source);
            var s = new Wire.Serializer(new SerializerOptions());
            s.Serialize(now, w.BaseStream);
            source.Position = 0;
            var newdate = s.Deserialize(source);
            //has Kind unspecified here
/cc @rogeralsing
Arjen Smits
Jun 03 2016 14:50
Jun 03 2016 16:52
@Horusiath thank you very much! I will try your second option ;)
Bartosz Sypytkowski
Jun 03 2016 18:51
@corneliutusnea @object concerning visualizers - this may be an interesting idea. Even more: @rogeralsing @Aaronontheweb this mechanism could be used to implement self balancing virtual actors in akka - to migrate the most communicating actors on the same machine under the hood.
Vagif Abilov
Jun 03 2016 20:19
@Horusiath thanks for the link, looks also very interesting.
@kevinmcfarlane try double-clicking on user actor. Should expand it.
Aaron Stannard
Jun 03 2016 22:19
@boekabart that's correct - if you don't specify a public-hostname then hostname will be used for both
but the idea is to allow an alias
@cgstevens not with Akka.NET, but I've definitely had this issue in ASP.NET MVC
oh snap, just saw the bit @Danthar posted
@Lejdholt no idea on that stuff :\