[jboss-user] [JBoss Seam] - Re: Incremental UI updates in AJAX with rich client state
do-not-reply at jboss.com
Fri May 11 11:38:29 EDT 2007
"mdoraisamy" wrote : Too good to be true!
| How does ICEFaces know what changed without any support from the object graph ?
| Does it manage the previous request's DOM to be able to indentify the changes ?
| Does it render the object graph into DOM and then does the comparision ?
| Is it a comparision by doing a full scan of DOM tree?
Of course, we reserve the right to make internal optimizations in ICEfaces or even radically change the implementation -- such things can be done because we only need to preserve the contract to the developer that standard JSF pages will behave as expected, but they will be updated smoothly and efficiently via Ajax. Currently, though, ICEfaces uses a technique called Direct-to-DOM rendering: The component tree is rendered into a DOM on the server (the output of the components is not parsed, the responseWriter is used like an inverse-SAX for efficiency) and a previous DOM is compared with the current DOM to determine an incremental update. The DOMs are scanned fully, but subtrees are not traversed when differences are found (we will be enhancing this algorithm in the future, but I won't go into that detail here).
"mdoraisamy" wrote :
| If i have returned a value from a query (or intensive processing) in an bean getter will it get executed irrespective of the change ? (which itself is not a problem but to understand the behaviour, so that i can model app correctly)
If the getter is for a property referenced by a component rendered on the page, it will be called (this is a JSF behavior, not an ICEfaces behavior). When an application has expensive getters, we typically recommend some form of caching, either in the beans themselves or in the persistence layer.
"mdoraisamy" wrote :
| Any reference/document that explains how ICEFaces does incremental UI updates should be of great help in pushing this case forward in my company. Thanks.
The ICEfaces architecture is described in the Developer's guide, but the implementation details have varied over time. It's probably best just to ask us questions on the areas that interest you.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4045044#4045044
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4045044
More information about the jboss-user