Return-Path: Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: (qmail 96415 invoked from network); 15 Oct 2010 11:38:30 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 15 Oct 2010 11:38:30 -0000 Received: (qmail 36559 invoked by uid 500); 15 Oct 2010 11:38:27 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 36083 invoked by uid 500); 15 Oct 2010 11:38:23 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 36068 invoked by uid 99); 15 Oct 2010 11:38:22 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 15 Oct 2010 11:38:22 +0000 X-ASF-Spam-Status: No, hits=1.5 required=10.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [194.109.157.34] (HELO servers.realworks.nl) (194.109.157.34) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 15 Oct 2010 11:38:15 +0000 Received: from localhost (localhost [127.0.0.1]) by rwlinux40.colo.realworks.nl (Postfix) with ESMTP id A0526C4299 for ; Fri, 15 Oct 2010 13:37:50 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at rwlinux40.colo.realworks.nl Received: from servers.realworks.nl ([127.0.0.1]) by localhost (rwlinux40.colo.realworks.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tVCOpUAIVhBl for ; Fri, 15 Oct 2010 13:37:50 +0200 (CEST) Received: from rwlinux10.colo.realworks.nl (rwlinux10.colo.realworks.nl [10.0.10.60]) by rwlinux40.colo.realworks.nl (Postfix) with ESMTP id 7707AC41E5 for ; Fri, 15 Oct 2010 13:37:50 +0200 (CEST) Received: from rwlinux10.colo.realworks.nl (localhost [127.0.0.1]) by rwlinux10.colo.realworks.nl (Postfix) with ESMTP id 669B0AB258 for ; Fri, 15 Oct 2010 13:37:50 +0200 (CEST) Date: Fri, 15 Oct 2010 13:37:50 +0200 (CEST) From: Ronald Klop To: Tomcat Users List Message-ID: <13708918.158.1287142670284.JavaMail.tomcat@localhost> In-Reply-To: <20101015110033.GD11111@c3po> References: <20101015080212.GC11111@c3po> <32807776.111.1287138850583.JavaMail.tomcat@localhost> <20101015110033.GD11111@c3po> Subject: Re: lock session in distributed environment MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_157_20316813.1287142670275" X-Mailer: Realworks (2.8.0-CRM-20454-117650) X-Originating-Host: from (office-ext.base.nl [213.53.208.101]) by rwlinux10 [10.0.10.60] with HTTP (Apache Tomcat/6.0.29); Fri, 15 Oct 2010 13:37:50 +0200 X-Priority: 3 (Normal) Importance: Normal X-Originating-User-Agent: Mozilla/5.0 (X11; U; FreeBSD amd64; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.127 Safari/533.4 ------=_Part_157_20316813.1287142670275 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Op vrijdag, 15 oktober 2010 13:00 schreef Roman Makurin : > > > > On Fri, Oct 15, 2010 at 12:34:10PM +0200, Ronald Klop wrote: > > Op vrijdag, 15 oktober 2010 10:02 schreef Roman Makurin : > > > > > > > > >Hi All! > > > > > >I have an app which rely on session locking and its key > > >point here. Everything work on single tomcat instance, > > >but its completly broken in distributed env. So i want to > > >know is there any way to get my app working without > > >complete redesing? I need lock all incoming requests untill > > >business logic will be done, this lock must be > > >available on all nodes in cluster. > > > > > >any advise? > > > > > >Thanks > > > > > >-- > > >If you think of MS-DOS as mono, and Windows as stereo, > > > then Linux is Dolby Digital and all the music is free... > > > > > > > > > > > > > > > > > > > > > > > > This is something a database can do very well. There are also things like a distributed HashMap which you might use to do locking in your setup. But that probably is what you see as complete redesign (and it is :-) ). > > > > Ronald. > > Looks like HashMap is like distributed HttpSession object, > but does it support locking? Eg. I lock session at first > node and all other nodes r aware of this lock. > > > > > > > If you are locking with synchronized or something like that than it doesn't work between different JVM's. Ronald. ------=_Part_157_20316813.1287142670275--