public Metrics metrics() {
            return metrics;
        }
The {@link Metrics} that this group belongs to.
<p>
Do not use this to add {@link Sensor Sensors}, since they will not be removed when this group is
{@link #close() closed}. Metrics can be added directly, as long as the metric names are obtained from
this group via the {@link #metricName(MetricNameTemplate)} method.

@return the metrics; never null
connect/runtime/src/main/java/org/apache/kafka/connect/runtime/ConnectMetrics.java