[
https://issues.apache.org/jira/browse/FLINK-24634?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot updated FLINK-24634:
-----------------------------------
Labels: pull-request-available (was: )
> Java 11 profile should target JDK 8
> -----------------------------------
>
> Key: FLINK-24634
> URL: https://issues.apache.org/jira/browse/FLINK-24634
> Project: Flink
> Issue Type: Technical Debt
> Components: Build System
> Reporter: Chesnay Schepler
> Assignee: Chesnay Schepler
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.15.0
>
>
> Thee {{java11}} profile currently targets Java 11. This was useful because we
> saw that doing so reveals additional issues that are not detected when
> building for Java 8. The end goal was to ensure a smooth transition once we
> switch.
> However, this has adverse effects on developer productivity.
> If you happen to switch between Java versions (for example, because of
> separate environments, or because certain features require Java 8), then you
> can easily run into UnsupportedVersionErrors when attempting to use Java 8
> with Java 11 bytecode.
> IntelliJ also picks up on this and automatically sets the language level to
> 11, which means that it will readily allow you to use Java 11 exclusive APIs
> that will fail on CI later on.
> To remedy this I propose to split the profile.
> The {{java11}} profile will pretty much stay as is, except that it is
> targeting java 8. The value proposition of this profile is being able to
> build Flink for Java 8 with Java 11.
> A new explicitly-opt-in {{java11-target}} profile then sets the target
> version to Java 11, which we will use on CI. This profile will ensure that we
> can readily switch to Java 11 as the target in the future.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)