当前位置: 首页>>代码示例>>Java>>正文


Java ReadaheadPool类代码示例

本文整理汇总了Java中org.apache.hadoop.io.ReadaheadPool的典型用法代码示例。如果您正苦于以下问题:Java ReadaheadPool类的具体用法?Java ReadaheadPool怎么用?Java ReadaheadPool使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ReadaheadPool类属于org.apache.hadoop.io包,在下文中一共展示了ReadaheadPool类的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: FadvisedFileRegion

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedFileRegion(RandomAccessFile file, long position, long count,
    boolean manageOsCache, int readaheadLength, ReadaheadPool readaheadPool,
    String identifier, int shuffleBufferSize, 
    boolean shuffleTransferToAllowed) throws IOException {
  super(file.getChannel(), position, count);
  this.manageOsCache = manageOsCache;
  this.readaheadLength = readaheadLength;
  this.readaheadPool = readaheadPool;
  this.fd = file.getFD();
  this.identifier = identifier;
  this.fileChannel = file.getChannel();
  this.count = count;
  this.position = position;
  this.shuffleBufferSize = shuffleBufferSize;
  this.shuffleTransferToAllowed = shuffleTransferToAllowed;
}
 
开发者ID:naver,项目名称:hadoop,代码行数:17,代码来源:FadvisedFileRegion.java

示例2: FadvisedFileRegion

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedFileRegion(RandomAccessFile file, long position, long count,
                          boolean manageOsCache, int readaheadLength, ReadaheadPool readaheadPool,
                          String identifier, int shuffleBufferSize,
                          boolean shuffleTransferToAllowed) throws IOException {
  super(file.getChannel(), position, count);
  this.manageOsCache = manageOsCache;
  this.readaheadLength = readaheadLength;
  this.readaheadPool = readaheadPool;
  this.fd = file.getFD();
  this.identifier = identifier;
  this.fileChannel = file.getChannel();
  this.count = count;
  this.position = position;
  this.shuffleBufferSize = shuffleBufferSize;
  this.shuffleTransferToAllowed = shuffleTransferToAllowed;
}
 
开发者ID:apache,项目名称:tajo,代码行数:17,代码来源:FadvisedFileRegion.java

示例3: FadvisedChunkedFile

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedChunkedFile(RandomAccessFile file, long position, long count,
    int chunkSize, boolean manageOsCache, int readaheadLength,
    ReadaheadPool readaheadPool, String identifier) throws IOException {
  super(file, position, count, chunkSize);
  this.manageOsCache = manageOsCache;
  this.readaheadLength = readaheadLength;
  this.readaheadPool = readaheadPool;
  this.fd = file.getFD();
  this.identifier = identifier;
}
 
开发者ID:naver,项目名称:hadoop,代码行数:11,代码来源:FadvisedChunkedFile.java

