Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,8 @@ class HiveExternalCatalogVersionsSuite extends SparkSubmitTestUtils {
case _: Exception => None
}
}
val sites = mirrors.distinct :+ "https://archive.apache.org/dist"
val sites =
mirrors.distinct :+ "https://archive.apache.org/dist" :+ PROCESS_TABLES.releaseMirror
logInfo(s"Trying to download Spark $version from $sites")
for (site <- sites) {
val filename = s"spark-$version-bin-hadoop2.7.tgz"
Expand Down Expand Up @@ -210,11 +211,12 @@ class HiveExternalCatalogVersionsSuite extends SparkSubmitTestUtils {
}

object PROCESS_TABLES extends QueryTest with SQLTestUtils {
val releaseMirror = "https://dist.apache.org/repos/dist/release"
// Tests the latest version of every release line.
val testingVersions: Seq[String] = {
import scala.io.Source
try {
Source.fromURL("https://dist.apache.org/repos/dist/release/spark/").mkString
Source.fromURL(s"${releaseMirror}/spark").mkString
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe $releaseMirror is better.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we're picking nits and you change it again, it's not really a mirror. It's the primary dist server. asfDist or something.

.split("\n")
.filter(_.contains("""<li><a href="spark-"""))
.map("""<a href="spark-(\d.\d.\d)/">""".r.findFirstMatchIn(_).get.group(1))
Expand Down