Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-15 Thread Yuan Gao
Thanks for the comment. Yes. The caller will call responseComplete(). Thanks, -Yuan On 3/14/2011 4:09 PM, Scott O'Bryan wrote: So the caller would do the responseComplete after rendering the noop, right? If so, that looks MUCH better to me.. +1 On Mar 14, 2011, at 5:06 PM, Yuan

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-14 Thread Yuan Gao
hi, Andy, I like your comments. As for the names, how about renderNoopAndCompleteResponse()? Thanks, -Yuan On 3/13/2011 7:48 AM, Andy Schwartz wrote: Hi Bernd - I am a bit hesitant about the names as well. Three possible options: 1.

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-14 Thread Andy Schwartz
Hi Yuan - On Mon, Mar 14, 2011 at 3:10 AM, Yuan Gao yuan@oracle.com wrote: I like your comments. As for the names, how about renderNoopAndCompleteResponse()? That's definitely the clearest of the names that we have discussed. :-) If we go with render, I can see three options: 1.

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-14 Thread Scott O'Bryan
Yes, I agree Andy. That proposed API scared me a bit because it seemed that we were trying to do to much in a single method call. There was a redirect message, a script and noop params. If we can separate them and use the real redirect functionality built into the EC, I'm good. :D On Mar 14,

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-14 Thread Yuan Gao
hi, I agree that we are trying to do too much in a method. Also talked with Blake about it. How about we leave the script and redirect to the caller, in this method we only do the noop writing? We don't do the complete response either. How do you like this then? /** * This method

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-14 Thread Scott O'Bryan
So the caller would do the responseComplete after rendering the noop, right? If so, that looks MUCH better to me.. +1 On Mar 14, 2011, at 5:06 PM, Yuan Gao yuan@oracle.com wrote: hi, I agree that we are trying to do too much in a method. Also talked with Blake about it. How about we

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-13 Thread Bernd Bohmann
Hello, completed is the right term? Is something else in the response? Perhaps 'render' is the better alternative. Regards Bernd On Sun, Mar 13, 2011 at 2:44 AM, Scott O'Bryan darkar...@gmail.com wrote: +1 to all of these comments.. On Mar 12, 2011, at 10:57 AM, Andy Schwartz

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-13 Thread Andy Schwartz
Hi Bernd - I am a bit hesitant about the names as well. Three possible options: 1. completeNoopResponse()/completeScriptResponse()/completeRedirectResponse(). 2. renderNoopResponse()/renderScriptResponse()/renderRedirectResponse(). 3.

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-13 Thread Andy Schwartz
Btw - another variant would be to drop the Response suffix from the method names. Andy On Mar 13, 2011, at 10:48 AM, Andy Schwartz andy.g.schwa...@gmail.com wrote: Hi Bernd - I am a bit hesitant about the names as well. Three possible options: 1.

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-13 Thread Scott O'Bryan
I like the idea of having three more simple API's although I think the redirect is unnecessary.. That should be handled correctly by ExtenalContext.redirect, even in PPR environments. On Mar 13, 2011, at 8:57 AM, Andy Schwartz andy.g.schwa...@gmail.com wrote: Btw - another variant would be to

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-13 Thread Scott O'Bryan
Also, I'm wondering if we might be able to do something Wih the no-op as well. For instance, can our XmlHttpResponseWriter detect whether content has been rendered before the response complete and? If it hasn't, send the noop response. Don't know if it's possible but simply needing to set

Re: propose a new utility API in PartialPageUtils to complate the response

2011-03-12 Thread Scott O'Bryan
+1 to all of these comments.. On Mar 12, 2011, at 10:57 AM, Andy Schwartz andy.g.schwa...@gmail.com wrote: Yuan - The documentation/contract isn't especially clear: * This method completes the PPR request and writes a noop/ to the response. * it also handles script and redirect I

propose a new utility API in PartialPageUtils to complate the response

2011-03-11 Thread Yuan Gao
hi, I'd like to propose a new utility API to complete the PPR response. Talked with Blake and we suggest to put it in PartialPageUtils. Here is the JIRA: https://issues.apache.org/jira/browse/TRINIDAD-2061 Please review. Thanks, -Yuan