Questions tagged [java-14]

Reference Implementation of version 14 of the Java SE Platform, as specified by JSR 389 in the Java Community Process. Use this tag for questions specific to Java 14, which is version 14 of the Java platform, released on 17 March 2020. In most cases you should also specify the java tag.

Version 14 of the Java programming language.

The reference implementation of Java 14 reached General Availability on 17 March 2020.

The JDK/14 production-ready binaries for Linux and Windows.

New features and improvements:

  • Pattern Matching for instanceof (Preview)
  • Packaging Tool (Incubator)
  • NUMA-Aware Memory Allocation for G1
  • JFR Event Streaming
  • Non-Volatile Mapped Byte Buffers
  • Helpful NullPointerExceptions
  • Records (Preview)
  • Switch Expressions (Standard)
  • Deprecate the Solaris and SPARC Ports
  • Remove the Concurrent Mark Sweep (CMS) Garbage Collector
  • ZGC on macOS
  • ZGC on Windows
  • Deprecate the ParallelScavenge + SerialOld GC Combination
  • Remove the Pack200 Tools and API
  • Text Blocks (Second Preview)
  • Foreign-Memory Access API (Incubator)

Specified by JSR 389 in the Java Community Process.

192 questions
7
votes
1 answer

JPMS: --add-opens doesn't work for java.lang.reflect.InaccessibleObjectException

I use Java 14 with Jetty 9.4 and Weld-servlet-shaded-3.1 and I get this exception: Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make protected final java.lang.Class …
Pavel_K
  • 10,748
  • 13
  • 73
  • 186
7
votes
2 answers

No default constructor found with Java record and BeanPropertyRowMapper

I am playing with the new Java 14 and Spring Boot. I have used the new cool record instead of a regular Java class for data holders. public record City(Long id, String name, Integer population) {} Later in my service class, I use Spring…
Jan Bodnar
  • 10,969
  • 6
  • 68
  • 77
6
votes
3 answers

Maven surefire plugin problems with Jacoco, JMockit and JDK14

I tried to upgrade my project from JDK 11 to JDK 14, but running the tests failed after setting the java version to 14. As I am using jacoco in combination with JMockit I configured my build as follows (edit: JaCoCo version is 0.8.3 / 0.8.5, JMockit…
Frank Murmann
  • 71
  • 1
  • 2
  • 5
6
votes
1 answer

AWS SDK 2 assume role

@Bean public DynamoDbClient amazonDynamoDB() { final AssumeRoleRequest assumeRoleRequest = AssumeRoleRequest.builder().roleSessionName(UUID.randomUUID().toString()).roleArn("roleArn").build(); final StsAssumeRoleCredentialsProvider …
6
votes
1 answer

Using JPackage how do I create the installer icon on Windows

I am using JPackage to install my Java application on Windows, I have my own application icon and I would also like this to also be used when I run the installer. I have followed the general approach described here to run jpackage twice, once…
Paul Taylor
  • 13,411
  • 42
  • 184
  • 351
6
votes
2 answers

Cannot rerun Java JPackage installer if already installed, second time just exits without warning

Cannot rerun JPackage installer if already installed, second time just seems to exit without warning, is this correct behaviour on Windows ? You may ask why I want to do this anyway? Well in my case I am trying to build a JPackage installer for my…
Paul Taylor
  • 13,411
  • 42
  • 184
  • 351
6
votes
1 answer

No enum constant org.gradle.api.JavaVersion.VERSION_14

Using Intellij IDEA, I created a new Gradle project using Gradle 6.4 and Java 14, but when I try to build the project, I'm getting this error : No enum constant org.gradle.api.JavaVersion.VERSION_14 What do I do ? Edit 1 : I'm using the latest…
Ayfri
  • 570
  • 1
  • 4
  • 24
6
votes
1 answer

gradle with openjdk 14 Unsupported class file major version 58

I am trying to run a gradle 6.3 build using openjdk 14, targeting java 14. I get the following error. I understand it's something related to the version of the compilation file but my understanding is that gradle 6.3 supports java 14. $ ./gradlew…
tzortzik
  • 4,993
  • 9
  • 57
  • 88
6
votes
1 answer

Configure IntelliJ to work with Java 14 and records

I have tried to make IntelliJ work with SDK-14, but I am obviously having problems getting records to work. Since the release date is in March, I would think that the good people at Jetbrains are close to having a version that works with SDK-14. I…
thomas77
  • 1,100
  • 13
  • 27
5
votes
1 answer

Set mssql-jdbc_auth with Maven

Hi i have following Problem with mssql-jdbc_auth-.dll if i manually add it to my path it works but since i use mave this is not the way in wanna go :(. i put following lines to my pom.xml