• Fully Compatible
    • v4.0, v3.6
    • Platforms 2018-05-21, Platforms 2018-06-04

      Provide a type which offers concurrent keyed and queued execution of tasks.

      Something that looks like:

      KeyedExecutor<std::string> ke(someExecutorMaybeThreadPool);
      auto doThingFuture = ke.execute("foo", []{ return doThing(); });
      auto doOtherThingFuture = ke.execute("foo", []{ return doOtherthing(); });
      auto waitForCurrentFooState = ke.waitForAll("foo");
      

      Where:

      • Jobs under the same key provide mutual exclusion
      • Tasks are executed via the passed executor
      • running jobs returns futures
      • waiting for a queue to clear up to a point is based on the back of the queue at the time of the call's future.

            Assignee:
            mira.carey@mongodb.com Mira Carey
            Reporter:
            mira.carey@mongodb.com Mira Carey
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: