[ http://issues.apache.org/jira/browse/PB-45?page=all ]

Ate Douma reopened PB-45:
-------------------------

             
Stupid spelling error in the issue should be corrected

> Should not use instanceof on Portlet request interfaces to distinguise 
> ActionRequest from RenderRequest
> -------------------------------------------------------------------------------------------------------
>
>                 Key: PB-45
>                 URL: http://issues.apache.org/jira/browse/PB-45
>             Project: Portals Bridges
>          Issue Type: Bug
>          Components: jsf, struts
>    Affects Versions: 1.0
>         Environment: Undisclosed portal
>            Reporter: Ate Douma
>         Assigned To: Ate Douma
>             Fix For: 1.0.1
>
>
> The struts and jsf bridge currently use in a few situations instanceof on a 
> PortletRequest object to determine if a request is in the action or render 
> phase.
> Although many/most portals use different implementation objects for 
> ActionRequest and RenderRequest, this is certainly not a requirement by the 
> portlet specification (JSR-168).
> More in general, instanceof should never be used with interfaces to 
> *distinguise* implementations!
> The solution for the jsf and struts bridge is very simple: provide a specific 
> request attribute indicating which type of request phase the portlet 
> currently is in.
> The Struts bridge already uses and sets such an attribute and even uses this 
> in most circumstances and for the jsf bridge this is easily added as well.
> This issue was reported on the Pluto developer mailing list by John Lewis 
> (Portlet-MVC):
>     http://www.mail-archive.com/pluto-dev%40portals.apache.org/msg01091.html

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

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

Reply via email to