微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

org.apache.hadoop.fs.Syncable的实例源码

项目:hadoop-oss    文件CryptoStreamsTestBase.java   
private void syncableCheck() throws IOException {
  OutputStream out = getoutputStream(smallBufferSize);
  try {
    int bytesWritten = dataLen / 3;
    out.write(data,bytesWritten);
    ((Syncable) out).hflush();

    InputStream in = getInputStream(defaultBufferSize);
    verify(in,bytesWritten,data);
    in.close();

    out.write(data,dataLen - bytesWritten);
    ((Syncable) out).hsync();

    in = getInputStream(defaultBufferSize);
    verify(in,dataLen,data);
    in.close();
  } finally {
    out.close();
  }
}
项目:hadoop    文件CryptoStreamsTestBase.java   
private void syncableCheck() throws IOException {
  OutputStream out = getoutputStream(smallBufferSize);
  try {
    int bytesWritten = dataLen / 3;
    out.write(data,data);
    in.close();
  } finally {
    out.close();
  }
}
项目:aliyun-oss-hadoop-fs    文件CryptoStreamsTestBase.java   
private void syncableCheck() throws IOException {
  OutputStream out = getoutputStream(smallBufferSize);
  try {
    int bytesWritten = dataLen / 3;
    out.write(data,data);
    in.close();
  } finally {
    out.close();
  }
}
项目:big-c    文件CryptoStreamsTestBase.java   
private void syncableCheck() throws IOException {
  OutputStream out = getoutputStream(smallBufferSize);
  try {
    int bytesWritten = dataLen / 3;
    out.write(data,data);
    in.close();
  } finally {
    out.close();
  }
}
项目:hadoop-2.6.0-cdh5.4.3    文件CryptoStreamsTestBase.java   
private void syncableCheck() throws IOException {
  OutputStream out = getoutputStream(smallBufferSize);
  try {
    int bytesWritten = dataLen / 3;
    out.write(data,data);
    in.close();
  } finally {
    out.close();
  }
}
项目:hops    文件CryptoStreamsTestBase.java   
private void syncableCheck() throws IOException {
  OutputStream out = getoutputStream(smallBufferSize);
  try {
    int bytesWritten = dataLen / 3;
    out.write(data,data);
    in.close();
  } finally {
    out.close();
  }
}
项目:hadoop-oss    文件CryptoOutputStream.java   
@Override
public void hflush() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hflush();
  }
}
项目:hadoop-oss    文件CryptoOutputStream.java   
@Override
public void hsync() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hsync();
  }
}
项目:hadoop    文件SyncableDataOutputStream.java   
@Override
public void hflush() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hflush();
  } else {
    out.flush();
  }
}
项目:hadoop    文件SyncableDataOutputStream.java   
@Override
public void hsync() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hsync();
  } else {
    out.flush();
  }
}
项目:hadoop    文件CryptoOutputStream.java   
@Override
public void hflush() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hflush();
  }
}
项目:hadoop    文件CryptoOutputStream.java   
@Override
public void hsync() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hsync();
  }
}
项目:aliyun-oss-hadoop-fs    文件SyncableDataOutputStream.java   
@Override
public void hflush() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hflush();
  } else {
    out.flush();
  }
}
项目:aliyun-oss-hadoop-fs    文件SyncableDataOutputStream.java   
@Override
public void hsync() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hsync();
  } else {
    out.flush();
  }
}
项目:aliyun-oss-hadoop-fs    文件CryptoOutputStream.java   
@Override
public void hflush() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hflush();
  }
}
项目:aliyun-oss-hadoop-fs    文件CryptoOutputStream.java   
@Override
public void hsync() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hsync();
  }
}
项目:big-c    文件SyncableDataOutputStream.java   
@Override
public void hflush() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hflush();
  } else {
    out.flush();
  }
}
项目:big-c    文件SyncableDataOutputStream.java   
@Override
public void hsync() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hsync();
  } else {
    out.flush();
  }
}
项目:big-c    文件CryptoOutputStream.java   
@Override
public void hflush() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hflush();
  }
}
项目:big-c    文件CryptoOutputStream.java   
@Override
public void hsync() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hsync();
  }
}
项目:hadoop-2.6.0-cdh5.4.3    文件SyncableDataOutputStream.java   
@Override
public void hflush() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hflush();
  } else {
    out.flush();
  }
}
项目:hadoop-2.6.0-cdh5.4.3    文件SyncableDataOutputStream.java   
@Override
public void hsync() throws IOException {
  if (out instanceof Syncable) {
    ((Syncable) out).hsync();
  } else {
    out.flush();
  }
}
项目:hadoop-2.6.0-cdh5.4.3    文件CryptoOutputStream.java   
@Override
public void hflush() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hflush();
  }
}
项目:hadoop-2.6.0-cdh5.4.3    文件CryptoOutputStream.java   
@Override
public void hsync() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hsync();
  }
}
项目:apex-malhar    文件FileSystemWAL.java   
protected void flush() throws IOException
{
  if (outputStream != null) {
    if (fileSystemWAL.fileContext.getDefaultFileSystem() instanceof LocalFs ||
        fileSystemWAL.fileContext.getDefaultFileSystem() instanceof RawLocalFs) {
      //until the stream is closed on the local FS,readers don't see any data.
      close();
    } else {
      Syncable syncableOutputStream = (Syncable)outputStream;
      syncableOutputStream.hflush();
      syncableOutputStream.hsync();
    }
  }
}
项目:hops    文件CryptoOutputStream.java   
@Override
public void hflush() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hflush();
  }
}
项目:hops    文件CryptoOutputStream.java   
@Override
public void hsync() throws IOException {
  flush();
  if (out instanceof Syncable) {
    ((Syncable)out).hsync();
  }
}

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。