Skip to content

Commit db55594

Browse files
authored
reconfigure build: target jdk -release=8 (#368)
* -release 8 for both javac and scalac * build with jdk19 * document in readme
1 parent 9549a87 commit db55594

File tree

4 files changed

+15
-14
lines changed

4 files changed

+15
-14
lines changed

.github/workflows/pr.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ jobs:
77
- uses: actions/checkout@v2
88
with:
99
fetch-depth: 1
10-
- name: Set up JDK 11
11-
uses: actions/setup-java@v2
10+
- name: Set up JDK
11+
uses: actions/setup-java@v3
1212
with:
1313
distribution: 'temurin'
14-
java-version: 11
14+
java-version: 19
1515
- uses: actions/cache@v2
1616
with:
1717
path: |

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ jobs:
1919
run: echo $PGP_SECRET | base64 --decode | gpg --batch --import
2020
env:
2121
PGP_SECRET: ${{ secrets.PGP_SECRET }}
22-
- name: Set up JDK 11
23-
uses: actions/setup-java@v2
22+
- name: Set up JDK
23+
uses: actions/setup-java@v3
2424
with:
2525
distribution: 'temurin'
26-
java-version: 11
26+
java-version: 19
2727
- uses: actions/cache@v2
2828
with:
2929
path: |

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,6 +144,10 @@ never hold a (strong) reference onto them in your main application: it would inh
144144
`overflowdb.util.DiffTool.compare(graph1, graph2)` allows you to do some very basic comparison of two graphs. It identifies nodes by their ids, and compares their existence, properties, adjacent edges and properties of those edges.
145145

146146
### FAQ
147+
1. **What JDK does OverflowDB support?**
148+
The build targets JDK8, so that's the minimum version. However it is highly encouraged to use a modern JVM, such as JDK20.
149+
The build itself requires JDK11+ though.
150+
147151
1. **Why not just use a simple cache instead of the overflow mechanism?**
148152
Regular caches require you have to specify a fixed size. OverflowDB is designed to run in the same JVM as your main application, and since
149153
most applications have varying memory needs over time, it would be hard/impossible to achieve our goal *use your entire heap and prevent OutOfMemoryError*

build.sbt

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,15 @@ ThisBuild/libraryDependencies ++= Seq(
1818
"org.scalatest" %% "scalatest" % "3.2.15" % Test,
1919
)
2020

21-
ThisBuild/scalacOptions ++= Seq("-deprecation", "-feature") ++ (
22-
CrossVersion.partialVersion(scalaVersion.value) match {
23-
case Some((3, _)) =>
24-
Seq("-Xtarget:8")
25-
case _ =>
26-
Seq("-target:jvm-1.8", "--release", "8")
27-
}
21+
ThisBuild/scalacOptions ++= Seq(
22+
"-release", "8",
23+
"-deprecation",
24+
"-feature"
2825
)
2926

3027
ThisBuild / compile / javacOptions ++= Seq(
3128
"-g", //debug symbols
32-
"--release=8"
29+
"--release", "8"
3330
)
3431

3532
ThisBuild/Test/testOptions += Tests.Argument(TestFrameworks.JUnit, "-a", "-v")

0 commit comments

Comments
 (0)