Currently the RenderResponsePhase loops on the PreRenderViewEvent until the view ID remains unchanged before and after the listeners are notified. However, there is no check for whether the response has been flagged as complete using FacesContext#responseComplete(). The loop should short-circuit and the render step skipped if one of the listeners invokes this method (the check would remain in the same place, after all listeners are invoked on that pass).<br>
<br><a href="https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=1136">https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=1136</a><br><br>Essentially, a redirect is just as likely as a view ID change in a PreRenderViewEvent listener. This is a critical piece of implementing view actions as an extension. Although, there is one workaround. It&#39;s possible to call UIViewRoot#setRendered(false) to prevent the view from being rendered, but that is inconsistent with the standard mechanism, which is to call FacesContext#responseComplete().<br>
<br>-Dan<br clear="all"><br>-- <br>Dan Allen<br>Senior Software Engineer, Red Hat | Author of Seam in Action<br><br><a href="http://mojavelinux.com">http://mojavelinux.com</a><br><a href="http://mojavelinux.com/seaminaction">http://mojavelinux.com/seaminaction</a><br>
<a href="http://in.relation.to/Bloggers/Dan">http://in.relation.to/Bloggers/Dan</a><br><br>NOTE: While I make a strong effort to keep up with my email on a daily<br>basis, personal or other work matters can sometimes keep me away<br>
from my email. If you contact me, but don&#39;t hear back for more than a week,<br>it is very likely that I am excessively backlogged or the message was<br>caught in the spam filters.  Please don&#39;t hesitate to resend a message if<br>
you feel that it did not reach my attention.<br>