Skip to content

Commit 1179fdc

Browse files
Merge pull request #23603: Keep Spark version in a single place only (BeamModulePlugin)
2 parents b5a0f48 + 7b6cc89 commit 1179fdc

3 files changed

Lines changed: 9 additions & 5 deletions

File tree

buildSrc/src/main/groovy/org/apache/beam/gradle/BeamModulePlugin.groovy

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -500,6 +500,10 @@ class BeamModulePlugin implements Plugin<Project> {
500500
def arrow_version = "5.0.0"
501501
def jmh_version = "1.34"
502502

503+
// Export Spark versions, so they are defined in a single place only
504+
project.ext.spark2_version = spark2_version
505+
project.ext.spark3_version = spark3_version
506+
503507
// A map of maps containing common libraries used per language. To use:
504508
// dependencies {
505509
// compile library.java.slf4j_api

runners/spark/2/build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
def basePath = '..'
2020
/* All properties required for loading the Spark build script */
2121
project.ext {
22-
// Set the version of all Spark-related dependencies here.
23-
spark_version = '2.4.8'
22+
// Spark 2 version as defined in BeamModulePlugin
23+
spark_version = spark2_version
2424
spark_scala_version = '2.11'
2525
// Copy shared sources for Spark 2 to use Spark 3 as primary version in place
2626
copySourceBase = true

runners/spark/3/build.gradle

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
def basePath = '..'
2020
/* All properties required for loading the Spark build script */
2121
project.ext {
22-
// Set the version of all Spark-related dependencies here.
23-
spark_version = '3.1.2'
22+
// Spark 3 version as defined in BeamModulePlugin
23+
spark_version = spark3_version
2424
spark_scala_version = '2.12'
2525
copySourceBase = false // disabled to use Spark 3 as primary dev version
2626
archives_base_name = 'beam-runners-spark-3'
@@ -29,7 +29,7 @@ project.ext {
2929
// Load the main build script which contains all build logic.
3030
apply from: "$basePath/spark_runner.gradle"
3131

32-
32+
// Additional supported Spark versions (used in compatibility tests)
3333
def sparkVersions = [
3434
"330": "3.3.0",
3535
"321": "3.2.1"

0 commit comments

Comments
 (0)