Java 类org.apache.hadoop.hdfs.server.common.StorageErrorReporter 实例源码

项目:hadoop    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StartupOption startOpt, StorageErrorReporter errorReporter)
    throws IOException {
  storage = new JNStorage(conf, logDir, startOpt, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:aliyun-oss-hadoop-fs    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StartupOption startOpt, StorageErrorReporter errorReporter)
    throws IOException {
  storage = new JNStorage(conf, logDir, startOpt, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    updateHighestWrittenTxId(latest.getLastTxId());
  }
}
项目:big-c    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StartupOption startOpt, StorageErrorReporter errorReporter)
    throws IOException {
  storage = new JNStorage(conf, logDir, startOpt, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:hadoop-2.6.0-cdh5.4.3    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StartupOption startOpt, StorageErrorReporter errorReporter)
    throws IOException {
  storage = new JNStorage(conf, logDir, startOpt, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:hadoop-EAR    文件:Journal.java   
Journal(File logDir, File imageDir, String journalId,
    StorageErrorReporter errorReporter, JournalNode journalNode) throws IOException {
  this.journalNode = journalNode;
  // initialize storage directories
  journalStorage = new JNStorage(logDir, errorReporter, false, journalNode.getConf());
  imageStorage = new JNStorage(imageDir, errorReporter, true, journalNode.getConf());

  // initialize journal and image managers
  this.fjm = new FileJournalManager(journalStorage.getSingularStorageDir(),
      null, errorReporter);

  this.imageManager = new FileImageManager(
      imageStorage.getStorageDirectory(), imageStorage);

  this.journalId = journalId;
  this.metrics = JournalMetrics.create(this);

  refreshCachedData();

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
    metrics.setLastWrittenTxId(highestWrittenTxId);
  }
}
项目:hadoop-plus    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StorageErrorReporter errorReporter) throws IOException {
  storage = new JNStorage(conf, logDir, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:FlexMap    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StartupOption startOpt, StorageErrorReporter errorReporter)
    throws IOException {
  storage = new JNStorage(conf, logDir, startOpt, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:hadoop-TCP    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StorageErrorReporter errorReporter) throws IOException {
  storage = new JNStorage(conf, logDir, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:hardfs    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StorageErrorReporter errorReporter) throws IOException {
  storage = new JNStorage(conf, logDir, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:hadoop-on-lustre2    文件:Journal.java   
Journal(Configuration conf, File logDir, String journalId,
    StartupOption startOpt, StorageErrorReporter errorReporter)
    throws IOException {
  storage = new JNStorage(conf, logDir, startOpt, errorReporter);
  this.journalId = journalId;

  refreshCachedData();

  this.fjm = storage.getJournalManager();

  this.metrics = JournalMetrics.create(this);

  EditLogFile latest = scanStorageForLatestEdits();
  if (latest != null) {
    highestWrittenTxId = latest.getLastTxId();
  }
}
项目:hadoop    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir, StartupOption startOpt,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeAndRecoverStorage(startOpt);
}
项目:aliyun-oss-hadoop-fs    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir, StartupOption startOpt,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeAndRecoverStorage(startOpt);
}
项目:big-c    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir, StartupOption startOpt,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeAndRecoverStorage(startOpt);
}
项目:hadoop-2.6.0-cdh5.4.3    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir, StartupOption startOpt,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeAndRecoverStorage(startOpt);
}
项目:hadoop-EAR    文件:ImageSet.java   
/**
 * Convert given list of files to a list of output streams.
 */
public static List<OutputStream> convertFilesToStreams(File[] localPaths,
    Storage dstStorage, String str) throws IOException {
  List<OutputStream> outputStreams = new ArrayList<OutputStream>();
  if (localPaths != null) {
    for (File f : localPaths) {
      try {
        if (f.exists()) {
          LOG.warn("Overwriting existing file " + f
              + " with file downloaded form " + str);
        }
        outputStreams.add(new FileOutputStream(f));
      } catch (IOException ioe) {
        LOG.warn("Unable to download file " + f, ioe);
        if (dstStorage != null
            && (dstStorage instanceof StorageErrorReporter)) {
          ((StorageErrorReporter) dstStorage).reportErrorOnFile(f);
        }
      }
    }

    if (outputStreams.isEmpty()) {
      throw new IOException("Unable to download to any storage directory");
    }
  }
  return outputStreams;
}
项目:hadoop-EAR    文件:JNStorage.java   
/**
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(File logDir, StorageErrorReporter errorReporter,
    boolean imageDir, Configuration conf) throws IOException {
  super(NodeType.JOURNAL_NODE);
  this.conf = conf;
  sd = new StorageDirectory(logDir, imageDir ? NameNodeDirType.IMAGE
      : NameNodeDirType.EDITS);
  this.addStorageDir(sd);
  this.isImageDir = imageDir;
  // null for metrics, will be extended


  analyzeStorage();
}
项目:hadoop-plus    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeStorage();
}
项目:FlexMap    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir, StartupOption startOpt,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeAndRecoverStorage(startOpt);
}
项目:hadoop-TCP    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeStorage();
}
项目:hardfs    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeStorage();
}
项目:hadoop-on-lustre2    文件:JNStorage.java   
/**
 * @param conf Configuration object
 * @param logDir the path to the directory in which data will be stored
 * @param errorReporter a callback to report errors
 * @throws IOException 
 */
protected JNStorage(Configuration conf, File logDir, StartupOption startOpt,
    StorageErrorReporter errorReporter) throws IOException {
  super(NodeType.JOURNAL_NODE);

  sd = new StorageDirectory(logDir);
  this.addStorageDir(sd);
  this.fjm = new FileJournalManager(conf, sd, errorReporter);

  analyzeAndRecoverStorage(startOpt);
}
项目:hadoop    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:aliyun-oss-hadoop-fs    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:big-c    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:hadoop-2.6.0-cdh5.4.3    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:hadoop-EAR    文件:FileJournalManagerReadOnly.java   
public FileJournalManagerReadOnly(StorageDirectory sd,
    NameNodeMetrics metrics, StorageErrorReporter errorReporter) {
  super(sd, metrics, errorReporter);
}
项目:hadoop-EAR    文件:FileJournalManager.java   
public FileJournalManager(StorageDirectory sd, NameNodeMetrics metrics,
    StorageErrorReporter errorReporter) {
  this.sd = sd;
  this.metrics = metrics;
  this.errorReporter = errorReporter;
}
项目:hadoop-plus    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:FlexMap    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:hadoop-TCP    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:hardfs    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}
项目:hadoop-on-lustre2    文件:FileJournalManager.java   
public FileJournalManager(Configuration conf, StorageDirectory sd,
    StorageErrorReporter errorReporter) {
  this.conf = conf;
  this.sd = sd;
  this.errorReporter = errorReporter;
}