Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8292365

CompletableFuture and CompletionStage should document Memory Model guarantees

XMLWordPrintable

      A DESCRIPTION OF THE PROBLEM :
      Please expand the documentation of CompletableFuture and CompletionStage to describe the Memory Model guarantees (e.g. happens-before relationships) these classes and their methods provide. Currently this is not documented for these classes at all, and one can only assume what the guarantees might be.

      Compare this to the class Future for which both the package documentation (https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/util/concurrent/package-summary.html) and the class documentation specify the Memory Model guarantees for the `get()` method.

      See also the following Stack Overflow questions about this:
      - https://stackoverflow.com/q/61575531
      - https://stackoverflow.com/q/34427972



            dl Doug Lea
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated: