Looks like a simple versioning error to me; you're doctype declaration:
> <!DOCTYPE struts-config PUBLIC
> "-//Apache Software Foundation//DTD Struts Configuration
1.3//EN"
> "http://jakarta.apache.org/struts/dtds/struts-config_1_3.dtd">
But you said:
> But, the struts-config_1_3.dtd is not in the struts.jar file (we're
> using Struts 1.2.9)
I wouldn't expect 1.2.9 to contain a 1.3 DTD... Either upgrade to Struts
1.3.9 or use the DTD corresponding to the release you are on:
<!DOCTYPE struts-config PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 1.2//EN"
"http://struts.apache.org/dtds/struts-config_1_2.dtd">
L.
Adam Gordon wrote:
Last night, our company had a maintenance window whereby Internet access
was shut off from our office to the outside world. During that time I
was doing development and attempted to start up our web app in a
development environment.
I've not seen this error in almost 2 years but it's apparently back:
[org.apache.struts.action.ActionServlet] [handleConfigException] Parsing
error processing resource path /WEB-INF/struts-optout.xml
java.net.UnknownHostException: jakarta.apache.org
at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:177)
at java.net.Socket.connect(Socket.java:520)
at java.net.Socket.connect(Socket.java:470)
at sun.net.NetworkClient.doConnect(NetworkClient.java:157)
...*snip*...
I remember this well. The problem is that struts-optout.xml has the
DOCTYPE of:
<!DOCTYPE struts-config PUBLIC
"-//Apache Software Foundation//DTD Struts Configuration 1.3//EN"
"http://jakarta.apache.org/struts/dtds/struts-config_1_3.dtd">
But, the struts-config_1_3.dtd is not in the struts.jar file (we're
using Struts 1.2.9) so, apparently in order to validate that the XML
file is well-formed at webapp start up time, Tomcat feels the need to go
out and retrieve this DTD - only it can't because Internet access was
down. The problem is greatly exacerbated by the fact that Tomcat stops
processing the loading of struts modules when this one fails essentially
rendering the web app useless.
I seem to recall playing with turning validation of XML files off, but
that not being a sufficient solution so I tried adding the DTD into the
struts JAR file in the same location as the other DTDs:
org/apache/struts/resources/struts-config_1_x.dtd (where x=0,1,2) but
that didn't work.
We need to be able to find a solution to where we can host the DTDs
locally and do not have to rely on a 3rd party server being up in order
to deploy our web application. I seem to recall this being an issue
with the W3C (especally w.r.t. [X]HTML validation in that it results in
a ton of unnecessary network calls to retrieve DTDs for validation
rather than web servers hosting the DTDs locally.
I'm sure I'm not the only one to have seen this so any help to resolve
this would be greatly appreciated. Thanks.
-- adam
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]