Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 58079 invoked from network); 8 Nov 2005 13:17:07 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 8 Nov 2005 13:17:06 -0000 Received: (qmail 30263 invoked by uid 500); 8 Nov 2005 13:17:03 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 29739 invoked by uid 500); 8 Nov 2005 13:17:02 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@cocoon.apache.org List-Id: Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 29728 invoked by uid 99); 8 Nov 2005 13:17:01 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Nov 2005 05:17:01 -0800 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: neutral (asf.osuosl.org: local policy) Received: from [84.96.21.10] (HELO mail.anyware-tech.com) (84.96.21.10) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Nov 2005 05:16:55 -0800 Received: from localhost (localhost [127.0.0.1]) by mail.anyware-tech.com (Postfix) with ESMTP id 83E3F33A6C for ; Tue, 8 Nov 2005 14:16:44 +0100 (CET) Received: from mail.anyware-tech.com ([127.0.0.1]) by localhost (trinity [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 13497-03 for ; Tue, 8 Nov 2005 14:16:42 +0100 (CET) Received: from [10.0.0.27] (poukram.anyware [10.0.0.27]) by mail.anyware-tech.com (Postfix) with ESMTP id D2DDE33A6D for ; Tue, 8 Nov 2005 14:16:42 +0100 (CET) Message-ID: <4370A535.4000703@apache.org> Date: Tue, 08 Nov 2005 14:16:37 +0100 From: Sylvain Wallez User-Agent: Thunderbird 1.4.1 (Macintosh/20051006) MIME-Version: 1.0 To: dev@cocoon.apache.org Subject: Re: Global variables in flowscript References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at anyware-tech.com X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N Ugo Cei wrote: > I am feeling a little confused. What is the expected behavior of te > following flowscript code: > > var x = 0; > > function fun() { print(++x); } > > when it is invoked multiple times by the same user? > > I am always getting "1" (with 2.1.8-rc1) as if the value of the global > variable wasn't retained between invocations. I expected to get an > incrementing sequence of values. Don't you have some session-related problems that could be caused by a proxy server in front of the servlet engine? Sylvain -- Sylvain Wallez Anyware Technologies http://people.apache.org/~sylvain http://www.anyware-tech.com Apache Software Foundation Member Research & Technology Director