Bird
0
0

Which of the following is the correct way to specify a consumer group ID in Kafka consumer configuration?

easy📝 Syntax Q12 of 15
Kafka - Consumer Groups
Which of the following is the correct way to specify a consumer group ID in Kafka consumer configuration?
A"groupName" : "my-group"
B"group.id" : "my-group"
C"consumer.group" : "my-group"
D"consumerId" : "my-group"
Step-by-Step Solution
Solution:
  1. Step 1: Recall Kafka consumer config keys

    The correct key to set the consumer group is "group.id".
  2. Step 2: Check other options

    Other keys like "consumer.group", "groupName", or "consumerId" are incorrect or do not exist.
  3. Final Answer:

    "group.id" : "my-group" -> Option B
  4. Quick Check:

    Consumer group ID key = "group.id" [OK]
Quick Trick: Remember Kafka uses "group.id" for consumer groups [OK]
Common Mistakes:
  • Using incorrect config keys
  • Confusing consumer ID with group ID
  • Misspelling the key name

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Kafka Quizzes