Package org.apache.hadoop.hbase.thrift.generated

Examples of org.apache.hadoop.hbase.thrift.generated.IllegalArgument


      LOG.debug("scannerClose: id=" + id);
      ResultScannerWrapper resultScannerWrapper = getScanner(id);
      if (resultScannerWrapper == null) {
        String message = "scanner ID is invalid";
        LOG.warn(message);
        throw new IllegalArgument("scanner ID is invalid");
      }
      resultScannerWrapper.getScanner().close();
      removeScanner(id);
    }
View Full Code Here


      LOG.debug("scannerGetList: id=" + id);
      ResultScannerWrapper resultScannerWrapper = getScanner(id);
      if (null == resultScannerWrapper) {
        String message = "scanner ID is invalid";
        LOG.warn(message);
        throw new IllegalArgument("scanner ID is invalid");
      }

      Result [] results = null;
      try {
        results = resultScannerWrapper.getScanner().next(nbRows);
View Full Code Here

            : HConstants.EMPTY_BYTE_ARRAY);

        put.setDurability(mput.writeToWAL ? Durability.SYNC_WAL : Durability.SKIP_WAL);
      } catch (IllegalArgumentException e) {
        LOG.warn(e.getMessage(), e);
        throw new IllegalArgument(e.getMessage());
      }

      HTable table = null;
      try {
        table = getTable(tableName);
        byte[][] famAndQf = KeyValue.parseColumn(getBytes(column));
        return table.checkAndPut(getBytes(row), famAndQf[0], famAndQf[1],
          value != null ? getBytes(value) : HConstants.EMPTY_BYTE_ARRAY, put);
      } catch (IOException e) {
        LOG.warn(e.getMessage(), e);
        throw new IOError(e.getMessage());
      } catch (IllegalArgumentException e) {
        LOG.warn(e.getMessage(), e);
        throw new IllegalArgument(e.getMessage());
      }
    }
View Full Code Here

      Compression.getCompressionAlgorithmByName(in.compression.toLowerCase());
    BloomType bt =
      BloomType.valueOf(in.bloomFilterType);

    if (in.name == null || !in.name.hasRemaining()) {
      throw new IllegalArgument("column name is empty");
    }
    byte [] parsedName = KeyValue.parseColumn(Bytes.getBytes(in.name))[0];
    HColumnDescriptor col = new HColumnDescriptor(parsedName)
        .setMaxVersions(in.maxVersions)
        .setCompressionType(comp)
View Full Code Here

        }
        admin.createTable(desc);
      } catch (IOException e) {
        throw new IOError(e.getMessage());
      } catch (IllegalArgumentException e) {
        throw new IllegalArgument(e.getMessage());
      }
    }
View Full Code Here

        if (!put.isEmpty())
          table.put(put);
      } catch (IOException e) {
        throw new IOError(e.getMessage());
      } catch (IllegalArgumentException e) {
        throw new IllegalArgument(e.getMessage());
      }
    }
View Full Code Here

          table.delete(del);
        }
      } catch (IOException e) {
        throw new IOError(e.getMessage());
      } catch (IllegalArgumentException e) {
        throw new IllegalArgument(e.getMessage());
      }
    }
View Full Code Here

   
    public void scannerClose(int id) throws IOError, IllegalArgument {
      LOG.debug("scannerClose: id=" + id);
      ResultScanner scanner = getScanner(id);
      if (scanner == null) {
        throw new IllegalArgument("scanner ID is invalid");
      }
      scanner.close();
      removeScanner(id);
    }
View Full Code Here

   
    public List<TRowResult> scannerGetList(int id,int nbRows) throws IllegalArgument, IOError {
        LOG.debug("scannerGetList: id=" + id);
        ResultScanner scanner = getScanner(id);
        if (null == scanner) {
            throw new IllegalArgument("scanner ID is invalid");
        }

        Result [] results = null;
        try {
            results = scanner.next(nbRows);
View Full Code Here

    if (in.bloomFilterType.compareTo("NONE") != 0) {
      bloom = true;
    }
   
    if (in.name == null || in.name.length <= 0) {
      throw new IllegalArgument("column name is empty");
    }
    HColumnDescriptor col = new HColumnDescriptor(in.name,
        in.maxVersions, comp.getName(), in.inMemory, in.blockCacheEnabled,
        in.timeToLive, bloom);
    return col;
View Full Code Here

TOP

Related Classes of org.apache.hadoop.hbase.thrift.generated.IllegalArgument

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.