Skip to content

Commit

Permalink
chore: Drop JDK 8 (#771)
Browse files Browse the repository at this point in the history
  • Loading branch information
patriknw authored Oct 9, 2023
1 parent 41e4718 commit cf0418e
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 6 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/h2-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,9 @@ jobs:
matrix:
include:
# leaving out some combinations (note that `checks.yml` doesn't run H2 test)
- { scalaVersion: "2.13", jdkVersion: "1.8.0", jvmName: "temurin:1.8.0", extraOpts: '' }
# { scalaVersion: "2.13", jdkVersion: "1.11.0", jvmName: "temurin:1.11.0", extraOpts: '-J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler' }
- { scalaVersion: "2.13", jdkVersion: "1.17.0", jvmName: "temurin:1.17.0", extraOpts: '' }

# { scalaVersion: "3.1", jdkVersion: "1.8.0", jvmName: "temurin:1.8.0", extraOpts: '' }
# { scalaVersion: "3.1", jdkVersion: "1.11.0", jvmName: "temurin:1.11.0", extraOpts: '-J-XX:+UnlockExperimentalVMOptions -J-XX:+UseJVMCICompiler' }
# { scalaVersion: "3.1", jdkVersion: "1.17.0", jvmName: "temurin:1.17.0", extraOpts: '' }
steps:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ jobs:
- name: Cache Coursier cache
uses: coursier/[email protected]

- name: Set up JDK 8
- name: Set up JDK 11
uses: coursier/[email protected]
with:
jvm: temurin:1.8.0-352
jvm: temurin:1.11.0.17

- name: Publish artifacts for all Scala versions
env:
Expand Down
7 changes: 7 additions & 0 deletions build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -94,3 +94,10 @@ TaskKey[Unit]("verifyCodeFmt") := {
}

addCommandAlias("verifyCodeStyle", "headerCheck; verifyCodeFmt")

val isJdk11orHigher: Boolean = {
val result = VersionNumber(sys.props("java.specification.version")).matchesSemVer(SemanticSelector(">=11"))
if (!result)
throw new IllegalArgumentException("JDK 11 or higher is required")
result
}
4 changes: 3 additions & 1 deletion project/ProjectAutoPlugin.scala
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,16 @@ object ProjectAutoPlugin extends AutoPlugin {
Test / fork := false,
Test / parallelExecution := false,
Test / logBuffered := true,
javacOptions ++= Seq("--release", "11"),
scalacOptions ++= Seq(
"-encoding",
"UTF-8",
"-unchecked",
"-Xlog-reflective-calls",
"-language:higherKinds",
"-language:implicitConversions",
"-target:jvm-1.8"),
"-release",
"11"),
Compile / scalacOptions ++= (CrossVersion.partialVersion(scalaVersion.value) match {
case Some((2, 13)) =>
disciplineScalacOptions -- Set(
Expand Down
2 changes: 1 addition & 1 deletion project/project-info.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ project-info {
version: "current"
scaladoc: "https://doc.akka.io/api/akka-persistence-jdbc/"${project-info.version}"/akka/persistence/jdbc/"
shared-info {
jdk-versions: ["Adopt OpenJDK 8", "Adopt OpenJDK 11"]
jdk-versions: ["Eclipse Temurin JDK 11", "Eclipse Temurin JDK 17"]
snapshots: {
url: "snapshots.html"
text: "Snapshots are available"
Expand Down

0 comments on commit cf0418e

Please sign in to comment.