chinnaraolalam commented on code in PR #5303: URL: https://github.com/apache/hive/pull/5303#discussion_r1670275889
########## itests/hive-unit-hadoop2/src/test/java/org/apache/hadoop/hive/metastore/security/TestHadoopAuthBridge23.java: ########## @@ -204,13 +204,22 @@ public void testDelegationTokenSharedStore() throws Exception { // expected } - // token expiration + // token Renewal MyTokenStore.TOKEN_STORE.addToken(d, new DelegationTokenInformation(0, t.getPassword())); Assert.assertNotNull(MyTokenStore.TOKEN_STORE.getToken(d)); anotherManager.removeExpiredTokens(); + Assert.assertTrue(MyTokenStore.TOKEN_STORE.getToken(d).getRenewDate() > 0); Review Comment: Its not about accessing maxtime, if maxtime is zero above statement "removeExpiredTokens()" will remove this token. After token removed calling getRenewDate() will throw NPE -- 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: gitbox-unsubscr...@hive.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For additional commands, e-mail: gitbox-h...@hive.apache.org