portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Sean Taylor <da...@bluesunrise.com>
Subject Re: [J2] Proposal: Handling encoding requirements for the Portal URL
Date Fri, 27 Aug 2004 06:34:47 GMT
Ate Douma wrote:

>
>
> David Sean Taylor wrote:
>
>>> 6) Within Jetspeed, HttpServletRequest.getPathInfo() may not be used 
>>> anymore because it will first decode the the path string which can 
>>> again break the
>>> url parsing. Luckily, this can be easily circumvented by using the 
>>> following statement:
>>>   String pathInfo =
>>>     
>>> request.getRequestURI().substring(request.getContextPath().length()+
>>>                                       
>>> request.getServletPath().length());
>>>
>> I would like to review each individual place where getPathInfo is 
>> used before just blindly changing it.
>> One issue on Weblogic, during a request dispatcher's include, 
>> getContextPath() returns the path to the dispatched servlet, where as 
>> on Tomcat and JBoss, it returns the context path to the dispatching 
>> servlet
>
> The Servlet spec (2.3, SRV4.4) says:
>   It is important to note that, except for URL encoding differences 
> between the
>   request URI and the path parts, the following equation is always true:
>      requestURI = contextPath + servletPath + pathInfo
>
> Assuming Weblogic is compliant to the specs aren't the pathInfo (and 
> servletPath) then also be of the dispatched servlet?
>
 From reading this, SRV 8.3.1, it sounds like Weblogic is correct.
Regardless I've added a fail-safe to ensure the contextPath is always 
that of the portal.
Still, please run the pathInfo changes by me before committing so that I 
can test J2 and Fusion on Tomcat4, Tomcat5, JBoss, Weblogic, and Websphere
I have Fusion running on all these platforms. J2 not yet...


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message