public class WALEdit extends Object implements org.apache.hadoop.io.Writable, HeapSize
Constructor and Description |
---|
WALEdit() |
Modifier and Type | Method and Description |
---|---|
void |
add(KeyValue kv) |
void |
addClusterId(UUID clusterId)
Marks that the cluster with the given clusterId has consumed the change.
|
void |
addClusterIds(List<UUID> clusterIds)
Marks that the clusters with the given clusterIds have consumed the change.
|
List<UUID> |
getClusterIds() |
Integer |
getFromScope(byte[] key) |
List<KeyValue> |
getKeyValues() |
NavigableMap<byte[],Integer> |
getScopes()
Deprecated.
use
getFromScope(byte[]) instead |
boolean |
hasClusterId(UUID clusterId) |
boolean |
hasKeyInScope(byte[] key) |
long |
heapSize() |
boolean |
isEmpty() |
void |
putIntoScope(byte[] key,
Integer value) |
void |
readFields(DataInput in) |
void |
setCodec(WALEditCodec codec) |
void |
setCompressionContext(org.apache.hadoop.hbase.regionserver.wal.CompressionContext compression)
setCodec(WALEditCodec) must be called before calling this method. |
void |
setScopes(NavigableMap<byte[],Integer> scopes)
Deprecated.
use
putIntoScope(byte[], Integer) instead. This completely overrides any
existing scopes |
int |
size() |
String |
toString() |
void |
write(DataOutput out) |
public void setCompressionContext(org.apache.hadoop.hbase.regionserver.wal.CompressionContext compression)
setCodec(WALEditCodec)
must be called before calling this method.compression
- the CompressionContext
for the underlying codec.public void setCodec(WALEditCodec codec)
public void add(KeyValue kv)
public boolean isEmpty()
public int size()
public Integer getFromScope(byte[] key)
@Deprecated public NavigableMap<byte[],Integer> getScopes()
getFromScope(byte[])
instead@Deprecated public void setScopes(NavigableMap<byte[],Integer> scopes)
putIntoScope(byte[], Integer)
instead. This completely overrides any
existing scopesscopes
- set all the replication scope information. Must be non-nullpublic void putIntoScope(byte[] key, Integer value)
public boolean hasKeyInScope(byte[] key)
public boolean hasClusterId(UUID clusterId)
public void addClusterId(UUID clusterId)
public void addClusterIds(List<UUID> clusterIds)
public List<UUID> getClusterIds()
public void readFields(DataInput in) throws IOException
readFields
in interface org.apache.hadoop.io.Writable
IOException
public void write(DataOutput out) throws IOException
write
in interface org.apache.hadoop.io.Writable
IOException
public long heapSize()
Copyright © 2014 The Apache Software Foundation. All Rights Reserved.