示例4: FadvisedFileRegion

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedFileRegion(RandomAccessFile file, long position, long count,
    boolean manageOsCache, int readaheadLength, ReadaheadPool readaheadPool,
    String identifier) throws IOException {
  super(file.getChannel(), position, count);
  this.manageOsCache = manageOsCache;
  this.readaheadLength = readaheadLength;
  this.readaheadPool = readaheadPool;
  this.fd = file.getFD();
  this.identifier = identifier;
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:11,代码来源:FadvisedFileRegion.java

示例5: startDataNode

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
/**
 * This method starts the data node with the specified conf.
 * 
 * @param conf - the configuration
 *  if conf's CONFIG_PROPERTY_SIMULATED property is set
 *  then a simulated storage based data node is created.
 * 
 * @param dataDirs - only for a non-simulated storage data node
 * @throws IOException
 */
void startDataNode(Configuration conf, 
                   AbstractList<File> dataDirs,
                  // DatanodeProtocol namenode,
                   SecureResources resources
                   ) throws IOException {
  if(UserGroupInformation.isSecurityEnabled() && resources == null) {
    if (!conf.getBoolean("ignore.secure.ports.for.testing", false)) {
      throw new RuntimeException("Cannot start secure cluster without "
          + "privileged resources.");
    }
  }

  // settings global for all BPs in the Data Node
  this.secureResources = resources;
  this.dataDirs = dataDirs;
  this.conf = conf;
  this.dnConf = new DNConf(conf);

  storage = new DataStorage();
  
  // global DN settings
  registerMXBean();
  initDataXceiver(conf);
  startInfoServer(conf);

  // BlockPoolTokenSecretManager is required to create ipc server.
  this.blockPoolTokenSecretManager = new BlockPoolTokenSecretManager();
  initIpcServer(conf);

  metrics = DataNodeMetrics.create(conf, getDisplayName());

  blockPoolManager = new BlockPoolManager(this);
  blockPoolManager.refreshNamenodes(conf);

  // Create the ReadaheadPool from the DataNode context so we can
  // exit without having to explicitly shutdown its thread pool.
  readaheadPool = ReadaheadPool.getInstance();
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:49,代码来源:DataNode.java

示例6: startDataNode

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
/**
 * This method starts the data node with the specified conf.
 *
 * @param conf
 *     - the configuration
 *     if conf's CONFIG_PROPERTY_SIMULATED property is set
 *     then a simulated storage based data node is created.
 * @param dataDirs
 *     - only for a non-simulated storage data node
 * @throws IOException
 */
void startDataNode(Configuration conf, AbstractList<File> dataDirs,
    // DatanodeProtocol namenode,
    SecureResources resources) throws IOException {
  if (UserGroupInformation.isSecurityEnabled() && resources == null) {
    if (!conf.getBoolean("ignore.secure.ports.for.testing", false)) {
      throw new RuntimeException(
          "Cannot start secure cluster without " + "privileged resources.");
    }
  }

  // settings global for all BPs in the Data Node
  this.secureResources = resources;
  this.dataDirs = dataDirs;
  this.conf = conf;
  this.dnConf = new DNConf(conf);

  storage = new DataStorage();
  
  // global DN settings
  registerMXBean();
  initDataXceiver(conf);
  startInfoServer(conf);

  // BlockPoolTokenSecretManager is required to create ipc server.
  this.blockPoolTokenSecretManager = new BlockPoolTokenSecretManager();
  initIpcServer(conf);

  metrics = DataNodeMetrics.create(conf, getDisplayName());

  blockPoolManager = new BlockPoolManager(this);
  blockPoolManager.refreshNamenodes(conf);

  // Create the ReadaheadPool from the DataNode context so we can
  // exit without having to explicitly shutdown its thread pool.
  readaheadPool = ReadaheadPool.getInstance();
}
 
开发者ID:hopshadoop,项目名称:hops,代码行数:48,代码来源:DataNode.java

示例7: FadvisedChunkedFile

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedChunkedFile(RandomAccessFile file, long position, long count,
                           int chunkSize, boolean manageOsCache, int readaheadLength,
                           ReadaheadPool readaheadPool, String identifier) throws IOException {
  super(file, position, count, chunkSize);
  this.manageOsCache = manageOsCache;
  this.readaheadLength = readaheadLength;
  this.readaheadPool = readaheadPool;
  this.fd = file.getFD();
  this.identifier = identifier;
}
 
开发者ID:apache,项目名称:tajo,代码行数:11,代码来源:FadvisedChunkedFile.java

示例8: FadvisedFileRegionWrapper

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedFileRegionWrapper(RandomAccessFile file, long position, long count,
                                 boolean manageOsCache, int readaheadLength, ReadaheadPool readaheadPool,
                                 String identifier) throws IOException {
  super(file, position, count, manageOsCache, readaheadLength, readaheadPool,
      identifier, DEFAULT_SHUFFLE_BUFFER_SIZE, true);
}
 
开发者ID:gruter,项目名称:tajo-cdh,代码行数:7,代码来源:FadvisedFileRegionWrapper.java

示例9: FadvisedFileRegionWrapper

import org.apache.hadoop.io.ReadaheadPool; //导入依赖的package包/类
public FadvisedFileRegionWrapper(RandomAccessFile file, long position, long count,
                                 boolean manageOsCache, int readaheadLength, ReadaheadPool readaheadPool,
                                 String identifier) throws IOException {
  super(file, position, count, manageOsCache, readaheadLength, readaheadPool, identifier);
}
 
开发者ID:gruter,项目名称:tajo-cdh,代码行数:6,代码来源:FadvisedFileRegionWrapper.java


注:本文中的org.apache.hadoop.io.ReadaheadPool类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。