vrozov commented on code in PR #52978:
URL: https://github.com/apache/spark/pull/52978#discussion_r2550922623


##########
project/SparkBuild.scala:
##########
@@ -1928,3 +1928,100 @@ object TestSettings {
   )
 
 }
+
+object DependencyVersions {
+  import java.util.Properties
+
+  private lazy val properties = settingKey[Properties]("Effective POM 
properties")
+  lazy val jacksonVersion = settingKey[String]("Jackson version")
+  lazy val jacksonModuleID = settingKey[ModuleID]("Jackson Module ID")
+  lazy val settings = Seq(
+    properties := SbtPomKeys.effectivePom.value.getProperties,
+    jacksonVersion := getVersion(properties.value, "fasterxml.jackson"),
+    jacksonModuleID := ModuleID("com.fasterxml.jackson", "jackson-bom", 
jacksonVersion.value),
+  )
+
+  private def getVersionFromPom(properties: Properties, property: String) : 
String = {
+    properties.get(property).asInstanceOf[String]
+  }
+
+  private def getVersion(properties: Properties, property: String) : String = {
+    val version = property + ".version"
+    sys.props.get(version).getOrElse(getVersionFromPom(properties, version))
+  }
+}
+
+// SparkBom can be removed once 
https://github.com/heremaps/here-sbt-bom/pull/47 is merged

Review Comment:
   @pan3793 I don't see any progress with 
https://github.com/heremaps/here-sbt-bom/pull/47. How do you want to proceed?



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to