Package org.apache.hadoop.hbase.client.HTable

Examples of org.apache.hadoop.hbase.client.HTable.DaemonThreadFactory


    TEST_UTIL.createTable(TABLE_NAME1, FAM_NAM);
    HConnection conn = HConnectionManager.createConnection(TEST_UTIL.getConfiguration());
    ThreadPoolExecutor pool = new ThreadPoolExecutor(1, 10,
        60, TimeUnit.SECONDS,
        new SynchronousQueue<Runnable>(),
        new DaemonThreadFactory());

    HTable table = new HTable(TABLE_NAME1, conn, pool);
    table.close();
    assertFalse(conn.isClosed());
    assertFalse(pool.isShutdown());
View Full Code Here


    HConnection conn = HConnectionManager.createConnection(TEST_UTIL
        .getConfiguration());
    ExecutorService pool = new ThreadPoolExecutor(1, Integer.MAX_VALUE,
        60, TimeUnit.SECONDS,
        new SynchronousQueue<Runnable>(),
        new DaemonThreadFactory());
    ((ThreadPoolExecutor)pool).allowCoreThreadTimeOut(true);
    HTable t = new HTable(tableName, conn, pool);
    HBaseAdmin ha = new HBaseAdmin(conn);
    assertTrue(ha.tableExists(tableName));
    assertTrue(t.get(new Get(ROW)).isEmpty());
View Full Code Here

TOP

Related Classes of org.apache.hadoop.hbase.client.HTable.DaemonThreadFactory

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.