[ 
https://issues.apache.org/jira/browse/HBASE-13387?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14505509#comment-14505509
 ] 

ramkrishna.s.vasudevan commented on HBASE-13387:
------------------------------------------------

I was always for throwing Exception but after discussions I think am ok either 
way.  Because we are any way introducing new APIs to handle Buffer's offset.
[~stack]
If you want to throw exceptions then having offset APIS for BBs wont make 
sense.  Because when we have both the type of getXXXOffset() and 
getXXXBBOffset() if the user is using the getXXXArray APIs with getXXXOFfset 
and getXXXBB() APIs with getXXXBBOFfset() then there is no problem, but if he 
interchanges these APIs,  we cannot figure out that he has jumbled the API 
usage. In that case we cannot throw any exception.  That could only be 
documented.

> Add ByteBufferedCell an extension to Cell
> -----------------------------------------
>
>                 Key: HBASE-13387
>                 URL: https://issues.apache.org/jira/browse/HBASE-13387
>             Project: HBase
>          Issue Type: Sub-task
>          Components: regionserver, Scanners
>            Reporter: Anoop Sam John
>            Assignee: Anoop Sam John
>         Attachments: ByteBufferedCell.docx, WIP_HBASE-13387_V2.patch, 
> WIP_ServerCell.patch
>
>
> This came in btw the discussion abt the parent Jira and recently Stack added 
> as a comment on the E2E patch on the parent Jira.
> The idea is to add a new Interface 'ByteBufferedCell'  in which we can add 
> new buffer based getter APIs and getters for position in components in BB.  
> We will keep this interface @InterfaceAudience.Private.   When the Cell is 
> backed by a DBB, we can create an Object implementing this new interface.
> The Comparators has to be aware abt this new Cell extension and has to use 
> the BB based APIs rather than getXXXArray().  Also give util APIs in CellUtil 
> to abstract the checks for new Cell type.  (Like matchingXXX APIs, 
> getValueAs<type> APIs etc)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to