[OSM-dev] Suggestion to replace created_by tags

Schuyler Erle schuyler at nocat.net
Sun Apr 29 22:29:50 BST 2007


* On 29-Apr-2007 at  9:36AM PDT, Richard Fairhurst said:
> Frederik Ramm wrote:
> 
> > Actually, a thing that we had discussed in Essen and that was  
> > widely accepted would solve the same problem: Making a set of  
> > changes belong to a "change group", which may have a description  
> > (and could also carry a client id).
> 
> Seems a clever idea. How would you envisage it working with online  
> editors which commit edits one at a time, rather than in a bunch?

One *could* treat the transaction ID as if it were an SQL sequence.
Clients could start by requesting a new transaction ID from the
server, and then apply the same transaction ID to each separate
update. The server would then merely need to take care that it never
issues the same transaction ID twice.

The idea of transactions are a fundamental part of my thinking about
possible future OSM data models, but I've been toying with about
identifying them with 128-bit UUIDs (as per RFC 4122).[1]

If OSM clients generate their own UUID for each transaction (for
whatever definition of 'transaction' the client uses), setting a
"change_group_id" or "transaction_id" tag to a 32 character
hexadecimal string, then they wouldn't even have to contact the server
first...

Further, clients could start doing this *now*, without changing the
API on the server... so this is what I would recommend considering for
implementation. There are UUID-generating libraries for just about
every modern programming language.

I don't know if the API currently supports this, but the next logical
step, however this is implemented, would be to start sending "diary
entries" (or whatever they're called in the database) keyed by
transaction ID, yielding something that might look like an CVS or SVN
revision history.

SDE

[1] http://www.ietf.org/rfc/rfc4122.txt




More information about the dev mailing list