Nashorn 15.6 is out, Nashorn 15.5 post-mortem & Github automated testing
Attila Szegedi
szegedia at gmail.com
Thu Dec 26 17:29:50 UTC 2024
Hi y'all,
I released Nashorn 15.6 this morning – the links on the website are updated
to point to it. It now fixes the NPE that was triggered by Log4j being used
through the JUL adapter. It's a problem with some unfortunately complicated
almost-circular startup initialization between various Nashorn components
that just happened to blow up in logging specifically with Log4J. Piotr P.
Karwasz and I collaborated on a solution for it and I released it as
Nashorn 15.5 ten days ago.
Unfortunately the release was a debacle as it contained a bug that
prevented Nashorn from starting up at all. The almost-circularity bit us
again, only this time worse – it was not even conditional on Log4j anymore
*facepalm*.
I want to stress that it being released in this state was entirely my fault
– I was devoting an odd half hour of my time to this every now and then,
and apparently managed to think I'm releasing something I already
reasonably tested, but then… turns out I didn't. I should've known better
than to release anything without one last re-run of all tests.
As soon as I noticed the problem I reverted links to 15.5 from our homepage
to 15.4 and marked it in the changelog as broken.
After this, I reworked the solution. It partially weakens the solution
Piotr contributed, but it is still an improvement enough to retain the
important effect (logging not killing client code with NPE when Log4J is
used.) This is now released as Nashorn 15.6.
More to the point, I added a Github workflow that runs the "ant test"
target on all PRs and all pushes to the main branch; this should have been
done ages ago by rights. Right now it tests on Java 11, but I also made
sure tests pass with Java 21 too (they were failing because the runtime was
printing Security Manager related warnings to stderr) and will soon add it
to the matrix as well.
All of this is to say, I'm learning the lesson from 15.5 and building out –
better late than never – automation safeguards against this kind of
scenario.
Thank you to everyone who patiently waited for this to get fixed.
Attila.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/nashorn-dev/attachments/20241226/d1f4ec2d/attachment-0001.htm>
More information about the nashorn-dev
mailing list