Skip to content

Conversation

@mbien
Copy link
Member

@mbien mbien commented Jan 30, 2026

this test was patched in past for similar reasons and can start failing again when the JDK updates.

testLockFile() is now disabled in CI

@mbien mbien added this to the NB29 milestone Jan 30, 2026
@mbien mbien added CI continuous integration changes tests labels Jan 30, 2026
this test was patched in past for similar reasons and can start
failing again when the JDK updates.

testLockFile() is now disabled in CI
@mbien mbien force-pushed the fix-lockfile-test-again branch from 32dfae6 to 53fc45b Compare January 30, 2026 20:11
@lkishalmi
Copy link
Contributor

If this happened and patched in the past, do we have a reference on that?


@Override
protected void setUp() throws java.lang.Exception {
GraphicsEnvironment.isHeadless(); // may cause file reads in a static initializer on linux
Copy link
Contributor

Choose a reason for hiding this comment

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

A little more info would be good to be provided in this issue at least.

Copy link
Member Author

@mbien mbien Feb 1, 2026

Choose a reason for hiding this comment

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

those tests monitor file IO by counting reads/writes. This calls something directly and eagerly which also does file IO. This method would have been called later indirectly by unrelated JDK API which would fail the tests - or worse - fail tests based on JDK update release or order of execution

@mbien
Copy link
Member Author

mbien commented Feb 1, 2026

If this happened and patched in the past, do we have a reference on that?

https://github.com/mbien/netbeans/commits/53fc45b42e1479ce0b1f1103d47cf5d99220ec19/platform/masterfs/test/unit/src/org/netbeans/modules/masterfs/filebasedfs/fileobjects/StatFilesTest.java

the hg archive repo seems to be down atm?

or #7410, #7974

@mbien
Copy link
Member Author

mbien commented Feb 2, 2026

merging to delivery so that we have CI again

@mbien mbien merged commit dedef60 into apache:delivery Feb 2, 2026
30 checks passed
Copy link
Contributor

@lahodaj lahodaj 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 I can live with this. (I would be completely OK with the isHeadless(), counting file accesses inevitably will be tricky and will need some code to warm up - alternative would be to trial-run one or more tests to warm up, and then do the real test run, but that's a bit tricky as well. So the @RandomlFails, well, it is what it is.)

@mbien
Copy link
Member Author

mbien commented Feb 2, 2026

we can revisit those test after #9151 is merged, because this will:

a) reduce the testing range and we can remove some of the patches again (e.g sections like if (version > 18) assume one read more etc)

b) we will have a list of tests which need to be migrated away from SM to JFR or other IO tracing methods and can handle them one by one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI continuous integration changes tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants