Package org.hbase.async

Examples of org.hbase.async.DeleteRequest


    client.setFlushInterval(SLOW_FLUSH);
    final byte[] table = TestIntegration.table.getBytes();
    final byte[] key = "cnt".getBytes();
    final byte[] family = TestIntegration.family.getBytes();
    final byte[] qual = { 'q' };
    final DeleteRequest del = new DeleteRequest(table, key, family, qual);
    del.setBufferable(false);
    client.delete(del).join();
    final int iterations = 100000;
    for (int i = 0; i < iterations; i++) {
      bufferIncrement(table, key, family, qual, 1);
    }
View Full Code Here


    client.ensureTableFamilyExists(table, family).join();

    LOG.info("Deleting existing rows...");
    for (int i = 0; i < NUM_ROWS; i++) {
      client.delete(new DeleteRequest(table, key(i), family, QUALIFIER))
        .addErrback(LOG_ERROR);
    }
    client.flush().join();
    LOG.info("Done deleting existing rows.");
View Full Code Here

        ensureArguments(args, 6, 6);
        final RowLockRequest rlr = new RowLockRequest(args[2], args[3]);
        lock = client.lockRow(rlr).joinUninterruptibly();
        LOG.info("Acquired explicit row lock: " + lock);
      }
      final DeleteRequest delete;
      if (lock == null) {
        switch (args.length) {
          case 4: delete = new DeleteRequest(args[2], args[3]); break;
          case 5: delete = new DeleteRequest(args[2], args[3], args[4]); break;
          case 6: delete = new DeleteRequest(args[2], args[3], args[4], args[5]); break;
          default: throw new AssertionError("Should never be here");
        }
      } else {
        delete = new DeleteRequest(args[2], args[3], args[4], args[5], lock);
      }
      args = null;
      try {
        final Object result = client.delete(delete).joinUninterruptibly();
        LOG.info("Delete result=" + result);
View Full Code Here

              qualifiers.add(column.qualifier());
            }
          }
         
          if (qualifiers.size() > 0) {
            final DeleteRequest delete = new DeleteRequest(tsdb.treeTable(),
                row.get(0).key(), TREE_FAMILY,
                qualifiers.toArray(new byte[qualifiers.size()][])
                );
            delete_deferreds.add(tsdb.getClient().delete(delete));
          }
View Full Code Here

      throw new IllegalArgumentException("The start timestamp has not been set");
    }
   
    final byte[] tsuid_byte = tsuid != null && !tsuid.isEmpty() ?
        UniqueId.stringToUid(tsuid) : null;
    final DeleteRequest delete = new DeleteRequest(tsdb.dataTable(),
        getRowKey(start_time, tsuid_byte), FAMILY,
        getQualifier(start_time));
    return tsdb.getClient().delete(delete);
  }
View Full Code Here

    }
    if (type == null) {
      throw new IllegalArgumentException("Missing type");
    }

    final DeleteRequest delete = new DeleteRequest(tsdb.uidTable(),
        UniqueId.stringToUid(uid), FAMILY,
        (type.toString().toLowerCase() + "_meta").getBytes(CHARSET));
    return tsdb.getClient().delete(delete);
  }
View Full Code Here

            }
          }
         
          if (qualifiers.size() > 0) {
            columns += qualifiers.size();
            final DeleteRequest delete = new DeleteRequest(tsdb.uidTable(),
                row.get(0).key(), NAME_FAMILY,
                qualifiers.toArray(new byte[qualifiers.size()][]));
            delete_calls.add(tsdb.getClient().delete(delete));
          }
        }
View Full Code Here

            }
          }
         
          if (qualifiers.size() > 0) {
            columns += qualifiers.size();
            final DeleteRequest delete = new DeleteRequest(tsdb.metaTable(),
                row.get(0).key(), NAME_FAMILY,
                qualifiers.toArray(new byte[qualifiers.size()][]));
            delete_calls.add(tsdb.getClient().delete(delete));
          }
        }
View Full Code Here

            }
          }
         
          if (qualifiers.size() > 0) {
            columns += qualifiers.size();
            final DeleteRequest delete = new DeleteRequest(tsdb.uidTable(),
                row.get(0).key(), NAME_FAMILY,
                qualifiers.toArray(new byte[qualifiers.size()][]));
            delete_calls.add(tsdb.getClient().delete(delete));
          }
        }
View Full Code Here

            }
          }
         
          if (qualifiers.size() > 0) {
            columns += qualifiers.size();
            final DeleteRequest delete = new DeleteRequest(tsdb.metaTable(),
                row.get(0).key(), NAME_FAMILY,
                qualifiers.toArray(new byte[qualifiers.size()][]));
            delete_calls.add(tsdb.getClient().delete(delete));
          }
        }
View Full Code Here

TOP

Related Classes of org.hbase.async.DeleteRequest

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.