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.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fix] Enable Kafka TLS when TLS auth is specified #2107
[fix] Enable Kafka TLS when TLS auth is specified #2107
Changes from 1 commit
0042cd3
5b48422
4e170e9
5dc88cb
4c760ad
7e8c615
1f1a6f6
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This means that if someone explicitly set
tls.enabled
tofalse, this will be silently changed to
true`. I have nothing against that, but perhaps there's a way to detect whether this value was explicitly provided and keep whatever the user set?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it can be done by changing the
enabled
property to a pointer. I am not sure if there is much value in it. Some signatures will have to be also changed to accept the logger.More controversial is this setting
Somebody omitting the auth type and specifying
tls.enabled=true
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yurishkuro any thoughts on this? I don't have a strong opinion whether
kafka.consumer.tls.enabled=true
should setkafka.consumer.authentication=tls
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
From Gitter, we just saw a case where a user wants TLS encryption between the agent and collector without the auth parts.
kafka.producer.tls.enabled=true
+kafka.producer.authentication=none
is a valid combination.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are right, it's confusing for people to have both
kafka.producer.tls.enabled
andkafka.producer.authentication
they will probably tend to forget the second one.I have updated the PR to set
tls
auth when.tls.enabled
istrue
.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's the opposite.
tls.enabled
does not implyauthentication=tls
. It's perfectly possible to haveauthentication=none
but the traffic be encrypted using TLS.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@jpkrohling I am not sure if I understand you...
This is exactly what the PR does.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I misunderstood you, you are absolutely correct :-)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These tests are duplicated. Don't we have Kafka flags parsed by a packaged shared between ingester and storage?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both tests are in different packages, there is no shared test class.