Class VolumeUtil


  • public class VolumeUtil
    extends Object
    Utility methods for managing absolute URIs contained in Accumulo metadata.
    • Constructor Detail

      • VolumeUtil

        public VolumeUtil()
    • Method Detail

      • removeTrailingSlash

        public static String removeTrailingSlash​(String path)
      • removeTrailingSlash

        public static org.apache.hadoop.fs.Path removeTrailingSlash​(org.apache.hadoop.fs.Path path)
      • switchVolume

        public static org.apache.hadoop.fs.Path switchVolume​(String path,
                                                             VolumeManager.FileType ft,
                                                             List<Pair<org.apache.hadoop.fs.Path,​org.apache.hadoop.fs.Path>> replacements)
      • updateTabletVolumes

        public static VolumeUtil.TabletFiles updateTabletVolumes​(ServerContext context,
                                                                 ServiceLock zooLock,
                                                                 KeyExtent extent,
                                                                 VolumeUtil.TabletFiles tabletFiles,
                                                                 boolean replicate)
        This method does two things. First, it switches any volumes a tablet is using that are configured in instance.volumes.replacements. Second, if a tablet dir is no longer configured for use it chooses a new tablet directory.