Hi, thank you for the advices, I did that :
--- a/plugins/sfEadPlugin/modules/sfEadPlugin/templates/indexSuccessHeader.xml.php
+++ b/plugins/sfEadPlugin/modules/sfEadPlugin/templates/indexSuccessHeader.xml.php
@@ -1,2 +1 @@
<?php echo '<?xml version="1.0" encoding="'.sfConfig::get('sf_charset', 'UTF-8')."\" ?>\n" ?>
-<!DOCTYPE ead PUBLIC "+//ISBN 1-931666-00-8//DTD ead.dtd (Encoded Archival Description (EAD) Version 2002)//EN" "http://lcweb2.loc.gov/xmlcommon/dtds/ead2002/ead.dtd">
and this worked around the first error (I now get another one, see below), but this seems to confirm something : something in the backend is not using the local dns resolver of my server, since I spoofed
lcweb2.loc.gov on my local domain and before my template edit AtoM was still getting the 403 errors from the real lcweb2.loc.gov server. So maybe, the code does not only uselessly fetch that DTD on every validation, but also query some unknown DNS server instead of using system one (and local caches), adding more useless traffic on the Internet.
The new error I get is this one:
[info] [2022-01-19 00:42:45] Job 131645 "arFindingAidJob": Job started.
[info] [2022-01-19 00:42:45] Job 131645 "arFindingAidJob": Generating finding aid (xxxxxxxx)...
[info] [2022-01-19 00:42:45] Job 131645 "arFindingAidJob": Running: java -jar '/var/www/xxxxxxxx/lib/task/pdf/saxon9he.jar' -s:'/tmp/phpjnGICP' -xsl:'/var/www/xxxxxxxx/lib/task/pdf/ead-pdf-inventory-summary.xsl' -o:'/tmp/phplyZfiP' 2>&1
[info] [2022-01-19 00:42:47] Job 131645 "arFindingAidJob": Running: fop -r -q -fo '/tmp/phplyZfiP' -pdf '/var/www/xxxxxxxx/downloads/xxxxxxxx.pdf' 2>&1
[info] [2022-01-19 00:42:47] Job 131645 "arFindingAidJob": Converting the EAD FO to PDF has failed.
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): [warning] /usr/bin/fop: JVM flavor 'sun' not understood
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): [warning] /usr/bin/fop: Unable to locate avalon-framework in /usr/share/java
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): Exception in thread "main" java.lang.NoSuchMethodError: java.nio.CharBuffer.limit(I)Ljava/nio/CharBuffer;
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FOText.characters(FOText.java:143)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FObjMixed.characters(FObjMixed.java:74)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FOTreeBuilder$MainFOHandler.characters(FOTreeBuilder.java:390)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FOTreeBuilder.characters(FOTreeBuilder.java:136)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xalan.transformer.TransformerIdentityImpl.characters(TransformerIdentityImpl.java:1126)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.AbstractSAXParser.characters(Unknown Source)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.xinclude.XIncludeHandler.characters(Unknown Source)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanContent(Unknown Source)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:485)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:293)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:116)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.Main.startFOP(Main.java:183)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.Main.main(Main.java:214)
[info] [2022-01-19 00:42:49] Job 131645 "arFindingAidJob": Job finished.
My Java version is OpenJDK 1.8.0 (from Ubuntu 20.04 LTS):
$ java -version
openjdk version "1.8.0_312"
OpenJDK Runtime Environment (build 1.8.0_312-8u312-b07-0ubuntu1~20.04-b07)
OpenJDK 64-Bit Server VM (build 25.312-b07, mixed mode)
I see two warnings and then an exception :
[info] [2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP): [warning] /usr/bin/fop: JVM flavor 'sun' not understood
[info]
[2022-01-19 00:42:48] Job 131645 "arFindingAidJob": ERROR(FOP):
[warning] /usr/bin/fop: Unable to locate avalon-framework in
/usr/share/java
[info] [2022-01-19 00:42:48] Job 131645
"arFindingAidJob": ERROR(FOP): Exception in thread "main"
java.lang.NoSuchMethodError:
java.nio.CharBuffer.limit(I)Ljava/nio/CharBuffer;
I don't know if the first one is significant.
For the second one I installed libavalon-framework-java and then, the second warning was gone but I still get an exception after the first warning:
[info] [2022-01-26 18:22:11] Job 131759 "arFindingAidJob": Job started.
[info] [2022-01-26 18:22:11] Job 131759 "arFindingAidJob": Generating finding aid (xxxxxxxx)...
[info] [2022-01-26 18:22:11] Job 131759 "arFindingAidJob": Running: java -jar '/var/www/xxxxxxxx/lib/task/pdf/saxon9he.jar' -s:'/tmp/php00pefN' -xsl:'/var/www/xxxxxxxx/lib/task/pdf/ead-pdf-inventory-summary.xsl' -o:'/tmp/php9rtzPN' 2>&1
[info] [2022-01-26 18:22:13] Job 131759 "arFindingAidJob": Running: fop -r -q -fo '/tmp/php9rtzPN' -pdf '/var/www/xxxxxxxx/downloads/xxxxxxxx.pdf' 2>&1
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": Converting the EAD FO to PDF has failed.
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): [warning] /usr/bin/fop: JVM flavor 'sun' not understood
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): Exception in thread "main" java.lang.NoSuchMethodError: java.nio.CharBuffer.limit(I)Ljava/nio/CharBuffer;
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FOText.characters(FOText.java:143)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FObjMixed.characters(FObjMixed.java:74)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FOTreeBuilder$MainFOHandler.characters(FOTreeBuilder.java:390)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.fo.FOTreeBuilder.characters(FOTreeBuilder.java:136)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xalan.transformer.TransformerIdentityImpl.characters(TransformerIdentityImpl.java:1126)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.AbstractSAXParser.characters(Unknown Source)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.xinclude.XIncludeHandler.characters(Unknown Source)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanContent(Unknown Source)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
[info] [2022-01-26 18:22:14] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:485)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:293)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:116)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.Main.startFOP(Main.java:183)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": ERROR(FOP): at org.apache.fop.cli.Main.main(Main.java:214)
[info] [2022-01-26 18:22:15] Job 131759 "arFindingAidJob": Job finished.
The issue looks similar to this one faced by another software:
https://github.com/netty/netty/issues/10593Instead that, on my end, it looks like I get the opposite one, Java 8 reporting there is no signature for a method that is newer. Maybe I'll have to update to a newer JDK.