On 9/24/01 3:09 PM, "Jason van Zyl" <[EMAIL PROTECTED]> wrote:
> On 9/24/01 2:57 PM, "Santiago Gala" <[EMAIL PROTECTED]> wrote:
>
>> Yes. Raphael sent a patch to Velocity for enabling the mixing of
>> different portlets in the same request. I'm not sure if this patch is
>> already in velocity cvs. I think we should release when we get a
>> Turbine-2.2+Velocity-1.2 release.
>
> We've seen this patch, and I'm not sure this is the best approach. It works
> for your portlets but I'm not sure if it's the best thing for the velocity
> code base. I think the thread of discussion petered out, I don't know where
> it stands. I don't think Geir was too thrilled with the patch.
The problem was that it forces a flush after every reference render, rather
than let the Writer buffer.
(I don't think this would have worked completely, as you would also want it
after literals, but that's another issue.)
The problem it was solving, if I remember, is that you want to flush to the
OutputStream in order that the intermixed portlet output goes out to the
client in the correct order.
Why couldn't the portlet framework do the flush before invoking a portlet?
You would have to give a reference to the Writer to the 'portlet tool' in
the Velocity context, but that seems like it would be manageable. (Or some
kind of wrapper...)
That way, Velocity can be as efficient as possible, taking advantage of the
buffering of the Writer, and yet the bytes will be flushed before any
portlet writes....
geir
--
Geir Magnusson Jr. [EMAIL PROTECTED]
System and Software Consulting
"Whoever would overthrow the liberty of a nation must begin by subduing the
freeness of speech." - Benjamin Franklin
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]