Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • 18:08
    Aaronontheweb commented #3937
  • 17:27
    Aaronontheweb commented #90
  • 17:26
    Aaronontheweb commented #90
  • 17:25
    Aaronontheweb assigned #90
  • 17:16

    Aaronontheweb on dev

    Provide static GetRoutees.Insta… (compare)

  • 17:16
    Aaronontheweb closed #3974
  • 17:16
    Aaronontheweb milestoned #3974
  • 16:05
    jackowild opened #90
  • 15:08
    Aaronontheweb commented #3974
  • 15:08
    Aaronontheweb commented #3974
  • Oct 13 14:40
    cptjazz synchronize #3974
  • Oct 13 14:07
    cptjazz opened #3974
  • Oct 13 08:30
    ismaelhamed commented #3937
  • Oct 12 15:50
    IrvinDominin opened #127
  • Oct 11 18:21
    Aaronontheweb commented #3973
  • Oct 11 18:20
    Aaronontheweb commented #3937
  • Oct 11 18:16
    Zetanova commented #3937
  • Oct 11 18:11
    Zetanova commented #3937
  • Oct 11 15:09
    Aaronontheweb commented #3937
  • Oct 11 15:08
    Aaronontheweb commented #3937
Aaron Stannard
@Aaronontheweb
with the colon instead
the other possibility here is that the HOCON parser in Akka.NET can't deal with the nested type in the FQN
which would be... odd
since you said you can see it being instantiated
Ronnie Overby
@ronnieoverby
leave it to me to find an edge case the very first time I try to use something. It never fails
Aaron Stannard
@Aaronontheweb
just a guess - I think an = should work
Ronnie Overby
@ronnieoverby
yeah it's a nested class because no other actor would ever need this mailbox
Aaron Stannard
@Aaronontheweb
but I noticed that's what we did in our specs
Ronnie Overby
@ronnieoverby
no that didn't help
Aaron Stannard
@Aaronontheweb
ok
theory 2
nested types
Ronnie Overby
@ronnieoverby
1 sec let me try
Aaron Stannard
@Aaronontheweb
theory 3: you can verify that this actor is actually receiving messages, right?
Ronnie Overby
@ronnieoverby
theory 3 yes I def see receive handlers getting hit
theory 2 is no good
unnested type gets constructed but overridden method never called
I can maybe work up an isolated failing test for you
Aaron Stannard
@Aaronontheweb
if messages are making it through then, means that either your actor isn't using this mailbox
Ronnie Overby
@ronnieoverby
you see my props creation, though
Aaron Stannard
@Aaronontheweb
yep
Ronnie Overby
@ronnieoverby
and I see a debugger breaking in the mailbox ctor
want a stack trace at that point?
idk if it will help or not
Aaron Stannard
@Aaronontheweb
nah, I believe you on that
do me a favor
throw an exception in the PriorityGenerator
Ronnie Overby
@ronnieoverby
?
ok
Aaron Stannard
@Aaronontheweb
we call this a "tracer round"
lol
Ronnie Overby
@ronnieoverby
i like it
nothing happened
    protected override int PriorityGenerator(object message)
    {
        throw new ApplicationException("BLARGH!");

        if (message is Unsubscribe || message is Subscribe)
            return 0;

        return 1;
    }
Aaron Stannard
@Aaronontheweb
alrighty then
and the actor still received its message?
Ronnie Overby
@ronnieoverby
yes
Aaron Stannard
@Aaronontheweb
you know... I wonder....
this would be extremely weird
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;
        }
    }
this is the unbounded priority mailbox in its full glory
Ronnie Overby
@ronnieoverby
pretty simple
Aaron Stannard
@Aaronontheweb
it's just a type provider
it takes your priority function and passes it into that queue
I wonder, if by some race condition
during the construction of this object
if it's possible
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);
        }
that this queue never ends up getting to call the SetPriorityCalculator
would you mind reporting a bug for this?