Support Jakarta Standard Tag Library 3.0 URIs in JSPs
Apache NetBeans version
Apache NetBeans 26
What happened
Currently the URIs for Jakarta Standard Tag Library 3.0 (this is from Jakarta EE 10, three years ago) aren't supported and the IDE shows an error when using them in a JSP:
This are the new URIs: https://jakarta.ee/specifications/tags/3.0/jakarta-tags-spec-3.0#multiple-tag-libraries
Language / Project Type / NetBeans Component
JSP
How to reproduce
Create new JSP and add the <%@taglib ... %> sentence with a JSTL 3.0 URI. The IDE shows an error with message "File [relative to JSP file]/jakarta.tags.[tag] not found.".
Did this work correctly in an earlier version?
No
Operating System
Ubuntu 24.10
JDK
OpenJDK Runtime Environment Temurin-23.0.2+7 (build 23.0.2+7)
Apache NetBeans packaging
Apache NetBeans binary zip
Anything else
Information on About:
Product Version: Apache NetBeans IDE 26 Java: 23.0.2; OpenJDK 64-Bit Server VM 23.0.2+7 Runtime: OpenJDK Runtime Environment 23.0.2+7 System: Linux version 6.11.0-14-generic running on amd64; UTF-8; es_ES (nb)
Are you willing to submit a pull request?
Yes
@johny65 please provide a minimal example project.
I had a shot look at this. I experimented with upgrading the bundled JSTL and upgrading the JSP compiler to the most recent Jakarta version. My key takeaways:
- both the javax version of jstl and the jakarta version can be packaged in the same module
- Apache Jasper (the JSP compiler) is tied hard to the Servlet API
- So depending on the project we need to either call the javax version of jasper together with the javax jstl or the corresponding jakarta version
- the
javax.servlet.jsppackages are used through out NetBeans and was considered a stable API. This needs to be abstracted to be able to switch implementations
@johny65 please have a look at #8976. That should take care of parsing jakarta based setups. A test/nightly build is available from the checks page for the next seven days. You can directly download it using this link: https://github.com/apache/netbeans/suites/48954433346/artifacts/4441900731.
I don't often use JSP features, so it would be great if you test this with new and old projects.
Hi @matthiasblaesing, thank you for your work. I'll test it as soon as possible.
It seems it's working fine, good job!
@johny65 thanks of testing! I did another pass, if nothing new comes up, I plan to merge to master in the not to distant future.