myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dora Rajappan <dorarajap...@yahoo.com>
Subject Re: [core] [discuss] Re: [jira] [Reopened] (MYFACES-3817) ajax redirect/navigation loosing state information when changes are executed with redirect/navigation
Date Tue, 17 Dec 2013 14:12:55 GMT
It is found that jsf is not able to send two responses to a request.
It is good to send view state with redirect response
<partial-response><changes><update id="j_id__v_0:javax.faces.ViewState:1"><![CDATA[XwZtxeX0oVV/pnTpYxnYBjkE26xY0NEL6/EG8tk4DMwc26zV]]></update></changes><redirect
url="/portlet-bridge-facelets-guess/guesscdiPartial.jsf"></redirect></partial-response>
Its not possible to support maximum sequential views to 100% with this constraint.



On Friday, December 13, 2013 10:54 PM, Dora Rajappan <dorarajappan@yahoo.com> wrote:
  
 
How about sending view state  to client side for navigation cases via action listener (including
ajax) as below?
<?xml version="1.0" encoding="UTF-8"?><partial-response><changes><update
id="j_id__v_0:javax.faces.ViewState:1"><![CDATA
[t9QSM5G6nfM6AJSbI5c1b4flUv63+nMJEut/BNVSBvDhSnkg]]></update></changes></partial-response>



On Thursday, December 12, 2013 6:22 PM, Dora Rajappan (JIRA) <dev@myfaces.apache.org>
wrote:
  

     [ https://issues.apache.org/jira/browse/MYFACES-3817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel]

Dora Rajappan reopened MYFACES-3817:
------------------------------------


According to http://myfaces.apache.org/core21/myfaces-impl/webconfig.html
NUMBER_OF_SEQUENTIAL_VIEWS_IN_SESSION  include redirect.

org.apache.myfaces.NUMBER_OF_SEQUENTIAL_VIEWS_IN_SESSION 2.0.6  Indicates the amount of views
(default is not active) that should be stored in session between sequential
 POST or POST-REDIRECT-GET if org .

Hence the in NavigationHandler the viewmap need not be cleared for redirect. After redirect
from page1 to page2 subsequent navigation to page1 can fetch the view from viewmap when serialisation
is applied. Now it fetches the view from tree.





>  ajax redirect/navigation loosing state information when changes are executed with redirect/navigation
> ------------------------------------------------------------------------------------------------------
>
>                 Key: MYFACES-3817
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3817
>             Project: MyFaces Core
>          Issue Type: Bug
> 
         Components: General
>    Affects Versions: 2.2.0-beta
>         Environment: Windows 8
>            Reporter: Dora Rajappan
>   Original Estimate: 0.8h
>  Remaining Estimate: 0.8h
>
>  Ajax redirect/navigation loosing state information when changes are executed with redirect. 
This can be addressed 
> #1 By putting a  flag in redirect and write it in response after save state in rendering
phase.
> #2 This behaviour true for redirect via navigation handler. In render phase it goes to
response complete and state saving is avoided. When its a redirect not make the response complete
true and flag it so that in rendering phase state is saved.



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