Hi,
I see https://issues.apache.org/jira/browse/FLINK-21672 has been open for a 
while. We at IBM are building Flink with the latest v11  Semeru JDK 
(https://developer.ibm.com/languages/java/semeru-runtimes/).
Flink fails to build with skipTests. It fails because 
sun.management.VMManagement class
Cannot be found at build time. I see some logic in the Flink code to tolerate 
the lack of com.sun packages, but not this sun package. We get:


ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-compiler-plugin:3.8.0:compile (default-compile) 
on project flink-local-recovery-and-allocation-test: Compilation failure: 
Compilation failure:

[ERROR] 
/Users/davidradley/flinkapicurio/flink-end-to-end-tests/flink-local-recovery-and-allocation-test/src/main/java/org/apache/flink/streaming/tests/StickyAllocationAndLocalRecoveryTestJob.java:[418,23]
 cannot find symbol

[ERROR]   symbol:   class VMManagement

[ERROR]   location: package sun.management

[ERROR] 
/Users/davidradley/flinkapicurio/flink-end-to-end-tests/flink-local-recovery-and-allocation-test/src/main/java/org/apache/flink/streaming/tests/StickyAllocationAndLocalRecoveryTestJob.java:[418,59]
 cannot find symbol

[ERROR]   symbol:   class VMManagement

[ERROR]   location: package sun.management


As per the link in the issue, sun. packages are not supported or part of the 
JDK after java 1.7.

I would like to have the priority raised on this Jira and would like to change 
the code so it builds successfully by  removing the dependency on this old / 
unsupported sun package . I am happy to work on this, if you are willing to 
support this by assigning me the Jira and merging the fix; ideally we would 
like this to be in the next release - Flink 1.19,
     Kind regards, David.

Unless otherwise stated above:

IBM United Kingdom Limited
Registered in England and Wales with number 741598
Registered office: PO Box 41, North Harbour, Portsmouth, Hants. PO6 3AU

Reply via email to