Return-Path: X-Original-To: apmail-myfaces-dev-archive@www.apache.org Delivered-To: apmail-myfaces-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 97ED7371E for ; Mon, 2 May 2011 15:21:42 +0000 (UTC) Received: (qmail 94079 invoked by uid 500); 2 May 2011 15:21:42 -0000 Delivered-To: apmail-myfaces-dev-archive@myfaces.apache.org Received: (qmail 94044 invoked by uid 500); 2 May 2011 15:21:42 -0000 Mailing-List: contact dev-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Development" Delivered-To: mailing list dev@myfaces.apache.org Received: (qmail 94037 invoked by uid 99); 2 May 2011 15:21:42 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 May 2011 15:21:42 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 02 May 2011 15:21:41 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 3ADE8BD3E4 for ; Mon, 2 May 2011 15:21:03 +0000 (UTC) Date: Mon, 2 May 2011 15:21:03 +0000 (UTC) From: "alex musort (JIRA)" To: dev@myfaces.apache.org Message-ID: <2046057830.15412.1304349663237.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1111588526.24324.1301578325735.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (MYFACES-3101) NavigationHandlerImpl throws NullpointerException if view is expired MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/MYFACES-3101?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13027692#comment-13027692 ] alex musort commented on MYFACES-3101: -------------------------------------- Hello... I'm new using this technology and it's nice to see the problem I'm facing is solved. Could anyone tell me where can I get the jars files with the solution implemented?? thx > NavigationHandlerImpl throws NullpointerException if view is expired > -------------------------------------------------------------------- > > Key: MYFACES-3101 > URL: https://issues.apache.org/jira/browse/MYFACES-3101 > Project: MyFaces Core > Issue Type: Bug > Components: General > Affects Versions: 2.0.4 > Reporter: Martin Stockhammer > Fix For: 2.0.6-SNAPSHOT > > Attachments: MYFACES-3101-v2.patch, MYFACES-3101.patch > > > I tried to use the NavigationHandler inside a Faces exception handler to deal with ViewExpiredException as mentioned here: http://www.nfjsone.com/blog/ed_burns/2009/09/dealing_gracefully_with_viewexpiredexception_in_jsf2. > The example does not work with myfaces, because org.apache.myfaces.application.NavigationHandlerImpl throws a NullpointerException while handleNavigation() is called. > The exception occurs in line 160: String viewId = facesContext.getViewRoot().getViewId(); > I think the cause is that the viewroot is not set anymore when the ViewExpiredException is thrown. > The official API for NavigationHandler.handleNavigation tells, that the NullpointerException is thrown only if the given facescontext is null. > NullPointerException - if context is null -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira