GoogleCloudPlatform/gcloud-node — pull request #35 by rakyll (2014-07-24 23:31:03+00:00)
Title: WIP: EventEmitter Subscription

Please don't merge.

Modifying Subscription to poll messages automatically.

~~~ js
var sub = conn.subscribe({ topicName: 'sometopic', name: 'sub1', autoAck: true });
sub.on('ready', console.log);
sub.on('error', function(err) {
console.log(err);
});
sub.on('message', function(message) {
console.log(message);
});
~~~