Sorry for the naive question - but how do I ignore them?
Let's say have these messages in the mailbox for Request 1:

Req1_time_slice_1
Req1_time_slice_2
Req1_time_slice_3
Req1_time_slice_4
Req1_time_slice_5
Req1_CANCEL_MESSAGE

Ideally with the PriorityMailBox - I will assume this situation:

   - Req1_time_slice_1 (OFF THE QUEUE) and being processed in onReceive()
   - Req1_CANCEL_MESSAGE *BUBBLES to postion 2 because of PriorityMailBox*
   - *NOW - I need to ignore the following messages in the mailbox:*
      - 
*Req1_time_slice_2 *
      - 
*Req1_time_slice_3 *
      - 
*Req1_time_slice_4 *
      - 
*Req1_time_slice_5 *
   

How is that achieved in Akka?

I apologize for the naive question as I am new to Akka and trying to wrap 
it in my head :-)
Meena

On Tuesday, April 8, 2014 12:56:18 PM UTC-4, √ wrote:
>
> Hi Meena,
>
> You don't need to delete them, you just need to ignore them.
> Deleting messages in the mailbox is going to me much costlier than 
> ignoring them.
>
>
> On Tue, Apr 8, 2014 at 6:51 PM, MV <[email protected] <javascript:>> wrote:
>
>> Hi Martynas
>>
>> Thanks for getting back to me. I guess my problem is also to figure out 
>> how to delete the messages in the mailbox for this specific request ID.
>> Basically, the mailbox will have multiple messages for the same requestID 
>> with different time slices. So when I get a cancel request for the specific 
>> ID, I want to also remove the existing messages in the mailbox for this ID.
>> I could not find a nice and easy way to accomplish this.
>>
>> Is there anything in the AKKA framework for something like this?
>>
>> Thanks
>> Meena
>>
>>
>> On Tuesday, April 8, 2014 10:58:44 AM UTC-4, Martynas Mickevičius wrote:
>>>
>>> You could use BoundedPriorityMailbox in your router. More info 
>>> here<http://doc.akka.io/docs/akka/2.3.1/scala/mailboxes.html>
>>> .
>>>
>>> Also, make sure that 'CANCEL REQUEST' message produces the same hash 
>>> value for the hashing pool as the message you want to cancel. Otherwise 
>>> 'CANCEL REQUEST' message could be routed to a worker which will not ever 
>>> get the message to be canceled.
>>>
>>> --
>>> Martynas Mickevičius
>>> Typesafe <http://typesafe.com/> – 
>>> Reactive<http://www.reactivemanifesto.org/> Apps 
>>> on the JVM
>>>
>>  -- 
>> >>>>>>>>>> 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.
>>
>
>
>
> -- 
> Cheers,
> √
>  

-- 
>>>>>>>>>>      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.

Reply via email to