Github user zentol commented on a diff in the pull request:

    https://github.com/apache/flink/pull/5115#discussion_r154904663
  
    --- Diff: 
flink-runtime/src/main/java/org/apache/flink/runtime/metrics/groups/AbstractMetricGroup.java
 ---
    @@ -409,6 +404,22 @@ public MetricGroup addGroup(String name) {
                return addGroup(name, false);
        }
     
    +   @Override
    +   public MetricGroup addGroup(String key, String value) {
    --- End diff --
    
    For any `GenericKeyMetricGroup` to be created, `keyed` must be true. Since 
this is only the case when creating the first group I don't understand how it 
could happen that the second group is created as a key group.
    
    This commit 
https://github.com/zentol/flink/commit/f3a91f6296994a33a7be448bec40f261b5343972 
removes the special case in addGroup(String, String) and reverts the logic for 
`createChildGroup` (which introduced a bug). The `MetricGroupTest` is passing.



---

Reply via email to