Wednesday, October 7, 2009

App Engine from Scratch

I decided to see how easy it was to deploy an app engine project without reading all the documentation.
I already have the Google plugin for Eclipse.
So I created a new default Google Java application project for GWT and AppEngine, changed the greeting service to reverse a String. Very stupid app, just for testing purposes.

Did have to ask a couple of questions, trying the experiment of NOT reading any documentation.
OK so:
1. Sign up for app engine.
2. Give them your cell phone number.
3. Get an SMS message back.
4. Enter it.
5. Create your application URL at https://appengine.google.com/
5 1/2. Make SURE you put your application name IN your appengine-web.xml file. This is where I ran into a snag!
It will look like:


<?xml version="1.0" encoding="utf-8"?>
<appengine-web-app xmlns="http://appengine.google.com/ns/1.0">
<application>edsmiley666test</application>
<version>1</version>


<!-- Configure java.util.logging -->
<system-properties>
<property name="java.util.logging.config.file" value="WEB-INF/logging.properties"/>
</system-properties>
</appengine-web-app>



Yeah, App Engine needs to look at that to be able to deploy! Otherwise appengine says WTF is this and 403s you.

6. Click your little app engine icon to deploy. It will grind away like this:
Compiling module geek.Edsappenginedemo
Compiling 6 permutations
Permutation compile succeeded
Linking into C:\eclipse3.4\workspace\edsappenginedemo\war
Link succeeded
Compilation succeeded -- 24.149s
Creating staging directory
Scanning for jsp files.
Scanning files on local disk.
Initiating update.
Cloning 31 static files.
Cloning 51 application files.
Uploading 26 files.
Uploaded 6 files.
Uploaded 12 files.
Uploaded 18 files.
Uploaded 24 files.
Deploying new version.
Will check again in 1 seconds
Closing update: new version is ready to start serving.
Uploading index definitions.
Deployment completed successfully

The app itself, which is not worth looking at is at http://edsmiley666test.appspot.com/.
Each deployed version gets a subdomain of it, e.g. http://1.latest.edsmiley666test.appspot.com/

October GTUG

SV-GTUG Tonight: App Engine 1.2.5 release.
October Meeting: App Engine 1.2.5 Coding Session Oct 7 Wed 6:00 PM
Where? Googleplex (Bldg. 43) 1600 Amphitheatre Parkway Tunis Conference Room Mountain View, CA 94043

...
blogging live from october sv-gtug

It’s a nice cozy group here, and several Santa Cruzans are here as well.
(Maybe the “write code” pared it down somewhat.)

So just finished off my ginormous burrito and diet coke.
Just learned about a framework for Groovy on AppEngine.