Skip to content

Commit 45583b6

Browse files
authored
Merge pull request #216 from cicirello/java-17
Migration to Java 17
2 parents 8d7f8ac + e6fe4d3 commit 45583b6

File tree

10 files changed

+44
-32
lines changed

10 files changed

+44
-32
lines changed

.github/workflows/build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ jobs:
2323
ref: badges
2424
path: badges
2525

26-
- name: Set up JDK 11
26+
- name: Set up JDK 17
2727
uses: actions/setup-java@v3
2828
with:
2929
distribution: 'adopt'
30-
java-version: '11'
30+
java-version: '17'
3131

3232
- name: Build with Maven
3333
run: mvn -B package -Pcoverage

.github/workflows/codeql-analysis.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,12 @@ jobs:
3737
- name: Checkout repository
3838
uses: actions/checkout@v3
3939

40+
- name: Set up JDK 17
41+
uses: actions/setup-java@v3
42+
with:
43+
distribution: 'adopt'
44+
java-version: '17'
45+
4046
# Initializes the CodeQL tools for scanning.
4147
- name: Initialize CodeQL
4248
uses: github/codeql-action/init@v2

.github/workflows/docs.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,11 @@ jobs:
2525
ref: gh-pages
2626
path: gh-pages
2727

28-
- name: Set up JDK 11
28+
- name: Set up JDK 17
2929
uses: actions/setup-java@v3
3030
with:
3131
distribution: 'adopt'
32-
java-version: '11'
32+
java-version: '17'
3333

3434
- name: Build docs with Maven
3535
run: mvn compile javadoc:javadoc

.github/workflows/manual-deploy-github-only.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,11 @@ jobs:
1818
steps:
1919
- uses: actions/checkout@v3
2020

21-
- name: Set up JDK 11 for deploy to github packages
21+
- name: Set up JDK 17 for deploy to github packages
2222
uses: actions/setup-java@v3
2323
with:
2424
distribution: 'adopt'
25-
java-version: '11'
25+
java-version: '17'
2626
server-id: github
2727

2828
- name: Build with Maven

.github/workflows/manual-deploy.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,11 @@ jobs:
1717

1818
steps:
1919
- uses: actions/checkout@v3
20-
- name: Set up JDK 11
20+
- name: Set up JDK 17
2121
uses: actions/setup-java@v3
2222
with:
2323
distribution: 'adopt'
24-
java-version: '11'
24+
java-version: '17'
2525
server-id: github
2626

2727
- name: Build with Maven

.github/workflows/maven-publish.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ jobs:
1919
id: get_version
2020
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\/v/}
2121

22-
- name: Set up JDK 11 for deploy to OSSRH
22+
- name: Set up JDK 17 for deploy to OSSRH
2323
uses: actions/setup-java@v3
2424
with:
2525
distribution: 'adopt'
26-
java-version: '11'
26+
java-version: '17'
2727
server-id: ossrh
2828
server-username: MAVEN_USERNAME
2929
server-password: MAVEN_CENTRAL_TOKEN
@@ -43,11 +43,11 @@ jobs:
4343
MAVEN_CENTRAL_TOKEN: ${{ secrets.MAVEN_CENTRAL_TOKEN }}
4444
MAVEN_GPG_PASSPHRASE: ${{ secrets.MAVEN_GPG_PASSPHRASE }}
4545

46-
- name: Set up JDK 11 for deploy to github packages
46+
- name: Set up JDK 17 for deploy to github packages
4747
uses: actions/setup-java@v3
4848
with:
4949
distribution: 'adopt'
50-
java-version: '11'
50+
java-version: '17'
5151
server-id: github
5252

5353
- name: Publish to GitHub Packages Apache Maven

.lift.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
jdkVersion = "11"
1+
jdkVersion = "17"
22

33
# don't run eslint... it is for js and will detect false positives
44
# in javadoc directories.

CHANGELOG.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,15 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7-
## [Unreleased] - 2022-06-01
7+
## [Unreleased] - 2022-06-02
8+
9+
**BREAKING CHANGES:** The next release is a major release that includes breaking changes. See
10+
details below.
811

