Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upAdd query hints to remote read #2580
Comments
brian-brazil
added
component/remote storage
kind/enhancement
labels
Apr 5, 2017
brian-brazil
added
priority/P3
not-as-easy-as-it-looks
labels
Jul 14, 2017
This was referenced Dec 27, 2017
This comment has been minimized.
This comment has been minimized.
|
I don't see an immediate benefit to making it unstructured initially. If you change something, the other end won't work anymore either way. Just that you won't notice it at compile time with None is more or less work than the other really. You can iterate just as well on structured info. |
This comment has been minimized.
This comment has been minimized.
|
This would be another argument to What I can see immediately would be: type Aggregation int
const (
AggrNone Aggregation = iota
AggrAvg
AggrMin
AggrMax
AggrCounter
AggrCount
)
type Param struct {
Step int64
Aggr Aggregation
}The aggregation would make some assumptions already about what a given PromQL function needs. We could just make it a function name of course. But I'd believe that every implementation making use of these would just end up mapping our dozens of functions theirselves, which introduces lots of room for error. |
This comment has been minimized.
This comment has been minimized.
|
I don't think we should make any assumptions about how downsampling works and what information it finds useful for a first version. Thus why I propose passing it down and only finalising this API after there's more experience. |
This comment has been minimized.
This comment has been minimized.
|
Then just the raw info
Strictly speaking |
This comment has been minimized.
This comment has been minimized.
|
There's no overlap between function names and operator names, so for a first pass I'd suggest putting them all in one field. |
This comment has been minimized.
This comment has been minimized.
|
I'd like to work on this - I've started taking a look and I'll report back here if I run into anything, otherwise will hopefully have a PR soon. |
henridf
referenced this issue
Apr 30, 2018
Merged
Pass query hints down into remote read query proto #4122
brian-brazil
closed this
May 8, 2018
This comment has been minimized.
This comment has been minimized.
lock
bot
commented
Mar 22, 2019
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
brian-brazil commentedApr 5, 2017
As discussed back at promcon, we should add a map[string]string with hints like the function wrapping the selector, the range and the step. This is unstructured and experimental as we don't know yet what if any of this will prove useful for things like downsampling optimisations on the other end.
At some point (likely after the rest of remote read is considered non-experimental), this should be changed to proper structured data when we have a good idea from multiple implementations what information is needed.