SVGs sometimes show "www.w3.org:80 failed to respond"

Having trouble installing Oxygen? Got a bug to report? Post it all here.
chrispitude
Posts: 907
Joined: Thu May 02, 2019 2:32 pm

SVGs sometimes show "www.w3.org:80 failed to respond"

Post by chrispitude »

Sometimes in the DITA editor, SVG images show up as broken links with the following error:
Cannot display image
<svg filename>

www.w3.org:80 failed to respond
(http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd)

To reload the image please use the Reload (F5 key) action.
Our company firewall is fairly conservative. Pings to external IPs are blocked completely so I can't assess the connection stability.

Is there a way to cache or suppress verification connections to DTD ports?

Strangely, this is random. If I close and reload the document, a different set of images might have issues. And some days are better than others, so for me the behavior isn't deterministic.
Radu
Posts: 9051
Joined: Fri Jul 09, 2004 5:18 pm

Re: SVGs sometimes show "www.w3.org:80 failed to respond"

Post by Radu »

Hi Chris,

I have a hunch (based on various sample projects I received from you) that in the Oxygen Preferences->"Document Type Association" page you unchecked the "SVG" framework configuration. The "SVG" framework configuration comes with an XML catalog which maps remote referenced DTDs like "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd" to resources located in the Oxygen OXYGEN_INSTALL_DIR\frameworks\svg\dtd folder.
So once you disabled the framework Oxygen will no longer use the XML catalog to resolve remote references to SVG DTDs, so it will start asking for the DTDs on the web.
About this remark:
Strangely, this is random. If I close and reload the document, a different set of images might have issues.
A while ago the W3C web site added some kind of constraint on their web server so that if an HTTP client asks for DTDs in fast succession (and Oxygen may do that if you have multiple images in the same document) the W3C server will issue a timeout and refuse to serve the files. They made this decision because they wanted to discourage applications from downloading the standard schemas from their web site and overload their servers.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
chrispitude
Posts: 907
Joined: Thu May 02, 2019 2:32 pm

Re: SVGs sometimes show "www.w3.org:80 failed to respond"

Post by chrispitude »

Radu, your hunch is correct! :) It's working much better now.

I had unchecked all the formats our writers would not be editing, thinking that it would improve the performance of their editing experience (opening files, etc.). Should I simply re-enable everything? Is there any performance or user-experience penalty for doing so?
chrispitude
Posts: 907
Joined: Thu May 02, 2019 2:32 pm

Re: SVGs sometimes show "www.w3.org:80 failed to respond"

Post by chrispitude »

Hmmm, I wonder if I broke something. Reenabling all frameworks results in responsive SVG display in the editor when opening topics (hooray!). However, I still see the following messages in the PDF Chemistry log file, and PDF publishing takes an extremely long time:

Code: Select all

     [exec] 22643 INFO [ main ] org.apache.http.impl.execchain.RetryExec - I/O exception (org.apache.http.NoHttpResponseException) caught when processing request to {}->http://www.w3.org:80: The target server failed to respond
     [exec] 22644 INFO [ main ] org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://www.w3.org:80
     [exec] 24375 INFO [ main ] org.apache.http.impl.execchain.RetryExec - I/O exception (org.apache.http.NoHttpResponseException) caught when processing request to {}->http://www.w3.org:80: The target server failed to respond
     [exec] 24376 INFO [ main ] org.apache.http.impl.execchain.RetryExec - Retrying request to {}->http://www.w3.org:80
Is there another setting I need to alter to enable DTD caching for PDF Chemistry?
Radu
Posts: 9051
Joined: Fri Jul 09, 2004 5:18 pm

Re: SVGs sometimes show "www.w3.org:80 failed to respond"

Post by Radu »

Hi Chris,

So:
Reenabling all frameworks results in responsive SVG display in the editor when opening topics (hooray!).
Great, you do not need to disable frameworks, you will not gain any performance improvement by doing so.
However, I still see the following messages in the PDF Chemistry log file, and PDF publishing takes an extremely long time
Usually in such cases to test this on my side I disable the network adapter and try to publish to PDF, if all goes well then the process should not contact any Web server at all during the publishing process.
But in this case indeed the final processing stage which takes the SVG and embeds it in the PDF seems indeed to need extra XML catalogs, catalogs that our DITA OT publishing plugin does not pass to it.
I added an issue to look into this, the Chemistry engine has support to add XML catalogs to it:

https://www.oxygenxml.com/doc/versions/ ... rface.html

but they do not seem to be passed to the final stage of the PDF construction.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply