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

Reflective access not working in tests in a modular (Java 9+) app in IntelliJ IDEA

I have a project where I use reflective access to my classes (e.g. by Spring, but also others). And everything is working fine. Now i tried to add a module-info.java and suddenly my tests can not find my production code using reflections in IntelliJ…
Itchy
  • 2,263
  • 28
  • 41
0
votes
2 answers

Spring webflux how to return 200 response to client before processing large file

I am working on a Spring Webflux project, I want to do something like, When client make API call, I want to send success message to client and perform large file operation in background. So client does not have to wait till my entire file is…
Alpesh Jikadra
  • 1,692
  • 3
  • 18
  • 38
0
votes
1 answer

Practical packaging of test code in modular project

I've been pondering the Java module system and had a question I didn't find addressed here. I poked around a bit more and worked out an answer, so I guess I'll post the info, in case it shortens anyone else's search. Traditionally, tests are kept in…
Toby Eggitt
  • 1,806
  • 19
  • 24
0
votes
0 answers

Java 9 ORMLite conflict in module-info

I have a Java 9 (or higher) project in which I want to include ORMLite with a H2 database. Therefore I need the two maven dependencies com.j256.ormlite
Andwari
  • 161
  • 1
  • 12
0
votes
0 answers

springboot application deployment issue with WAS 8.5.5.12

I am trying to deploy a springboot application in was server 8.5.5.12., but facing an issue as application stops automatically after few seconds or does not start at all with following error: 11/29/19 2:18:39:584 CET] 0002c36e WSModuleDescr E …
Harsha
  • 87
  • 1
  • 14
0
votes
0 answers

InvalidAlgorithmParameterException for openjdk 9

Windows, Java project, using OpenJDK 9, when I tried to run maven clean, got the error below. I checked the file cacerts exists in C:\Program Files\Java\java-se-9-ri\jdk-9\lib\security. How to fix the error? [ERROR] Plugin…
heshuguo
  • 21
  • 4
0
votes
1 answer

Java Modularity with Dependency Injection

Let's assume an OpenJDK 11 + OpenJFX 11 based application. The codebase is organized in a single java module (see A Guide to Java 9 Modularity for reference). Until now I combined all my JavaFX based projects with Google's dependency injection…
0x1C1B
  • 1,204
  • 11
  • 40
0
votes
0 answers

Usage of tools.jar in JDK9 and beyond

IN my project, I have a dependency on tools.jar for instrumentation purposes. Without tools.jar in jdk9 and beyond (in JD11 too), where and how can I resolve the dependency? Has anyone come across same scenario? Regards,
ha9u63a7
  • 6,233
  • 16
  • 73
  • 108
0
votes
1 answer

SOLR 7.5 crashes

I'm rebuilding my index from a Wordpress plugin, this uses the Parametric solr-php-client. Frequently, when updating the index, SOLR crashes with an error message as below. Unfortunately, I'm not too familiar with debugging SOLR/Java applications.…
Cthulhu
  • 1
  • 1
0
votes
1 answer

Android Studio 3.5 update issue

While updating android studio 3.5 getting below error. If i click cancel it deleting installed patch file. Some conflict were found in the installation area.
Samsul Huq
  • 21
  • 2
0
votes
0 answers

IntelliJ highlights a split packaging error, but surefire runs tests successfully

I am doing a project to get familiar with Java 9 module system. I intend to use module-info.java files to contain my packages and trim down the jre with jlink. The only dependency in my project is Jsoup. jlink does not support automatic modules so I…
user5818995
0
votes
0 answers

Cannot figure out how to get java runtime to load local test copy of tool in standard jdk9 runtime

I have made a local copy of the jdeps tool from the openjdk sources. (I want to use it to help me learn more about internals of modules.) I can build the tool but I cannot run it. Java always runs the standard one in the jdk/jmods directory. I…
Mark Roberts
  • 101
  • 4
0
votes
1 answer

How to use Java to create checkboxes in Google Spreadsheet

I was having trouble looking for ways to create and modify checkboxes in Google Spreadsheet using Java. I have looked through the Google API documentation and only found some Javascript APIS that could do that. The worst case is to use javax.script…
0
votes
0 answers

Exception message from JVM not printed correctly in console when using Java 9 and using Japanese locale (probably due to compact strings)

Given the following environment: Windows 10 Language is set to Japanese Language for non-unicode programs is set to Japanese Java program is run on console Upon execution, an IOException is encountered, and the message expected in the console is…
javayoyo
  • 1
  • 1
0
votes
0 answers

How to fix the error in load() method of FXMLLoader

I'm doing a project using javafx where scene changing is applied. There are two fxml files, first scene contains a button which is supposed to move the scene to the next scene. But I got an error in the controller class of first fxml file at the…
Mateen
  • 1,455
  • 10
  • 17