[
https://issues.apache.org/jira/browse/HBASE-11447?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14058002#comment-14058002
]
Shengzhe Yao commented on HBASE-11447:
--------------------------------------
1. Could you please explain TransactionStatus in more details ? It might be
super helpful if we can also draw some concrete examples how we gonna to use
these status, this provide a guideline for transaction implementor to use
correct status in the right way and avoid misinterpretation.
2. As someone mentioned earlier, do we really need to provide TransactionStatus
in the public API, could this be implementation specific ?
3. TransactionServiceClient declares all methods as static, could we remove
that keyword ?
4. TransactionInterface contains several Transaction(...) methods, looks like
all these are constructors. It is better to not include them in the interface,
let implementation to decide the proper way to initialize the object. Even if
we really want to control the existence of some properties, it is better to
define setter&getter or provide a base abstract implementation.
5. Should TransactionInterface.commit() and TransactionInterface.rollback()
have return values ?
6. TransactionInterface.setTransactionTimeout should be better to have extra
TimeUnit parameter, so that user won't be confused by timeout resolution (the
meaning of timeout could be milliseconds, seconds or even hours).
7. TransactionInterface.toByteArray, instead of this, maybe we can add one more
method that accepts an OutputStream, so that it might allow more efficient
implementation of Transaction serialization.
8. It might be better to replace TransactionTable.setTransaction by
TransactionTable.addTransaction, because I think most of time there is not only
a single transaction but multiple of them can happen.
[~cuijianwei] recently announced a transaction implementation based on HBase,
called Themis which is inspired by Google's percolator. I'd like to hear if you
([~cuijianwei]) have comments for this transaction API.
> Proposal for a generic transaction API for HBase
> ------------------------------------------------
>
> Key: HBASE-11447
> URL: https://issues.apache.org/jira/browse/HBASE-11447
> Project: HBase
> Issue Type: New Feature
> Components: Client
> Affects Versions: 1.0.0
> Environment: Any.
> Reporter: John de Roo
> Priority: Minor
> Labels: features, newbie
> Fix For: 1.0.0
>
> Attachments: Proposal for a common transactional API for HBase
> v0.3_1.pdf, Proposal for a common transactional API for HBase v0.4_1.pdf, Re
> Proposal for a generic transaction API for HBase.htm
>
>
> HBase transaction management today is provided by a number of products, each
> implementing a different API, each having different strengths. The lack of a
> common API for transactional interfaces means that applications need to be
> coded to work with a specific Transaction Manager. This proposal outlines an
> API which, if implemented by the different Transaction Manager vendors would
> provide stability and choice to HBase application developers.
--
This message was sent by Atlassian JIRA
(v6.2#6252)