<br><br><div class="gmail_quote">On Fri, May 29, 2009 at 5:30 PM, Gavin King <span dir="ltr">&lt;<a href="mailto:gavin.king@gmail.com">gavin.king@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
OK, Dan, I&#39;ll have to respect your judgment on this because I&#39;m not up<br>
to date on how this stuff works in JSF2.<br>
<br>
So I&#39;m happy to make changes with respect to JSF conversation<br>
propagation rules if it doesn&#39;t disrupt/delay the RI team (Pete,<br>
WDYT?) and if there are no objections from the EG (anyone?).</blockquote><div><br>No, no objection here.  <br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
<br>
But it seems that you&#39;re asking for two changes here:<br>
<br>
(1) that the conversation is restored at the beginning of RESTORE_VIEW</blockquote><div><br>Is there any reason we can&#39;t require the conversation to be restored before the invocation of any servlet filter?  <br> </div>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
(2) that you want some kind of conversation propagation to other servlets<br>
<br>
Change (1) seems a pretty straightforward change.<br>
<br>
So we get to (2).<br>
<br>
Currently we don&#39;t even have a built-in conversation context in<br>
servlets and we would need some kind of additional rules surrounding<br>
conversation propagation between servlets. I think what you are<br>
suggesting is that the conversation is propagated whenever there is a<br>
request parameter named &quot;cid&quot; containing the conversation id, and that<br>
it is the user&#39;s responsibility to pass it along through the view.<br>
That doesn&#39;t sound unreasonable to me at this moment, and is probably<br>
not very difficult to specify.<br>
<br>
However, I&#39;m concerned about two things here:<br>
<br>
(a) we don&#39;t provide a way to propagate conversations by a &quot;natural<br>
id&quot; held in some other request parameter - yes, I know we don&#39;t<br>
provide that for JSF either, but in the servlet world it seems even<br>
more important.<br>
(b) impact upon the RI timetable.<br>
<br>
Today we can provide a portable extension that does conversation<br>
propagation in servlets, using cid, or natural ids. If we bake<br>
something into the spec, that becomes a little more difficult.<br>
<br>
So I want to know that this is *really* something that we should<br>
address in this release.</blockquote><div><br>I agree, we don&#39;t need to specify conversation propagation for any servlet request.  Frameworks can handle propagation however is convenient to them.<br><br>
<br><br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
<div><div></div><div class="h5"><br>
On Thu, May 28, 2009 at 9:32 PM, Dan Allen &lt;<a href="mailto:dan.j.allen@gmail.com">dan.j.allen@gmail.com</a>&gt; wrote:<br>
&gt; Gavin,<br>
&gt;<br>
&gt; Since you reached an interlude (however brief it may be), I&#39;d like to take<br>
&gt; the opportunity to reconsider the conversation context lifecycle. Currently,<br>
&gt; the spec states:<br>
&gt;<br>
&gt; - For a JSF faces request, the context is active from the beginning of the<br>
&gt; apply request values phase until the response is complete.<br>
&gt; - For a JSF non-faces request, the context is active during the render<br>
&gt; response phase.<br>
&gt;<br>
&gt; I feel that these boundaries are two narrow. I&#39;ll focus first on the faces<br>
&gt; request. In Seam, it&#39;s necessary to delay resuming the conversation until<br>
&gt; the apply request values phase because the conversation id is stored in the<br>
&gt; view root. At one time, the conversation context was even stored in the view<br>
&gt; root, making it even more imperative. But we get a chance to start fresh.<br>
&gt;<br>
&gt; There are three factors that call for the boundaries to be extended:<br>
&gt;<br>
&gt; - As of JSF 2.0, parts of the component tree is visited in the restore view<br>
&gt; phase, which happens to resolve value expressions bound to UIData<br>
&gt; components. This triggers a scope not active exception if a<br>
&gt; conversation-scoped bean is hit.<br>
&gt; - JSF 2.0 gives us far greater flexibility to control inbound and outbound<br>
&gt; requests. So it&#39;s no longer necessary to store the id in the view root. The<br>
&gt; query string would be sufficient (I&#39;ve already modified Web Beans to<br>
&gt; prototype this)<br>
&gt; - Servlets on subsequent requests may want to participate in the<br>
&gt; conversation (and perhaps even servlet filters)<br>
&gt;<br>
&gt; For all of these reasons, I&#39;d like the conversation lifecycle to wrap the<br>
&gt; entire JSF lifecycle and i&#39;d like the conversation id to be propagated using<br>
&gt; a query string parameter since that&#39;s the most universal way of propagating<br>
&gt; state. As a result, custom servlets can read this value and restore the<br>
&gt; conversation as needed. It&#39;s really inconvenient for the conversation id to<br>
&gt; be hidden away into the component tree, aside from being problematic in JSF<br>
&gt; 2.0.<br>
&gt;<br>
&gt; Please reconsider. Thanks.<br>
&gt;<br>
&gt; -Dan<br>
&gt;<br>
&gt; --<br>
&gt; Dan Allen<br>
&gt; Senior Software Engineer, Red Hat | Author of Seam in Action<br>
&gt;<br>
&gt; <a href="http://mojavelinux.com" target="_blank">http://mojavelinux.com</a><br>
&gt; <a href="http://mojavelinux.com/seaminaction" target="_blank">http://mojavelinux.com/seaminaction</a><br>
&gt; <a href="http://in.relation.to/Bloggers/Dan" target="_blank">http://in.relation.to/Bloggers/Dan</a><br>
&gt;<br>
&gt; NOTE: While I make a strong effort to keep up with my email on a daily<br>
&gt; basis, personal or other work matters can sometimes keep me away<br>
&gt; from my email. If you contact me, but don&#39;t hear back for more than a week,<br>
&gt; it is very likely that I am excessively backlogged or the message was<br>
&gt; caught in the spam filters.  Please don&#39;t hesitate to resend a message if<br>
&gt; you feel that it did not reach my attention.<br>
&gt;<br>
</div></div><div class="im">&gt; _______________________________________________<br>
&gt; webbeans-dev mailing list<br>
&gt; <a href="mailto:webbeans-dev@lists.jboss.org">webbeans-dev@lists.jboss.org</a><br>
&gt; <a href="https://lists.jboss.org/mailman/listinfo/webbeans-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/webbeans-dev</a><br>
&gt;<br>
&gt;<br>
<br>
<br>
<br>
</div><font color="#888888">--<br>
Gavin King<br>
<a href="mailto:gavin.king@gmail.com">gavin.king@gmail.com</a><br>
<a href="http://in.relation.to/Bloggers/Gavin" target="_blank">http://in.relation.to/Bloggers/Gavin</a><br>
<a href="http://hibernate.org" target="_blank">http://hibernate.org</a><br>
<a href="http://seamframework.org" target="_blank">http://seamframework.org</a><br>
</font><div><div></div><div class="h5"><br>
_______________________________________________<br>
webbeans-dev mailing list<br>
<a href="mailto:webbeans-dev@lists.jboss.org">webbeans-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/webbeans-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/webbeans-dev</a><br>
</div></div></blockquote></div><br>