>"Morrison, John" a écrit :
>>
<skipped />
>>
>> So; should I put the code back to how it was prior to the getRealPath ->
>> getResource conversion or add tests for "if(servletContextPath != null)"
and
>> make the decision based on that?
>>
>> Can't we use the jndi protocol to get at the jar files?
>>
>No, because we want to be able to list the contents of a directory. We
>should switch back to getRealPath() all classpath stuff in
>CocoonServlet.

Why not use the META-INF/manifest.mf and set the Class-Path there?
CocoonServlet can use getResourceAsStream() to read the data from the file
then will create its classpath according to the list. I think that this is
the best solution for this problem.
IMO, getRealPath() must be never used, except if you use paths outside of
application context (e.g. for a log file, that can be placed anywhere in the
file system).

Regards,
    Konstantin Piroumian

>--
>Sylvain Wallez
>Anyware Technologies - http://www.anyware-tech.com



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

Reply via email to