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

allow target[]=foo specification #688

Merged
merged 1 commit into from
Jul 13, 2017

Conversation

Dieterbe
Copy link
Contributor

Rails/PHP/jQuery common practice format: target[]=path.1&target[]=path.2
Not really correct, but graphite allows it. So now we do also.

Rails/PHP/jQuery common practice format: target[]=path.1&target[]=path.2
Not really correct, but graphite allows it. So now we do also.
@Dieterbe
Copy link
Contributor Author

interestingly, macaron allows for non-urlencoded [] also, so all 3 work:

GET /render?target=metrictank.stats.docker-env.default.memory.gc.last_duration.gauge64&from=-30s 
GET /render?target%5B%5D=metrictank.stats.docker-env.default.memory.gc.last_duration.gauge64&from=-30s
GET /render?target[]=metrictank.stats.docker-env.default.memory.gc.last_duration.gauge64&from=-30s

i also tested with multiple, though note the different ways of specifying cannot be combined. While we could trivially also allow that, I don't think we should be any more permissive wrt illegal syntax than graphite already is.

@Dieterbe Dieterbe requested a review from woodsaj July 13, 2017 09:41
@Dieterbe Dieterbe merged commit 474b04f into master Jul 13, 2017
@Dieterbe Dieterbe deleted the exception-for-jquery-php-rails-like-graphite branch September 18, 2018 09:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants