     if (region.getCoprocessorHost() != null) {
       result = region.getCoprocessorHost().postCheckAndDelete(row, family,
         qualifier, compareOp, comparator, delete, result);
-@@ -3757,4 +3757,281 @@ public class HRegionServer implements HRegionInterface, HBaseRPCErrorHandler,
+@@ -3757,4 +3698,281 @@ public class HRegionServer implements HRegionInterface, HBaseRPCErrorHandler,
        HRegionInfo info = region.getRegionInfo();
        return CompactionRequest.getCompactionState(info.getRegionId()).name();
    }

 /**
  * Clients interact with HRegionServers using a handle to the HRegionInterface.
  *
@@ -222,8 +235,27 @@ public interface HRegionInterface extends VersionedProtocol, Stoppable, Abortabl
    * @return true if the new put was execute, false otherwise
    */
   public boolean checkAndPut(final byte[] regionName, final byte [] row,
+                             final byte [] family, final byte [] qualifier, final byte [] value,
+                             final Put put)
+    throws IOException;
+
+  /**
+   * Atomically checks if a row/family/qualifier value match the expectedValue.
+   * If it does, it adds the put. If passed expected value is null, then the
+   * check is for non-existance of the row/column.
+   *
+   * @param regionName region name
+   * @param row row to check
+   * @param family column family
+   * @param qualifier column qualifier
+   * @param value the expected value
+   * @param put data to put if check succeeds
+   * @throws IOException e
+   * @return true if the new put was execute, false otherwise
+   */
+  public boolean checkAndPut(final byte[] regionName, final byte [] row,
       final byte [] family, final byte [] qualifier, final byte [] value,
-      final Put put)
+      final long readVersion, final Put put)
   throws IOException;
 
 
@@ -237,13 +269,14 @@ public interface HRegionInterface extends VersionedProtocol, Stoppable, Abortabl
    * @param family column family
    * @param qualifier column qualifier
    * @param value the expected value

 /**
  * <p>Used to communicate with a single HBase table.
  *
@@ -864,13 +874,24 @@ public class HTable implements HTableInterface {
    */
   @Override
   public boolean checkAndPut(final byte [] row,
+                             final byte [] family, final byte [] qualifier, final byte [] value,
+                             final Put put)
+  throws IOException {
+    return this.checkAndPut(row, family, qualifier, value, Long.MAX_VALUE, put);
+  }
+
+  /**
