SteNicholas commented on code in PR #3455: URL: https://github.com/apache/celeborn/pull/3455#discussion_r2329259447
########## common/src/main/java/org/apache/celeborn/common/network/sasl/SecretRegistry.java: ########## @@ -28,4 +30,12 @@ public interface SecretRegistry { void register(String appId, String secret); void unregister(String appId); + + /** + * Checks if the SecretRegistry can register the application. If it cant register (for example, + * not the current leader when running in HA), then throws an exception + */ + default void ensureRegistrationAllowed() throws IOException { Review Comment: Why does not this method return boolean value to represent whether the SecretRegistry can register the application? IMO, returning boolean value is better than throwing exception for implementation of `SecretRegistry`. -- 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: issues-unsubscr...@celeborn.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org