[Bese-devel] Re: generated content with ucw

Marco Baringer mb at bese.it
Fri Feb 17 13:23:36 UTC 2006


Attila Lendvai wrote:
> ucw writes all its output into a string buffer (html-stream in the
> request, which is basically the same as *yaclml-stream*). i've managed
> to get hold of the raw network stream, but:
>  - it is hackend-dependent (no big deal)
>  - it doesnt work, because the entire html header is written in the
> string buffer and therefore it will be rendered _after_ the binary
> data i've written into the raw stream

this can be fixed by exposing the underlying content-stream as part of
the backend protocol. however this stream may or may not be bivalent.

> i hope Marco can shed some light on the issue and propose some
> solution that i would be more then happy to implement if i can manage.

you could try to first call (shutdown (context.request *context*)), this
should write out the headers, and then write directly to the
content-stream (which is, unfortunetly, backend specific).

> i tought of a new component similar to window-component, that somehow
> manages to bind *yaclml-stream* to the raw output stream and does not
> use the response string buffering. but i don't understand ucw
> internals enough for these things...

it wouldn't be that hard to create such a component, but you'll lose
much of ucw's error handling (the html erro pages at least, the slime
debugger hook should remain)

> any hints/plans for this?

ucw would be better with it, but i don't know when i'll get around to
it. it's not that hard really, but will require some carefull refactoring.

-- 
-Marco
Ring the bells that still can ring.
Forget the perfect offering.
There is a crack in everything.
That's how the light gets in.
	-Leonard Cohen




More information about the bese-devel mailing list