Skip to content
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
This repository was archived by the owner on Aug 8, 2023. It is now read-only.

Use stale TileJSON data #2724

Description

@kkaefer

With #2617 in place, we now get stale data from the cache. Currently, stale TileJSON data loaded as part of loading a Source aren't used, but we should change this.

  • The easy case is when the refreshed request returns a 304. In this case, we don't have to do anything.
  • The hard case is when we get a different response. This is not a typical case however, so we could implement this with drastic action.

Things that could change in a TileJSON:

  • Tile endpoint: We need to reload all tiles to make sure we load the right data
  • Tile size: We need to recalculate the tiles we need to load because we might have to load tiles for a different zoom level
  • Min/Max zoom: We need to recalculate what tiles to load, if we have tiles loaded that are outside the new zoom range
  • Attribution: We need to notify the embedding application that this changed (Derive attribution from sources in current style #2723)
  • Center/bounds: We're not using these values currently

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    performanceSpeed, stability, CPU usage, memory usage, or power usage

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions