[web-devel] simple-sendfile
Kazu Yamamoto ( 山本和彦 )
kazu at iij.ad.jp
Tue Jun 21 09:15:05 CEST 2011
Hello,
Sorry for the delay.
> Looks good, I'd love to merge this. I think the only thing we'd need
> modified to the simple-sendfile API is to accept a callback that's
> triggered each time a chunk is sent over the stream. How about:
>
> sendfile :: Socket -> FilePath -> FileRange -> IO () -> IO ()
I will change the API soon.
> I know it will hurt performance a bit, but what do you think of
> changing simple-sendfile to send in smaller chunks?
Since all sockets in Haskell are set as non-blocking, sendfile returns
with EAGAIN even in case of small files. So, changing API does not
change the current behavior. :)
--Kazu
More information about the web-devel
mailing list