[ 
https://issues.apache.org/jira/browse/KAFKA-6123?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kevin Lu updated KAFKA-6123:
----------------------------
    Affects Version/s:     (was: 0.11.0.0)
          Description: 
KAFKA-4756 bugfix resolved the broker's KafkaMetricsReporter missing auto 
generated broker ids, but this was not fixed on the client side.

 

Metric reporters configured for clients should also be given the auto-generated 
client id in the `configure` method. The interceptors do receive the 
auto-generated client id.

  was:
When a {{MetricsReporter}} is configured for a client, it will receive the 
user-specified configurations via {{Configurable.configure(Map<String, ?> 
configs)}}. Likewise, {{ProducerInterceptor}} and {{ConsumerInterceptor}} 
receive user-specified configurations in their configure methods. 

The difference is when a user does not specify the {{client.id}} field, Kafka 
will auto-generate client ids (producer-1, producer-2, consumer-1, consumer-2, 
etc). This auto-generated {{client.id}} will be passed into the interceptors' 
configure method, but it is not passed to the {{MetricsReporter}} configure 
method.

This makes it harder to directly map {{MetricsReporter}} with the interceptors 
for the client when users do not specify the {{client.id}} field. The 
{{client.id}} can be determined from identifying a metric with the 
{{client.id}} tag, but this is hacky and requires traversal. 

It would be useful to have auto-generated {{client.id}} field also passed to 
the {{MetricsReporter}}.

           Issue Type: Bug  (was: Improvement)
              Summary: Give MetricsReporter auto-generated client.id  (was: 
MetricsReporter does not get auto-generated client.id)

> Give MetricsReporter auto-generated client.id
> ---------------------------------------------
>
>                 Key: KAFKA-6123
>                 URL: https://issues.apache.org/jira/browse/KAFKA-6123
>             Project: Kafka
>          Issue Type: Bug
>          Components: clients, metrics
>            Reporter: Kevin Lu
>            Priority: Minor
>              Labels: clients, metrics, newbie++
>
> KAFKA-4756 bugfix resolved the broker's KafkaMetricsReporter missing auto 
> generated broker ids, but this was not fixed on the client side.
>  
> Metric reporters configured for clients should also be given the 
> auto-generated client id in the `configure` method. The interceptors do 
> receive the auto-generated client id.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to