openmaptiles/layers
Patrik Sylve f70ae783b2
Set columns to null instead of dropping to avoid pg_deadlock during updates (#1710)
This PR addresses a pg_deadlock error that would cause an update to fail if a `select getmvt` was queried during update. The deadlock occurred due to an ALTER TABLE DROP COLUMN operation on temporary columns  ( `new_source_ids` and `old_source_ids`) in some linestring tables.

**Changes:**
*  instead of adding/dropping the columns during update, they are now updated and set to NULL. 
* Added new indexes on the source_ids columns  to speed up the UPDATE. 
* Will refresh `osm_park_polygon_dissolve_z4` concurrently in `park_polygon.refresh()` to avoid blocking. 

Co-authored-by: Patrik Sylve <patrik.sylve@t-kartor.com>
2025-02-28 13:27:52 +01:00
..
aerodrome_label
aeroway
boundary
building
housenumber
landcover
landuse
mountain_peak
park
place
poi
transportation
transportation_name
water
water_name
waterway