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

Customize request URL #9

Closed
hampsterx opened this issue Aug 24, 2018 · 1 comment
Closed

Customize request URL #9

hampsterx opened this issue Aug 24, 2018 · 1 comment

Comments

@hampsterx
Copy link

fn proceed_replica_probe_http(url: &str, body_match: &Option<Regex>) -> bool {
    let url_bang = format!("{}?{}", url, time::now().to_timespec().sec);

Nice project, I have a couple of backend services that don't like having extraneous query params so I can't use them currently. I can understand you want to cache break the requests but this implementation prevents using requests with query params as well

@valeriansaliou
Copy link
Owner

Hi there. Yes, that's right! The solution would be to detect any existing query string parameters, and append the cache buster with '&' instead of '?'.

I'm accepting PRs!

@valeriansaliou valeriansaliou changed the title customize request url Customize request URL Sep 5, 2018
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