hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Enis Soztutar (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HBASE-10354) Add an API for defining consistency per request
Date Fri, 31 Jan 2014 03:30:09 GMT

     [ https://issues.apache.org/jira/browse/HBASE-10354?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Enis Soztutar updated HBASE-10354:
----------------------------------

    Attachment: hbase-10354_v1.patch

Attaching a patch which 

- Defines a new class for setting per get/scan consistency: 
{code}
public enum Consistency {
  /**
   * Strong consistency is the default consistency model in HBase,
   * where reads and writes go through a single server which serializes
   * the updates, and returns all data that was written and ack'd.
   */
  STRONG,

  /**
   * Eventual consistent reads might return values that may not see
   * the most recent updates. Write transactions are always performed
   * in strong consistency model in HBase. In eventual consistency,
   * the order of observed transactions is always in the same sequence
   * that the transactions were written.
   * Reads will be seeing a previous version of the database.
   */
  EVENTUAL,
}
{code}
 - Adds setConsistency to Get and Scan 
 - Adds Result.isStale() to inspect whether the result from Scan or Get is possibly stale.

 - Adds shell support for setting consistency level per operation. 

I think having an enum like Consistency will fit nicely into our API, which we also define
Durability and Isolation similarly. 

We can rename Consistency.EVENTUAL to Consistency.TIMELINE if there is concern that it will
cause confusion. 



> Add an API for defining consistency per request
> -----------------------------------------------
>
>                 Key: HBASE-10354
>                 URL: https://issues.apache.org/jira/browse/HBASE-10354
>             Project: HBase
>          Issue Type: Sub-task
>          Components: Client
>            Reporter: Enis Soztutar
>            Assignee: Enis Soztutar
>             Fix For: 0.99.0
>
>         Attachments: hbase-10354_v1.patch
>
>
> We should add an API to be able to define the expected consistency level per operation.
This API should also allow to check whether the results coming from a query (get or scan)
is stale or not. The defaults should reflect the current semantics. 



--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Mime
View raw message