You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Reinhard Poetz <re...@apache.org> on 2008/03/12 08:22:32 UTC

[ssf] context path

Grzegorz Kossakowski wrote:
> reinhard@apache.org pisze:
>> Author: reinhard
>> Date: Tue Mar 11 03:58:38 2008
>> New Revision: 635881
>>
>> URL: http://svn.apache.org/viewvc?rev=635881&view=rev
>> Log:
>> the context attribute might not exist
>>
> [...]
> 
>> +        if(contextPath != null) {
>> +            int tmp = contextPath.indexOf(':');
>> +            boolean tmp2 = !(contextPath.startsWith("file:") || contextPath.startsWith("/") || contextPath.indexOf(':') == -1);
> 
> This is not a solution IMHO. I forgot to bring this issue to mailing list, my fault. Actually, I
> think we should disallow empty context-path and mount-path attributes because there is no sane way
> to handle such cases. If you don't set contextPath, then you break a contract in ServletContext
> class because getResource() method no longer works.
> 
> I think we should just change our schema and throw an exception when any of attributes is null.

after thinking about it again, it makes sense to me.

-- 
Reinhard Pötz                            Managing Director, {Indoqa} GmbH
                           http://www.indoqa.com/en/people/reinhard.poetz/

Member of the Apache Software Foundation
Apache Cocoon Committer, PMC member, PMC Chair        reinhard@apache.org
_________________________________________________________________________

Re: [ssf] context path

Posted by Grzegorz Kossakowski <gr...@tuffmail.com>.
Reinhard Poetz pisze:
>>
>> This is not a solution IMHO. I forgot to bring this issue to mailing
>> list, my fault. Actually, I
>> think we should disallow empty context-path and mount-path attributes
>> because there is no sane way
>> to handle such cases. If you don't set contextPath, then you break a
>> contract in ServletContext
>> class because getResource() method no longer works.
>>
>> I think we should just change our schema and throw an exception when
>> any of attributes is null.
> 
> after thinking about it again, it makes sense to me.

Done in r636472.

-- 
Grzegorz Kossakowski