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

Fix ion asset caching #6353

Merged
merged 2 commits into from
Mar 22, 2018
Merged

Fix ion asset caching #6353

merged 2 commits into from
Mar 22, 2018

Commits on Mar 21, 2018

  1. Fix ion asset caching

    ion asset caching was essentially broken because sending the access token
    in the query string would bust the cache. The initial fix was to allow the
    token in the Authorization header, which fixed caching but triggered a
    preflight request for every tile request (due to CORS), this adds
    unnecessary overhead. To work around this CORS limitation, the ion servers
    also support including the token in the `Accept` header, which is
    non-standard but perfectly legal and does not trigger a pre-flight.
    
    Unfortunately, including token in the Accept header means we can no longer
    vary the accept header to handle terrain extensions. Cesium ion supports
    passing extensions via query parameters, so `CesiumTerrainProvider` now
    detects an ion resource and uses query parameters for them.
    
    Also turned the private and static function `Resource._makeRequest` into
    a prototype function so that I could override it `IonResource`
    mramato committed Mar 21, 2018
    Configuration menu
    Copy the full SHA
    c67111c View commit details
    Browse the repository at this point in the history
  2. Update CHANGES

    mramato committed Mar 21, 2018
    Configuration menu
    Copy the full SHA
    8dbcd0d View commit details
    Browse the repository at this point in the history