[Sugar-devel] On datastore object IDs

Tomeu Vizoso tomeu at sugarlabs.org
Fri Jul 3 11:43:35 EDT 2009


On Thu, Jul 2, 2009 at 20:44, Eben Eliason<eben at laptop.org> wrote:
> On Thu, Jul 2, 2009 at 2:21 PM, Benjamin M.
> Schwartz<bmschwar at fas.harvard.edu> wrote:
>> Eben Eliason wrote:
>>> On Thu, Jul 2, 2009 at 1:40 PM, Benjamin M.
>>> Schwartz<bmschwar at fas.harvard.edu> wrote:
>>>> Eben Eliason wrote:
>>>>
>>>> If editing a Document's metadata produces a new Document, as befitting our
>>>> Copy-on-Write model of versioning, then the process of editing the
>>>> "associated_actions" field produces a new version.  Therefore, every time
>>>> an Action adds a Document to itself, the process of adding the
>>>> back-reference would produce a new version of the Document, so only one
>>>> Action would ever end up referring to one version of the a Document.
>>>
>>> Metadata is attached to the version, I believe. I don't think we
>>> should be versioning metadata, so I don't think that it makes sense to
>>> create a new version when changing the metadata.
>>
>> I don't see such a big distinction between the data and metadata.  In
>> fact, Activities whose state is easily represented as key:value pairs can
>> put their entire state into the metadata, instead of storing it in a blob.
>
> Hmm, I do see a distinction, actually. Though Perhaps it depends on
> the the type. As an example:
>
> 1. I make an image.
> 2. I make several changes to this image over time, resulting in new versions.
> 3. I decide that one of these intermediate images was meaningful in
> some way, and desire to tag it accordingly.
>
> I definitely don't want changing the description, or the tags, on some
> previous version to inadvertently a) make a new version and b) make
> that new version the most recent (and therefore most exposed) version.
>
> Perhaps we need to bite the bullet and consider having both versioned
> and unversioned metadata...

I think so. I definitely see part of the state of an activity stored
in the metadata (current page, current paint tool, etc). But we have
also some metadata properties that are bits of info about that
particular entry: author, title, tags, 'keep', etc. I think that we
should be able to modify those ones without creating a new version.

In fact, Ben's versioned prototype had all the blob and metadata
versioned and we needed to make some properties non-versioned because
of the intended user experience.

Regards,

Tomeu


More information about the Sugar-devel mailing list