Skip to content

Commit 807a963

Browse files
spark: replace bundled hadoop-client 3.4.1 jars with HADOOP_VERSION so aws bundle methods resolve
1 parent bd5dd46 commit 807a963

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

dev/spark/Dockerfile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,17 @@ RUN apt-get update -qq && \
4343
# fixed-master-key KMS used by the encryption integration test on the Spark write path.
4444
RUN set -e && \
4545
cd "${SPARK_HOME}/jars" && \
46+
# Spark 4.0.1 ships hadoop-client-{api,runtime} 3.4.1; replace them with HADOOP_VERSION so
47+
# hadoop-aws methods like ConfigurationHelper.resolveEnum / S3ABlockOutputStream.builder()
48+
# that iceberg-aws-bundle 1.11.0 expects are present at runtime.
49+
rm -f hadoop-client-api-*.jar hadoop-client-runtime-*.jar && \
4650
for jar_path in \
4751
"org/apache/iceberg/iceberg-spark-runtime-${ICEBERG_SPARK_RUNTIME_VERSION}/${ICEBERG_VERSION}/iceberg-spark-runtime-${ICEBERG_SPARK_RUNTIME_VERSION}-${ICEBERG_VERSION}.jar" \
4852
"org/apache/iceberg/iceberg-aws-bundle/${ICEBERG_VERSION}/iceberg-aws-bundle-${ICEBERG_VERSION}.jar" \
4953
"org/apache/iceberg/iceberg-core/${ICEBERG_VERSION}/iceberg-core-${ICEBERG_VERSION}-tests.jar" \
5054
"org/apache/hadoop/hadoop-aws/${HADOOP_VERSION}/hadoop-aws-${HADOOP_VERSION}.jar" \
55+
"org/apache/hadoop/hadoop-client-api/${HADOOP_VERSION}/hadoop-client-api-${HADOOP_VERSION}.jar" \
56+
"org/apache/hadoop/hadoop-client-runtime/${HADOOP_VERSION}/hadoop-client-runtime-${HADOOP_VERSION}.jar" \
5157
"software/amazon/awssdk/bundle/${AWS_SDK_VERSION}/bundle-${AWS_SDK_VERSION}.jar"; \
5258
do \
5359
jar_name=$(basename "${jar_path}") && \

0 commit comments

Comments
 (0)