Metrics-curl.rb output not sent to influxdb?

My check looks like this:

---
type: CheckConfig
api_version: core/v2
metadata:
  name: metrics
spec:
  command: "metrics-curl.rb -u https://thesite.com"
  proxy_entity_name: thesite.com
  round_robin: true
  publish: true
  interval: 30
  handlers:
  - plivo
  runtime_assets:
  - sensu-plugins/sensu-plugins-http
  - sensu/sensu-ruby-runtime
  subscriptions:
  - proxy
  output_metric_format: nagios_perfdata
  output_metric_handlers:
  - influxdb

I see what appear to be metrics in the event list:

  thesite.com   thesite-metrics         dc2e6cb14e16.curl_timings.time_total 0.179716 1578949159                                                                                            0   false      2020-01-13 12:59:19 -0800 PST  
                                          dc2e6cb14e16.curl_timings.time_namelookup 0.008926 1578949159                                                                                                                                     
                                          dc2e6cb14e16.curl_timings.time_connect 0.019085 1578949159                                                                                                                                        
                                          dc2e6cb14e16.curl_timings.time_pretransfer 0.088613 1578949159                                                                                                                                    
                                          dc2e6cb14e16.curl_timings.time_redirect 0.000000 1578949159                                                                                                                                       
                                          dc2e6cb14e16.curl_timings.time_starttransfer 0.169122 1578949159                                                                                                                                  
                                          dc2e6cb14e16.curl_timings.http_code 200 1578949159                                                                                                                                                

but no data in influxdb. i have other checks using sensu/monotoring-plugins that are able to output metrics to influx, so the handler seems to be working correctly. Why isn’t this working?

you have the metric format set wrong.
that looks like graphite_plaintext to me not nagios_perfdata

https://docs.sensu.io/sensu-go/latest/guides/extract-metrics-with-checks/#supported-output-metric-formats

lol. Was just going to post about that and/or delete the post. looks like it should be graphite_plaintext.

Hey I have one more question about the influxdb handler.

Is there a way to name the measurement that’s created? It seems to be a randomized string.

Since I’m running dockerized, my queries all break when I restart the db and it creates a new measurement name. I have to go in and update all the queries to use the new string. It would be cool if I could specify that… somewhere.

its actual the check that is naming the measurements. In in the case of that check… its using the hostname of the running agent by default.

The -s scheme option lets you replace the prefix with anything you want.

using that option and then using token substitution refering to Sensu Agent labels/annotations you can make a reusable check that uses the scheme from the agent config.