jenkinsci / gradle-jpi-plugin

Build Jenkins Plugins with Gradle
79 stars 50 forks source link

Thoughts on Toolchains for Access Modifier #231

Closed sghill closed 8 months ago

sghill commented 9 months ago

Given this plugin is not officially supported, we already run builds internally on Java 17, and maven-hpi-plugin requires running with Java 11, I'm currently leaning toward starting to depend on newer libraries and making Java 11 required. If anyone is watching this repository and has input, please feel free to comment. I plan on making a decision in the next week or so.

Background

Recent Jenkins tooling, like lib-access-modifier, require Java 11 or newer.

One simple way to support this is to upgrade and require all builds run Gradle with Java 11 or newer.

Another option is using Gradle Toolchains. Practically this allows us to declare a minimum of Java 11 for the tasks that run these tools, but still allow Gradle itself to run with Java 8.

Cons of this approach are: