Return-Path: Delivered-To: apmail-myfaces-users-archive@www.apache.org Received: (qmail 26436 invoked from network); 28 Mar 2008 18:46:37 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 28 Mar 2008 18:46:37 -0000 Received: (qmail 38051 invoked by uid 500); 28 Mar 2008 18:46:25 -0000 Delivered-To: apmail-myfaces-users-archive@myfaces.apache.org Received: (qmail 38019 invoked by uid 500); 28 Mar 2008 18:46:25 -0000 Mailing-List: contact users-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Discussion" Delivered-To: mailing list users@myfaces.apache.org Received: (qmail 38008 invoked by uid 99); 28 Mar 2008 18:46:25 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Mar 2008 11:46:25 -0700 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: local policy) Received: from [87.106.17.201] (HELO winterstein-it.de) (87.106.17.201) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 28 Mar 2008 18:45:44 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by winterstein-it.de (Postfix) with ESMTP id DE687C01018 for ; Fri, 28 Mar 2008 19:45:54 +0100 (CET) Received: from winterstein-it.de ([127.0.0.1]) by localhost (s15217351.onlinehome-server.info [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 26623-05 for ; Fri, 28 Mar 2008 19:45:54 +0100 (CET) Received: from [192.168.178.25] (p57B8B9AF.dip.t-dialin.net [87.184.185.175]) by winterstein-it.de (Postfix) with ESMTP id 756FBC0101B for ; Fri, 28 Mar 2008 19:45:54 +0100 (CET) Message-Id: <48521CC1-CBD6-4C9F-96E0-60E43A01BA4C@winterstein-web.de> From: Bernd Winterstein To: "MyFaces Discussion" In-Reply-To: <1206709877.6529.15.camel@simon-laptop> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v919.2) Subject: Re: orchestra conversation closed by stylesheet Date: Fri, 28 Mar 2008 19:45:54 +0100 References: <4AC0EA1B-E0C8-463C-896E-D6E117A4A816@winterstein-web.de> <1206709877.6529.15.camel@simon-laptop> X-Mailer: Apple Mail (2.919.2) X-Virus-Scanned: Debian amavisd-new at s15217351.onlinehome-server.info X-Virus-Checked: Checked by ClamAV on apache.org Hi Simon, many thanks for your tips. I checked the phase-listener solution, but it's a little dirty. The resource request skips phases 2-5. And the after RESTORE_VIEW callback is not called. In the before callback I do not know how to get the view id. As a solution i check the source component of the phase event. If it starts with org.ajax4jsf.resource.ResourceLifecycle I tell orchestra to ignore the request. It's not beautiful but it seems to work. Bernd Am 28.03.2008 um 14:11 schrieb simon: > Hi Bernd, > > On Fri, 2008-03-28 at 12:11 +0100, Bernd Winterstein wrote: >> Hi >> I have a one page conversation with access-scope. The page contains >> several tabs which are switched by Ajax calls. >> The first time the page is loaded the last request is a css download, >> upon which orchestra closes the conversation. The following requests >> for other tabs works perfect, the conversations stays open. >> >> >> Mrz 28 11:37:21 DEBUG >> org >> .apache.myfaces.orchestra.conversation.jsf.AccessScopePhaseListener >> invalidateAccessScopedConversations Clearing access-scoped >> conversation contactSearchController after rendering view /pages/ >> doctor_details.jsp >> <-- THIS IS OKAY(old page) >> >> Mrz 28 11:37:21 DEBUG >> org >> .apache.myfaces.orchestra.conversation.jsf.AccessScopePhaseListener >> invalidateAccessScopedConversations Not clearing accessed >> conversation doctorDetailsController after rendering view /pages/ >> doctor_details.jsp >> <-- THIS IS OKAY(NEW PAGE, CONVERSATION SHOULD STAY OPEN) >> >> >> Mrz 28 11:37:21 DEBUG >> org >> .apache.myfaces.orchestra.conversation.jsf.AccessScopePhaseListener >> invalidateAccessScopedConversations Clearing access-scoped >> conversation doctorDetailsController after rendering view /org/ >> richfaces/renderkit/html/css/basic_classes.xcss >> <-- THIS IS WHAT I DON'T understand > > You appear to have the suffix ".xcss" mapped to the FacesServlet, ie > that full facelets lifecycle (including phase listeners) is being run > when serving up that css file. > > That's not usual; normally a css is a static resource, and is not > served by the FacesServlet. Therefore the jsf phase-listeners do not > run and this will not occur. I suppose it's some odd RichFaces > feature that requires a JSF lifecycle to serve a css file. > > Orchestra's AccessScopeManagerConfiguration class can be configured > in spring to ignore specific view names: > > > name > = > "org > .apache > .myfaces.orchestra.conversation.AccessScopeManagerConfiguration" > > class > = > "org > .apache > .myfaces.orchestra.conversation.AccessScopeManagerConfiguration" > scope="singleton"> > ... define set of views to ignore here ... > > > However currently this supports only fixed view names, not patterns > like "*.xcss", so this doesn't help in your case. > > The AccessScopePhaseListener does also ignore requests, however, if > AccessScopeManager.getInstance().setIgnoreRequest() > has been called. So I suggest that you add a phase-listener which > just checks the current view-id, and if it ends with ".xcss" then > set the ignoreRequest state on the AccessScopeManager. Note that > this is just a request-scoped object, so there is no need to "reset" > the state. > > Regards, > Simon > > > See file spring-orchestra-init.xml within the orchestra jar for some > further details. > > The AccessScopePhaseLinstener. > > Hmm.. > So for now, you probably need to subclass the AccessScopeManager > class itself, > >