[Tile-serving] [osm2pgsql] Partitioning (#92)
apmon
notifications at github.com
Thu Oct 17 03:18:37 UTC 2013
I have a branch of osm2pgsql ( https://github.com/apmon/osm2pgsql/tree/partitioning ) for quite some time, which allows for partitioning of the osm2pgsql tables according to arbitrary where clauses. Once the release is out and the parallelisation functionality landed, I hope to look at this branch again and plan to merge it.
At the moment the partitionings are still defined in code and not user changeable, but I hope to change this and they are defined by a single data structure. e.g the following partitions the polygon table into buildings and non buildings and the line table into highways and non highways.
partitions [] = {
{ .name = "buildings", t_poly, "building is not null", "NEW.building is not null"},
{ .name = "nonbuildings", t_poly, "building is null", "NEW.building is null"},
{ .name = "highways", t_line, "highway is not null", "NEW.highway is not null"},
{ .name = "nonhighways", t_line, "highway is null", "NEW.highway is null"}
};
One can also use this to partition things into further sub-structures, as long as the combination of where clauses are complete and mutually exclusive.
---
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/osm2pgsql/issues/92#issuecomment-26476669
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/tile-serving/attachments/20131016/e27414d9/attachment.html>
More information about the Tile-serving
mailing list