Class AbstractPatternFilter
java.lang.Object
org.apache.hadoop.metrics2.MetricsFilter
org.apache.hadoop.metrics2.filter.AbstractPatternFilter
- All Implemented Interfaces:
MetricsPlugin
- Direct Known Subclasses:
GlobFilter,RegexFilter
Base class for pattern based filters
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbooleanaccepts(Iterable<MetricsTag> tags) Whether to accept the tagsbooleanWhether to accept the namebooleanaccepts(MetricsTag tag) Whether to accept the tagprotected abstract com.google.re2j.PatternCompile a string pattern in to a pattern objectvoidinit(org.apache.commons.configuration2.SubsetConfiguration conf) Initialize the pluginMethods inherited from class org.apache.hadoop.metrics2.MetricsFilter
accepts
-
Field Details
-
INCLUDE_KEY
- See Also:
-
EXCLUDE_KEY
- See Also:
-
INCLUDE_TAGS_KEY
- See Also:
-
EXCLUDE_TAGS_KEY
- See Also:
-
-
Method Details
-
init
public void init(org.apache.commons.configuration2.SubsetConfiguration conf) Description copied from interface:MetricsPluginInitialize the plugin- Parameters:
conf- the configuration object for the plugin
-
accepts
Description copied from class:MetricsFilterWhether to accept the tag- Specified by:
acceptsin classMetricsFilter- Parameters:
tag- to filter on- Returns:
- true to accept; false otherwise
-
accepts
Description copied from class:MetricsFilterWhether to accept the tags- Specified by:
acceptsin classMetricsFilter- Parameters:
tags- to filter on- Returns:
- true to accept; false otherwise
-
accepts
Description copied from class:MetricsFilterWhether to accept the name- Specified by:
acceptsin classMetricsFilter- Parameters:
name- to filter on- Returns:
- true to accept; false otherwise.
-
compile
Compile a string pattern in to a pattern object- Parameters:
s- the string pattern to compile- Returns:
- the compiled pattern object
-