[JAVAEETUTORIAL-127] mention timeouts and render complete handling Created: 12/Jul/12  Updated: 16/Aug/12  Resolved: 25/Jul/12

Status: Resolved
Project: javaeetutorial
Component/s: doc
Affects Version/s: 6.0.7-5
Fix Version/s: None

Type: Improvement Priority: Major
Reporter: Brant Gurganus Assignee: Kim Haase
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


These issues may not apply to this Ajax implementation, but they come up with the PrimeFaces implementation, and I don't see them addressed here yet so I wanted to mention them as something I'd like to know: How can an Ajax timeout be handled? How can the timeout duration be set? That is, if the server doesn't reply in 5 seconds, go into some timeout handling scenario instead of waiting indefinitely for a response that may never come. You can simulate this scenario by setting a breakpoint in the server while a backing bean method is called. The server connection is still open but no response is going to come. Network issues and server issues can cause these, and a robust application needs to handle those scenarios. The other issue we see is: We have races between the AJAX partial response being rendered and JavaScript that applies to what gets rendered. The way to handle that would be listening for an partial update rendered event or setting a callback to be called when the partial update is completed rendering. So are there mechanisms to do that?

Comment by Brant Gurganus [ 12/Jul/12 ]

This is prompted by the "Using Faces with Facelets" page at http://docs.oracle.com/javaee/6/tutorial/doc/gkabr.html

Comment by Brant Gurganus [ 12/Jul/12 ]

Looks like onevent might handle the timeout scenario, but I don't see a way to set the timeout duration yet.

Comment by Kim Haase [ 25/Jul/12 ]

I'm told by the JSF spec folks that there will be a "delay" attribute in the next release of JSF that should accomplish what you need. It'll be documented at that time.

Generated at Thu Nov 26 08:51:37 UTC 2015 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.