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

Add support for cancelling a CancellationSource with a Status

    • Type: Icon: Task Task
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • Server Programmability
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      Currently, the Status that's used to cancel an operation with via CancellationSource is entirely up to the cancellation logic. This makes it needlessly onerous for cancellation logic to accept a Status with which to cancel the operation from the calling code that requests cancellation. We should change the signature of CancellationSource::cancel() to accept (perhaps optionally) a Status so that callers can directly provide the Status to the cancellation logic, as opposed to through some contrived handoff through external state.

            Assignee:
            Unassigned Unassigned
            Reporter:
            james.bronsted@mongodb.com James Bronsted
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              None
              None
              None
              None