org.apache.accumulo.server.util
public class FileUtil extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
FileUtil.FileInfo |
| Constructor and Description |
|---|
FileUtil() |
| Modifier and Type | Method and Description |
|---|---|
protected static void |
cleanupIndexOp(AccumuloConfiguration acuConf,
org.apache.hadoop.fs.Path tmpDir,
VolumeManager fs,
ArrayList<FileSKVIterator> readers) |
static double |
estimatePercentageLTE(VolumeManager fs,
AccumuloConfiguration acuconf,
org.apache.hadoop.io.Text prevEndRow,
org.apache.hadoop.io.Text endRow,
Collection<String> mapFiles,
org.apache.hadoop.io.Text splitRow) |
static Map<KeyExtent,Long> |
estimateSizes(AccumuloConfiguration acuConf,
org.apache.hadoop.fs.Path mapFile,
long fileSize,
List<KeyExtent> extents,
org.apache.hadoop.conf.Configuration conf,
VolumeManager fs) |
static org.apache.hadoop.io.WritableComparable<Key> |
findLastKey(VolumeManager fs,
AccumuloConfiguration acuConf,
Collection<FileRef> mapFiles) |
static SortedMap<Double,Key> |
findMidPoint(VolumeManager fs,
AccumuloConfiguration acuConf,
org.apache.hadoop.io.Text prevEndRow,
org.apache.hadoop.io.Text endRow,
Collection<String> mapFiles,
double minSplit) |
static SortedMap<Double,Key> |
findMidPoint(VolumeManager fs,
AccumuloConfiguration acuConf,
org.apache.hadoop.io.Text prevEndRow,
org.apache.hadoop.io.Text endRow,
Collection<String> mapFiles,
double minSplit,
boolean useIndex) |
static Collection<String> |
reduceFiles(AccumuloConfiguration acuConf,
org.apache.hadoop.conf.Configuration conf,
VolumeManager fs,
org.apache.hadoop.io.Text prevEndRow,
org.apache.hadoop.io.Text endRow,
Collection<String> mapFiles,
int maxFiles,
org.apache.hadoop.fs.Path tmpDir,
int pass) |
static Collection<String> |
toPathStrings(Collection<FileRef> refs) |
static Map<FileRef,FileUtil.FileInfo> |
tryToGetFirstAndLastRows(VolumeManager fs,
AccumuloConfiguration acuConf,
Set<FileRef> mapfiles) |
public static Collection<String> reduceFiles(AccumuloConfiguration acuConf, org.apache.hadoop.conf.Configuration conf, VolumeManager fs, org.apache.hadoop.io.Text prevEndRow, org.apache.hadoop.io.Text endRow, Collection<String> mapFiles, int maxFiles, org.apache.hadoop.fs.Path tmpDir, int pass) throws IOException
IOExceptionpublic static SortedMap<Double,Key> findMidPoint(VolumeManager fs, AccumuloConfiguration acuConf, org.apache.hadoop.io.Text prevEndRow, org.apache.hadoop.io.Text endRow, Collection<String> mapFiles, double minSplit) throws IOException
IOExceptionpublic static double estimatePercentageLTE(VolumeManager fs, AccumuloConfiguration acuconf, org.apache.hadoop.io.Text prevEndRow, org.apache.hadoop.io.Text endRow, Collection<String> mapFiles, org.apache.hadoop.io.Text splitRow) throws IOException
IOExceptionpublic static SortedMap<Double,Key> findMidPoint(VolumeManager fs, AccumuloConfiguration acuConf, org.apache.hadoop.io.Text prevEndRow, org.apache.hadoop.io.Text endRow, Collection<String> mapFiles, double minSplit, boolean useIndex) throws IOException
mapFiles - - list MapFiles to find the mid point key
ISSUES : This method used the index files to find the mid point. If the map files have different index intervals this method will not return an
accurate mid point. Also, it would be tricky to use this method in conjunction with an in memory map because the indexing interval is unknown.IOExceptionprotected static void cleanupIndexOp(AccumuloConfiguration acuConf, org.apache.hadoop.fs.Path tmpDir, VolumeManager fs, ArrayList<FileSKVIterator> readers) throws IOException
IOExceptionpublic static Map<FileRef,FileUtil.FileInfo> tryToGetFirstAndLastRows(VolumeManager fs, AccumuloConfiguration acuConf, Set<FileRef> mapfiles)
public static org.apache.hadoop.io.WritableComparable<Key> findLastKey(VolumeManager fs, AccumuloConfiguration acuConf, Collection<FileRef> mapFiles) throws IOException
IOExceptionpublic static Map<KeyExtent,Long> estimateSizes(AccumuloConfiguration acuConf, org.apache.hadoop.fs.Path mapFile, long fileSize, List<KeyExtent> extents, org.apache.hadoop.conf.Configuration conf, VolumeManager fs) throws IOException
IOExceptionpublic static Collection<String> toPathStrings(Collection<FileRef> refs)
Copyright © 2011–2016 The Apache Software Foundation. All rights reserved.