You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by GitBox <gi...@apache.org> on 2021/09/17 18:23:00 UTC
[GitHub] [pulsar] michaeljmarshall opened a new pull request #12077: [Broker] Only store authentication data after authentication is complete
michaeljmarshall opened a new pull request #12077:
URL: https://github.com/apache/pulsar/pull/12077
### Motivation
The `ServerCnx` class stores the most recent `AuthenticationDataSource` for a connection in the `authenticationData` field. This should not be stored until the authentication state `isComplete` has returned `true`. Since the `ServerCnx` state does not go to `Connected` until after the auth state has completed, this is really just a cosmetic change.
For historical context, it looks like this line was added a while ago here: https://github.com/apache/pulsar/pull/5462. At that time, the `doAuthentication` method did not set the `authenticationState` field. The method now sets that field, so I think we should remove this line. https://github.com/apache/pulsar/blob/fb76b23be6a1b8334225d4be55f93e02626ccec5/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java#L623-L632
### Modifications
* Remove the premature setting of authentication data in `ServerCnx`
### Verifying this change
This change is mostly cosmetic. The `authenticationData` field is only used when the class's state is `Connected`, and that only happens after the authentication state has returned true for `isComplete`. As such, I think tests passing will be enough to ensure correctness.
### Does this pull request potentially affect one of the following parts:
This change is not breaking.
### Documentation
No docs required.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] lhotari commented on pull request #12077: [Broker] Only store authentication data after authentication is complete
Posted by GitBox <gi...@apache.org>.
lhotari commented on pull request #12077:
URL: https://github.com/apache/pulsar/pull/12077#issuecomment-963088143
Closing and re-opening to trigger a new fresh test run.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] michaeljmarshall commented on pull request #12077: [Broker] Only store authentication data after authentication is complete
Posted by GitBox <gi...@apache.org>.
michaeljmarshall commented on pull request #12077:
URL: https://github.com/apache/pulsar/pull/12077#issuecomment-977240948
/pulsarbot run-failure-checks
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] michaeljmarshall commented on pull request #12077: [Broker] Only store authentication data after authentication is complete
Posted by GitBox <gi...@apache.org>.
michaeljmarshall commented on pull request #12077:
URL: https://github.com/apache/pulsar/pull/12077#issuecomment-977552184
Just rebased. The same line is the only change.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] lhotari closed pull request #12077: [Broker] Only store authentication data after authentication is complete
Posted by GitBox <gi...@apache.org>.
lhotari closed pull request #12077:
URL: https://github.com/apache/pulsar/pull/12077
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [pulsar] codelipenghui merged pull request #12077: [Broker] Only store authentication data after authentication is complete
Posted by GitBox <gi...@apache.org>.
codelipenghui merged pull request #12077:
URL: https://github.com/apache/pulsar/pull/12077
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org