912
### Added
1013

1114
### Changed
15+
* Minimum supported Java version is now Java 17 (breaking change).
1216

1317
### Deprecated
1418

README.md

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -32,13 +32,19 @@ computation on permutations and sequences. It includes implementations of a vari
3232
of permutation distance metrics as well as distance metrics on sequences (i.e., Strings,
3333
arrays, and other ordered data types).
3434

35-
## Java 11+
35+
## Java 17+
3636

37-
Beginning with version 3.0.0, the library supports Java 11+. Our development process
38-
utilizes OpenJDK 11, and all jar files released via Maven Central, GitHub Packages,
39-
and GitHub Releases are built with a Java 11 target.
37+
We currently support Java 17+. See the following table for mapping between library version
38+
and minimum supported Java version.
4039

41-
Versions prior to 3.0.0 previously required Java 8+.
40+
| version | Java requirements |
41+
| --- | --- |
42+
| 4.x.y | Java 17+ |
43+
| 3.x.y | Java 11+ |
44+
| 1.x.y to 2.x.y | Java 8+ |
45+
46+
The jar files of the library are released via Maven Central, GitHub Packages,
47+
and GitHub Releases.
4248

4349
## Versioning Scheme
4450

@@ -86,7 +92,7 @@ module your.module.name.here {
8692

8793
This module includes the `org.cicirello.permutations` and `org.cicirello.sequences`
8894
packages as well as their subpackages. See the [API documentation](https://jpt.cicirello.org/api)
89-
for details.
95+
for details of all packages included in this module.
9096

9197
Beginning with version 3.0.0, randomization and other math utilities, and some
9298
generic utilities, have been
@@ -95,12 +101,8 @@ and [org.cicirello.core](https://github.com/cicirello/core), which are
95101
now dependencies of JavaPermutationTools. Your dependency manager (see next section)
96102
will handle downloading these for you.
97103

98-
To ease the transition of users of the library who may have been relying on those
99-
utilities, we have configured the `module-info.java` for the `org.cicirello.jpt` module to
100-
require these transitively so that your application should only need to
101-
require `org.cicirello.jpt` to access the functionality of those new modules.
102-
However, it is possible that you __may__ actually need the following to access
103-
some of that functionality, such as the RandomIndexer class, or other math or utility classes:
104+
If you are directly utilizing the functionality of the dependencies, then you may instead
105+
need the following:
104106

105107
```Java
106108
module your.module.name.here {
@@ -119,7 +121,7 @@ with the version you want to use.
119121
<dependency>
120122
<groupId>org.cicirello</groupId>
121123
<artifactId>jpt</artifactId>
122-
<version>3.0.0</version>
124+
<version>4.0.0</version>
123125
</dependency>
124126
```
125127

@@ -146,9 +148,9 @@ or if you simply prefer to download manually, prebuilt jars are also attached to
146148
each [GitHub Release](https://github.com/cicirello/JavaPermutationTools).
147149

148150
In addition to the regular jar of the library, we also regularly publish a
149-
`jar-with-dependencies`. The `jar-with-dependencies` is built for a Java 11 target,
150-
but does not contain any module declarations (unlike the regular jar file which does).
151-
Therefore, the `jar-with-dependencies` should be used on the classpath.
151+
`jar-with-dependencies`. The `jar-with-dependencies` does not contain any module
152+
declarations (unlike the regular jar file which does). Therefore, the
153+
`jar-with-dependencies` should be used on the classpath.
152154

153155
## License
154156

pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
<groupId>org.cicirello</groupId>
88
<artifactId>jpt</artifactId>
9-
<version>3.0.0</version>
9+
<version>4.0.0</version>
1010
<packaging>jar</packaging>
1111

1212
<name>JavaPermutationTools</name>
@@ -184,7 +184,7 @@
184184

185185
<properties>
186186
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
187-
<maven.compiler.release>11</maven.compiler.release>
187+
<maven.compiler.release>17</maven.compiler.release>
188188
</properties>
189189

190190
<build>

0 commit comments

Comments
 (0)