thrift-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jake Luciani <jak...@gmail.com>
Subject Re: How to make use of new ByteBuffer features in Java
Date Tue, 19 Oct 2010 17:34:38 GMT
"There’s some trickiness that goes into understanding why the first element
in the backing byte array is arrayOffset() + position(), but for right now,
trust me that it’s the case."

Can you explain this? also, remaining() is defined as limit() - position()
so when you say out.write(value.array(), value.arrayOffset() +
value.position(), value.remaining());
Won't you overflow?

-Jake

On Tue, Oct 19, 2010 at 1:27 PM, Bryan Duxbury <bryan@rapleaf.com> wrote:

> I wrote up a very quick explanation about how you might make use of the new
> ByteBuffer features in Java Thrift 0.5 to achieve a zero-copy system:
>
>
> http://blog.rapleaf.com/dev/2010/10/19/striving-for-zero-copies-with-thrift-0.5/
>
> I'd love your feedback!
>
> -Bryan
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message