org.apache.hadoop.hdfs.util.ByteArrayManager的实例源码

项目:hadoop    文件ClientContext.java   
private ClientContext(String name,Conf conf) {
  this.name = name;
  this.confString = confAsstring(conf);
  this.shortCircuitCache = new ShortCircuitCache(
      conf.shortCircuitStreamsCacheSize,conf.shortCircuitStreamsCacheExpiryMs,conf.shortCircuitMmapCacheSize,conf.shortCircuitMmapCacheExpiryMs,conf.shortCircuitMmapCacheRetryTimeout,conf.shortCircuitCacheStaleThresholdMs,conf.shortCircuitSharedMemoryWatcherInterruptCheckMs);
  this.peerCache =
        new PeerCache(conf.socketCacheCapacity,conf.socketCacheExpiry);
  this.keyProviderCache = new KeyProviderCache(conf.keyProviderCacheExpiryMs);
  this.useLegacyBlockReaderLocal = conf.useLegacyBlockReaderLocal;
  this.domainSocketFactory = new DomainSocketFactory(conf);

  this.byteArrayManager = ByteArrayManager.newInstance(conf.writeByteArrayManagerConf);
}
项目:aliyun-oss-hadoop-fs    文件ClientContext.java   
private ClientContext(String name,DfsClientConf conf) {
  final ShortCircuitConf scConf = conf.getShortCircuitConf();

  this.name = name;
  this.confString = scConf.confAsstring();
  this.shortCircuitCache = ShortCircuitCache.fromConf(scConf);
  this.peerCache = new PeerCache(scConf.getSocketCacheCapacity(),scConf.getSocketCacheExpiry());
  this.keyProviderCache = new KeyProviderCache(
      scConf.getKeyProviderCacheExpiryMs());
  this.useLegacyBlockReaderLocal = scConf.isUseLegacyBlockReaderLocal();
  this.domainSocketFactory = new DomainSocketFactory(scConf);

  this.byteArrayManager = ByteArrayManager.newInstance(
      conf.getWriteByteArrayManagerConf());
}
项目:aliyun-oss-hadoop-fs    文件DataStreamer.java   
private DataStreamer(HdfsFileStatus stat,ExtendedBlock block,DFSClient dfsClient,String src,Progressable progress,DataChecksum checksum,atomicreference<CachingStrategy> cachingStrategy,ByteArrayManager byteArrayManage,boolean isAppend,String[] favorednodes) {
  this.block = block;
  this.dfsClient = dfsClient;
  this.src = src;
  this.progress = progress;
  this.stat = stat;
  this.checksum4WriteBlock = checksum;
  this.cachingStrategy = cachingStrategy;
  this.byteArrayManager = byteArrayManage;
  this.isLazyPersistFile = isLazyPersist(stat);
  this.isAppend = isAppend;
  this.favorednodes = favorednodes;

  final DfsClientConf conf = dfsClient.getConf();
  this.dfsclientSlowLogThresholdMs = conf.getSlowIoWarningThresholdMs();
  this.excludednodes = initExcludednodes(conf.getExcludednodesCacheExpiry());
  this.errorState = new ErrorState(conf.getDatanodeRestartTimeout());
}
项目:big-c    文件ClientContext.java   
private ClientContext(String name,conf.socketCacheExpiry);
  this.keyProviderCache = new KeyProviderCache(conf.keyProviderCacheExpiryMs);
  this.useLegacyBlockReaderLocal = conf.useLegacyBlockReaderLocal;
  this.domainSocketFactory = new DomainSocketFactory(conf);

  this.byteArrayManager = ByteArrayManager.newInstance(conf.writeByteArrayManagerConf);
}
项目:hadoop-2.6.0-cdh5.4.3    文件ClientContext.java   
private ClientContext(String name,conf.socketCacheExpiry);
  this.keyProviderCache = new KeyProviderCache(conf.keyProviderCacheExpiryMs);
  this.useLegacyBlockReaderLocal = conf.useLegacyBlockReaderLocal;
  this.domainSocketFactory = new DomainSocketFactory(conf);

  this.byteArrayManager = ByteArrayManager.newInstance(conf.writeByteArrayManagerConf);
}
项目:FlexMap    文件ClientContext.java   
private ClientContext(String name,conf.socketCacheExpiry);
  this.useLegacyBlockReaderLocal = conf.useLegacyBlockReaderLocal;
  this.domainSocketFactory = new DomainSocketFactory(conf);

  this.byteArrayManager = ByteArrayManager.newInstance(conf.writeByteArrayManagerConf);
}
项目:aliyun-oss-hadoop-fs    文件DataStreamer.java   
/**
 * release a list of packets to ByteArrayManager
 *
 * @param packets packets to be release
 * @param bam ByteArrayManager
 */
