воскресенье, 9 июня 2013 г.

Failed to compile JSP files during Glass QuickStart for Java

The instructions I am following are here:

https://developers.google.com/glass/quickstart/java

I get to step 2 of Deploying. I am on a Windows machine and cd into app engine sdk bin folder and run the command specified but I modify the last parameter to be fully qualified.

It looks like this:

C:\Users\mscheel\Documents\Work\Glass\appengine-java-sdk-1.7.6\bin>appcfg.sh --o  auth2 update C:\Users\mscheel\Documents\Work\Glass\mirror-quickstart  -java-master\web  

The very first time I ran this I got a web popup with an oauth dialog and got a success code that I pasted into the running app and then got an error, like this one I am pasting in from a subsequent run:

This took a lot of effort, unfortunately, but the final solution was fairly simple. But first the problem. If you look in my original post at the execution you can see this line:

Error while executing: C:\Program Files (x86)\Java\jre6\bin\java.exe -classpath  

In the top code snippet.

That JRE is bad. I want to be using a JDK. I discovered this eventually by running through Eclipse (trying to deploy to app engine) and saw a better error message there.

The solution for Eclipse was to modify my Eclipse.ini as instructed here:

http://wiki.eclipse.org/Eclipse.ini

This forces eclipse to use the JDK instead of the JRE to allow deploy to app engine through eclipse (gets you past the jsp compilation failure).

My exact ini file snippet is:

...  -vm  C:\Program Files\Java\jdk1.7.0_21\bin\javaw.exe  ...  

But this did not fix things through the command line via appcfg. This page had the solution:

https://code.google.com/p/googleappengine/issues/detail?id=1226

Which appears to be windows specific, and will be a problem for anyone that previously installed JRE 6 at least. You have to uninstall all old JRE's. See comment #6 on that page. I did this through the uninstall applications GUI in Windows.

Once I did both these things I no longer have a failure compiling JSP's related to the mirror api.



http://stackoverflow.com/questions/16778089/failed-to-compile-jsp-files-during-glass-quickstart-for-java

Комментариев нет:

Отправить комментарий