Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-43665

Add support for inline deadline + uninterruptibility in Interruptible

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Major - P3
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 4.3 Desired
    • Component/s: Internal Code
    • Labels:
      None
    • Backwards Compatibility:
      Fully Compatible

      Description

      Add support for a single level form of subsidiary deadlines + uninterruptibility in Interruptible with a syntax that looks like:

      future.get(interruptible->makeTimer(deadline, code));
      

      That syntax should produce a type convertible to an Interruptible* which wraps underlying calls to checkForInterrupt or waitForConditionOrInterruptUntil calls in the appropriate guards. It should replace the more wordy:

      interruptible->runWithDeadline(deadline, code, [&]{
        future.get(interruptible);
      });
      

      when a subsidiary deadline or uninterruptible invocation is needed at the very bottom of the callstack.

      That type should not nest and should not alter the state of the parent interruptible

        Attachments

          Activity

            People

            • Assignee:
              jason.carey Jason Carey
              Reporter:
              jason.carey Jason Carey
              Participants:
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: