Questions tagged [java-9]

Use this tag for questions specific to Java 9, which is version 9 of the Java platform, released on the 21st of September 2017. In most cases you should also specify the java tag.

Oracle has released its updated list of proposed or targeted Java 9 enhancements. In addition to previously confirmed Java modularity updates, the most recent list includes a common logging system for all JVM components (JEP 158), more HotSpot JIT compiler controls (JEP 158), and refinements to improve the efficiency of garbage collection (JEP 214), and repair issues introduced by Project Coin language updates in JDK 7 (JEP 213). This is also the first release under the new version-string schema (JEP 223) and will hence be officially be numbered 9, not "1.9.0" as was the case for earlier versions.

Even with delays, Oracle has been steadily moving forward with its plans to modularize the JDK. But the scope of Java modularity took a step up in September, when Oracle announced four new JEPs, including JEP 220: Modular Run-Time Images. Ben Evans, writing for InfoQ, noted that swapping JARs for modules is the "point of no return for modularity," with serious implications for IDEs, toolmakers, and many Java application frameworks:

After this point, The Java Runtime Environment (JRE) will no longer be contained in jar files, and instead will be composed of modules (JSR 376). Files such as rt.jar and tools.jar no longer exist in the JRE. The platform will continue to accept and run applications and libraries packaged in conventional jar files, modular jar files, or in the new module file format. The intention is that over time, application developers wil migrate to the new modular formats as well.

See "Oracle Commit to Java Modularity" for more from Ben Evans on modularity updates in Java 9. Also see Takipi Blog: "Java 9 – The Ultimate Feature List" for a comprehensive (as of November 20, 2014) description of new features accepted or proposed for the next major release of Java, and "What's New in Java 9? (Besides Modules)" for another more recent compilation of features.

The API documentation of the release can be accessed at Oracle's technetwork.

1606 questions
0
votes
1 answer

Not able to start spring boot application using jshell

I am trying to start a spring boot jar executable for my project from jshell but it throws an exception and does not start. Commands that I am running: ./jshell --class-path myapp-0.0.1-SNAPSHOT.jar Once jshell starts I…
hithacker
  • 151
  • 7
0
votes
0 answers

How to migrate JavaFX app from JDK 1.8 to JDK 10

I have a legacy JavaFX app which compiles and runs correctly on JDK 1.8. To move to JDK 10 I've added these to the pom.xml: javax.xml.bind jaxb-api
Dean Schulze
  • 9,633
  • 24
  • 100
  • 165
0
votes
0 answers

JApplet via Java Web Start 9 and 10 seems to take width as height setting

I am porting a Java Web Start application, which worked fine under Oracle JDK Java 7 and 8, to Java 9 and 10. What remains to be solved is a layout bug: The application is a former Java applet which is running as JApplet, using the
mvw
  • 5,075
  • 1
  • 28
  • 34
0
votes
3 answers

Is there a way to convert Array into a Map?

I have an array which I want to convert to Map such that the first element in the array is key and second element is value and so on. I am trying something like below: Arrays.asList("Tamilnadu", "chennai", "Karnataka", "Bengluru") …
Vinay Prajapati
  • 7,199
  • 9
  • 45
  • 86
0
votes
1 answer

Felix: unable to add extension bundle on JDK 9

Upon migration to JDK 9+, our OSGi container built around apache Felix started to fail installing an extension bundle. The error message is: Caused by: org.osgi.framework.BundleException: Could not create bundle object. at…
gjoranv
  • 4,376
  • 3
  • 21
  • 37
0
votes
0 answers

build openjdk9 on macos and crash

I encountered these problems when I building openjdk9. os: macos high sierra(10.13.5) xcode: 9.4 freetype: 2.9.1 I encountered these problems when I building openjdk9 Building target 'default (exploded-image)' in configuration 'macosx- …
0
votes
1 answer

Intelij scala project does not support swing

I am unable to use swing library with my scala-sdk-2.12.4. I am using Java 9 version. When I try to run the program: package rs.ac.bg.etf.zd173013m.gui import swing._ object HelloWorld extends SimpleSwingApplication { def top = new MainFrame { …
0
votes
3 answers

No Java virtual machine was found after searching the following locations:

A Java Run Time Environment(JRE) or Java development Kit (JDK) must be available in order to run eclipse. No Java virtual machine was found after searching the following locations: H:\Important Software\eclipse\jre\bin\javaw.exe java.exe…
0
votes
1 answer

Java Shell line input on Windows

The Java Shell REPL's line input on Windows doesn't behave the way line input behaves in most other Windows console applications: The Ctrl+Left Arrow key combination does not go to the start of the previous line. The End-of-File character is Ctrl+D…
DodgyCodeException
  • 5,963
  • 3
  • 21
  • 42
0
votes
0 answers

Unable to build code with google error prone on JDK 9 for hibernate

I am unable to build my code which makes use of hibernate to generate some classes and google error prone for static code analysis. I thought I enabled the java.sql module, but I am still unable to generate classes for Hibernate so my compilation…
Walter
  • 1,290
  • 2
  • 21
  • 46
0
votes
0 answers

Eclipse Oxygen 3a (4.7.3a) not finding test classes with Java 9

I am trying to get my open source project (JFXtras) running with Java 9 in Eclipse. IntelliJ is working fine, but not a fan. In JFXtras there is a subproject jfxtras-test-support which contains classes for unit testing. This is not a Java 9 module.…
tbeernot
  • 2,473
  • 4
  • 24
  • 31
0
votes
1 answer

groovy-maven-plugin:2.0:execute failed: No such property: canonicalFile for class: java.io.File

I started working on migrating one of my projects into Java9 and I ran into this issue while running, the project works alright with Java8 not sure where this error is coming from !!! mvn clean install Failed to execute goal…
Arar
  • 1,926
  • 5
  • 29
  • 47
0
votes
1 answer

unable to make module-based jar with javapackager

I am new to javapackager and Java 9, and am working through the examples in the javapackager reference, with the first example shown below: Example 1 - Using the -createjar Command javapackager -createjar -appclass package.ClassName -srcdir…
Phil Freihofner
  • 7,645
  • 1
  • 20
  • 41
0
votes
0 answers

Java 9 Modules - Package and Jar difference

In Java we have package, jar concepts to achieve modular programming. Why Java 9 introduced "Modules" again . What is the difference between these concepts . Looks like , just Python/Node.js and other languages has this module and Java simply…
JavaUser
  • 25,542
  • 46
  • 113
  • 139
0
votes
1 answer

Run Apache TomEE 7.0.4 with JDK 9 and JDK 10

I can not get TomEE 7.0.4 to work with java 9 and 10. TomEE 7.0.4 does not work with java 9 and 10. I think I understand that it is necessary to configure catalina.bat (I use windows). If I understood correctly, it all depends on the modules of jdk…
javista
  • 1
  • 1