Jean-Francois Arcand a écrit :



Henri Gomez wrote:

I traced TC 5.0 and Digester and suspect what could be the problem
with external entities when only SYTEM is defined ie :


<!ENTITY appset1 SYSTEM "appset1.xml"> <!ENTITY appset2 SYSTEM "appset2.xml">


In Digester.java, at least in the 1.5 release, resolveEntity return null if publicId is null even if systemId is set.

To make it works, I just replaced :

--

        if (entityURL == null){
        return (null);

by ---

        if (entityURL == null){
            if (systemId == null)
                   return (null);
               else
                   entityURL = systemId;
        }


FYI, in resolveEntity we got as parms for previous app1&app2 entities declaration:

systemid="jndi:/localhost/myapp/WEB-INF/appset1.xml" and publicid=null

systemid="jndi:/localhost/myapp/WEB-INF/appset2.xml" and publicid=null


This hack will solve the resolution of entities presents in WEB-INF.


That's strange since in Tomcat 5, the resolver is under o.a.c.u.SchemaResolver. Have you change something there? You should customize that class instead of the Digester one (will be easier and doesn't require commons-dev folks).

Nope, I'm using a standard TC 5.0.12 from inside my Eclipse IDE.


I double check another time today...

BTW, my webapp is not in c:/jakarta-tomcat-5.0.12/webapps but in c:\eclipse\workspace\customer\webapp.

So in server.xml I've got :

<Context path="/myapp" docBase="c:\eclipse\workspace\customer\webapp" debug="99" >







---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to