Skip to content

Latest commit

 

History

History
20 lines (13 loc) · 2.46 KB

README.md

File metadata and controls

20 lines (13 loc) · 2.46 KB

GlassWebNotes

By Victor Kaiser-Pendergrast

About##

An application demonstrating how to connect the Glass GDK with App Engine Endpoints. Sign-in is handled through OAuth for Devices. See here for Google's documentation on it.

Notes are stored on the server component, which is a Java Google App Engine project. The server makes use of the Endpoints API

##Glass Application## The code for the Glass application is located in the GlassNotesApp folder. It is a fairly straightforward Glass app.

If anything, the parts to note are located under the auth subpackage. These classes are used to handle OAuth authentication.

Also, see the classes under the api subpackage, which demonstrate making API calls to the server through HTTP GETs and POSTs.

##App Engine Component## The App Engine side is also fairly basic; you can find it in the GlassNotesServer folder. The Endpoints API makes OAuth 2.0 rather easy to implement, see the code in EndpointApi for how easy it is to use OAuth 2.0 on App Engine.

User notes are saved with the Datastore API and a write cache. A cron job is used to periodically persist all the data in the write cache to the datastore. See UserDatabase for how the write cache is implemented.