[ 
https://issues.apache.org/jira/browse/KAFKA-17315?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17876464#comment-17876464
 ] 

Chia-Ping Tsai commented on KAFKA-17315:
----------------------------------------

push to trunk, 3.9, 3.8, and 3.7

trunk: 
https://github.com/apache/kafka/commit/4a485ddb71c844acc8bf241feda1fcbffc5ce9be

3.9: 
https://github.com/apache/kafka/commit/dcb4578903983ad0dbb7038326a1e2ad210248ff

3.8: 
https://github.com/apache/kafka/commit/163dcaf6ab59fc91d42417a3a6f170de623fd5e0

3.7: 
https://github.com/apache/kafka/commit/f596a0dffc332351ea53bf1213f8564ea0172d12

noted: I don't backport all tests to 3.8/3.7 since KAFKA-15751 and KAFKA-15752 
are not in 3.8/3.7. I have opened 
https://issues.apache.org/jira/browse/KAFKA-17417 for it.

> Fix the behavior of delegation tokens that expire immediately upon creation 
> in KRaft mode
> -----------------------------------------------------------------------------------------
>
>                 Key: KAFKA-17315
>                 URL: https://issues.apache.org/jira/browse/KAFKA-17315
>             Project: Kafka
>          Issue Type: Improvement
>            Reporter: Chia-Ping Tsai
>            Assignee: TengYao Chi
>            Priority: Blocker
>             Fix For: 4.0.0, 3.9.0, 3.7.2, 3.8.1
>
>
> In kraft mode, expiring delegation token (`expiryTimePeriodMs` < 0) has 
> following different behavior to zk mode.
> 1. `ExpiryTimestampMs` is set to "expiryTimePeriodMs" [0] rather than "now" 
> [1]
> 2.  it throws exception directly if the token is expired already [2]. By 
> contrast, zk mode does not. [3]
> [0] 
> https://github.com/apache/kafka/blob/49fc14f6116a697550339a8804177bd9290d15db/metadata/src/main/java/org/apache/kafka/controller/DelegationTokenControlManager.java#L316
> [1] 
> https://github.com/apache/kafka/blob/49fc14f6116a697550339a8804177bd9290d15db/core/src/main/scala/kafka/server/DelegationTokenManagerZk.scala#L292
> [2] 
> https://github.com/apache/kafka/blob/49fc14f6116a697550339a8804177bd9290d15db/metadata/src/main/java/org/apache/kafka/controller/DelegationTokenControlManager.java#L305
> [3] 
> https://github.com/apache/kafka/blob/49fc14f6116a697550339a8804177bd9290d15db/core/src/main/scala/kafka/server/DelegationTokenManagerZk.scala#L293



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to