You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hbase.apache.org by "Andrew Kyle Purtell (Jira)" <ji...@apache.org> on 2022/06/13 16:19:00 UTC
[jira] [Resolved] (HBASE-5761) [Thrift2] TDelete.deleteType defaults to TDeleteType.DELETE_COLUMNS, but the docs suggest otherwise
[ https://issues.apache.org/jira/browse/HBASE-5761?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andrew Kyle Purtell resolved HBASE-5761.
----------------------------------------
Resolution: Incomplete
> [Thrift2] TDelete.deleteType defaults to TDeleteType.DELETE_COLUMNS, but the docs suggest otherwise
> ---------------------------------------------------------------------------------------------------
>
> Key: HBASE-5761
> URL: https://issues.apache.org/jira/browse/HBASE-5761
> Project: HBase
> Issue Type: Bug
> Components: documentation
> Reporter: Wouter Bolsterlee
> Priority: Trivial
> Labels: beginner
>
> It seems to me there is an inconsistency (or error) in the Thrift2 {{TDelete}} struct and its documentation. The docs for the {{TDelete}} struct state:
> {quote}
> If no timestamp is specified the most recent version will be deleted. To delete all previous versions, specify the DELETE_COLUMNS TDeleteType.
> {quote}
> ...which implies that the default is {{TDeleteType.DELETE_COLUMN}} (singular), not {{TDeleteType.DELETE_COLUMNS}} (plural).
> However, the {{deleteType}} field in the {{TDelete}} struct defaults to the value {{1}}, which is {{TDeleteType.DELETE_COLUMNS}} (plural) in {{/src/main/resources/org/apache/hadoop/hbase/thrift2/hbase.thrift}}. The field is currently (r1239241) defined as follows:
> {{4: optional TDeleteType deleteType = 1,}}
> I'd suggest that the default for this optional field is changed to {{TDeleteType.DELETE_COLUMN}} (singular). The line above from the {{TDelete}} struct would then become:
> {{4: optional TDeleteType deleteType = 0,}}
> Since this change just involves changing a {{1}} into a {{0}}, I'll leave the trivial patch to someone who can also commit it in one go. Thanks in advance. :)
--
This message was sent by Atlassian Jira
(v8.20.7#820007)