Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Rest Message Queue using JSON as protocol and HTTP as transport, appengine version

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 images
Octocat-spinner-32 js
Octocat-spinner-32 README
Octocat-spinner-32 admin.html
Octocat-spinner-32 app.yaml
Octocat-spinner-32 check.html
Octocat-spinner-32 index.html
Octocat-spinner-32 index.yaml
Octocat-spinner-32 jsoncmds.txt
Octocat-spinner-32 post.html
Octocat-spinner-32 queue.py
Octocat-spinner-32 queuetest.py
README
RestMQ - Appengine version
Simple Message Queue which uses REST routes, HTTP as transport layer and JSON as payload/protocol.
This one can be seen running at http://jsonqueue.appspot.com.
Protocol is simple and uses an API Key.
There is a twisted/redis version too somewhere.

-- Quick Howto -----

http://jsonqueue.appspot.com/admin
create your API Key and save it. You may regenerate it later.

{
	"cmd": "add",
	"queue": "genesis",
        "value": "abacab",
        "apikey":"your-api-key"
}

{
	 "cmd": "add",
	 "queue": "genesis",
	 "value": "turn it on",
         "apikey":"your-api-key"
}

{
	 "cmd": "add",
	 "queue": "genesis",
	 "value": {"composer": "phil collins",
"drummer":"phil collins"},
         "apikey":"your-api-key"
}

http://jsonqueue.appspot.com/stats/genesis - 3 items on backlog

{
	 "cmd": "take",
	 "queue": "genesis",
         "apikey":"your-api-key"
}

http://jsonqueue.appspot.com/stats/genesis - 2 items on backlog

{
	 "cmd": "get",
	 "queue": "genesis",
         "apikey":"your-api-key"
}

do this 2 times, there must be a count field, which is incremented with every get request.

{"queue": "genesis", "count": 1, "key": "aglqc29ucXVldWVyEQsSClF1ZXVlTW9kZWwYyRoM", "value": "turn it on"}

do whatever you want to do and delete this item using the key attribute (which is unique between queue items)

{
	 "cmd": "del",
	 "queue": "genesis",
 	 "key":"aglqc29ucXVldWVyEQsSClF1ZXVlTW9kZWwYyRoM",
         "apikey":"your-api-key"
}

check stats again, there must be just one item in the backlog
http://jsonqueue.appspot.com/stats/genesis


key - queue item unique id
apikey - your API Key
cmd - which command is meant to be executed
value - any json object you wish to put in the queue.

Something went wrong with that request. Please try again.