Modifier and Type | Method and Description |
---|---|
static WALKeyImpl |
doFullAppendTransaction(WAL wal,
NavigableMap<byte[],Integer> replicationScope,
RegionInfo hri,
WALEdit edit,
MultiVersionConcurrencyControl mvcc,
boolean sync)
A 'full' WAL transaction involves starting an mvcc transaction followed by an append,
an optional sync, and then a call to complete the mvcc transaction.
|
static long |
getWALBlockSize(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path dir)
Blocksize returned here is 2x the default HDFS blocksize unless explicitly set in
Configuration.
|
static long |
getWALBlockSize(org.apache.hadoop.conf.Configuration conf,
org.apache.hadoop.fs.FileSystem fs,
org.apache.hadoop.fs.Path dir,
boolean isRecoverEdits)
Public because of FSHLog.
|
static WALKeyImpl |
writeBulkLoadMarkerAndSync(WAL wal,
NavigableMap<byte[],Integer> replicationScope,
RegionInfo hri,
WALProtos.BulkLoadDescriptor desc,
MultiVersionConcurrencyControl mvcc)
Write a log marker that a bulk load has succeeded and is about to be committed.
|
static WALKeyImpl |
writeCompactionMarker(WAL wal,
NavigableMap<byte[],Integer> replicationScope,
RegionInfo hri,
WALProtos.CompactionDescriptor c,
MultiVersionConcurrencyControl mvcc)
Write the marker that a compaction has succeeded and is about to be committed.
|
static WALKeyImpl |
writeFlushMarker(WAL wal,
NavigableMap<byte[],Integer> replicationScope,
RegionInfo hri,
WALProtos.FlushDescriptor f,
boolean sync,
MultiVersionConcurrencyControl mvcc)
Write a flush marker indicating a start / abort or a complete of a region flush
|
static WALKeyImpl |
writeRegionEventMarker(WAL wal,
NavigableMap<byte[],Integer> replicationScope,
RegionInfo hri,
WALProtos.RegionEventDescriptor r,
MultiVersionConcurrencyControl mvcc)
Write a region open marker indicating that the region is opened.
|
public static WALKeyImpl writeCompactionMarker(WAL wal, NavigableMap<byte[],Integer> replicationScope, RegionInfo hri, WALProtos.CompactionDescriptor c, MultiVersionConcurrencyControl mvcc) throws IOException
This write is for internal use only. Not for external client consumption.
mvcc
- Used by WAL to get sequence Id for the waledit.IOException
public static WALKeyImpl writeFlushMarker(WAL wal, NavigableMap<byte[],Integer> replicationScope, RegionInfo hri, WALProtos.FlushDescriptor f, boolean sync, MultiVersionConcurrencyControl mvcc) throws IOException
This write is for internal use only. Not for external client consumption.
IOException
public static WALKeyImpl writeRegionEventMarker(WAL wal, NavigableMap<byte[],Integer> replicationScope, RegionInfo hri, WALProtos.RegionEventDescriptor r, MultiVersionConcurrencyControl mvcc) throws IOException
IOException
public static WALKeyImpl writeBulkLoadMarkerAndSync(WAL wal, NavigableMap<byte[],Integer> replicationScope, RegionInfo hri, WALProtos.BulkLoadDescriptor desc, MultiVersionConcurrencyControl mvcc) throws IOException
wal
- The log to write into.replicationScope
- The replication scope of the families in the HRegionhri
- A description of the region in the table that we are bulk loading into.desc
- A protocol buffers based description of the client's bulk loading requestIOException
- We will throw an IOException if we can not append to the HLog.public static WALKeyImpl doFullAppendTransaction(WAL wal, NavigableMap<byte[],Integer> replicationScope, RegionInfo hri, WALEdit edit, MultiVersionConcurrencyControl mvcc, boolean sync) throws IOException
This write is for internal use only. Not for external client consumption.
IOException
public static long getWALBlockSize(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path dir) throws IOException
IOException
public static long getWALBlockSize(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.fs.FileSystem fs, org.apache.hadoop.fs.Path dir, boolean isRecoverEdits) throws IOException
isRecoverEdits
- the created writer is for recovered edits or WAL. For recovered edits, it
is true and for WAL it is false.IOException
Copyright © 2007–2019 Cloudera. All rights reserved.