How to add GlassFish 4.1 server in Eclipse Neon 2?

I have a new installation of the Eclipse IDE for Java EE developers - for WIndows 64bit - Version: Neon.2 Release (4.6.2)

I downloaded the latest versions of GlassFish server 4.1.1 - both Full and Web Profie

I set the latest GlassFish rates using the Eclipse Marketplace:
https://marketplace.eclipse.org/content/glassfish-tools


Now I'm trying to add GlassFish Server to Eclipse using the latest JDK 8, but it complains that Java 6 or 7 is required:

enter image description here


Ok, then I try to use the latest JDK 7 instead of 8, but this time he complains that this is an invalid GlassFish installation.

enter image description here


How can I add a GlassFish server to Eclipse, what am I doing wrong?

+6
source share
2 answers

After many trial and error, I finally dealt with this problem.
The glassfish should be specified instead of the base installation directory, and everything works fine.

enter image description here

+11
source

Regarding "Java 6 or 7 required" is a problem; I managed to get past this by adding a trailing slash to the java location.

 /usr/lib/jvm/java-8-oracle # "Java 6 or 7 is required" /usr/lib/jvm/java-8-oracle/ # Works 

This is on Linux, so it may not apply to your Windows environment.

+3
source

Source: https://habr.com/ru/post/1013671/


All Articles