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

Pending requests from Application.invokeLater can cause input event starvation

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: 7u6
    • Fix Version/s: 8
    • Component/s: javafx
    • Labels:
      None
    • Environment:

      Windows

      Description

      The root cause of RT-19897 is that, on Windows at least, Runnables posted to the event queue with Application.runLater will be processed at a higher priority than input events. This leads to input event starvation in cases where there is always a pending Runnable on the queue. We have a partial solution to RT-19897 by releasing the barrier early allowing the FX application thread a short window of time to process events before posting the next runnable, but it is fragile.

      Additionally, it is the reason we cannot run in full-speed mode without some sort of periodic sleep.

      Ideally, runnables and input events would be treated at the same priority and processed in order. At the very least, we need a mechanism to ensure that we don't starve input events.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                anthony Anthony Petrov (Inactive)
                Reporter:
                kcr Kevin Rushforth
              • Votes:
                0 Vote for this issue
                Watchers:
                10 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported: