Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Mozilla changes to the mobwrite protocol
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  6 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
Joe Walker  
View profile  
 More options Aug 12, 6:49 am
From: Joe Walker <jwal...@mozilla.com>
Date: Wed, 12 Aug 2009 11:49:49 +0100
Local: Wed, Aug 12 2009 6:49 am
Subject: Mozilla changes to the mobwrite protocol

I thought it would be worth documenting the changes that we've made to  
mobwrite as part of bespin development:

The mobwrite protocol defines the following 'header names':
u/U: User, more correctly known as page identifier
f/F: File, identifier for the file to be synchronized
d/D: Request an edit by posting a diff
r/R: Request a raw file dump
n/N: Request clearing file to 0 bytes
b/B: Buffer ID to allow request splitting

The Mozilla version of mobwrite adds the following:
h/H: Handle. A username:ip-addr combination, 'client' header but added  
by the server, so it can be trusted. Needed to handle non world-write  
access.
C: Collaborators. Server added header informing the client of handles  
of other clients collaborating on the file.
x/X: Close view. The client may be able to tell the server to close a  
view, reducing memory consumption, and allowing more accurate display  
of collaborators.
E: Error: Server added header informing the client of a failure  
condition.
O: Read Only: Server added to inform the client that access to the  
given file is read-only. Attempts to alter it will be ignored.
S: Save state: The mobwrite version of the file is not considered  
'final' until saved. This server added header informs clients if the  
file has changed since editing. (Planned, not implemented)
q: Debug. This is a temporary fix to allow additional debug to be  
displayed on the server console.

We have also added a number of extra events to allow mobwrite to  
inform a shareHandler of the state of a file:

- reportCollaborators(userEntriesArray) Called by mobwrite to update  
the list of collaborators working on a given file
- raiseError(message, isRecoverable) Called when mobwrite detects an  
error condition
- setReadOnly(boolean) Called when access to the given file changes
- syncWithoutChange() mobwrite does not call setClientText() or  
patchClientText() if it believes that no changes are needed. This  
allows an editor to know that an initial synchronization has taken  
place even when no changes are needed.
- setDirty(boolean) Called whenever a collaborator saves the file  
(Planned, not implemented)

All of our work on these additions is focussed primarily on Mozilla  
requirements rather than trying to solve all generic problems, however  
I'm keen to evolve our alterations into more generic solutions.

The latest versions are always available in the bespin repo:
- http://hg.mozilla.org/labs/bespin/file/tip/frontend/js/bespin/mobwrite
- http://hg.mozilla.org/labs/bespin/file/tip/backend/python/bespin/mobw...

And I keep a version of the mobwrite repo with our changes copied in  
as time allows. This is currently a bit behind.
- http://bitbucket.org/joewalker/bespin-mobwrite/overview

Keen to hear of better ways of doing any of the above.

Joe.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Neil Fraser  
View profile  
 More options Aug 12, 4:55 pm
From: Neil Fraser <r...@neil.fraser.name>
Date: Wed, 12 Aug 2009 13:55:42 -0700
Local: Wed, Aug 12 2009 4:55 pm
Subject: Re: Mozilla changes to the mobwrite protocol
2009/8/12 Joe Walker <jwal...@mozilla.com>:

> n/N: Request clearing file to 0 bytes

Quick check that this has been interpreted properly.  n/N does not
zero the file.  That could be done with "R:"  The purpose of n/N is to
destroy the file completely from the server side.

The distinction is that when a client first syncs with a file, it says:
r:Hello world
Which means I have 'Hello World', but I don't consider this to be the
latest.  If the server has a copy of the file, it will reply with:
R:Goodbye World  (or the equivalent less-readable diff to that effect).
Which means your initial copy is out of date, here's what we have now.
 However if the server has never seen the file before, it will reply
with:
d:=11
Which means, fine, I'll take what you have, I've got no changes, keep going.

Setting the file to 0 bytes would mean editors joining in the future
would have any existing text cleared.  Deleting all trace of the file
fro the server would mean the server will take whatever the next
editor has.

Hope this clears things up.

--
Neil Fraser, Programmer & Wizard
http://neil.fraser.name


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joe Walker  
View profile  
 More options Aug 18, 8:36 am
From: Joe Walker <j...@getahead.org>
Date: Tue, 18 Aug 2009 13:36:47 +0100
Local: Tues, Aug 18 2009 8:36 am
Subject: Re: Mozilla changes to the mobwrite protocol

Ahh - makes sense. Thanks.

Joe.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Alexandre Martani  
View profile  
 More options Aug 24, 12:12 am
From: Alexandre Martani <amart...@gmail.com>
Date: Mon, 24 Aug 2009 01:12:28 -0300
Local: Mon, Aug 24 2009 12:12 am
Subject: Re: Mozilla changes to the mobwrite protocol
I'm interested on the save state feature. Any estimative of when it
will be done?

--
Alexandre Martani - amartani em gmail com
Sent from Sao Jose Dos Campos, SP, Brazil


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joe Walker  
View profile  
 More options Aug 24, 2:51 am
From: Joe Walker <jwal...@mozilla.com>
Date: Mon, 24 Aug 2009 07:51:51 +0100
Local: Mon, Aug 24 2009 2:51 am
Subject: Re: Mozilla changes to the mobwrite protocol

I think it's 70% likely to be done in the next month. There is a chance that
the feature could get lost in the rush to the next feature, but it's hard to
predict.

Joe.

On Mon, Aug 24, 2009 at 5:12 AM, Alexandre Martani <amart...@gmail.com>wrote:


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Joe Walker  
View profile  
 More options Aug 26, 9:29 am
From: Joe Walker <jwal...@mozilla.com>
Date: Wed, 26 Aug 2009 14:29:22 +0100
Local: Wed, Aug 26 2009 9:29 am
Subject: Re: Mozilla changes to the mobwrite protocol

Neil - This list changes over time - I'd like to document the changes more
permanently. The obvious places would be the mobwrite wiki or a page in this
group. What do you think is best?

The latest addition is some logic to handle the case where the server is
restarted. The net effect is that it ends up reverting clients to the last
persisted version. We can do better than this, but I think it needs a way
for the server to say "start again".

Joe.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google