Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » Is Eclipse 2019-06 meant to work with Java 9+?(Multiple annoying difficulties with Java 9 modules)
Is Eclipse 2019-06 meant to work with Java 9+? [message #1822471] Sat, 07 March 2020 17:53 Go to next message
mike rodent is currently offline mike rodentFriend
Messages: 6
Registered: February 2014
Junior Member
I've been using Eclipse for at least 10 years but I'm now being FORCED to start learning Intellij by Eclipse's apparent inability to cope with Gradle and Java 9 modules. (In fact I'm using Java 11 currently).

EXAMPLE 1
This problem concerns use of modules with jlink and JavaFX in a Gradle context. Spurious errors are shown but the Gradle commands run fine at the CLI. Zero answers to date.

EXAMPLE 2
This problem concerns the fact that `Gradle - Refresh` causes my configured modules, added under Java Build Path --> Libraries --> Module path to disappear. Spurious errors are shown but the Gradle commands run fine at the CLI. Zero answers to date.

EXAMPLE 3
I just created a new project today and created two source folders with packages in each. Because I wanted to do an experiment with Java 9+ modules I put an module-info.java into both locations. To my utter exasperation Eclipse pipes up with "The project was not built due to "Build path contains duplicate entry: 'module-info.java' for project 'ModuleTest'". Fix the problem, then try refreshing this project and building it since it may be inconsistent". This is WRONG. Spurious errors are shown but the Java commands run fine at the CLI.

For anyone interested, I am also unable to switch to Eclipse 2019-09 or -12 (though I doubt very much that these problems will have been corrected) because of a mysterious grey bar which obscures all my editors when I install these newer version. Another SO question about this also has zero answers.

One can also add to that the fact that the crucial Groovy-Eclipse plug-in for Eclipse is being severely hampered due to Eclipse having sat on some bugs for several years: see this Groovy-Eclipse issue raised by me recently. This results in particular in an open Package Explorer and any open editor windows producing an error when I start Eclipse: "org.eclipse.core.runtime.InvalidRegistryObjectException: Invalid registry object" - these screens are then messed up, forcing one to close and reopen them. This bug appears to have been live since 2017.

Should it perhaps be openly admitted that the Eclipse platform can't in fact cope with Java 9+ modules, especially when used in conjunction with Groovy?

As I say, ALL these problems are non-existent: most of the time I run my Gradle projects at the CLI, i.e. outside Eclipse. I want to have the choice of TURNING OFF PERMANENTLY these spurious and very annoying error marks in Eclipse since they are erroneous and serve no purpose.
Re: Is Eclipse 2019-06 meant to work with Java 9+? [message #1822475 is a reply to message #1822471] Sat, 07 March 2020 19:35 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33257
Registered: July 2009
Senior Member
Certainly Eclipse's Java Development Tools have fine support for all released versions of Java. But when it comes to questions about Gradle then I suppose you are using Buildship and would be better to ask about that on their forum:

https://discuss.gradle.org/c/help-discuss/buildship


Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Is Eclipse 2019-06 meant to work with Java 9+? [message #1822488 is a reply to message #1822475] Sun, 08 March 2020 08:37 Go to previous messageGo to next message
mike rodent is currently offline mike rodentFriend
Messages: 6
Registered: February 2014
Junior Member
Thanks... good to have a view from a "Senior Member". What about the fact of not allowing two module-info.java files under separate "source folders"? This is not a Gradle project but a bog-standard Java one.

And in fact a bit of fiddling with renaming files (module-info.java --> module-info.java_OLD) shows that in fact you can't even VIEW THE FILES IN THE PROJECT (!) if there is more than one module-info.java, under different source folders. Do you not even acknowledge that that is a major flaw which must be corrected as a matter of urgency?

Better still, as I say, acknowledge that sometimes Eclipse can't cope with certain newer technologies, or is not correctly "tuned" 100% of the time, pending patches and bugfixes (some of which take years to happen), and give us the chance to turn off error types, or display them as warnings/"info". This sort of categorisation of some types of "anomalies" is already left to users under Prefs --> Java --> Compiler --> Errors/Warnings. What real argument can there be for not extending that handling much further?
Re: Is Eclipse 2019-06 meant to work with Java 9+? [message #1822491 is a reply to message #1822488] Sun, 08 March 2020 10:32 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33257
Registered: July 2009
Senior Member
The JDT developers will be more likely to see Java specific questions on the JDT forum:

https://www.eclipse.org/forums/index.php/f/13/

But they aren't likely to be able to help with Gradle. Also note that if you're using an older version of the Java IDE that version (which one are you using?) may well not contain the latest Java support and of course will not have the latest bug fixes.

When posting to the JDT forum, It would be good to share enough details that someone else could reproduce the problem that you're seeing even if it's just a screen capture showing the state of the project with the expanded tree of the project. The forum is not so helpful with making it easy to add attachments, but if you do a "Preview Quick Reply" can you see that you can attach files.


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:Eclipse on Win 10 x64 with AdoptOpenJDK jdk-13.0.2+8
Next Topic:Why did I have t o click "Reload" on the SpringToolSuite update site?
Goto Forum:
  


Current Time: Tue Dec 03 03:37:35 GMT 2024

Powered by FUDForum. Page generated in 0.03156 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top