Return-Path: Delivered-To: apmail-myfaces-dev-archive@www.apache.org Received: (qmail 41460 invoked from network); 12 Jan 2011 06:56:12 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 12 Jan 2011 06:56:12 -0000 Received: (qmail 30765 invoked by uid 500); 12 Jan 2011 06:56:11 -0000 Delivered-To: apmail-myfaces-dev-archive@myfaces.apache.org Received: (qmail 30515 invoked by uid 500); 12 Jan 2011 06:56:11 -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 30489 invoked by uid 99); 12 Jan 2011 06:56:09 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Jan 2011 06:56:09 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Jan 2011 06:56:06 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id p0C6tjJn023829 for ; Wed, 12 Jan 2011 06:55:45 GMT Message-ID: <20841436.307501294815345606.JavaMail.jira@thor> Date: Wed, 12 Jan 2011 01:55:45 -0500 (EST) From: "Gurkan Erdogdu (JIRA)" To: dev@myfaces.apache.org Subject: [jira] Commented: (MYFACES-3006) FacesContext current instance is null in managed bean action method for Tomcat 7 In-Reply-To: <12027101.266601293022620771.JavaMail.jira@thor> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/MYFACES-3006?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12980595#action_12980595 ] Gurkan Erdogdu commented on MYFACES-3006: ----------------------------------------- As I indicated in the code, I am closing another non-JSF application context, not current running JSF application context. Therefore, your observation is not correct > FacesContext current instance is null in managed bean action method for Tomcat 7 > -------------------------------------------------------------------------------- > > Key: MYFACES-3006 > URL: https://issues.apache.org/jira/browse/MYFACES-3006 > Project: MyFaces Core > Issue Type: Bug > Affects Versions: 2.0.2 > Reporter: Gurkan Erdogdu > Assignee: Leonardo Uribe > > Hello, > Actually I am not sure that this is an error related with MyFaces. > In a managed bean action method, I have stopped an application "Tomcat Context"(not same with the current JSF application). > public String stopContext(){ > > FacesContext.getCurrentInsatnce() --> It is ok, faces context is not null > Context context = get Tomcat application context; > //Stop tomcat context > context.stop(); --> This is any application on Tomcat, not same with current JSF application > FacesContext.getCurrentInstance() --> Problem, it is NULL > } > I think that Tomcat clear current JSF application thread locals. But I ask to stop other application context, therefore it must not destroy current application thread locals. > What do you think? -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.