aboutsummaryrefslogtreecommitdiffstats
path: root/webmap-publish
diff options
context:
space:
mode:
authorGuilhem Moulin <guilhem@fripost.org>2025-04-23 17:55:57 +0200
committerGuilhem Moulin <guilhem@fripost.org>2025-04-24 16:49:37 +0200
commit80882acd6ba407847fed0ef308e440b88796e0e1 (patch)
tree7084e4508c9ad3aa72c034735e8cbc85738af93c /webmap-publish
parentc42245fc566eab01dd2e1f4b07bcbef7432c89c1 (diff)
Change layer cache logic to target destination layers rather than sources.
In a future commit we'll fingerprint layers to detect changes. Comparing modification times is not enough since some sources (for instance Naturvårdsverket's SCI_Rikstackande) are updated on the server even though no objects are being added; the source layer remains unchanged but the file differs because of OBJECTID changes we are not interested in. Rather than using another cache layer/table for fingerprints, we cache destination layernames rather than triplets (source_path, archive_member, layername), along with the time at which the import was started rather than source_path's mtime. There is indeed no value in having exact source_path's mtime in the cache. What we need is simply a way to detect whether source paths have been updated in a subsequent run. Thanks to the shared locks the ctime of any updated source path will be at least the time when the locks are released, thereby exceeding the last_updated value.
Diffstat (limited to 'webmap-publish')
0 files changed, 0 insertions, 0 deletions