@InterfaceAudience.Private public class BoundedRegionGroupingProvider extends RegionGroupingProvider
RegionGroupingProvider.RegionGroupingProvider.IdentityGroupingStrategy, RegionGroupingProvider.RegionGroupingStrategy, RegionGroupingProvider.StrategiesWALProvider.Writer| Modifier and Type | Field and Description |
|---|---|
private AtomicInteger |
counter |
(package private) static int |
DEFAULT_NUM_REGION_GROUPS |
private WALProvider[] |
delegates |
private static org.apache.commons.logging.Log |
LOG |
(package private) static String |
NUM_REGION_GROUPS |
cached, DEFAULT_DELEGATE_PROVIDER, DELEGATE_PROVIDER, 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).
|
void |
init(WALFactory factory,
org.apache.hadoop.conf.Configuration conf,
List<WALActionsListener> listeners,
String providerId)
Set up the provider to create wals.
|
(package private) WALProvider |
populateCache(byte[] group)
Populate the cache for this group.
|
void |
shutdown()
persist outstanding WALs to storage and stop accepting new appends.
|
getStrategy, getWALprivate static final org.apache.commons.logging.Log LOG
static final String NUM_REGION_GROUPS
static final int DEFAULT_NUM_REGION_GROUPS
private WALProvider[] delegates
private AtomicInteger counter
public void init(WALFactory factory, org.apache.hadoop.conf.Configuration conf, List<WALActionsListener> listeners, String providerId) throws IOException
WALProviderinit in interface WALProviderinit in class RegionGroupingProviderfactory - factory that made us may not be nullconf - may not be nulllisteners - may be nullproviderId - differentiate between providers from one factory. may be nullIOExceptionWALProvider populateCache(byte[] group)
RegionGroupingProviderpopulateCache in class RegionGroupingProviderpublic void shutdown()
throws IOException
WALProvidershutdown in interface WALProvidershutdown in class RegionGroupingProviderIOExceptionpublic void close()
throws IOException
WALProviderclose in interface WALProviderclose in class RegionGroupingProviderIOExceptionpublic static long getNumLogFiles(WALFactory walFactory)
walFactory - may not be null.public static long getLogFileSize(WALFactory walFactory)
walFactory - may not be null.Copyright © 2007–2019 The Apache Software Foundation. All rights reserved.