-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66322/
-----------------------------------------------------------

Review request for mesos, Chun-Hung Hsiao, Greg Mann, and Jie Yu.


Bugs: MESOS-8741
    https://issues.apache.org/jira/browse/MESOS-8741


Repository: mesos


Description
-------

Adding item to sequence is realized by dispatching
`add()` to the sequence actor. However, this could
race with the sequence actor termination.

This patch fixes this by enqueueing the terminate
message at the end of the message queue.

Also removed the clock settle in the test `DiscardAll`.
As the processing of the messages are now guaranteed
to happen before the actor termination.

Also added comments to clarify the onDiscard propagation.


Diffs
-----

  3rdparty/libprocess/include/process/sequence.hpp 
b4d7593221bf225a9e53e3b7f94e45624400078a 
  3rdparty/libprocess/src/tests/sequence_tests.cpp 
43911b6c7a4220a4b8ea1baca191035355817e7b 


Diff: https://reviews.apache.org/r/66322/diff/1/


Testing
-------

make check

After modifying test `DiscardAll`, it fails with the old implementation. After 
modifying the `inject` flag, it passes.


Thanks,

Meng Zhu

Reply via email to