Buffer Sainity QNA
Bill Burke
bburke at redhat.com
Thu Oct 20 17:18:48 EDT 2011
One thing I noticed is that there's a lot of copying going on in Netty.
Specifically from the NIO ByteBuffer to a ChannelBuffer with every
request.
On 10/20/11 5:13 PM, Trustin Lee wrote:
> Netty provides composite buffers and dynamically growing buffers.
> However, they are usually used for heap buffers rather than dynamic
> buffers. If you have good control over the life cycle of the direct
> buffers you allocated, you could write your own ChannelBufferFactory to
> utilize direct buffers without worrying OOME.
>
> HTH
>
>
> On Thursday, October 20, 2011 at 3:51 AM, qballer wrote:
>> Hi guys,
>>
>> I have an ongoing work on some buffer issues I'm facing, you can read
>> more
>> http://stackoverflow.com/questions/7780034/looking-for-a-does-everything-buffer-in-java-decided-to-work-with-netty
>> here.
>>
>>
>> Basically, I'm developing a system that distributes large amounts of
>> data to
>> different servers. I would like to work with direct mapped buffers,
>> because
>> I think I will enjoy from faster deployment of my data through out the
>> system. still I don't know what will be my buffer sizes. I'm considering
>> developing my own Composite Buffer. This will expose the Buffer Chanel
>> interface, but will hold a collection of direct buffers, I will just
>> do the
>> work of "connecting" them, making the user think he has one huge buffer.
>>
>>
>> I would like to hear you opinion on this solution since this is my first
>> time using such technologies, NIO in general and Netty specifically. I
>> might
>> just understandg/doing something all wrong.
>>
>>
>> Specific questions:
>>
>> Did any of you guys implemented something like this?
>> is there any solution like that in The Netty project?
>> Does my solution makes sense to you or am I missing a core concept of
>> Netty?
>> Feel free to share any other input you have.
>>
>> Thanks,
>> Qballer
>>
>>
>> --
>> View this message in context:
>> http://netty-forums-and-mailing-lists.685743.n2.nabble.com/Buffer-Sainity-QNA-tp6912457p6912457.html
>> Sent from the Netty User Group mailing list archive at Nabble.com
>> <http://Nabble.com>.
>> _______________________________________________
>> netty-users mailing list
>> netty-users at lists.jboss.org <mailto:netty-users at lists.jboss.org>
>> https://lists.jboss.org/mailman/listinfo/netty-users
>
>
>
> _______________________________________________
> netty-users mailing list
> netty-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/netty-users
--
Bill Burke
JBoss, a division of Red Hat
http://bill.burkecentral.com
More information about the netty-users
mailing list