<div dir="ltr">This is great Mathieu !<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Le ven. 15 nov. 2024 à 12:52, Mathieu Pellerin via QGIS-PSC <<a href="mailto:qgis-psc@lists.osgeo.org">qgis-psc@lists.osgeo.org</a>> a écrit :<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Greetings PSC,</div><div><br></div><div>I’m happy to report that the work for the above-mentioned QEP has
been completed during the months of August and September 2024. The work
includes:<br><br>- A new “smart” network cache mode - enabled by default
– which adopts modern browsers’ strategies to determine the on-disk
network cache size based on users’ available space. Starting with QGIS,
for the fast majority of users, this will increase the network cache
size from 0.25gb to 1gb, which in turn will allow for greater space to
cache XYZ raster tiles, including those served by <a href="http://openstreetmap.org" target="_blank">openstreetmap.org</a>. While a backport was made available, it was deemed – wisely :) - too risky to merge.<br><br>-
The following processing algorithms were modified to insure QGIS users
do not accidentally breach the OSMF tile usage policy with regards to
bulk downloads: the generate XYZ tiles (MBTiles) algorithm, the generate
XYZ tiles (Directory) algorithm, and the convert map to raster
algorithm. In all three algorithms, a check is now in place to insure
that no more than 5,000 tiles will be fetched from <a href="http://openstreetmap.org" target="_blank">openstreetmap.org</a>.
If the amount of tiles goes behind this threshold, users will be
informed through a warning message in their processing algorithm dialog
that the layer serving <a href="http://openstreetmap.org" target="_blank">openstreetmap.org</a>
tiles has been removed from the set of layers being rendered. Below
5,000 tiles, we assume users are not aimed at bulk downloading tiles but
rather preparing a map of reasonable extent for viewing. These changes
have been backported to the current 3.34 LTR.<br><br>- Additionally,
further safeguards were put in place while researching other means
through which bulk downloads could be achieved. The same 5,000 tiles
threshold when saving a XYZ raster layer through the browser panel as
well as through the layers panel when those tiles are served through <a href="http://openstreetmap.org" target="_blank">openstreetmap.org</a>.
As with the processing algorithms, when users surpasses the threshold, a
message box will appear to inform them of the OSMF tile usage policy.
These changes are available in 3.40 and have also been backported to the
current 3.34 LTR.<br><br>- Finally, I took the opportunity to apply an
improvement to the default OpenStreetMap XYZ layer available through the
browser panel. On fresh QGIS installations, this layer now now has its
tile resolution set to 96DPI instead of unknown. The change results in a
significant reduction in tiles being fetched when exporting a print
layout in high DPI (e.g. 300). The benefits in terms of tile fetching
reduction also impacts atlas and report layout exports. The change
arguably improves layout exports by avoiding tiny, unreadable labels.
Users can always manually change this tile resolution setting if
desired. This change is available in 3.40 and has also been backported
to the current 3.34 LTR.<br><br>With those improvements in place, QGIS
3.40 has the safeguards in place to insure that bulk downloads -
accidental or intentional - are prohibited. Furthermore, the network
caching improvement and the adjusted configuration of the default
OpenStreetMap XYZ layer shipped with QGIS are undoubtedly going to
reduce any stress caused by normal usage’s fetching of tiles.<br></div><div><br></div><div>Regards,</div><div><br></div><div>Mathieu Pellerin<br></div><div>OPENGIS.ch</div></div>
_______________________________________________<br>
QGIS-PSC mailing list<br>
<a href="mailto:QGIS-PSC@lists.osgeo.org" target="_blank">QGIS-PSC@lists.osgeo.org</a><br>
<a href="https://lists.osgeo.org/mailman/listinfo/qgis-psc" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/qgis-psc</a><br>
</blockquote></div>