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 sporadic failures with: access-filter.json already exists #659

Merged

Conversation

dnestoro
Copy link
Collaborator

@dnestoro dnestoro commented Dec 23, 2024

It appears that our previous implementation with milliseconds doesn't work because there is still a chance that two threads can make an access-filter-file within the same millisecond.

This PR replaces usage of milliseconds with nano time.

The PR fixes: #653 and #626

@dnestoro dnestoro requested review from melix and olpaw December 23, 2024 11:54
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Dec 23, 2024
@dnestoro dnestoro self-assigned this Dec 25, 2024
Copy link
Collaborator

@melix melix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the issue is less that it can be accessed at the same milliseconds, than the fact that the Java clock for System.currentTimeMillis() doesn't guarantee anything and can return the same ms in 2 subsequent invocations separated by more than a ms.

@dnestoro dnestoro force-pushed the dnestoro/fix-sporadic-failures-with-default-access-filter branch from 3a0fd26 to 1e17965 Compare January 9, 2025 09:30
@dnestoro dnestoro merged commit caae59f into master Jan 9, 2025
223 checks passed
@dnestoro dnestoro deleted the dnestoro/fix-sporadic-failures-with-default-access-filter branch January 9, 2025 10:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
OCA Verified All contributors have signed the Oracle Contributor Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sporadic Gradle failure: access-filter.json already exists (still exist in 0.10.4)
2 participants