Replace colons in group ID with dash #291
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi. I have recent been encountering an issue when using Racecar with AWS MSK. Whenever I use a consumer class which is not namespaced (e.g.
MyFunnyConsumer
), everything works fine, however, if I use a consumer class which is namespace, (e.g.MyFunny::Consumer
), I no longer am able to see Cloudwatch metrics for that consumer group.From some testing it seems like it is due to the
:
in the group ID. I see some logic exists to format the group ID, however it seems limited to handling camel case. In my example here, theMyFunny::Consumer
class is transformed into a group ID ofmy-funny::consumer
.racecar/lib/racecar/config.rb
Lines 219 to 220 in 73f424f
Now, I know my use case here, and the issue I am seeing, is limited to a proprietary Kafka implementation. However, I believe colons may be illegal characters for Kafka group IDs. I have struggled to find canonical documentation around this, but I have come across some related documentation:
From: https://www.ibm.com/docs/en/app-connect/11.0.0?topic=enterprise-consuming-messages-from-kafka-topics
From: SOHU-Co/kafka-node#394
I can understand if there may be something I'm overlooking, or that the current behaviour is the desired behaviour - but I thought I'd open a quick PR in case this is valid.