Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix file watching for unix #150

Merged
merged 2 commits into from
May 14, 2018
Merged

Fix file watching for unix #150

merged 2 commits into from
May 14, 2018

Commits on May 10, 2018

  1. Fix file watching for linux

    I inadvertently forgot to reset the watch key after reading the events.
    This would cause the EventMonitor to miss watch events because the watch
    service stopped posting events to the full key. I looked at the jdk
    source code and it looks like each watch key can hold up to 512 events,
    so I added a test to ensure that after adding 1000 files, watch events
    were still triggered. The test failed before the change to EventMonitor.
    I also realized that I reintroduced the bug fixed by @oneill in
    881e835 so I fixed that as well.
    eatkins committed May 10, 2018
    Configuration menu
    Copy the full SHA
    c7b813a View commit details
    Browse the repository at this point in the history
  2. Don't clear events in reset()

    We already drain the events in pollEvents. Clearing in reset() can cause
    events to be missed (which manifested as flaky tests).
    eatkins committed May 10, 2018
    Configuration menu
    Copy the full SHA
    70b4c74 View commit details
    Browse the repository at this point in the history