mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joseph Wu <>
Subject Re: Review Request 57358: Implemented discard behavior in process::Queue.
Date Tue, 21 Mar 2017 21:40:39 GMT

This is an automatically generated e-mail. To reply, visit:

(Updated March 21, 2017, 2:40 p.m.)

Review request for mesos, Benjamin Mahler and Greg Mann.


Changed implementation of discard to do a (potentially) expensive queue cleanup upon discard.

Bugs: MESOS-6919

Repository: mesos

Description (updated)

When a consumer calls `Queue::get` on an empty Queue, the Queue creates
a Promise to back the Future return value.  This Promise currently
does not have a discard handler, which may cause problems if the
Future is chained to multiple continuations.  For example, see
the scenario in MESOS-6919.

This commit implements an (potentially expensive) discard handler
on the Queue's Promise.  If the Future return value is discarded,
the Queue will remove the corresponding Promise from its internal
queue of promises.  The operation is expensive because it needs
to reconstruct the entire internal queue of promises.

Diffs (updated)

  3rdparty/libprocess/include/process/queue.hpp ab08e30df742412f22a06202526f8b55350ed435 
  3rdparty/libprocess/src/tests/queue_tests.cpp 95b738133fa50641f8f9b83014837d2808e0e4ff 





make libprocess-tests

3rdparty/libprocess/src/tests/libprocess-tests --gtest_filter="Scheme/HTTPTest.Endpoints/0"
--gtest_repeat="`ulimit -n`"

make check


Joseph Wu

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message