myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dora Rajappan <dorarajap...@yahoo.com>
Subject Re: [jira] [Comment Edited] (MYFACES-3804) Use the same key in server side state saving for ajax requests
Date Wed, 13 Nov 2013 11:31:03 GMT
 
" What happens now is  in invoke application executor the action is processed and navigation
handled and next view is created and this view is in same execute cycle and this overwrites
the ajax view and gets rendered with ajax view id in the page."

This behaviour of showing a previous view id in the page with new view gives rise to ViewExpiredException
after a few navigations back and forth. It is required to show the view id of the new view
in the page when navigating through action listener.

 



On Wednesday, November 6, 2013 2:40 PM, Dora Rajappan <dorarajappan@yahoo.com> wrote:
  
Well thanks Mike. Its possible to view the unedited comments from mail list and edited ones
in Jira. But expressions such as smileys are not good in mail list :) 
 
 
Regarding use the same key in server side state saving for ajax requests it is ok since use
of navigation with ajax is  rare and so may be redirect.
 
 



On Tuesday, November 5, 2013 9:56 PM, Mike Kienenberger (JIRA) <dev@myfaces.apache.org>
wrote:
  

    [ https://issues.apache.org/jira/browse/MYFACES-3804?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13814014#comment-13814014]


Mike Kienenberger edited comment on MYFACES-3804 at 11/5/13 4:24 PM:
---------------------------------------------------------------------

Dora,

We need to move discussion to the developer mailing list, and reserve the JIRA for resolving
issues.
There are a number of reasons why the JIRA issue is not the best place for discussion, which
I wrote
 about here:

http://mail-archives.apache.org/mod_mbox/myfaces-dev/201311.mbox/%3CCAM1yOjZHhSRwrAQ2Va_Em0yAcPD9mA9D-7daCG7z-eHfr%3DZ0-g%40mail.gmail.com%3E

I'm sorry that I didn't speak up a while back when I first noticed it happening, but we need
to resume using the developer mailing list for its intended purpose.   Please repost your
comments from here directly on the developer mailing list.



was (Author: mkienenb):
Dora,

We need to move discussion to the developer mailing list, and reserve the JIRA for resolving
issues.
There are a number of reasons why the
 JIRA issue is not the best place for discussion, which I wrote about here:

http://mail-archives.apache.org/mod_mbox/myfaces-dev/201311.mbox/%3CCAM1yOjZHhSRwrAQ2Va_Em0yAcPD9mA9D-7daCG7z-eHfr%3DZ0-g%40mail.gmail.com%3E

I'm sorry that I didn't speak up a while back when I first noticed it happening, but we need
to resume using the developer mailing list for its intended purpose.


> Use the same key in server side state saving for ajax requests
> --------------------------------------------------------------
>
>                 Key: MYFACES-3804
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3804
>         
    Project: MyFaces Core
>          Issue Type: Improvement
>          Components: JSR-344
>            Reporter: Leonardo Uribe
>         Attachments: ajaxviewkeytest.patch, ajaxviewkeytest2.patch, ajaxviewsamekey.patch,
ajaxviewsamekey2.patch, ajaxviewsamekey3.patch
>
>
> The current code for server side state saving creates one key per request to store the
view state. This is ok, but it is not necessary for ajax requests. 
> The reason why is not necessary is because you can never go back to a page when using
ajax. If you are on page A and the current request is an ajax request and it returns to the
same page and the view is the same that the one that has been restored, the key or the token
sent
 does not need to change, what changes is the internal state of the view. From the client
side the page is
 the same. We can take advantage of this fact and just update the state stored in SerializedViewCollection
for the view. 
> The challenge here is detect when this strategy is applicable. For example, what happen
if there is an ajax redirect? It looks is a good idea for implement in 2.2, because it avoids
to store unnecessary information into session and optimize the use of each view slot. 



--
This message was sent by Atlassian JIRA
(v6.1#6144)
Mime
View raw message