Ignore relations with more than 32k members#716
Conversation
There is a hard restriction in the pgsql middle tables, where relation members are indexed using a smallint. To remain consistent, drop all relations which exceed this size. Fixes osm2pgsql-dev#713.
|
@lonvia , Just a minor remark: It may be difficult or impossible to implement at this particular stage of processing or code, but wouldn't it be better to reject the entire changeset containing the offending relation wholesale, instead of just dropping the relation? If I understand the code right, this will just drop the relation, but potentially leave an inconsistently imported changeset in the database. |
osm2pgsql has nothing to do with changesets and really knows nothing about them. It doesn't import changesets, which are intended to be useful to humans. Unless Even if it were possible, I'd still do it this way. |
|
It's also worth noting that this PR doesn't introduce a restriction, the restriction was always there. |
There is a hard restriction in the pgsql middle tables, where relation members are indexed using a smallint. This change just restricts to the technical limit to fix the issue with the diff file.
Fixes #713.