[OSM-talk] Topology

Robert (Jamie) Munro rjmunro at arjam.net
Thu Apr 26 19:06:26 BST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Martijn van Oosterhout wrote:
> On 4/26/07, Artem Pavlenko <artem at mapnik.org> wrote:
>> OK, I was hoping you have something to play with. I think investigating
>> PostGIS topology or even fixing MySQL is a good plan. I'm not so sure about
>> Oracle.
> 
> Is there a particular reason why we need PostGIS topology? If we store
> ways as arrays of node IDs and index them (which can be done in
> standard postgres) you get almost all the way. Add a trigger to
> automatically regenerate the polyline wherever the array changes and
> it should work just fine.

I began trying to implement this as an experiment - the idea was to take
the existing data structure and add an extra column to the node, segment
and way tables that was a PostGIS feature column with the node, segment
or way modelled in it. Then triggers would be added to all the tables so
that if anything changes the feature columns could all be updated, or if
that is difficult to do from a trigger, just set them to null. A process
could run once a minute or something finding all the null feature
columns and populating them.

Mapnik could then run directly on the ways and nodes tables.

The api could be speeded up by using PostGIS's indexes to fetch parts it
needed etc. Anything that relied on the existing data would still work
(apart from relying on MySQLs strange syntax).

I didn't get anywhere - I haven't had time to get past installing
PostGIS etc.

Robert (Jamie) Munro
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGMOogz+aYVHdncI0RArdDAKCBBBAfDOeIvd7MBLJCOE+aX4fNVgCgmS+0
xJ6Tgjg87CpHehjW/HJ2KCc=
=plVd
-----END PGP SIGNATURE-----




More information about the talk mailing list