view schema/demo-data/published_services.sql @ 2987:524f1382558a

Make snapping of many axis segments faster Since a CTE is materialized anyhow, make the one for the UTM projected axis a temporary table, extended by the precalculated geometry boundaries and a spatial index on these, which then can be used in geometry comparisons within the recursive CTE. This makes snapping several hundreds of segments faster by more than an order of magnitude at the expense of longer runtime for snapping only very few segments, because of the additional cost for index creation. This could be further optimized by first checking if there is a direct match without any snapping, but since the function is currently only used in import processes, a runtime of a few seconds seems acceptable.
author Tom Gottfried <tom@intevation.de>
date Wed, 10 Apr 2019 10:02:07 +0200
parents c9032a57996e
children b90b17d0b5a9
line wrap: on
line source

-- This is Free Software under GNU Affero General Public License v >= 3.0
-- without warranty, see README.md and license for details.

-- SPDX-License-Identifier: AGPL-3.0-or-later
-- License-Filename: LICENSES/AGPL-3.0.txt

-- Copyright (C) 2018 by via donau
--   – Österreichische Wasserstraßen-Gesellschaft mbH
-- Software engineering by Intevation GmbH

-- Author(s):
--  * Tom Gottfried <tom@intevation.de>

INSERT INTO sys_admin.published_services (name) VALUES
    ('waterway.stretches_geoserver'),
    ('waterway.fairway_dimensions'),
    ('waterway.gauges_geoserver'),
    ('waterway.distance_marks_ashore_geoserver'),
    ('waterway.distance_marks_geoserver'),
    ('waterway.sounding_results_contour_lines_geoserver'),
    ('waterway.bottlenecks_geoserver'),
    ('waterway.bottleneck_overview'),
    ('waterway.waterway_axis'),
    ('waterway.waterway_area'),
    ('waterway.waterway_profiles'),
    ('waterway.sounding_differences')