Class Utils
- java.lang.Object
-
- org.apache.accumulo.master.tableOps.Utils
-
public class Utils extends Object
-
-
Constructor Summary
Constructors Constructor Description Utils()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static StringgetNamespaceId(Instance instance, String tableId, TableOperation op, String namespaceId)static LockgetReadLock(String tableId, long tid)static longreserveHdfsDirectory(String directory, long tid)static longreserveNamespace(String namespaceId, long id, boolean writeLock, boolean mustExist, TableOperation op)static longreserveTable(String tableId, long tid, boolean writeLock, boolean tableMustExist, TableOperation op)static voidunreserveHdfsDirectory(String directory, long tid)static voidunreserveNamespace(String namespaceId, long id, boolean writeLock)static voidunreserveTable(String tableId, long tid, boolean writeLock)
-
-
-
Method Detail
-
reserveTable
public static long reserveTable(String tableId, long tid, boolean writeLock, boolean tableMustExist, TableOperation op) throws Exception
- Throws:
Exception
-
unreserveTable
public static void unreserveTable(String tableId, long tid, boolean writeLock) throws Exception
- Throws:
Exception
-
unreserveNamespace
public static void unreserveNamespace(String namespaceId, long id, boolean writeLock) throws Exception
- Throws:
Exception
-
reserveNamespace
public static long reserveNamespace(String namespaceId, long id, boolean writeLock, boolean mustExist, TableOperation op) throws Exception
- Throws:
Exception
-
getNamespaceId
public static String getNamespaceId(Instance instance, String tableId, TableOperation op, String namespaceId) throws Exception
- Throws:
Exception
-
reserveHdfsDirectory
public static long reserveHdfsDirectory(String directory, long tid) throws org.apache.zookeeper.KeeperException, InterruptedException
- Throws:
org.apache.zookeeper.KeeperExceptionInterruptedException
-
unreserveHdfsDirectory
public static void unreserveHdfsDirectory(String directory, long tid) throws org.apache.zookeeper.KeeperException, InterruptedException
- Throws:
org.apache.zookeeper.KeeperExceptionInterruptedException
-
-