I want Eclipse to download and install Apache Tomcat server environment but that option is greyed out for me
Any idea what might be missing?
Eclipse details :
Eclipse Java EE IDE for Web Developers.
Version: Mars.2 Release(4.5.2)
Java 8
It appears that this is caused by the lack of installable runtimes being defined for a given version of Tomcat in eclipse's org.eclipse.jst.server.tomcat.core
plugin.
In my case, I had eclipse "Photon" installed on my Windows box. In this version, the Download and Install
button is active for Tomcat 8.0, but it is not for 8.5:
To enable it, I had to add two entries to the plugin.xml
in the org.eclipse.jst.server.tomcat.core
jar, located in the plugins dir:
The entries are as follows, under the org.eclipse.wst.server.core.installableRuntimes
extension node:
<extension point="org.eclipse.wst.server.core.installableRuntimes">
...
<runtime
id="org.eclipse.jst.server.tomcat.runtime.85"
licenseUrl="http://www.apache.org/licenses/LICENSE-2.0.txt"
archiveUrl="http://archive.apache.org/dist/tomcat/tomcat-8/v8.5.38/bin/apache-tomcat-8.5.38-windows-x86.zip"
archivePath="apache-tomcat-8.5.38"
archiveSize="11402963"
fileCount="645"
os="win32"/>
<runtime
id="org.eclipse.jst.server.tomcat.runtime.85"
licenseUrl="http://www.apache.org/licenses/LICENSE-2.0.txt"
archiveUrl="http://archive.apache.org/dist/tomcat/tomcat-8/v8.5.38/bin/apache-tomcat-8.5.38.tar.gz"
archivePath="apache-tomcat-8.5.38"
archiveSize="9672042"
fileCount="641"
os="linux"/>
</extension>
I just chose the latest 8.5 binaries available from archive.apache.org
and obtained the archiveSize
and fileCount
values with ls
and find | wc
:
$ ls -l
-rw-r--r-- 1 cody group 9672042 Feb 5 07:21 apache-tomcat-8.5.38.tar.gz
-rw-r--r-- 1 cody group 11402963 Feb 5 07:21 apache-tomcat-8.5.38-windows-x86.zip
$ find apache-tomcat-8.5.38 -type f | wc -l
641
After updating the plugin jar, I modified eclipse.ini
to add the -clean
flag such that all plugin cache is purged. Remember to remove this after re-launching, as it will obviously cause eclipse to start up much more slowly:
-clean
-startup
plugins/org.eclipse.equinox.launcher_1.5.0.v20180512-1130.jar
--launcher.library
...
Once eclipse is up, the button is now enabled for 8.5 and functions as expected:
You can download tomcat separatly, than you can specify particulare installation path
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With