@Override public void loadFiles(TInfo tinfo, TCredentials credentials, long tid, String dir, Map<TKeyExtent,Map<String,MapFileInfo>> tabletImports, boolean setTime) throws ThriftSecurityException { if (!security.canPerformSystemActions(credentials)) throw new ThriftSecurityException(credentials.getPrincipal(), SecurityErrorCode.PERMISSION_DENIED); watcher.runQuietly(Constants.BULK_ARBITRATOR_TYPE, tid, () -> { tabletImports.forEach((tke, fileMap) -> { Map<FileRef,MapFileInfo> fileRefMap = new HashMap<>(); for (Entry<String,MapFileInfo> mapping : fileMap.entrySet()) { Path path = new Path(dir, mapping.getKey()); FileSystem ns = fs.getVolumeByPath(path).getFileSystem(); path = ns.makeQualified(path); fileRefMap.put(new FileRef(path.toString(), path), mapping.getValue()); } Tablet importTablet = onlineTablets.get(new KeyExtent(tke)); if (importTablet != null) { try { importTablet.importMapFiles(tid, fileRefMap, setTime); } catch (IOException ioe) { log.debug("files {} not imported to {}: {}", fileMap.keySet(), new KeyExtent(tke), ioe.getMessage()); } } }); }); }