Skip to content

Commit

Permalink
Fix hbase and hcatalog test dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Abacn committed Dec 6, 2024
1 parent e38715a commit 887d4fc
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 12 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{
"comment": "Modify this file in a trivial way to cause this test suite to run",
"modification": 1
"modification": 2
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{}
2 changes: 1 addition & 1 deletion sdks/java/io/hadoop-common/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def hadoopVersions = [
"2102": "2.10.2",
"324": "3.2.4",
"336": "3.3.6",
"341": "3.4.1",
// "341": "3.4.1", // tests already exercised on the default version
]

hadoopVersions.each {kv -> configurations.create("hadoopVersion$kv.key")}
Expand Down
2 changes: 1 addition & 1 deletion sdks/java/io/hadoop-file-system/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def hadoopVersions = [
"2102": "2.10.2",
"324": "3.2.4",
"336": "3.3.6",
"341": "3.4.1",
// "341": "3.4.1", // tests already exercised on the default version
]

hadoopVersions.each {kv -> configurations.create("hadoopVersion$kv.key")}
Expand Down
2 changes: 1 addition & 1 deletion sdks/java/io/hadoop-format/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def hadoopVersions = [
"2102": "2.10.2",
"324": "3.2.4",
"336": "3.3.6",
"341": "3.4.1",
// "341": "3.4.1", // tests already exercised on the default version
]

hadoopVersions.each {kv -> configurations.create("hadoopVersion$kv.key")}
Expand Down
9 changes: 2 additions & 7 deletions sdks/java/io/hbase/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ test {
jvmArgs "-Dtest.build.data.basedirectory=build/test-data"
}

def hbase_version = "2.5.5"
def hbase_version = "2.6.1-hadoop3"

dependencies {
implementation library.java.vendored_guava_32_1_2_jre
Expand All @@ -46,12 +46,7 @@ dependencies {
testImplementation project(path: ":sdks:java:core", configuration: "shadowTest")
testImplementation library.java.junit
testImplementation library.java.hamcrest
testImplementation library.java.hadoop_minicluster
testImplementation library.java.hadoop_hdfs
testImplementation library.java.hadoop_common
// shaded-testing-utils has shaded all Hadoop/HBase dependencies
testImplementation("org.apache.hbase:hbase-shaded-testing-util:$hbase_version")
testImplementation "org.apache.hbase:hbase-hadoop-compat:$hbase_version:tests"
testImplementation "org.apache.hbase:hbase-hadoop2-compat:$hbase_version:tests"
testRuntimeOnly project(path: ":runners:direct-java", configuration: "shadow")
}

10 changes: 9 additions & 1 deletion sdks/java/io/hcatalog/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def hadoopVersions = [
"2102": "2.10.2",
"324": "3.2.4",
"336": "3.3.6",
"341": "3.4.1",
// "341": "3.4.1", // tests already exercised on the default version
]

hadoopVersions.each {kv -> configurations.create("hadoopVersion$kv.key")}
Expand Down Expand Up @@ -71,13 +71,21 @@ dependencies {
testRuntimeOnly project(path: ":runners:direct-java", configuration: "shadow")
hadoopVersions.each {kv ->
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-common:$kv.value"
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-hdfs:$kv.value"
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-hdfs-client:$kv.value"
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-mapreduce-client-core:$kv.value"
}
}

hadoopVersions.each {kv ->
configurations."hadoopVersion$kv.key" {
resolutionStrategy {
force "org.apache.hadoop:hadoop-client:$kv.value"
force "org.apache.hadoop:hadoop-common:$kv.value"
force "org.apache.hadoop:hadoop-mapreduce-client-core:$kv.value"
force "org.apache.hadoop:hadoop-minicluster:$kv.value"
force "org.apache.hadoop:hadoop-hdfs:$kv.value"
force "org.apache.hadoop:hadoop-hdfs-client:$kv.value"
}
}
}
Expand Down
8 changes: 8 additions & 0 deletions sdks/java/io/iceberg/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -71,13 +71,21 @@ dependencies {
testRuntimeOnly project(path: ":runners:google-cloud-dataflow-java")
hadoopVersions.each {kv ->
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-client:$kv.value"
"hadoopVersion$kv.key" "org.apache.hadoop:hdfs:$kv.value"
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-hdfs-client:$kv.value"
"hadoopVersion$kv.key" "org.apache.hadoop:hadoop-mapreduce-client-core:$kv.value"
}
}

hadoopVersions.each {kv ->
configurations."hadoopVersion$kv.key" {
resolutionStrategy {
force "org.apache.hadoop:hadoop-client:$kv.value"
force "org.apache.hadoop:hadoop-common:$kv.value"
force "org.apache.hadoop:hadoop-mapreduce-client-core:$kv.value"
force "org.apache.hadoop:hadoop-minicluster:$kv.value"
force "org.apache.hadoop:hadoop-hdfs:$kv.value"
force "org.apache.hadoop:hadoop-hdfs-client:$kv.value"
}
}
}
Expand Down

0 comments on commit 887d4fc

Please sign in to comment.