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

TS.MRANGE add NOLABELS to reduce returned answer #267

Closed
gkorland opened this issue Dec 10, 2019 · 2 comments · Fixed by #285
Closed

TS.MRANGE add NOLABELS to reduce returned answer #267

gkorland opened this issue Dec 10, 2019 · 2 comments · Fixed by #285
Assignees
Labels
enhancement New feature or request

Comments

@gkorland
Copy link
Contributor

No description provided.

@filipecosta90 filipecosta90 self-assigned this Dec 10, 2019
@filipecosta90 filipecosta90 added the enhancement New feature or request label Dec 12, 2019
@filipecosta90 filipecosta90 changed the title TS.MRANGE add NO_LABELS to reduce returned answer TS.MRANGE add NOLABELS to reduce returned answer Dec 12, 2019
@filipecosta90
Copy link
Contributor

@gkorland regarding the return value, and in order to keep compatibility on all clients we should return an empty list in the position of the labels array. Do you agree?

example of command with the default option

TS.MRANGE - + COUNT 5 FILTER measurement=cpu fieldname=usage_user
1) 1) "cpu_usage_user{948008140}"
    2)  1) 1) "hostname"
           2) "host_3"
        2) 1) "region"
           2) "us-west-2"
        3) 1) "datacenter"
           2) "us-west-2b"
        4) 1) "rack"
           2) "12"
        5) 1) "os"
           2) "Ubuntu15.10"
        6) 1) "arch"
           2) "x64"
        7) 1) "team"
           2) "CHI"
        8) 1) "service"
           2) "18"
        9) 1) "service_version"
           2) "1"
       10) 1) "service_environment"
           2) "production"
       11) 1) "measurement"
           2) "cpu"
       12) 1) "fieldname"
           2) "usage_user"
    3) 1) 1) (integer) 1451606400000
          2) "8"
       2) 1) (integer) 1451606410000
          2) "7"
       3) 1) (integer) 1451606420000
          2) "6"
       4) 1) (integer) 1451606430000
          2) "5"
       5) 1) (integer) 1451606440000
          2) "5"

example of command with the NOLABELS option

TS.MRANGE - + COUNT 5 NOLABELS FILTER measurement=cpu fieldname=usage_user
1) 1) "cpu_usage_user{948008140}"
    2) (empty array)
    3) 1) 1) (integer) 1451606400000
          2) "8"
       2) 1) (integer) 1451606410000
          2) "7"
       3) 1) (integer) 1451606420000
          2) "6"
       4) 1) (integer) 1451606430000
          2) "5"
       5) 1) (integer) 1451606440000
          2) "5"

@gkorland
Copy link
Contributor Author

Agree

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
2 participants