magibney commented on code in PR #2491: URL: https://github.com/apache/solr/pull/2491#discussion_r1629991095
########## solr/modules/hdfs/src/java/org/apache/solr/hdfs/update/HdfsUpdateLog.java: ########## @@ -81,31 +77,15 @@ public void init(PluginInfo info) { log.info("Initializing HdfsUpdateLog: tlogDfsReplication={}", tlogDfsReplication); } - private Configuration getConf(Path path) { - Configuration conf = new Configuration(); - if (confDir != null) { - HdfsUtil.addHdfsResources(conf, confDir); - } - - String fsScheme = path.toUri().getScheme(); - if (fsScheme != null) { - conf.setBoolean("fs." + fsScheme + ".impl.disable.cache", true); - } - return conf; - } - @Override - public void init(UpdateHandler uhandler, SolrCore core) { - - // ulogDir from CoreDescriptor overrides - String ulogDir = core.getCoreDescriptor().getUlogDir(); - - this.uhandler = uhandler; - + protected boolean initCheckRepoen(SolrCore core) { synchronized (fsLock) { // just like dataDir, we do not allow // moving the tlog dir on reload if (fs == null) { + // ulogDir from CoreDescriptor overrides + String ulogDir = core.getCoreDescriptor().getUlogDir(); Review Comment: >A rote refactor is safe no matter if the code was buggy or not; no? 💯 yeah, I wasn't suggesting it wasn't safe, and I think this PR was an improvement. 962b99f430c56f7387fbf233950fbc12946aaa70 applies the spirit of this PR to #1895, and I'm pretty happy with the results (it forced me to confront some of the duplication that had been a lingering source of confusion). -- 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...@solr.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org For additional commands, e-mail: issues-h...@solr.apache.org