-
Notifications
You must be signed in to change notification settings - Fork 920
Add support for debugging Nashorn 15.4 for OpenJDK >= 15 #7069
Copy link
Copy link
Closed
Labels
Java[ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form)[ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form)JavaScript[ci] enable web job and extra JavaScript tests (webcommon/javascript2.editor)[ci] enable web job and extra JavaScript tests (webcommon/javascript2.editor)kind:featureA feature requestA feature request
Metadata
Metadata
Assignees
Labels
Java[ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form)[ci] enable extra Java tests (java.completion, java.source.base, java.hints, refactoring.java, form)JavaScript[ci] enable web job and extra JavaScript tests (webcommon/javascript2.editor)[ci] enable web job and extra JavaScript tests (webcommon/javascript2.editor)kind:featureA feature requestA feature request
Type
Fields
Give feedbackNo fields configured for issues without a type.
Description
Netbeans does support debugging of legacy Nashorn JavaScript engine bundled with OpenJDK < 15.0.
It does not support the the most recent Nashorn 15.4 extracted from OpenJDK, that has different package name.
Request is to add debug support for the Nashorn 15.4.
Use case/motivation
Citing from Wikipedia:
With the release of Java 11, Nashorn was deprecated citing challenges to maintenance, and has been removed from JDK 15 onwards - https://openjdk.org/jeps/372
Nashorn development continues on GitHub as a standalone OpenJDK project. Because it has renamed the package name(s), the support located in below mentioned modules does not work:
Quick and dirty renaming of constants describing the new package of Nashorn works for me. Question is if the Netbeans maintainers are willing to accept the fix. Bellow you can find the dirty patch:
nashorn-15.patch
I'd like to open discussion if and how the support can be added into Netbeans:
a) just polish attached patch, discarding the support for the old Nashorn
b) maintain support for both Nashorn engines at the same time - automatic detection
c) maintain support for both Nashorn engines at the same time - by turning an option in preferences
d) any other suggestion?
Thank you,
Libor
Related issues
No response
Are you willing to submit a pull request?
Yes