gemmellr commented on code in PR #5477: URL: https://github.com/apache/activemq-artemis/pull/5477#discussion_r1934322842
########## artemis-server/src/main/java/org/apache/activemq/artemis/spi/core/security/jaas/JaasCallbackHandler.java: ########## @@ -77,8 +76,8 @@ public void handle(Callback[] callbacks) throws IOException, UnsupportedCallback if (peerPrincipalFromConnection != null) { principalsCallback.setPeerPrincipals(new Principal[] {peerPrincipalFromConnection}); } - } else if (callback instanceof ClientIDCallback) { - ((ClientIDCallback) callback).setClientID(remotingConnection.getClientID()); + } else if (callback instanceof ClientIDCallback dCallback) { + dCallback.setClientID(remotingConnection.getClientID()); Review Comment: ```suggestion } else if (callback instanceof ClientIDCallback clientIDCallback) { clientIDCallback.setClientID(remotingConnection.getClientID()); ``` -- 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...@activemq.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@activemq.apache.org For additional commands, e-mail: gitbox-h...@activemq.apache.org For further information, visit: https://activemq.apache.org/contact