Examples of undelete()


Examples of org.apache.hadoop.fs.FileSystem.undelete()

          System.getProperty("user.name")));

      // temp directory automatically skips trash.
      createFile(fs, new Path("/tmp/testDelete"));
      TestCase.assertTrue(fs.delete(new Path("/tmp/testDelete"), false, false));
      TestCase.assertFalse(fs.undelete(new Path("/tmp/testDelete"),
          System.getProperty("user.name")));
    }
    finally {
      if (cluster != null) {cluster.shutdown();}
    }
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));

      // do the undelete using non-exist userName
      String nonExistedUser = UUID.randomUUID().toString();
      assertFalse(raidFs.undelete(srcPath, nonExistedUser));

      // verify the results
      assertFalse(raidFs.exists(srcPath));
      assertFalse(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(srcPath));
      assertFalse(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));

      // do the undelete file using current userName
      assertTrue(raidFs.undelete(srcPath, null));
      //verify the results.
      assertTrue(raidFs.exists(srcPath));
      assertTrue(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(srcParityPath));
      assertFalse(raidFs.exists(srcParityPath2));
      assertFalse(raidFs.exists(srcParityPath.getParent()));

      // undelete the dir
      assertTrue(raidFs.undelete(srcPath2.getParent(), null));
      // verify the results.
      assertTrue(raidFs.exists(srcPath));
      assertTrue(raidFs.exists(srcPath2));
      assertTrue(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));

      // do the undelete using non-exist userName
      String nonExistedUser = UUID.randomUUID().toString();
      assertFalse(raidFs.undelete(srcPath, nonExistedUser));

      // verify the results
      assertFalse(raidFs.exists(srcPath));
      assertFalse(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(srcPath));
      assertFalse(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));

      // do the undelete file using current userName
      assertTrue(raidFs.undelete(srcPath, null));
      //verify the results.
      assertTrue(raidFs.exists(srcPath));
      assertTrue(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(srcParityPath));
      assertFalse(raidFs.exists(srcParityPath2));
      assertFalse(raidFs.exists(srcParityPath.getParent()));

      // undelete the dir
      assertTrue(raidFs.undelete(srcPath2.getParent(), null));
      // verify the results.
      assertTrue(raidFs.exists(srcPath));
      assertTrue(raidFs.exists(srcPath2));
      assertTrue(raidFs.exists(srcParityPath));
      assertTrue(raidFs.exists(srcParityPath2));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      assertFalse(raidFs.exists(dirPath));
      assertFalse(raidFs.exists(srcParityPath));

      // do the undelete using non-exist userName
      String nonExistedUser = UUID.randomUUID().toString();
      assertFalse(raidFs.undelete(dirPath, nonExistedUser));

      // verify the results
      assertFalse(raidFs.exists(dirPath));
      assertFalse(raidFs.exists(srcParityPath));
View Full Code Here

Examples of org.apache.hadoop.hdfs.DistributedRaidFileSystem.undelete()

      // verify the results
      assertFalse(raidFs.exists(dirPath));
      assertFalse(raidFs.exists(srcParityPath));

      // do the undelete file using current userName
      assertTrue(raidFs.undelete(dirPath, null));
      //verify the results.
      assertTrue(raidFs.exists(dirPath));
      assertTrue(raidFs.exists(srcParityPath));
    } finally {
      stopCluster();
View Full Code Here

Examples of org.infinispan.container.entries.MVCCEntry.undelete()

      CacheEntry cacheEntry = getFromContext(ctx, key);
      MVCCEntry mvccEntry;
      if (cacheEntry != null && cacheEntry.isNull()) cacheEntry = null;
      if (cacheEntry != null) {
         mvccEntry = wrapMvccEntryForPut(ctx, key, cacheEntry);
         mvccEntry.undelete(undeleteIfNeeded);
      } else {
         InternalCacheEntry ice = (icEntry == null ? getFromContainer(key) : icEntry);
         // A putForExternalRead is putIfAbsent, so if key present, do nothing
         if (ice != null && cmd.hasFlag(Flag.PUT_FOR_EXTERNAL_READ)) {
            // make sure we record this! Null value since this is a forced lock on the key
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.