Does anyone know if there will be support for GlassFish 5 in Eclipse in nearer future (GlassFish Tools supports 3.1 and 4.x)?
Is there another way to integrate Glassfish in Eclipse besides GlassFish Tools?
GlassFish Tools just checks for a version as follows:
Version version = getVersion();
if (!version.matches("[3.1-5)")) {
return new Status(Status.ERROR, GlassfishToolsPlugin.SYMBOLIC_NAME, Messages.unsupportedVersion);
}
Where getVersion()
is obtained from reading [install dir]/glassfish/modules/glassfish-api.jar!META-INF/MANIFEST.MF
and then the Bundle-Version
entry.
So a hacky way to get Eclipse working with GlassFish 5 and Payara 5 is:
4
and make sure digits are all single (i.e. 181 should become 0 or so)Now you can add a runtime and server for GlassFish 5 and Payara 5 as you would normally do, and start, debug, deploy etc.
For illustration, the entry to be changed looks as follows:
Bundle-Name: Public APIs of Glassfish
Bundle-Version: 5.181.0.Alpha4-SNAPSHOT
Created-By: Apache Maven Bundle Plugin
Build-Jdk: 1.8.0_144
Should become:
Bundle-Name: Public APIs of Glassfish
Bundle-Version: 4.0.0.Alpha4-SNAPSHOT
Created-By: Apache Maven Bundle Plugin
Build-Jdk: 1.8.0_144
The GlassFish tooling is currently in proposal to be donated to Eclipse, so it may take a while to be updated. Meanwhile, I'm planning to create a derivative version before long with some extra enhancements, but that too may take some time.