hash = (37 * hash) + OP_TIME_MS_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getOpTimeMs());
private void apply(DeleteFileEntry entry) { long id = entry.getId(); Inode inode = mInodeStore.get(id).get(); mInodeStore.removeInodeAndParentEdge(inode); updateLastModifiedAndChildCount(inode.getParentId(), entry.getOpTimeMs(), -1); mPinnedInodeFileIds.remove(id); mReplicationLimitedFileIds.remove(id); // The recursive option is only used by old versions. if (inode.isDirectory() && entry.getRecursive()) { Queue<InodeDirectory> dirsToDelete = new ArrayDeque<>(); dirsToDelete.add(inode.asDirectory()); while (!dirsToDelete.isEmpty()) { InodeDirectory dir = dirsToDelete.poll(); mInodeStore.remove(inode); for (Inode child : mInodeStore.getChildren(dir)) { if (child.isDirectory()) { dirsToDelete.add(child.asDirectory()); } else { mInodeStore.remove(inode); } } } } }
result = result && (getOpTimeMs() == other.getOpTimeMs());
public Builder mergeFrom(alluxio.proto.journal.File.DeleteFileEntry other) { if (other == alluxio.proto.journal.File.DeleteFileEntry.getDefaultInstance()) return this; if (other.hasId()) { setId(other.getId()); } if (other.hasRecursive()) { setRecursive(other.getRecursive()); } if (other.hasOpTimeMs()) { setOpTimeMs(other.getOpTimeMs()); } if (other.hasAlluxioOnly()) { setAlluxioOnly(other.getAlluxioOnly()); } this.mergeUnknownFields(other.getUnknownFields()); return this; }
/** * @param entry the entry to use */ private void deleteFromEntry(DeleteFileEntry entry) { Metrics.DELETE_PATHS_OPS.inc(); try (LockedInodePath inodePath = mInodeTree.lockFullInodePath(entry.getId(), InodeTree.LockMode.WRITE)) { deleteInternal(RpcContext.NOOP, inodePath, true, entry.getOpTimeMs(), DeleteOptions.defaults() .setRecursive(entry.getRecursive()).setAlluxioOnly(entry.getAlluxioOnly())); } catch (Exception e) { throw new RuntimeException(e); } }
public Builder mergeFrom(alluxio.proto.journal.File.DeleteFileEntry other) { if (other == alluxio.proto.journal.File.DeleteFileEntry.getDefaultInstance()) return this; if (other.hasId()) { setId(other.getId()); } if (other.hasRecursive()) { setRecursive(other.getRecursive()); } if (other.hasOpTimeMs()) { setOpTimeMs(other.getOpTimeMs()); } if (other.hasAlluxioOnly()) { setAlluxioOnly(other.getAlluxioOnly()); } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; }