@InterfaceAudience.Private public class AsyncProtobufLogWriter extends AbstractProtobufLogWriter implements AsyncFSWALProvider.AsyncWriter
cellEncoder, compressionContext, compressor, conf, length, trailer, trailerWarnSize, trailerWritten
Constructor and Description |
---|
AsyncProtobufLogWriter(org.apache.hbase.thirdparty.io.netty.channel.EventLoopGroup eventLoopGroup,
Class<? extends org.apache.hbase.thirdparty.io.netty.channel.Channel> channelClass) |
Modifier and Type | Method and Description |
---|---|
void |
append(WAL.Entry entry) |
void |
close() |
AsyncFSOutput |
getOutput() |
protected OutputStream |
getOutputStreamForCellEncoder() |
protected String |
getWriterClassName() |
protected void |
initOutput(org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path path,
boolean overwritable,
int bufferSize,
short replication,
long blockSize) |
CompletableFuture<Long> |
sync() |
protected long |
writeMagicAndWALHeader(byte[] magic,
WALProtos.WALHeader header)
return the file length after written.
|
protected long |
writeWALTrailerAndMagic(WALProtos.WALTrailer trailer,
byte[] magic) |
buildSecureWALHeader, buildWALHeader, getLength, init, initAfterHeader, secureInitAfterHeader, setEncryptor, writeWALTrailer
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
init
getLength
public AsyncProtobufLogWriter(org.apache.hbase.thirdparty.io.netty.channel.EventLoopGroup eventLoopGroup, Class<? extends org.apache.hbase.thirdparty.io.netty.channel.Channel> channelClass)
protected String getWriterClassName()
getWriterClassName
in class AbstractProtobufLogWriter
public void append(WAL.Entry entry)
append
in interface WALProvider.AsyncWriter
public CompletableFuture<Long> sync()
sync
in interface WALProvider.AsyncWriter
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
public AsyncFSOutput getOutput()
protected void initOutput(org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path path, boolean overwritable, int bufferSize, short replication, long blockSize) throws IOException, CommonFSUtils.StreamLacksCapabilityException
initOutput
in class AbstractProtobufLogWriter
IOException
CommonFSUtils.StreamLacksCapabilityException
protected long writeMagicAndWALHeader(byte[] magic, WALProtos.WALHeader header) throws IOException
AbstractProtobufLogWriter
writeMagicAndWALHeader
in class AbstractProtobufLogWriter
IOException
protected long writeWALTrailerAndMagic(WALProtos.WALTrailer trailer, byte[] magic) throws IOException
writeWALTrailerAndMagic
in class AbstractProtobufLogWriter
IOException
protected OutputStream getOutputStreamForCellEncoder()
getOutputStreamForCellEncoder
in class AbstractProtobufLogWriter
Copyright © 2007–2019 Cloudera. All rights reserved.