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

Add ability to not cache-bust a particular URL in a check directive #16

Open
mcbridem opened this issue Apr 12, 2018 · 3 comments
Open

Comments

@mcbridem
Copy link
Contributor

Some URLs behave differently when a cache-buster—a query string—is appended. Setting aside whether it's reasonable for a Web server or Web application to behave differently if, for example, /?_=1234 is requested instead of /, URLs observed in the wild do sometimes differentiate, making testing difficult.

Would it make sense to add a no_cachebust: true or similar flag to check directives? This feels kind of hokey and it would be an inverted label. On the other hand, it would somewhat neatly complement the --no-cachebust command-line argument. By default we cache-bust all URLs and transform them if a non-live level is specified. Maybe a more generic leave_this_url_alone: true (or exact: true) flag would be better on a per-check directive basis?

@malerichc
Copy link
Contributor

We could add a cachebust key to check directives, and if it is not there, assume its value is true. Something like:

-   directive: check
    url: https://www.usnews.com
    cachebust: false

Or:

-   directive: check
    url: https://www.usnews.com
    transformations:
        cachebust: false

The latter could also contain more options for toggling or changing the behavior of other URL-transformations on a per-directive basis.

@mcbridem
Copy link
Contributor Author

Yes. I had a similar thought today, except it was:

-   directive: check
    url: https://www.usnews.com
    transformations: false

This would be the same as exact: true, just not in a redirect block?

If we went the list of transformations toggles route, what would we have besides cache_bust: false? level_mangling: false, as a complementary feature to only_levels? Any others?

@malerichc
Copy link
Contributor

The only one I personally desire is toggling cachebusting. I definitely want to be able to turn off cachebusting but leave level-mangling on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants