[Tile-serving] [openstreetmap/osm2pgsql] Add tilesets to flex output allowing more flexible expire configuration (PR #1912)
Jochen Topf
notifications at github.com
Sat Feb 11 16:22:11 UTC 2023
*This should be merged only after the next (bugfix) release.*
Tilesets are defined with `define_tileset()` in the Lua config file. They have a name, min and max zoom levels, and a filename or table name (optionally with schema). The filename or table specify where the contents of the tilesets are written to at the end of an osm2pgsql run.
Tilesets are referenced from geometry columns of database tables. A new `expire` field allows setting any number of tilesets and some additional parameters. In append mode, any geometry written to those columns triggers an entry in the corresponding tileset(s). Deletes also trigger these entries.
For backwards compatibility an expire config set with -e/--expire-tiles and -o/--expire-output is automatically added to all tables. Those command line options (together with --expire-bbox-size) should be marked as deprecated at some point and later removed.
You can view, comment on, or merge this pull request online at:
https://github.com/openstreetmap/osm2pgsql/pull/1912
-- Commit Summary --
* Make get_from_idx_param()/index_from_param() more generic
* Add tilesets to flex output allowing more flexible expire configuration
-- File Changes --
A flex-config/tilesets.lua (168)
M src/CMakeLists.txt (2)
M src/expire-config.hpp (8)
M src/expire-tiles.cpp (23)
M src/expire-tiles.hpp (20)
M src/flex-lua-table.cpp (117)
M src/flex-lua-table.hpp (4)
A src/flex-lua-tileset.cpp (99)
A src/flex-lua-tileset.hpp (22)
M src/flex-table-column.cpp (17)
M src/flex-table-column.hpp (19)
M src/flex-table.cpp (36)
M src/flex-table.hpp (20)
A src/flex-tileset.cpp (26)
A src/flex-tileset.hpp (76)
M src/flex-write.cpp (13)
M src/flex-write.hpp (9)
M src/lua-utils.cpp (20)
M src/lua-utils.hpp (3)
M src/output-flex.cpp (318)
M src/output-flex.hpp (19)
M tests/CMakeLists.txt (2)
A tests/bdd/flex/lua-expire.feature (210)
M tests/bdd/flex/lua-index-definitions.feature (4)
A tests/bdd/flex/lua-tileset-definitions.feature (174)
A tests/bdd/flex/run-with-expire.feature (41)
-- Patch Links --
https://github.com/openstreetmap/osm2pgsql/pull/1912.patch
https://github.com/openstreetmap/osm2pgsql/pull/1912.diff
--
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/osm2pgsql/pull/1912
You are receiving this because you are subscribed to this thread.
Message ID: <openstreetmap/osm2pgsql/pull/1912 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/tile-serving/attachments/20230211/df70e823/attachment-0001.htm>
More information about the Tile-serving
mailing list