BTW on the page http://localhost:16010/master-status#userTables there is no sign of the supposedly existing table either
________________________________ From: jeff saremi <[email protected]> Sent: Tuesday, April 25, 2017 4:05:56 PM To: [email protected] Subject: Baffling situation with tableExists and createTable I have a super simple piece of code which tries to create a test table if it does not exist calling admin.tableExists(TableName.valueOf(table)) returns false causing the control to be passed to the line that creates it admin.createTable(tableDescriptor). Then i get an exception that the table exists! Exception in thread "main" org.apache.hadoop.hbase.TableExistsException: LoadTest String table = config.tableName; ... Connection conn = ConnectionFactory.createConnection(hbaseconf); Admin admin = conn.getAdmin(); if(!admin.tableExists(TableName.valueOf(table))) { Log.info("table " + table + " does not exist. Creating it..."); HTableDescriptor tableDescriptor = new HTableDescriptor(TableName.valueOf(table)); tableDescriptor.addFamily(new HColumnDescriptor(config.FAMILY)); admin.createTable(tableDescriptor); } Jeff
