@InterfaceAudience.Private public class BoundedRegionGroupingProvider extends Object
RegionGroupingProvider.| Modifier and Type | Class and Description |
|---|---|
static interface |
RegionGroupingProvider.RegionGroupingStrategy
Map identifiers to a group number.
|
WALProvider.Writer| Modifier and Type | Field and Description |
|---|---|
protected ConcurrentMap<byte[],WALProvider> |
cached |
protected RegionGroupingProvider.RegionGroupingStrategy |
strategy |
| Constructor and Description |
|---|
BoundedRegionGroupingProvider() |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
shutdown utstanding WALs and clean up any persisted state.
|
static long |
getLogFileSize(WALFactory walFactory)
iff the given WALFactory is using the BoundedRegionGroupingProvider for meta and/or non-meta,
count the size of files (rolled and active).
|
static long |
getNumLogFiles(WALFactory walFactory)
iff the given WALFactory is using the BoundedRegionGroupingProvider for meta and/or non-meta,
count the number of files (rolled and active).
|
WAL |
getWAL(byte[] identifier) |
void |
init(WALFactory factory,
org.apache.hadoop.conf.Configuration conf,
List<WALActionsListener> listeners,
String providerId)
Set up the provider to create wals.
|
void |
shutdown()
persist outstanding WALs to storage and stop accepting new appends.
|
protected final ConcurrentMap<byte[],WALProvider> cached
protected RegionGroupingProvider.RegionGroupingStrategy strategy
public void init(WALFactory factory, org.apache.hadoop.conf.Configuration conf, List<WALActionsListener> listeners, String providerId) throws IOException
WALProviderinit in interface WALProviderfactory - factory that made us may not be nullconf - may not be nulllisteners - may be nullproviderId - differentiate between providers from one factory. may be nullIOExceptionpublic void shutdown()
throws IOException
WALProvidershutdown in interface WALProviderIOExceptionpublic void close()
throws IOException
WALProviderclose in interface WALProviderIOExceptionpublic static long getNumLogFiles(WALFactory walFactory)
walFactory - may not be null.public static long getLogFileSize(WALFactory walFactory)
walFactory - may not be null.public WAL getWAL(byte[] identifier) throws IOException
getWAL in interface WALProvideridentifier - may not be null. contents will not be altered.IOExceptionCopyright © 2007-2016 The Apache Software Foundation. All Rights Reserved.