That could definitely work.

I'd still (even for curiosity's sake) be interested in lower level
access to the response, e.g. response.write that goes right out to the
client.

On Dec 22, 7:36 pm, David Pollak <feeder.of.the.be...@gmail.com>
wrote:
> On Tue, Dec 22, 2009 at 4:28 PM, Alex Black <a...@alexblack.ca> wrote:
> > Hi David,
>
> > Its a huge-ass google sitemap, so I'm forming XML for it, and its
> > really large, and I thought I'd send chunks of it out at a time rather
> > than composing all of it in RAM before sending it out.
>
> How about composing it as a big file on disk and use the StreamingResponse
> class?
>
>
>
>
>
>
>
> > - Alex
>
> > On Dec 22, 5:56 pm, David Pollak <feeder.of.the.be...@gmail.com>
> > wrote:
> > > On Tue, Dec 22, 2009 at 2:38 PM, Alex Black <a...@alexblack.ca> wrote:
> > > > I've got a large response I'd like to send out, and I'd like to chunk
> > > > it up.
>
> > > >http://en.wikipedia.org/wiki/Chunked_transfer_encoding
>
> > > > Does Lift provide any built in support for this?
>
> > > No.
>
> > > > I've explored using StreamingResponse, but it expects a dataLength,
> > > > which I don't have.  I had hoped to provide it a stream which would
> > > > provide each chunk.
>
> > > > Is there a lower level mechanism to write data out?
>
> > > Not really.  Can you describe your use case a little more?  For very
> > large
> > > responses (e.g., a large PDF), in what case would you not know the
> > length?
>
> > > > - Alex
>
> > > > --
>
> > > > You received this message because you are subscribed to the Google
> > Groups
> > > > "Lift" group.
> > > > To post to this group, send email to lift...@googlegroups.com.
> > > > To unsubscribe from this group, send email to
> > > > liftweb+unsubscr...@googlegroups.com<liftweb%2bunsubscr...@googlegroups.com
> > > >  >
> > <liftweb%2bunsubscr...@googlegroups.com<liftweb%252bunsubscr...@googlegroup 
> > s.com>>
> > > > .
> > > > For more options, visit this group at
> > > >http://groups.google.com/group/liftweb?hl=en.
>
> > > --
> > > Lift, the simply functional web frameworkhttp://liftweb.net
> > > Beginning Scalahttp://www.apress.com/book/view/1430219890
> > > Follow me:http://twitter.com/dpp
> > > Surf the harmonics
>
> > --
>
> > You received this message because you are subscribed to the Google Groups
> > "Lift" group.
> > To post to this group, send email to lift...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > liftweb+unsubscr...@googlegroups.com<liftweb%2bunsubscr...@googlegroups.com 
> > >
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/liftweb?hl=en.
>
> --
> Lift, the simply functional web frameworkhttp://liftweb.net
> Beginning Scalahttp://www.apress.com/book/view/1430219890
> Follow me:http://twitter.com/dpp
> Surf the harmonics

--

You received this message because you are subscribed to the Google Groups 
"Lift" group.
To post to this group, send email to lift...@googlegroups.com.
To unsubscribe from this group, send email to 
liftweb+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/liftweb?hl=en.


Reply via email to