Skip to content
Haeinsa is linearly scalable multi-row, multi-table transaction library for HBase
Java Thrift
Branch: master
Clone or download

Latest commit

Fetching latest commit…
Cannot retrieve the latest commit at this time.


Type Name Latest commit message Commit time
Failed to load latest commit information.
src Merge row mutations faster not using HaeinsaDeleteTracker. Feb 28, 2017
tools configure thrift maven plugin Feb 28, 2013
wiki Fix typo (s/senantics/semantics/) Jul 25, 2016
.gitignore remove maven-release-plugin output Sep 30, 2013
.travis.yml Update .travis.yml Mar 31, 2016
HEADER.txt add inception date on license header Jan 1, 2014
LICENSE.txt HAEINSA-33 add license on source file headers Aug 11, 2013
NOTICE.txt Add NOTICE.txt file May 1, 2014 Fix typo (s/senantics/semantics/) Jul 25, 2016
checkstyle.xml Reformat codes Feb 6, 2015
pom.xml [maven-release-plugin] prepare for next development iteration Mar 20, 2015


Build Status

Haeinsa is linearly scalable multi-row, multi-table transaction library for HBase. Haeinsa uses two-phase locking and optimistic concurrency control for implementing transaction. The isolation level of transaction is serializable.


Please see Haeinsa Wiki for further information.

  • ACID: Provides multi-row, multi-table transaction with full ACID semantics.
  • Linearly scalable: Can linearly scale out throughput of transaction as scale out your HBase cluster.
  • Serializability: Provide isolation level of serializability.
  • Low overhead: Relatively low overhead compared to other comparable libraries.
  • Fault-tolerant: Haeinsa is fault-tolerant against both client and HBase failures.
  • Easy migration: Add transaction feature to your own HBase cluster without any change in HBase cluster except adding lock column family.
  • Used in practice: Haeinsa is used in real service.


APIs of Haeinsa is really similar to APIs of HBase. Please see How to Use and API Usage document for further information.

HaeinsaTransactionManager tm = new HaeinsaTransactionManager(tablePool);
HaeinsaTableIface table = tablePool.getTable("test");
byte[] family = Bytes.toBytes("data");
byte[] qualifier = Bytes.toBytes("status");

HaeinsaTransaction tx = tm.begin(); // start transaction

HaeinsaPut put1 = new HaeinsaPut(Bytes.toBytes("user1"));
put1.add(family, qualifier, Bytes.toBytes("Hello World!"));
table.put(tx, put1);

HaeinsaPut put2 = new HaeinsaPut(Bytes.toBytes("user2"));
put2.add(family, qualifier, Bytes.toBytes("Linearly Scalable!"));
table.put(tx, put2);

tx.commit(); // commit transaction to HBase



Copyright (C) 2013-2015 VCNC Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
See the License for the specific language governing permissions and
limitations under the License.
You can’t perform that action at this time.