THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
CreateDelegationTokenOptions class will be updated to take "owner" principal as input
Code Block | ||||
---|---|---|---|---|
| ||||
AdminClient { //create delegation token with supplied options public abstract CreateDelegationTokenResult createDelegationToken(CreateDelegationTokenOptions options) } public class CreateDelegationTokenOptions extends AbstractOptions<CreateDelegationTokenOptions> { |
...
private long maxLifeTimeMs = -1; |
...
private List<KafkaPrincipal> renewers = new LinkedList<>(); |
...
private Optional<KafkaPrincipal> owner = Optional.empty(); |
...
// New public CreateDelegationTokenOptions owner(KafkaPrincipal owner) { |
...
// New this.owner = Optional.of(owner); |
...
return this; |
...
} |
...
public CreateDelegationTokenOptions renewers(List<KafkaPrincipal> renewers) { |
...
this.renewers = renewers; |
...
return this; |
...
} |
...
public Optional<KafkaPrincipal> owner() { |
...
return owner; |
...
} |
...
public List<KafkaPrincipal> renewers() { |
...
return renewers; |
...
} |
...
public CreateDelegationTokenOptions maxlifeTimeMs(long maxLifeTimeMs) { |
...
this.maxLifeTimeMs = maxLifeTimeMs; |
...
return this; |
...
} |
...
public long maxlifeTimeMs() { |
...
return maxLifeTimeMs; |
...
} |
...
} |
...
ACL Changes:
DelegationTokenCommand Changes:
...