-
Notifications
You must be signed in to change notification settings - Fork 364
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
race condition in XRLog/JDKXRLogger #646
Comments
Thanks to @testinfected 👍 . Code for reproducing the error: public static void main(String[] args) throws Exception {
int p = 20;
CountDownLatch latch = new CountDownLatch(p);
for (int i = 0; i < p;i++) {
new Thread(() -> {
latch.countDown();
try {
latch.await();
XRLog.log(Level.SEVERE, LogMessageId.LogMessageId0Param.CASCADE_IS_ABSOLUTE_CSS_UNKNOWN_GIVEN);
} catch (InterruptedException e) {
}
}).start();
}
} |
seems that moving openhtmltopdf/openhtmltopdf-core/src/main/java/com/openhtmltopdf/util/JDKXRLogger.java Line 111 in 801780b
after the call We could even wrap the |
We're having what seems to be a race condition in our tests, which run in parallel in different threads :
I will put up a test case which reproduces the problem
Originally posted by @testinfected in #552 (comment)
The text was updated successfully, but these errors were encountered: