Hi Roland, Below is the full stack trace. I do see its trying to tell me something, but I cannot figure out what. I would guess maybe it is saying that not all message types are being handled, but I do have the else at the end there.
[ERROR] [05/10/2014 08:01:17.336] [application-akka.actor.default-dispatcher-10] [akka://application/user/gradebook/courses] configuration problem while creating [akka://application/user/gradebook/courses/C4] with dispatcher [priority-dispatcher] and mailbox [akka.actor.default-mailbox] akka.ConfigurationException: configuration problem while creating [akka://application/user/gradebook/courses/C4] with dispatcher [priority-dispatcher] and mailbox [akka.actor.default-mailbox] at akka.actor.LocalActorRefProvider.actorOf(ActorRefProvider.scala:722) at akka.actor.dungeon.Children$class.makeChild(Children.scala:207) at akka.actor.dungeon.Children$class.actorOf(Children.scala:38) at akka.actor.ActorCell.actorOf(ActorCell.scala:369) at services.CoursesActor.getCourse(CoursesActor.java:30) at services.CoursesActor.lambda$new$0(CoursesActor.java:15) at services.CoursesActor$$Lambda$5/2083464974.apply(Unknown Source) at akka.japi.pf.UnitCaseStatement.apply(CaseStatements.scala:26) at akka.japi.pf.UnitCaseStatement.apply(CaseStatements.scala:21) at scala.PartialFunction$class.applyOrElse(PartialFunction.scala:118) at akka.japi.pf.UnitCaseStatement.applyOrElse(CaseStatements.scala:21) at scala.PartialFunction$OrElse.applyOrElse(PartialFunction.scala:165) at akka.actor.Actor$class.aroundReceive(Actor.scala:465) at akka.actor.AbstractActor.aroundReceive(AbstractActor.scala:47) at akka.actor.ActorCell.receiveMessage(ActorCell.scala:516) at akka.actor.ActorCell.invoke(ActorCell.scala:487) at akka.dispatch.Mailbox.processMailbox(Mailbox.scala:238) at akka.dispatch.Mailbox.run(Mailbox.scala:220) at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:393) at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260) at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339) at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979) at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107) Caused by: java.lang.IllegalArgumentException: produced message queue type [class akka.dispatch.UnboundedPriorityMailbox$MessageQueue] does not fulfill requirement for actor class [class services.CourseActor] at akka.dispatch.Mailboxes.verifyRequirements$1(Mailboxes.scala:148) at akka.dispatch.Mailboxes.getMailboxType(Mailboxes.scala:156) at akka.actor.LocalActorRefProvider.actorOf(ActorRefProvider.scala:717) ... 22 more On Saturday, May 10, 2014 6:26:03 AM UTC-4, Akka Team wrote: > > Hi Chanan, > > your exception log is missing the important part: which exception caused > this configuration problem? > > Regards, > > Roland > > > > On Fri, May 9, 2014 at 1:38 PM, Chanan Braunstein > <[email protected]<javascript:> > > wrote: > >> Hello, >> >> I am sure I am missing something obvious, but I don't see it. I created a >> simple priority mailbox similar to the one in the doc: >> >> package services; >> ... >> public class PriorityMailbox extends UnboundedPriorityMailbox { >> >> public PriorityMailbox(ActorSystem.Settings settings, Config config) { >> // Create a new PriorityGenerator, lower prio means more important >> super(new PriorityGenerator() { >> @Override >> public int gen(Object message) { >> if (message instanceof Queries.CourseAverageRequest) >> return 0; // 'highpriority messages should be treated >> first if possible >> else if (message instanceof Queries.GroupAverageRequest) >> return 1; // 'lowpriority messages should be treated >> last if possible >> else if (message.equals(PoisonPill.getInstance())) >> return 4; // PoisonPill when no other left >> else >> return 2; // By default they go between high and low >> prio >> } >> }); >> } >> } >> >> priority-dispatcher { >> mailbox-type = "services.PriorityMailbox" >> } >> >> and create the actor (CoursesActor.java:30): >> return >> getContext().actorOf(Props.create(CourseActor.class).withDispatcher("priority-dispatcher"), >> >> name); >> >> And at runtime I get: >> >> [ERROR] [05/09/2014 07:24:24.417] >> [application-akka.actor.default-dispatcher-12] >> [akka://application/user/gradebook/courses] configuration problem while >> creating [akka://application/user/gradebook/courses/C0] with dispatcher >> [priority-dispatcher] and mailbox [akka.actor.default-mailbox] >> akka.ConfigurationException: configuration problem while creating >> [akka://application/user/gradebook/courses/C0] with dispatcher >> [priority-dispatcher] and mailbox [akka.actor.default-mailbox] >> at akka.actor.LocalActorRefProvider.actorOf(ActorRefProvider.scala:722) >> at akka.actor.dungeon.Children$class.makeChild(Children.scala:207) >> at akka.actor.dungeon.Children$class.actorOf(Children.scala:38) >> at akka.actor.ActorCell.actorOf(ActorCell.scala:369) >> at services.CoursesActor.getCourse(CoursesActor.java:30) >> >> Where am I going wrong? >> >> -- >> >>>>>>>>>> Read the docs: http://akka.io/docs/ >> >>>>>>>>>> Check the FAQ: >> http://doc.akka.io/docs/akka/current/additional/faq.html >> >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user >> --- >> You received this message because you are subscribed to the Google Groups >> "Akka User List" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected] <javascript:>. >> To post to this group, send email to [email protected]<javascript:> >> . >> Visit this group at http://groups.google.com/group/akka-user. >> For more options, visit https://groups.google.com/d/optout. >> > > > > -- > Akka Team > Typesafe - The software stack for applications that scale > Blog: letitcrash.com > Twitter: @akkateam > -- >>>>>>>>>> Read the docs: http://akka.io/docs/ >>>>>>>>>> Check the FAQ: >>>>>>>>>> http://doc.akka.io/docs/akka/current/additional/faq.html >>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user --- You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/akka-user. For more options, visit https://groups.google.com/d/optout.
