Skip to content

Commit

Permalink
Support Java 17 compilation
Browse files Browse the repository at this point in the history
  • Loading branch information
yogyagamage committed Jul 12, 2022
1 parent ccfc8f0 commit 2b11b48
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 3 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/pr-builder.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# This workflow will build the project on pull requests with tests
# Uses:
# OS: ubuntu-latest
# JDK: Adopt JDK 8
# JDK: Adopt JDK 11 and Adopt JDK 17

name: PR Builder

Expand All @@ -17,12 +17,16 @@ jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
java-version: [ 11, 17 ]

steps:
- uses: actions/checkout@v2
- name: Set up Adopt JDK 8
- name: Set up Adopt JDK 11 and 17
uses: actions/setup-java@v2
with:
java-version: "8"
java-version: ${{ matrix.java-version }}
distribution: "adopt"
- name: Cache local Maven repository
id: cache-maven-m2
Expand Down
21 changes: 21 additions & 0 deletions findbugs-exclude-filter.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,25 @@
<Match>
<Bug pattern="JAXRS_ENDPOINT" />
</Match>
<!--
The following exclusions are added as in java 11 and java 17,
findbugs shows the bug of unused fields, but the unused fields
cannot be removed as they are used inside unused but public classes.
-->
<Match>
<Class name="org.wso2.carbon.identity.rest.api.user.challenge.v1.ApiException" />
<Bug pattern="URF_UNREAD_FIELD"/>
</Match>
<Match>
<Class name="org.wso2.carbon.identity.rest.api.user.authorized.apps.v1.ApiException" />
<Bug pattern="URF_UNREAD_FIELD"/>
</Match>
<Match>
<Class name="org.wso2.carbon.identity.rest.api.user.session.v1.ApiException" />
<Bug pattern="URF_UNREAD_FIELD"/>
</Match>
<Match>
<Class name="org.wso2.carbon.identity.rest.api.user.recovery.v1.impl.core.exceptions.InternalServerErrorException" />
<Bug pattern="UUF_UNUSED_FIELD"/>
</Match>
</FindBugsFilter>
6 changes: 6 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,11 @@
<artifactId>commons-lang</artifactId>
<version>${commons-lang.wso2.version}</version>
</dependency>
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>${lombok.version}</version>
</dependency>

<!-- Kernel Dependencies-->
<dependency>
Expand Down Expand Up @@ -366,6 +371,7 @@
<fido2.version>5.1.17</fido2.version>
<identity.totp.version>2.1.4</identity.totp.version>
<identity.backup.code.version>0.0.4</identity.backup.code.version>
<lombok.version>1.18.20</lombok.version>
<maven.checkstyleplugin.excludes>**/gen/**/*</maven.checkstyleplugin.excludes>
<commons-lang.wso2.version>2.6.0.wso2v1</commons-lang.wso2.version>
<mavan.findbugsplugin.exclude.file>findbugs-exclude-filter.xml</mavan.findbugsplugin.exclude.file>
Expand Down

0 comments on commit 2b11b48

Please sign in to comment.