private static void releaseBuffer(List<DFSPacket> packets,ByteArrayManager bam) {
  for(DFSPacket p : packets) {
    p.releaseBuffer(bam);
  }
  packets.clear();
}
项目:aliyun-oss-hadoop-fs    文件DataStreamer.java   
/**
 * construction with tracing info
 */
DataStreamer(HdfsFileStatus stat,String[] favorednodes) {
  this(stat,block,dfsClient,src,progress,checksum,cachingStrategy,byteArrayManage,false,favorednodes);
  stage = BlockConstructionStage.PIPELINE_SETUP_CREATE;
}
项目:aliyun-oss-hadoop-fs    文件DataStreamer.java   
/**
 * Construct a data streamer for appending to the last partial block
 * @param lastBlock last block of the file to be appended
 * @param stat status of the file to be appended
 */
DataStreamer(LocatedBlock lastBlock,HdfsFileStatus stat,ByteArrayManager byteArrayManage) {
  this(stat,lastBlock.getBlock(),true,null);
  stage = BlockConstructionStage.PIPELINE_SETUP_APPEND;
  bytesSent = block.getNumBytes();
  accesstoken = lastBlock.getBlockToken();
}
项目:aliyun-oss-hadoop-fs    文件StripedDataStreamer.java   
StripedDataStreamer(HdfsFileStatus stat,String[] favorednodes,short index,Coordinator coordinator) {
  super(stat,null,favorednodes);
  this.index = index;
  this.coordinator = coordinator;
}
项目:hadoop    文件DFSOutputStream.java   
private static void releaseBuffer(List<DFSPacket> packets,ByteArrayManager bam) {
  for (DFSPacket p : packets) {
    p.releaseBuffer(bam);
  }
  packets.clear();
}
项目:hadoop    文件ClientContext.java   
public ByteArrayManager getByteArrayManager() {
  return byteArrayManager;
}
项目:aliyun-oss-hadoop-fs    文件ClientContext.java   
public ByteArrayManager getByteArrayManager() {
  return byteArrayManager;
}
项目:aliyun-oss-hadoop-fs    文件DfsClientConf.java   
/**
 * @return the writeByteArrayManagerConf
 */
public ByteArrayManager.Conf getWriteByteArrayManagerConf() {
  return writeByteArrayManagerConf;
}
项目:aliyun-oss-hadoop-fs    文件DFSPacket.java   
/**
 * Release the buffer in this packet to ByteArrayManager.
 */
synchronized void releaseBuffer(ByteArrayManager bam) {
  bam.release(buf);
  buf = null;
}
项目:big-c    文件DFSOutputStream.java   
private static void releaseBuffer(List<DFSPacket> packets,ByteArrayManager bam) {
  for (DFSPacket p : packets) {
    p.releaseBuffer(bam);
  }
  packets.clear();
}
项目:big-c    文件ClientContext.java   
public ByteArrayManager getByteArrayManager() {
  return byteArrayManager;
}
项目:hadoop-2.6.0-cdh5.4.3    文件DFSOutputStream.java   
private synchronized void releaseBuffer(ByteArrayManager bam) {
  bam.release(buf);
  buf = null;
}
项目:hadoop-2.6.0-cdh5.4.3    文件DFSOutputStream.java   
private static void releaseBuffer(List<Packet> packets,ByteArrayManager bam) {
  for(Packet p : packets) {
    p.releaseBuffer(bam);
  }
  packets.clear();
}
项目:hadoop-2.6.0-cdh5.4.3    文件ClientContext.java   
public ByteArrayManager getByteArrayManager() {
  return byteArrayManager;
}
项目:FlexMap    文件DFSOutputStream.java   
private void releaseBuffer(ByteArrayManager bam) {
  bam.release(buf);
  buf = null;
}
项目:FlexMap    文件ClientContext.java   
public ByteArrayManager getByteArrayManager() {
  return byteArrayManager;
}
项目:hadoop    文件DFSPacket.java   
/**
 * Release the buffer in this packet to ByteArrayManager.
 *
 * @param bam
 */
synchronized void releaseBuffer(ByteArrayManager bam) {
  bam.release(buf);
  buf = null;
}
项目:big-c    文件DFSPacket.java   
/**
 * Release the buffer in this packet to ByteArrayManager.
 *
 * @param bam
 */
synchronized void releaseBuffer(ByteArrayManager bam) {
  bam.release(buf);
  buf = null;
}

相关文章

买水果
比较全面的redis工具类
gson 反序列化到多态子类
java 版本的 mb_strwidth
JAVA 反转字符串的最快方法,大概比StringBuffer.reverse()性...
com.google.gson.internal.bind.ArrayTypeAdapter的实例源码...