Return-Path: Delivered-To: apmail-click-dev-archive@www.apache.org Received: (qmail 22491 invoked from network); 13 Mar 2010 06:22:35 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 13 Mar 2010 06:22:35 -0000 Received: (qmail 36878 invoked by uid 500); 13 Mar 2010 06:21:56 -0000 Delivered-To: apmail-click-dev-archive@click.apache.org Received: (qmail 36827 invoked by uid 500); 13 Mar 2010 06:21:56 -0000 Mailing-List: contact dev-help@click.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@click.apache.org Delivered-To: mailing list dev@click.apache.org Received: (qmail 36820 invoked by uid 99); 13 Mar 2010 06:21:55 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 13 Mar 2010 06:21:55 +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.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 13 Mar 2010 06:21:47 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 315A4234C4BF for ; Sat, 13 Mar 2010 06:21:27 +0000 (UTC) Message-ID: <1709685705.242511268461287201.JavaMail.jira@brutus.apache.org> Date: Sat, 13 Mar 2010 06:21:27 +0000 (UTC) From: "Henry Saputra (JIRA)" To: dev@click.apache.org Subject: [jira] Closed: (CLK-642) Fix the logic to manage Context with ThreadLocal In-Reply-To: <648849496.230551268416107453.JavaMail.jira@brutus.apache.org> 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/CLK-642?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Henry Saputra closed CLK-642. ----------------------------- Resolution: Not A Problem By design to resolve maintaining context during page forwarding > Fix the logic to manage Context with ThreadLocal > ------------------------------------------------ > > Key: CLK-642 > URL: https://issues.apache.org/jira/browse/CLK-642 > Project: Click > Issue Type: Bug > Components: core > Affects Versions: 2.2.0 > Reporter: Henry Saputra > Priority: Minor > Attachments: context_change.patch > > > Currently, the Context class maintains a ThreadLocal instance to store all contexts created for each Click request. However since Clck is using servlet mechanism, each request will be processed in a separate thread so there should be just a single Context in a thread execution lifetime. > Within a thread scope, we could just use ThreadLocal to manage a single context since ThreadLocal guarantee a unique instance per thread. > I dont think we need to manage the Context instances in ContextStack because there should be only one Context instance per request, which supported by execution in a separate thread for each request and ThreadLocal. > I created repository for Click in codereview.appspot.com to help with code review and created an entry for this JIRA: > http://codereview.appspot.com/471041/show -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.