Hello everyone,
I am trying to use the Datadog metric plugin for logstash. I have configured it to use a CSV file as an input and then perform the parse with grok. Unfortately I am not able to take these metrics and push them to Datadog using the community supported Datadog metrics plugin.
I would apprecaite any help to get this off the ground.
Thanks!
My logstash file
input {
file {
path => "/opt/server_counters.log.csv"
type => "csv"
}
}
filter {
if [type] == "csv" {
csv {
remove_field => ["message"]
columns => [
"log_timestamp",
"CPU",
"Usage",
"Threads",
"File Descriptors",
"RSS Virtual Bytes",
"Available Bytes",
"Broker Memory Usage",
"Broker Store Usage",
"Total Messages Enqueued",
"Total Messages Dequeued",
"Number of Pending Messages",
"Number of Queues",
"Number of Topics",
"Total CPU Usage",
"Process - IO Read Operations/sec",
"Process - IO Write Operations/sec",
"Disk Stats - Reads Completed Successfully/sec",
"Disk Stats - Writes Completed Successfully/sec",
"App Allocated Bytes",
"Allocator Sys Bytes",
"Allocator Available Bytes",
"Allocator Thread Caches Bytes"
]
convert => {
"CPU" => "float"
"Usage" => "float"
"Threads" => "float"
"File Descriptors" => "float"
"RSS Virtual Bytes" => "float"
"Available Bytes" => "float"
"Broker Memory Usage" => "float"
"Broker Store Usage" => "float"
"Total Messages Enqueued" => "float"
"Total Messages Dequeued" => "float"
"Number of Pending Messages" => "float"
"Number of Queues" => "float"
"Number of Topics" => "float"
"Total CPU Usage" => "float"
"Process - IO Read Operations/sec" => "float"
"Process - IO Write Operations/sec" => "float"
"Disk Stats - Reads Completed Successfully/sec" => "float"
"Disk Stats - Writes Completed Successfully/sec" => "float"
"App Allocated Bytes" => "float"
"Allocator Sys Bytes" => "float"
"Allocator Available Bytes" => "float"
"Allocator Thread Caches Bytes" => "float"
}
}
}
}
output {
datadog_metrics {
api_key => "my-api-key"
metric_name => "metric-name"
metric_type => "gauge"
metric_value => "metric value"
timeframe => 1
}
}