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

Leonardo Uribe commented on MYFACES-3779:
-----------------------------------------

Precisely the point is the weight of all actives jsf views in the application 
is usually very small compared with the additional information stored into 
session. We can say in the most simple application (the booking application 
from the performance comparison) is about less than 20%, and in complex 
applications that difference becomes less and less because the key point is 
watch out all beans stored in session (view, conversation, flow, access, 
session). This is the reason why I'm saying "...  it is required more 
information about the usefulness of the change proposed from performance 
perspective. ...".

In my personal opinion, if I have to choose between server side (more bandwith 
- more cpu availability - less server memory) and client side (less bandwith - 
less cpu availability  - more server memory) I would prefer server side, 
because it does not grow as fast as you can imagine, and the bandwidth/cpu 
tends to limit the overall throughput of the system more quickly (note that 
depends on the average session size we are talking about). The evidence 
gathered suggest these days first you reach the theoretical maximum number of 
concurrent clients than fill the available memory and get an 
OutOfMemoryException (it depends of what you have as hardware, of course). New 
evidence will be most welcomed.

In any case, I would prefer a simpler approach, just something that you can say 
"... this view or this group of views should use client side state saving with 
these params, but this other group use server side with these params ...".

But maybe the real problem is not in JSF, and what we need is something in the 
web server (Tomcat) to send the whole session to the client.

Suggestions are welcome.
                
> Mixed mode(Server+client) for state saving
> ------------------------------------------
>
>                 Key: MYFACES-3779
>                 URL: https://issues.apache.org/jira/browse/MYFACES-3779
>             Project: MyFaces Core
>          Issue Type: New Feature
>            Reporter: Ertio Lew
>
> How about having a mixed mode for state saving whereby state is initially 
> kept on server for a configurable amount of time (so that fast frequent 
> requests are served without transferring the state from client to server 
> several times, the drawback with client side saving) & after that period of 
> time if the page is still alive in browser but it is idle, a javascript 
> request is triggered which asks the server for that state data & now it will 
> be kept on client side, now the client & the server both know that state for 
> this session is there on client. If the page has died & no request has been 
> sent to server asking for state data till that period of time, then state 
> data would be removed from server.
> A further enhancement could be that you could set a fixed amount out of all 
> memory on server that you want to allocate for state saving of all sessions. 
> Till the time that quota remains, state is kept on server using that quota. 
> But when that quota is over all the state information for further sessions is 
> kept using client side state saving. Also a mixed mode.
> Such mixed modes would be very helpful in improving performance, & better 
> utilization of the server resources.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to