smolnar82 commented on a change in pull request #426:
URL: https://github.com/apache/knox/pull/426#discussion_r604318035



##########
File path: 
gateway-server/src/main/java/org/apache/knox/gateway/services/token/impl/AliasBasedTokenStateService.java
##########
@@ -446,13 +446,15 @@ protected void addMetadataInMemory(String tokenId, 
TokenMetadata metadata) {
   }
 
   @Override
-  public TokenMetadata getTokenMetadata(String tokenId) {
+  public TokenMetadata getTokenMetadata(String tokenId) throws 
UnknownTokenException {
     TokenMetadata tokenMetadata = super.getTokenMetadata(tokenId);

Review comment:
       UnknownTokenException should be handled. In HA case it may happen that 
the in-memory collection will not have the given token metadata -> super will 
throw UTE. We should catch it and continue with the alias service action.




-- 
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.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to