[xmlc] Issues with XMLC 2.3.2

Sasa Bojanic <[email protected]> Mon, 07 Mar 2011 13:56:15 +0100
Newsgroups gmane.comp.java.enhydra.xmlc
Message-ID <[email protected]>
This is a multi-part message in MIME format...

------------=_1299502591-30467-14566
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

Hi,

I'm trying to upgrade our applications that use XMLC 2.3.1 to the newest 
XMLC version.
Our applications are deployed both under the Tomcat 6.0.29 application 
server and Enhydra application server (based on Tomcat 6.0.29).

There are two issues I faced:

1) when deploying under the Tomcat, XMLC JAR files are placed together 
with the application JAR files into application's WEB-INF\lib folder (so 
application classloader is used to load them). In this case, XMLC can't 
load resources (*.html and *.xmlc files) from JAR file. When resources 
are not in the JAR file but unpacked into WEB-INF\classes folder 
everything works.

After "patching" the method getPathURLFromClasspath() from 
XMLCDeferredParsingFactory to add:

       if (srcURL != null && srcURL.toString().indexOf(".jar") >= 0) {
             try {
                String mdurl = srcURL.toString();
                srcURL = new URL("jar:"
                                 + mdurl.substring(0, 
mdurl.indexOf(".jar")) + ".jar!/"
                                 + mdurl.substring(mdurl.indexOf(".jar") 
+ 4));
             } catch (Exception ex) {
          }
       }

after the line:

       URL srcURL = fDynamicClassLoader.getResource(path);

it works fine.

2) when deploying under Enhydra application server or under Tomcat, but 
instead of putting XMLC JAR files into application's WEB-INF\lib, we put 
it into Tomcat's lib folder, XMLC can't find resources no matter if 
resources are inside JAR file or unpacked, and it can't find it even in 
the case I put application's JAR file into Tomcat's lib folder.

Is it a bug in XMLC? Can somebody help?

Regards,
Sasa.


------------=_1299502591-30467-14566
Content-Type: text/plain; charset="UTF-8"; name="message-footer.txt"
Content-Disposition: inline; filename="message-footer.txt"
Content-Transfer-Encoding: quoted-printable


--
You receive this message as a subscriber of the [email protected] mailing list=
.
To unsubscribe: mailto:[email protected]
For general help: mailto:[email protected]?subject=3Dhelp
OW2 mailing lists service home page: http://www.ow2.org/wws

------------=_1299502591-30467-14566--