tisonkun commented on code in PR #20860:
URL: https://github.com/apache/pulsar/pull/20860#discussion_r1285506796
##########
pulsar-sql/presto-pulsar/src/main/java/org/apache/pulsar/sql/presto/PulsarConnectorConfig.java:
##########
@@ -500,10 +513,19 @@ public PulsarAdmin getPulsarAdmin() throws
PulsarClientException {
if (this.pulsarAdmin == null) {
PulsarAdminBuilder builder = PulsarAdmin.builder();
+ if (getAuthPlugin() != null && getAuthToken() != null) {
+ throw new IllegalArgumentException("Either pulsar.auth-plugin
or pulsar.auth-token can be used,"
+ + " but not both at the same time");
+ }
+
if (getAuthPlugin() != null) {
builder.authentication(getAuthPlugin(), getAuthParams());
}
+ if (getAuthToken() != null){
Review Comment:
```suggestion
if (getAuthToken() != null) {
```
You may checkstyle locally with `mvn checkstyle:check`.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]