incubator-awf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Séven Le Mesle (JIRA) <>
Subject [jira] [Resolved] (DEFT-185) Use FileChannel.transferTo() instead of MappedByteBuffer
Date Mon, 19 Sep 2011 22:55:09 GMT


Séven Le Mesle resolved DEFT-185.

    Resolution: Fixed

waiting for review

> Use FileChannel.transferTo() instead of MappedByteBuffer
> --------------------------------------------------------
>                 Key: DEFT-185
>                 URL:
>             Project: Deft
>          Issue Type: New Feature
>          Components: Core
>    Affects Versions: 0.4.0
>            Reporter: Séven Le Mesle
>            Assignee: Séven Le Mesle
>             Fix For: 0.4.0
> Using a MappedByteBuffer to deliver static content is not good as we can not use kernel
sendFile directive when available.
> The FileChannel.transferTo() allows for such a feature and would be far better. Even
notice that MappedByteBuffer is memory consuming, with transferTo() on his side is light and
efficient (no buffers involved for many OS). 
> The only backside is that we need to take great care of the opened files !
> Work would be to replace MBB stuff with the transferTo call and store a FileInputStream
as key attachment, the underlying FileChannel can be used to maintain position.

This message is automatically generated by JIRA.
For more information on JIRA, see:


View raw message