xmltask usage in plugins using old XPATH API
Post here questions and problems related to editing and publishing DITA content.
-
- Posts: 13
- Joined: Thu Feb 04, 2010 10:37 pm
xmltask usage in plugins using old XPATH API
Hi,
I have recently updated to v25 with the updated JDK.
Executing:
"C:\Ixiasoft\og\client-og-6.3\data\dita-ot-2.5.4/bin/dita.bat" -v -f xhtml-client -o C:\Ixiasoft\projects\client\Hazard-and-Warning\Hazards_Warnings_and_Cautions.Export[DRM].English\content\authoring/out/xhtml-client -t C:\Ixiasoft\projects\client\Hazard-and-Warning\Hazards_Warnings_and_Cautions.Export[DRM].English\content\authoring/temp/xhtml-client -i C:\Ixiasoft\projects\client\Hazard-and-Warning\Hazards_Warnings_and_Cautions.Export[DRM].English\content\authoring\nze1529959654580.ditamap "-Dclean.temp=no"
init:
dita2xhtml-client.init:
Error: java.lang.IllegalAccessError: class com.oopsconsultancy.xmltask.jdk15.XPathAnalyser15 (in unnamed module @0x16612a51) cannot access class com.sun.org.apache.xpath.internal.XPathAPI (in module java.xml) because module java.xml does not export com.sun.org.apache.xpath.internal to unnamed module @0x16612a51
From what I can gather from Googling things I need to add the following as JVM option. I still get the error whne I add it to the JVM arguments section of the scenario. What's the best way to resolve this issue?
"--add-opens java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED"
If I add "-Dadd-opens=java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED" on the command line for the OT (copied from oxygen), then this works fine outside of oxygen. But I can't seem to get it too work inside oxygen via the JVM Argument in the scenario.
I have recently updated to v25 with the updated JDK.
Executing:
"C:\Ixiasoft\og\client-og-6.3\data\dita-ot-2.5.4/bin/dita.bat" -v -f xhtml-client -o C:\Ixiasoft\projects\client\Hazard-and-Warning\Hazards_Warnings_and_Cautions.Export[DRM].English\content\authoring/out/xhtml-client -t C:\Ixiasoft\projects\client\Hazard-and-Warning\Hazards_Warnings_and_Cautions.Export[DRM].English\content\authoring/temp/xhtml-client -i C:\Ixiasoft\projects\client\Hazard-and-Warning\Hazards_Warnings_and_Cautions.Export[DRM].English\content\authoring\nze1529959654580.ditamap "-Dclean.temp=no"
init:
dita2xhtml-client.init:
Error: java.lang.IllegalAccessError: class com.oopsconsultancy.xmltask.jdk15.XPathAnalyser15 (in unnamed module @0x16612a51) cannot access class com.sun.org.apache.xpath.internal.XPathAPI (in module java.xml) because module java.xml does not export com.sun.org.apache.xpath.internal to unnamed module @0x16612a51
From what I can gather from Googling things I need to add the following as JVM option. I still get the error whne I add it to the JVM arguments section of the scenario. What's the best way to resolve this issue?
"--add-opens java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED"
If I add "-Dadd-opens=java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED" on the command line for the OT (copied from oxygen), then this works fine outside of oxygen. But I can't seem to get it too work inside oxygen via the JVM Argument in the scenario.
-
- Posts: 9436
- Joined: Fri Jul 09, 2004 5:18 pm
Re: xmltask usage in plugins using old XPATH API
Hi Eric,
So you have a custom DITA OT publishing engine probably delivered by Ixiasoft and you are running it from inside Oxygen XML Editor right?
And more recent versions of Oxygen are bundled with Java 17 which shows such errors when using content that it considers to be non-API.
So:
This should work, of course there should be an "=" after the "--add-opens" (something like --add-opens=java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED)but I suppose you have it like that on your side. You can take a look at the command line line Oxygen creates to run the DITA OT, if it contains that extra "--add-opens" after the path to the Java executable then things should work.
Regards,
Radu
So you have a custom DITA OT publishing engine probably delivered by Ixiasoft and you are running it from inside Oxygen XML Editor right?
And more recent versions of Oxygen are bundled with Java 17 which shows such errors when using content that it considers to be non-API.
So:
Indeed the "JVM Arguments" field in the transformation scenario is the proper place where to place the extra add-opens.From what I can gather from Googling things I need to add the following as JVM option. I still get the error whne I add it to the JVM arguments section of the scenario. What's the best way to resolve this issue?
"--add-opens java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED"
This should work, of course there should be an "=" after the "--add-opens" (something like --add-opens=java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED)but I suppose you have it like that on your side. You can take a look at the command line line Oxygen creates to run the DITA OT, if it contains that extra "--add-opens" after the path to the Java executable then things should work.
I'm not sure if using "-D..." works, this is used to pass system property name/value pairs. But add-opens instructions are not system properties, they need to have the form --add-opens=java.base/java.net=ALL-UNNAMEDIf I add "-Dadd-opens=java.xml/com.sun.org.apache.xpath.internal=ALL-UNNAMED" on the command line for the OT (copied from oxygen), then this works fine outside of oxygen. But I can't seem to get it too work inside oxygen via the JVM Argument in the scenario.
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 2
- Joined: Wed Oct 05, 2022 10:02 pm
Re: xmltask usage in plugins using old XPATH API
I've run into a similar situation with the xmltask ant task (v. 1.16 from oopsconsultancy.com). This is bundled with our dita-ot plugin and works fine on Oxygen 23, but when the same plugin is run from Oxygen 25, it fails. When I grab the xmltask.jar from org.doctales.xmltask (v.1.17 from a fork of the original), this works fine in Oxygen 25. I'm assuming this is some sort of incompatibility with the Java version in Oxygen 25. I may just end up using the JAR file from org.doctales.xmltask, but first, I'll diff the source so I can see what has changed.
No question. Just information that may be helpful to others running into this issue.
...scott
No question. Just information that may be helpful to others running into this issue.
...scott
Return to “DITA (Editing and Publishing DITA Content)”
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service