Parth Chandra created PARQUET-78:
------------------------------------
Summary: Provide a ByteBuffer based write path
Key: PARQUET-78
URL: https://issues.apache.org/jira/browse/PARQUET-78
Project: Parquet
Issue Type: Improvement
Components: parquet-mr
Reporter: Parth Chandra
Attachments: parquet-ByteBuffer-write.diff
Similar to the effort to use a ByteBuffer in the read path, we should provide a
path to use a ByteBuffer in the write path.
The proposed idea is to provide an allocator in the writer that is passed down
to CapacityByteArrayOutputStream and is used to allocate a ByteBuffer instead
of the byte array that it currently uses.
I've attached a patch based on the 1.5 release that does that. There are two
implementations of the allocator - one for Heap memory and one for Direct
memory. In addition, the allocator interface allows for a 'release' method so
that reference counted memory allocators like Netty's ByteBuf can be used to
provide an allocator.
--
This message was sent by Atlassian JIRA
(v6.2#6252)