-
Notifications
You must be signed in to change notification settings - Fork 5
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
Lock jdk creation using file locks #73
Conversation
Unfortunatley this is difficult to test.
Generate changelog in
|
The build failed due to this plugin itself, on the issue I'm trying to fix
|
path.getParent().resolve(path.getFileName() + ".lock"), | ||
StandardOpenOption.CREATE, | ||
StandardOpenOption.WRITE)); | ||
FileLock fileLock = channel.lock(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fancy - didn't know you could get process-level file locks like this. What does it do on windows/NTFS, out of curiosity?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On windows, the in-process (non-fs lock) is actually unnecessary since unlike unix, locks aren't owned by entire processes! No reason to remove that lock, though, since it would only increase the code complexity. Ideally we could get windows tests running in #69, however there are some hurdles with pjf+checkstyle
Released 0.20.0 |
Previously concurrent requests for JDKs would result in parallel unpacks which fail in unexpected ways due to serial existence checks succeeding in parallel.
Unfortunately this is difficult to test.
==COMMIT_MSG==
Lock jdk creation using file locks
==COMMIT_MSG==
We'll leave around
<jdk-dir-name>.lock
files in the jdks directory