Hi all,

I'm stuck using axis2-1.5.4.

Here's what I think is happening:

Axis2 does this sort of container-in-a-container thing. It creates its own
classloader and pulls in all of its jar libraries dynamically. The problem
is that it uses a java.net.URL to target the files. This would be fine
except for the problem that the folder name, when using parallel
deployment, is

/path/to/yourWar##12345

So (from org.apache.axis2.deployment.util.Utils)

    public static URL[] getURLsForAllJars(URL url, File tmpDir) {
        FileInputStream fin = null;
        InputStream in = null;
        ZipInputStream zin = null;
        try {
            ArrayList array = new ArrayList();
            in = url.openStream();

The problem is that URL was constructed from a File object in the
org.apache.axis2.deployment.repository.util.DeploymentFileData.setClassLoader(boolean,
ClassLoader, File) method using the toURL() method. The toURL() method is
deprecated because it doesn't escape special characters, namely the "##" in
the path.

When it hits url.openStream() it is discarding everything after the ##nnnnn
part of the path (think hash value in a web URL). It throws a
"java.io.FileNotFoundException: /path/to/yourWar (No such file or
directory)"

Getting in there and patching axis2-1.5.4 is less-than-desirable. So many
things to go wrong.

Is there a way to alter the way tomcat unpacks the warfile? Is there a way
to configure the version delimiters from ## to perhaps ~~ or $$ ?

CG

Reply via email to