Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expired tiles are not reloaded #2950

Open
alasram opened this issue Oct 18, 2024 · 0 comments
Open

Expired tiles are not reloaded #2950

alasram opened this issue Oct 18, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@alasram
Copy link
Collaborator

alasram commented Oct 18, 2024

Describe the bug
Tiles with short lifespan are not reloaded (example: weather tiles that are changing every seconds, traffic data that are changing every 3 seconds...).
The lifetime is is set as a max-age HTTP Cache-Control.
When the tile is loaded the expiration information max-age is set in mbgl::Response::expires.
The response expiration will eventually flow to the Tile in mbgl::Tile::expires. The value stored in mbgl::Tile::expires is only used in the debug visualization. The tile cache and the algorithm that updates what tiles are retained do not use the expiration information.
The tile cache logic needs to be updated to consider the expiration information and to reload the tile if it expires. This should also triggers a rendering repaint when tiles are reloaded.

@alasram alasram added the bug Something isn't working label Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant