On Sep 5, 1:42 am, James Purser <[email protected]> wrote: > The FedOne server has it's own way of doing Extensions. These are called > Agents.
The current agent API is quite different from the robot API. Basically, an agent is a Java client which talks to FedOne, and which receives the complete history of a wave as a series of document operations. There are good and bad things about the agent API: * Good - There's no need to retransmit the entire document for each keystroke, as is required by the current robot API. This means you actually have a chance of responding to DOCUMENT_CHANGED without burning gigabytes of bandwidth every day. - You can see exactly where the document is being modified, so there's no need to rescan an entire blip after each change. - Your agent is an ordinary Java process, so you can debug it easily, write unit tests, and so on. * Bad - Every time your agent is restarted, it sees a replay of the entire document's history. There's no distinction between old and new changes. So every time you restart Echoey, for example, it goes back to the beginning of the conversation and re-echoes each message. - There's no equivalent of the BLIP_SUBMITTED message. - The quick-and-dirty client library doesn't actually do OT; it just submits deltas blindly to the server. I'm not sure what happens if this fails. - The protocol spoken between the wave server and the agent is pretty arbitrary—it's based on the backend used by the demo ConsoleClient. Basically, the agent API is just a toy right now, and a lot of work will be required to make it production-ready. (And much of that work would be obsoleted by the next big code drop from Google.) So if you're developing robots, your best bet is probably to use the published robot API. The source code for Echoey.java is instructive, but not terribly useful. Cheers, Eric P.S. Here's a JRuby port of Echoey.java: http://gist.github.com/181379 To run it, you will need to modify the wave-protocol/build.xml file to create 'dist/fedone-agent-api-0.2.jar', which is identical to the stanza that builds Echoey, except that it doesn't have an entry point. I'll post a complete set of patches soon. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Wave API" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/google-wave-api?hl=en -~----------~----~----~----~------~----~------~--~---
