Current Robot Wire Protocol

0 views
Skip to first unread message

p2k

unread,
Jun 4, 2009, 9:15:29 AM6/4/09
to Google Wave API
Hi Googlers,

as you might know, I'm developing a Google Wave server (this is going
pretty fast, eh?). So I dug through the Java and Python APIs and had a
close look at the Python Client Library.

My question: Are the following assumptions true?

- The Wave server sends the complete Wavelet the robot is about to
work on through the protocol every time one or more events occur.
- The client library always unmarshals the received data and exposes
the freshly created Wave objects to the robot. There is no persistent
Wave(let) state maintained by the client, as those objects get
discarded after the events were handled.
- The robot has no way to see directly what has changed on a document,
when a DOCUMENT_CHANGED event was sent. It could save a copy of the
previous context and track the changes by itself, though.
- There is no explicit "user types a letter" event. That, and my
aforementioned assumption, is the reason why all sample robots only
react to submitted blips. Gotcha.
- So, with the current robot wire protocol one could not write a live-
translation robot and the traffic will get pretty high once the Wave
becomes larger.

I know, the client code and its protocol are all work in progress and
subject to change. I just want to know if I'm not missing out
something or got mixed up.

Thanks and keep up the good work,
p2k.

Bryce

unread,
Jun 4, 2009, 9:11:54 PM6/4/09
to google-...@googlegroups.com
Hi,

If by developing a "Google Wave server" that you are developing a server that will talk to over servers in a federated sense then you may want to go to the wave federation protocol group: http://groups.google.com/group/wave-protocol?pli=1

The server to server communication is all done via the wave federation protocol which you can find more details on here:
http://www.waveprotocol.org/

Cheers
Bryce

Seth Covitz (Google Employee)

unread,
Jun 11, 2009, 8:03:14 PM6/11/09
to Google Wave API
Hi p2k,

Thanks for looking into the robot wire protocols. As Bryce pointed
out, the robot wire protocol and the server-to-server federation
protocols are not the same. The robot wire protocol is designed to
support sessionless clients over http where only a limited amount of
context can be sent with each event.

Robots can receive events character by character (DOCUMENT_CHANGED),
but you are correct that the API does not currently expose the delta.
So it is up to the robot to know what changed. Polly is a great sample
robot that builds a preview of a form character by character as you
define the form in the form builder. So yes, you can write a live-
translation robot if you'd like.

We are looking to expose more robust robot to server communication
including finer grain events with more context as you are interested
in which will make such robots easier to write.

Seth
Reply all
Reply to author
Forward
0 new messages