nrg4878 commented on code in PR #6002: URL: https://github.com/apache/hive/pull/6002#discussion_r2247937877
########## standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/ServletSecurity.java: ########## @@ -310,7 +310,18 @@ static void loginServerPrincipal(Configuration conf) throws IOException { * @throws IOException if getting password fails */ static SslContextFactory createSslContextFactory(Configuration conf) throws IOException { - final boolean useSsl = MetastoreConf.getBoolVar(conf, MetastoreConf.ConfVars.USE_SSL); + return createSslContextFactory(conf, MetastoreConf.ConfVars.USE_SSL); + } + + /** + * Creates an SSL context factory if configuration states so. + * @param conf the configuration + * @param condition the condition variable to check for SSL + * @return null if no ssl in config, an instance otherwise + * @throws IOException if getting password fails + */ + static SslContextFactory createSslContextFactory(Configuration conf, MetastoreConf.ConfVars condition) throws IOException { Review Comment: nit: the method name suggest that this method creates a SSL Context Factory. But it is conditional based on whether or not a config is enabled. If you do not have a better name, its fine as well. -- 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