-
Notifications
You must be signed in to change notification settings - Fork 305
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
FISH-5851 Prevent NullPointerException in com.sun.jts.CosTransactions.RecoveryManager
#5492
Conversation
Make a copy of the EventSemaphore before checking its state.
Hi, @chrjohn Thank you for the PR, we're happy to receive your contribution, before we can proceed you will need to sign the CLA and send it to us. Thank you, |
jenkins test please |
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.
When verifying the changes I noted two methods in EventSemaphore
that are not used:
EventSemaphore(boolean)
and EventSemaphore.clear
.
It would be good to delete those as well, so it is clear that EventSemaphore only transitions once, from false
to true
@pdudits , thanks, will do. |
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.
LGTM
com.sun.jts.CosTransactions.RecoveryManager
com.sun.jts.CosTransactions.RecoveryManager
Thanks we have the CLA |
jenkins test please |
FISH-5851 Prevent NullPointerException in `com.sun.jts.CosTransactions.RecoveryManager`
FISH-5851 Prevent NullPointerException in `com.sun.jts.CosTransactions.RecoveryManager`
Fixes #5491
Make a copy of the EventSemaphore before accessing it.
Description
Prevents NPE in
com.sun.jts.CosTransactions.RecoveryManager
by making a copy of theEventSemaphore
. This was suggested by @pdudits in https://forum.payara.fish/t/nullpointerexception-in-com-sun-jts-costransactions-recoverymanager-when-restoring-ejb-timers/81Important Info
Testing
This is a race condition which occurs very rarely. We only encountered this once in several years.
However, if anyone has an idea for a test I'd be happy to work on it.
Testing Performed
n/a
Testing Environment
n/a
Documentation
n/a
Notes for Reviewers
n/a