0

We are getting metrics details by the below command:

curl --insecure --cacert ca.crt -H "Authorization: Bearer 2XwxlTO_ls_HqpwTe5OWhGwuTu5qEzFxVGIhe761V7A" -H "Hawkular-Tenant: openshift-infra" -X GET https://hawkular-metrics.example.com/hawkular/metrics/metrics

We do not get data using below command:

curl --insecure --cacert ca.crt -H "Authorization: Bearer 2XwxlTO_ls_HqpwTe5OWhGwuTu5qEzFxVGIhe761V7A" -H "Hawkular-Tenant: openshift-infra" -X GET https://hawkular-metrics.example.com/hawkular/metrics/counter/data?tags=descrpitor_name:cpu/usage,pod_name:hawkular-cassandra

we are getting below error:

"errorMsg":"RESTEASY003210: Could not find resource for full path: https://hawkular-metrics.example.com/hawkular/metrics/counter"

JOY
  • 53
  • 1
  • 1
  • 9

1 Answers1

0

I think you mistyped the URL, there's a s at counters. See the doc: http://www.hawkular.org/docs/rest/rest-metrics.html#GET__counters_data

By the way I think you will have to provide at least buckets or bucketDuration parameter to your query, else you'll get another error.

Joel
  • 2,374
  • 17
  • 26
  • now I am getting below error: errorMsg":"Either the buckets or bucketDuration parameter must be used my query was curl --insecure --cacert ca.crt -H "Authorization: Bearer wL3srMiStrFfz_9LhweEbcZWhwKb4mUV8afjAXbSzog" -H "Hawkular-tenant: openshift-infra" -X GET https://hawkular-metrics.example.com/hawkular/metrics/counters/data?tags=descriptor_name:cpu/usage,pod_name:registry-console&stacked=true&buckets=3&start='date -d -10minutes +%s%3N' – JOY Jun 18 '18 at 12:28