Aaronontheweb on 1.4.14
Aaronontheweb on master
Bump Mongo2Go from 2.2.14 to 2.… Bump MongoDB.Driver from 2.11.4… Bump Microsoft.NET.Test.Sdk fro… and 4 more (compare)
Aaronontheweb on 1.4.14
Aaronontheweb on dev
Added v1.4.14 release notes (#1… (compare)
Aaronontheweb on dev
ensure that all recovered Times… (compare)
public abstract class UnboundedPriorityMailbox : MailboxType, IProducesMessageQueue<UnboundedPriorityMessageQueue>
{
protected abstract int PriorityGenerator(object message);
public int InitialCapacity { get; }
public const int DefaultCapacity = 11;
public sealed override IMessageQueue Create(IActorRef owner, ActorSystem system)
{
return new UnboundedPriorityMessageQueue(PriorityGenerator, InitialCapacity);
}
protected UnboundedPriorityMailbox(Settings settings, Config config) : base(settings, config)
{
InitialCapacity = DefaultCapacity;
}
}
public class UnboundedPriorityMessageQueue : BlockingMessageQueue
{
private readonly ListPriorityQueue _prioQueue;
public UnboundedPriorityMessageQueue(int initialCapacity)
{
_prioQueue = new ListPriorityQueue(initialCapacity);
}
public UnboundedPriorityMessageQueue(Func<object, int> priorityGenerator, int initialCapacity) : this(initialCapacity)
{
_prioQueue.SetPriorityCalculator(priorityGenerator);
}
internal void SetPriorityGenerator(Func<object, int> priorityGenerator)
{
_prioQueue.SetPriorityCalculator(priorityGenerator);
}
SetPriorityCalculator
Thread.Interrupt
call we make on one of the specs caused the XUnit test runner to blow up
I am not sure if this is a bug or not, or if this should be posted here or not, but here it goes...
I am using Akka.NET remoting, I have one "client" and one "server" application (I know akka doesn't distinguish between them) and I wanted to receive some entity (called History) from the server.
The class I was sending from the server has an IReadOnlyCollection of one of my custom entities (conveniently called Entity).
Now the Entity class had 2 constructors, first of which took a string and parsed it into a DateTime object, and the second which took a DateTime object.
However, when I tried to send this History from the server to the client I would get a disassociated exception.
Looking into it, I first commented out the construct that takes the DateTime object. However, when the other constructor was invoked, the string paramater (which I would like to parse to a DateTime) was equal to null.
Commenting out the constructor that takes a string and tries to parse it into a DateTime, I was left with only the second constructor which takes a DateTime object. This worked.
But I don't know why exactly it didn't work when I had both constructors, or why the string parameter was equal to null.
I can send or link the file with all of the classes if it could help.
Sorry if I am/was unclear.
public static class SerializerTestHelpers
{
public static async Task<T> AkkaSerialized<T>(this T src)
{
var hokon = "akka.actor.provider = \"Akka.Remote.RemoteActorRefProvider, Akka.Remote\"" +
Environment.NewLine +
"akka.remote.helios.tcp.port = 0" + Environment.NewLine +
"akka.remote.helios.tcp.hostname = localhost";
var sys = ActorSystem.Create("src");//, ConfigurationFactory.ParseString(hokon));
await sys.Terminate();
var ser = sys.Serialization.FindSerializerFor(src);
var bin = ser.ToBinary(src);
return (T)ser.FromBinary(bin, typeof(T));
}
}