Esempio n. 1
0
 @Override
 public Response truncate(String path, long size, Map<Byte, Long> instanceMap) throws TException {
   path = makePathAbsolute(path);
   Set<Byte> parts = oracle.partitionsOf(path);
   Command cmd = newCommand(CommandType.TRUNCATE, parts, instanceMap);
   TruncateCmd truncate = new TruncateCmd(path, size, parts);
   cmd.setTruncate(truncate);
   replica.submitCommand(cmd);
   Response r = new Response(replica.getInstanceMap());
   return r;
 }