[postgis-tickets] [PostGIS] #4934: Deprecate topology function creating invalid topologies
PostGIS
trac at osgeo.org
Thu Jul 15 10:34:03 PDT 2021
#4934: Deprecate topology function creating invalid topologies
--------------------------+---------------------------
Reporter: strk | Owner: strk
Type: enhancement | Status: new
Priority: medium | Milestone: PostGIS 3.2.0
Component: topology | Version: 2.5.x
Resolution: | Keywords:
--------------------------+---------------------------
Description changed by strk:
Old description:
> Some topology functions are creating invalid topologies, and are
> documented to do so. They were written before SQL/MM full specification
> was implemented, so it wasn't that easy to create valid topologies.
>
> Nowadays those functions just make it harder to maintain the codebase as
> there are testcases proving the functionality of some of them still works
> in presence of invalid topologies and we impelment code to ensure invalid
> topologies are still somehow handled. Better stop now :)
>
> Such functions are (list to be grown I guess):
>
> - AddEdge (does not do edge linking nor face labeling)
> - AddNode (allows inserting isolated nodes with wrong containing_face)
>
> Another idea would be to *allow* creating invalid topology but somehow
> encode the kind of invalidity when doing so. For example in the
> AddLineStringNoFace function used as part of the proposed
> https://git.osgeo.org/gitea/postgis/postgis/pulls/28 change we encode the
> concept of "unknown side faces" by using the -1 pivot value in the
> left_face and right_face of edges with such unknown faces.
New description:
Some topology functions are creating invalid topologies, and are
documented to do so. They were written before SQL/MM full specification
was implemented, so it wasn't that easy to create valid topologies.
Nowadays those functions just make it harder to maintain the codebase as
there are testcases proving the functionality of some of them still works
in presence of invalid topologies and we impelment code to ensure invalid
topologies are still somehow handled. Better stop now :)
Such functions are (list to be grown I guess):
- AddEdge (does not do edge linking nor face labeling)
- AddNode (allows inserting isolated nodes with wrong containing_face)
- AddFace (allows leaving unresolved dangling edges)
Another idea would be to *allow* creating invalid topology but somehow
encode the kind of invalidity when doing so. For example in the
AddLineStringNoFace function used as part of the proposed
https://git.osgeo.org/gitea/postgis/postgis/pulls/28 change we encode the
concept of "unknown side faces" by using the -1 pivot value in the
left_face and right_face of edges with such unknown faces.
--
--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/4934#comment:2>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.
More information about the postgis-tickets
mailing list