This is an automated email from the ASF dual-hosted git repository.
ddanielr pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/accumulo.git
The following commit(s) were added to refs/heads/main by this push:
new de61d097e9 Fix build failure from merge
de61d097e9 is described below
commit de61d097e9b885bf3e527ddeca26b803f965f897
Author: Daniel Roberts ddanielr <[email protected]>
AuthorDate: Wed Sep 24 01:07:34 2025 +0000
Fix build failure from merge
java.nio.file.Path and org.apache.hadoop.fs.Path were conflicting.
Modernizer wanted Path.resolve to be used instead of new File
---
.../accumulo/miniclusterImpl/MiniAccumuloConfigImpl.java | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git
a/minicluster/src/main/java/org/apache/accumulo/miniclusterImpl/MiniAccumuloConfigImpl.java
b/minicluster/src/main/java/org/apache/accumulo/miniclusterImpl/MiniAccumuloConfigImpl.java
index 83163a9573..1a7a64ff4a 100644
---
a/minicluster/src/main/java/org/apache/accumulo/miniclusterImpl/MiniAccumuloConfigImpl.java
+++
b/minicluster/src/main/java/org/apache/accumulo/miniclusterImpl/MiniAccumuloConfigImpl.java
@@ -28,6 +28,7 @@ import static
org.apache.accumulo.minicluster.ServerType.ZOOKEEPER;
import java.io.File;
import java.io.IOException;
+import java.nio.file.Path;
import java.util.EnumMap;
import java.util.HashMap;
import java.util.Iterator;
@@ -52,7 +53,6 @@ import org.apache.accumulo.tserver.ScanServer;
import org.apache.accumulo.tserver.TabletServer;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.fs.FileSystem;
-import org.apache.hadoop.fs.Path;
import org.apache.zookeeper.server.ZooKeeperServerMain;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -261,11 +261,10 @@ public class MiniAccumuloConfigImpl {
Configuration buildHadoopConfiguration() {
Configuration conf = new Configuration(false);
if (hadoopConfDir != null) {
- File coreSite = new File(hadoopConfDir, "core-site.xml");
- File hdfsSite = new File(hadoopConfDir, "hdfs-site.xml");
-
- conf.addResource(new Path(coreSite.toURI()));
- conf.addResource(new Path(hdfsSite.toURI()));
+ File coreSite = hadoopConfDir.toPath().resolve("core-site.xml").toFile();
+ File hdfsSite = hadoopConfDir.toPath().resolve("hdfs-site.xml").toFile();
+ conf.addResource(new org.apache.hadoop.fs.Path(coreSite.toURI()));
+ conf.addResource(new org.apache.hadoop.fs.Path(hdfsSite.toURI()));
}
return conf;
}