[erlang-questions] erlang:process_info(Pid, messages) result order

Jesper Louis Andersen jesper.louis.andersen@REDACTED
Fri Aug 22 14:01:49 CEST 2014


LIFO is really good when you fail to meet a deadline, if you also have a
way to "get rid of the rest of the mailbox". The reason is that in a stack:
[a,b,...] you know that b entered before a. So if a is too old, then so
must b. Hence you can avoid doing work by simply ignoring the extra work.

Currently though, this is easily implementable in Erlang itself, so unless
you need very high processing speed it is not a problem.



On Fri, Aug 22, 2014 at 1:56 PM, Dmitry Kolesnikov <dmkolesnikov@REDACTED>
wrote:

> I would think that LIFO are manageable through in-process publish /
> subscribe. However, in-the-middle process impacts the performance to
> compare with native queue implementation. What is you use-case for LIFO?
>
> Best Regards,
> Dmitry
>
> On 22 Aug 2014, at 14:50, Jesper Louis Andersen <
> jesper.louis.andersen@REDACTED> wrote:
>
>
> On Thu, Aug 21, 2014 at 4:10 PM, Michael Klishin <
> michael.s.klishin@REDACTED> wrote:
>
>> How would old messages get a chance at being processed at high message
>> rates, if the order wasn't FIFO?
>>
>
> Sometimes, this is actually a bad idea. LIFO mailboxes would be really
> really cool to have in certain situations.
>
>
> --
> J.
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
>
>
>


-- 
J.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20140822/91941b4d/attachment.htm>


More information about the erlang-questions mailing list