You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2022/06/10 16:56:01 UTC

[GitHub] [kafka] omkreddy commented on a diff in pull request #10738: KAFKA-6945: KIP-373, allow users to create delegation token for others

omkreddy commented on code in PR #10738:
URL: https://github.com/apache/kafka/pull/10738#discussion_r894688213


##########
clients/src/main/java/org/apache/kafka/common/protocol/Errors.java:
##########
@@ -364,7 +365,8 @@ public enum Errors {
     INCONSISTENT_TOPIC_ID(103, "The log's topic ID did not match the topic ID in the request", InconsistentTopicIdException::new),
     INCONSISTENT_CLUSTER_ID(104, "The clusterId in the request does not match that found on the server", InconsistentClusterIdException::new),
     TRANSACTIONAL_ID_NOT_FOUND(105, "The transactionalId could not be found", TransactionalIdNotFoundException::new),
-    FETCH_SESSION_TOPIC_ID_ERROR(106, "The fetch session encountered inconsistent topic ID usage", FetchSessionTopicIdException::new);
+    FETCH_SESSION_TOPIC_ID_ERROR(106, "The fetch session encountered inconsistent topic ID usage", FetchSessionTopicIdException::new),
+    USER_AUTHORIATION_FAILED(107, "User authorization failed", UserAuthorizationException::new);

Review Comment:
   minor typo: `USER_AUTHORIATION_FAILED` => `USER_AUTHORIAZATION_FAILED`



##########
clients/src/main/java/org/apache/kafka/common/protocol/Errors.java:
##########
@@ -364,7 +365,8 @@ public enum Errors {
     INCONSISTENT_TOPIC_ID(103, "The log's topic ID did not match the topic ID in the request", InconsistentTopicIdException::new),
     INCONSISTENT_CLUSTER_ID(104, "The clusterId in the request does not match that found on the server", InconsistentClusterIdException::new),
     TRANSACTIONAL_ID_NOT_FOUND(105, "The transactionalId could not be found", TransactionalIdNotFoundException::new),
-    FETCH_SESSION_TOPIC_ID_ERROR(106, "The fetch session encountered inconsistent topic ID usage", FetchSessionTopicIdException::new);
+    FETCH_SESSION_TOPIC_ID_ERROR(106, "The fetch session encountered inconsistent topic ID usage", FetchSessionTopicIdException::new),
+    USER_AUTHORIATION_FAILED(107, "User authorization failed", UserAuthorizationException::new);

Review Comment:
   Also we are not using this error. Can we remove this. We can just `DELEGATION_TOKEN_AUTHORIZATION_FAILED` error for all token related authorisation issues.



-- 
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: jira-unsubscribe@kafka.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org