[ 
https://issues.apache.org/jira/browse/MYFACES-3105?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Leonardo Uribe resolved MYFACES-3105.
-------------------------------------

       Resolution: Fixed
    Fix Version/s: 2.1.2
                   2.0.8
         Assignee: Leonardo Uribe

I checked it and even if no viewRoot on facesContext, the algorithm should 
calculate the renderKitId and get a valid RenderKit, because after all if this 
happens on an ajax request, the renderKitId could be on requestMap, or in the 
worst case, a valid response should be send. After all, if a redirect is sent, 
the next view will be the one that send the response, so if the view exists or 
not is something without importance.

> Navigation with redirect after ViewExpiredExpcetion throws NPE
> --------------------------------------------------------------
>
>                 Key: MYFACES-3105
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3105
>             Project: MyFaces Core
>          Issue Type: Bug
>          Components: General
>    Affects Versions: 2.0.6-SNAPSHOT
>         Environment: myfaces trunk
>            Reporter: Martin Kočí
>            Assignee: Leonardo Uribe
>             Fix For: 2.0.8, 2.1.2
>
>
> http://www.nfjsone.com/blog/ed_burns/2009/09/dealing_gracefully_with_viewexpiredexception_in_jsf2.
> MYFACES-3101 patch solves that for HTML request. 
> For partial/ajax request/response new problems appear: if you try to use 
> redirect like:
> /viewExpired.xhtml?faces-redirect=true
> myfaces throw NPE in 
> org.apache.myfaces.context.servlet.PartialViewContextImpl.getPartialResponseWriter(),
>  because 
> _facesContext.getRenderKit() returns null in this case (no view root is 
> available)
> Second easy to fix problem is line 
> facesContext.getViewRoot().getViewId().equals(newViewId) in 
> NavigationHandlerImpl.handleNavigation(FacesContext, String, String) in case 
> of navigationCase.isRedirect().

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to