Class JobMetricGroup<C extends ComponentMetricGroup<C>>
- java.lang.Object
-
- org.apache.flink.runtime.metrics.groups.AbstractMetricGroup<P>
-
- org.apache.flink.runtime.metrics.groups.ComponentMetricGroup<C>
-
- org.apache.flink.runtime.metrics.groups.JobMetricGroup<C>
-
- Type Parameters:
C- The type of the parent ComponentMetricGroup.
- All Implemented Interfaces:
org.apache.flink.metrics.MetricGroup
- Direct Known Subclasses:
JobManagerJobMetricGroup,TaskManagerJobMetricGroup
@Internal public abstract class JobMetricGroup<C extends ComponentMetricGroup<C>> extends ComponentMetricGroup<C>
Special abstractMetricGrouprepresenting everything belonging to a specific job.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.flink.runtime.metrics.groups.AbstractMetricGroup
AbstractMetricGroup.ChildType
-
-
Field Summary
Fields Modifier and Type Field Description protected org.apache.flink.api.common.JobIDjobIdThe ID of the job represented by this metrics group.protected StringjobNameThe name of the job represented by this metrics group.-
Fields inherited from class org.apache.flink.runtime.metrics.groups.AbstractMetricGroup
LOG, parent, queryServiceScopeInfo, registry, variables
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedJobMetricGroup(MetricRegistry registry, C parent, org.apache.flink.api.common.JobID jobId, String jobName, String[] scope)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddEvent(org.apache.flink.events.EventBuilder eventBuilder)voidaddSpan(org.apache.flink.traces.SpanBuilder spanBuilder)protected QueryScopeInfo.JobQueryScopeInfocreateQueryServiceMetricInfo(org.apache.flink.metrics.CharacterFilter filter)Creates the metric query service scope for this group.protected StringgetGroupName(org.apache.flink.metrics.CharacterFilter filter)Returns the name for this group, meaning what kind of entity it represents, for example "taskmanager".org.apache.flink.api.common.JobIDjobId()StringjobName()protected voidputVariables(Map<String,String> variables)Enters all variables specific to thisAbstractMetricGroupand their associated values into the map.-
Methods inherited from class org.apache.flink.runtime.metrics.groups.ComponentMetricGroup
close, subComponents
-
Methods inherited from class org.apache.flink.runtime.metrics.groups.AbstractMetricGroup
addGroup, addGroup, addMetric, counter, counter, createChildGroup, createLogicalScope, gauge, getAllVariables, getAllVariables, getLogicalScope, getLogicalScope, getMetricIdentifier, getMetricIdentifier, getMetricIdentifier, getQueryServiceMetricInfo, getScopeComponents, histogram, isClosed, meter
-
-
-
-
Field Detail
-
jobId
protected final org.apache.flink.api.common.JobID jobId
The ID of the job represented by this metrics group.
-
jobName
@Nullable protected final String jobName
The name of the job represented by this metrics group.
-
-
Constructor Detail
-
JobMetricGroup
protected JobMetricGroup(MetricRegistry registry, C parent, org.apache.flink.api.common.JobID jobId, @Nullable String jobName, String[] scope)
-
-
Method Detail
-
jobId
public org.apache.flink.api.common.JobID jobId()
-
jobName
@Nullable public String jobName()
-
createQueryServiceMetricInfo
protected QueryScopeInfo.JobQueryScopeInfo createQueryServiceMetricInfo(org.apache.flink.metrics.CharacterFilter filter)
Description copied from class:AbstractMetricGroupCreates the metric query service scope for this group.- Specified by:
createQueryServiceMetricInfoin classAbstractMetricGroup<C extends ComponentMetricGroup<C>>- Parameters:
filter- character filter- Returns:
- query service scope
-
addSpan
public void addSpan(org.apache.flink.traces.SpanBuilder spanBuilder)
- Specified by:
addSpanin interfaceorg.apache.flink.metrics.MetricGroup- Overrides:
addSpanin classAbstractMetricGroup<C extends ComponentMetricGroup<C>>
-
addEvent
public void addEvent(org.apache.flink.events.EventBuilder eventBuilder)
- Specified by:
addEventin interfaceorg.apache.flink.metrics.MetricGroup- Overrides:
addEventin classAbstractMetricGroup<C extends ComponentMetricGroup<C>>
-
putVariables
protected void putVariables(Map<String,String> variables)
Description copied from class:AbstractMetricGroupEnters all variables specific to thisAbstractMetricGroupand their associated values into the map.- Overrides:
putVariablesin classAbstractMetricGroup<C extends ComponentMetricGroup<C>>- Parameters:
variables- map to enter variables and their values into
-
getGroupName
protected String getGroupName(org.apache.flink.metrics.CharacterFilter filter)
Description copied from class:AbstractMetricGroupReturns the name for this group, meaning what kind of entity it represents, for example "taskmanager".- Specified by:
getGroupNamein classAbstractMetricGroup<C extends ComponentMetricGroup<C>>- Parameters:
filter- character filter which is applied to the name- Returns:
- logical name for this group
-
-