3
votes

I got this issue when deploying my Java app to App Engine

Unable to update app: Cannot get the System Java Compiler. Please use a JDK, not a JRE.

See the deployment console for more details
Unable to update app: Cannot get the System Java Compiler. Please use a JDK, not a JRE.

That is absurd because I set up jdk1.7 in Installed JREs as the following picture:

enter image description here

In the log file. Debugging information may be found in C:\Users\AppData\Local\Temp\appengine-deploy3218365179732638698.log

    Unable to update:
java.lang.RuntimeException: Cannot get the System Java Compiler. Please use a JDK, not a JRE.
    at com.google.appengine.tools.admin.Application.compileJavaFiles(Application.java:904)
    at com.google.appengine.tools.admin.Application.compileJsps(Application.java:892)
    at com.google.appengine.tools.admin.Application.populateStagingDirectory(Application.java:687)
    at com.google.appengine.tools.admin.Application.createStagingDirectory(Application.java:629)
    at com.google.appengine.tools.admin.AppAdminImpl.doUpdate(AppAdminImpl.java:569)
    at com.google.appengine.tools.admin.AppAdminImpl.update(AppAdminImpl.java:58)
    at com.google.appengine.eclipse.core.proxy.AppEngineBridgeImpl.deploy(AppEngineBridgeImpl.java:433)
    at com.google.appengine.eclipse.core.deploy.DeployProjectJob.runInWorkspace(DeployProjectJob.java:158)
    at org.eclipse.core.internal.resources.InternalWorkspaceJob.run(InternalWorkspaceJob.java:38)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:53)

What is wrong?

This is my eclipse.ini

-startup
plugins/org.eclipse.equinox.launcher_1.3.0.v20120522-1813.jar
--launcher.library
plugins/org.eclipse.equinox.launcher.win32.win32.x86_64_1.1.200.v20120522-1813
-product
org.eclipse.epp.package.jee.product
--launcher.defaultAction
openFile
--launcher.XXMaxPermSize
256M
-showsplash
org.eclipse.platform
--launcher.XXMaxPermSize
256m
--launcher.defaultAction
openFile
-vm
C:\Program Files (x86)\Java\jdk1.7.0_79\bin
-vmargs
-Dosgi.requiredJavaVersion=1.5
-Dhelp.lucene.tokenizer=standard
-Xms40m
-Xmx512m
1

1 Answers

2
votes

Your eclipse is configured properly but the tooling is looking for system java compiler which it cannot find probably because you do not have java in your path. Include the path to jdk in your path or set the JAVA_HOME environment variable