Code Monkey home page Code Monkey logo

recordsofexistence's Introduction

Records of Existence: a jQuery-Claypool Site Running on Google App Engine

Is a website built with server side jquery-claypool and runs on google app engine.
It is a great working example of some of the elegant features available from
jquery-claypools small, light weight frameworkf plugins.

It is a real web site running at recordsofexistence.com
so you can play with the example urls below to see they really work. We do ask that if you use
this project to get started on your next apps engine project, please remove
the references and logos to recordsofexistence.

Running

If you would like to develop locally you can get the google apps engine development
environment (is really just jetty with a mini bigtable backend built in.) The
appengine dev is here:

Google AppEngine SDK

All you need to do is unzip it (we’ll assume unix-like paths) and run:

$> /path/to/appengine/bin/dev_appserver.sh /path/to/recordsofexistence/

At this point you should be able to open up a browser see

http://localhost:8080/

Managing the Database

To build/rebuild the database you will want to be familiar with the following
urls. They will allow you to empty, load from json, and get a database dump
as json. Try them in the browser in this order:

the last will ask you to save a file, this is noramlly saved as :

/path/to/recordsofexistence/data/__initial__.json

You’ll also notice these urls are not available at www.recordsofexistence.com,
or rather they are password protected.

The Site and its Features

The site is a simple website, suitable for small merchants or home businesses.
Data is stored the Google’s Big Table (though to the developer it is transparent
and will still feel like ajax), and the data files (images etc are stored on s3).
For local development we will store the images locally, and they could be served
directly fro app engine as well.

JSON Views

jQuery-Claypool on AppsEngine is not too much unlike CouchDB. In Fact we add a
simple Filter in app/config/filters.js to provide a simple json view of the data
aggregated from the database for each page of the site. To get json instead of
html just add ?fo=json to any url in the site! Here are some examples:

or for the impatient

For giggles you can also try fo=xml on all these urls

Rest Interfaces

If you want to access the database directly, you can make use of the rest
interfaces. Again these urls are password protected at www.recordsofexistence.com
for obvious reasons but you can see them locally. Here are just a few (and dont
forget this is just GET, we support POST, PUT, and DELETE as well)

Admin Interface

On any page you can add ?admin to access the admin interface (if available, most
pages have an admin interface). Locally you will be able to modify your database,
but of course the back end urls are password protected at the live site:

or for the impatient

Deploying

When you are ready to deploy, it is basically as simple as toggling you environment in
app/boot/server.js from

$.env('defaults', "dev.client"); //$.env('defaults', "appengine.server");

to

//$.env('defaults', "dev.client"); $.env('defaults', "appengine.server");

and finally

$> /path/to/appengine/bin/appcfg.sh update /path/to/recordsofexistence/

(don’t forget to make sure WEB-INF/appengine-web.xml points to your app id)

recordsofexistence's People

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.