You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-dev@portals.apache.org by "Hubert Felber (JIRA)" <ji...@apache.org> on 2009/10/22 11:26:59 UTC

[jira] Created: (PLUTO-582) forwarding to jsp in action phase causes error if is used in jsp

forwarding to jsp in action phase causes error if  <portlet:defineObjects/> is used in jsp
------------------------------------------------------------------------------------------

                 Key: PLUTO-582
                 URL: https://issues.apache.org/jira/browse/PLUTO-582
             Project: Pluto
          Issue Type: Bug
    Affects Versions: 2.0.0
         Environment: windows, JBOSS 4.2.2 GA
            Reporter: Hubert Felber


in the action phase I do a

getPortletContext().getRequestDispatcher("test.jsp").forward(request,response);

in test.jsp I defined
<%@ taglib uri="http://java.sun.com/portlet_2_0" prefix="portlet" %>
<portlet:defineObjects/>

The compiled jsp then contains
      renderRequest = (javax.portlet.RenderRequest) _jspx_page_context.findAttribute("renderRequest");

which causes a 

javax.servlet.ServletException: javax.portlet.PortletException: java.lang.ClassCastException: org.apache.pluto.container.impl.ActionRequestImpl cannot be cast to javax.portlet.RenderRequest
	org.apache.pluto.driver.PortalDriverServlet.doGet(PortalDriverServlet.java:141)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
	org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (PLUTO-582) forwarding to jsp in action phase causes error if is used in jsp

Posted by "Ate Douma (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/PLUTO-582?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ate Douma resolved PLUTO-582.
-----------------------------

    Resolution: Cannot Reproduce

I cannot reproduce this problem.
Checking the implementation of the *pluto* portlet_2_0.tld and the corresponding <defineObject/> tag (DefineObjectsTag286.java) my suspicion is that you actually might be executing a different tag library implementation at runtime (maybe one from JBOSS Portal?).
The Pluto portlet_2_0.tld DefineObjectsTag286 implementation very clearly does not set the renderRequest attribute during an ACTION_PHASE, only during the RENDER_PHASE.

If you however can provide a reproducible test-case which somehow can prove this to be an error within the Pluto implementation, do reopen this issue.   

> forwarding to jsp in action phase causes error if  <portlet:defineObjects/> is used in jsp
> ------------------------------------------------------------------------------------------
>
>                 Key: PLUTO-582
>                 URL: https://issues.apache.org/jira/browse/PLUTO-582
>             Project: Pluto
>          Issue Type: Bug
>    Affects Versions: 2.0.0
>         Environment: windows, JBOSS 4.2.2 GA
>            Reporter: Hubert Felber
>
> in the action phase I do a
> getPortletContext().getRequestDispatcher("test.jsp").forward(request,response);
> in test.jsp I defined
> <%@ taglib uri="http://java.sun.com/portlet_2_0" prefix="portlet" %>
> <portlet:defineObjects/>
> The compiled jsp then contains
>       renderRequest = (javax.portlet.RenderRequest) _jspx_page_context.findAttribute("renderRequest");
> which causes a 
> javax.servlet.ServletException: javax.portlet.PortletException: java.lang.ClassCastException: org.apache.pluto.container.impl.ActionRequestImpl cannot be cast to javax.portlet.RenderRequest
> 	org.apache.pluto.driver.PortalDriverServlet.doGet(PortalDriverServlet.java:141)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:690)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
> 	org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.