Uploaded image for project: 'Pluto'
  1. Pluto
  2. PLUTO-600

HttpServletPortletRequestWrapper.getAttribute delegates to wrapped ServletRequest

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 2.1.0
    • portlet container
    • None

    Description

      The HttpServletPortletRequestWrapper.getAttribute(String) method is doing fall back to retrieve the attribute from the underlying ServletRequest

      // First try to retrieve the attribute from the (possibly buffered/cached/previously set) portletRequest
      Object value = portletRequest.getAttribute(name);
      // if null, fall back to retrieve the attribute from the web container itself
      return value != null ? value : getRequest().getAttribute(name);
      

      The problem with this is it nullifies the portal's ability to influence the request attributes that can be seen by a portlet and any servlets it dispatches to via the PortletRequestContext. Since the default PortletRequestContextImpl in Pluto already has the ServletRequest.getAttribute(String) fallback code I believe it can be removed from HttpServletPortletRequestWrapper.

      Attachments

        Activity

          People

            edalquist Eric Dalquist
            edalquist Eric Dalquist
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: