Examples of Delete


Examples of org.apache.cocoon.rest.controller.method.Delete

        }

        @Override
        public RestResponse execute(Object controller) throws Exception {
            if (controller instanceof Delete) {
                Delete delete = (Delete) controller;
                return delete.doDelete();
            }
            return super.execute(controller);
        }
View Full Code Here

Examples of org.apache.falcon.oozie.workflow.DELETE

        final PREPARE prepare = new PREPARE();
        final List<DELETE> deleteList = prepare.getDelete();

        for (String deletePath : deleteOutputPathList) {
            final DELETE delete = new DELETE();
            delete.setPath(deletePath);
            deleteList.add(delete);
        }

        if (!deleteList.isEmpty()) {
            pigAction.setPrepare(prepare);
View Full Code Here

Examples of org.apache.gora.sql.statement.Delete

    return false;
  }

  @Override
  public boolean delete(K key) throws IOException {
    Delete delete = new Delete();
    delete.from(sqlTable.getName())
          .where().equals(primaryColumn.getName(), "?");

    PreparedStatement statement = null;
    try {
      statement = connection.prepareStatement(delete.toString());
      setObject(statement, 1, key, keySqlType, primaryColumn);

      int ret = statement.executeUpdate();
      return ret > 0;
    } catch (SQLException ex) {
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

  /**
   * Deletes region from meta table
   */
  private void deleteMetaRegion(HbckInfo hi) throws IOException {
    Delete d = new Delete(hi.metaEntry.getRegionName());
    meta.delete(d);
    meta.flushCommits();
    LOG.info("Deleted " + hi.metaEntry.getRegionNameAsString() + " from META" );
  }
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

  /**
   * Reset the split parent region info in meta table
   */
  private void resetSplitParent(HbckInfo hi) throws IOException {
    RowMutations mutations = new RowMutations(hi.metaEntry.getRegionName());
    Delete d = new Delete(hi.metaEntry.getRegionName());
    d.deleteColumn(HConstants.CATALOG_FAMILY, HConstants.SPLITA_QUALIFIER);
    d.deleteColumn(HConstants.CATALOG_FAMILY, HConstants.SPLITB_QUALIFIER);
    mutations.add(d);

    Put p = new Put(hi.metaEntry.getRegionName());
    HRegionInfo hri = new HRegionInfo(hi.metaEntry);
    hri.setOffline(false);
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

   * @throws IOException
   */
  public static void deleteRegion(CatalogTracker catalogTracker,
      HRegionInfo regionInfo)
  throws IOException {
    Delete delete = new Delete(regionInfo.getRegionName());
    deleteFromMetaTable(catalogTracker, delete);
    LOG.info("Deleted region " + regionInfo.getRegionNameAsString() + " from META");
  }
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

   */
  public static void deleteRegions(CatalogTracker catalogTracker,
      List<HRegionInfo> regionsInfo) throws IOException {
    List<Delete> deletes = new ArrayList<Delete>(regionsInfo.size());
    for (HRegionInfo hri: regionsInfo) {
      deletes.add(new Delete(hri.getRegionName()));
    }
    deleteFromMetaTable(catalogTracker, deletes);
    LOG.info("Deleted from META, regions: " + regionsInfo);
  }
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

      final List<HRegionInfo> regionsToRemove, final List<HRegionInfo> regionsToAdd)
      throws IOException {
    List<Mutation> mutation = new ArrayList<Mutation>();
    if (regionsToRemove != null) {
      for (HRegionInfo hri: regionsToRemove) {
        mutation.add(new Delete(hri.getRegionName()));
      }
    }
    if (regionsToAdd != null) {
      for (HRegionInfo hri: regionsToAdd) {
        mutation.add(makePutFromRegionInfo(hri));
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

   * @throws IOException
   */
  public static void deleteDaughtersReferencesInParent(CatalogTracker catalogTracker,
      final HRegionInfo parent)
  throws NotAllMetaRegionsOnlineException, IOException {
    Delete delete = new Delete(parent.getRegionName());
    delete.deleteColumns(HConstants.CATALOG_FAMILY, HConstants.SPLITA_QUALIFIER);
    delete.deleteColumns(HConstants.CATALOG_FAMILY, HConstants.SPLITB_QUALIFIER);
    deleteFromMetaTable(catalogTracker, delete);
    LOG.info("Deleted daughters references, qualifier=" + Bytes.toStringBinary(HConstants.SPLITA_QUALIFIER) +
      " and qualifier=" + Bytes.toStringBinary(HConstants.SPLITB_QUALIFIER) +
      ", from parent " + parent.getRegionNameAsString());
  }
View Full Code Here

Examples of org.apache.hadoop.hbase.client.Delete

                            ByteBuffer row,
                            ByteBuffer column,
        long timestamp, Map<ByteBuffer, ByteBuffer> attributes) throws IOError {
      try {
        HTable table = getTable(tableName);
        Delete delete  = new Delete(getBytes(row));
        addAttributes(delete, attributes);
        byte [][] famAndQf = KeyValue.parseColumn(getBytes(column));
        if (famAndQf.length == 1) {
          delete.deleteFamily(famAndQf[0], timestamp);
        } else {
          delete.deleteColumns(famAndQf[0], famAndQf[1], timestamp);
        }
        table.delete(delete);

      } catch (IOException e) {
        LOG.warn(e.getMessage(), e);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.