Barry Fruitman
Barry Fruitman

Reputation: 12664

How do I create a graph of the average value of an log attribute using Datadog?

My mobile app is posting the following log messages to Datadog:

logger.log(
    priority = Log.INFO,
    message = "Jank Report",
    attributes = mapOf(
        "percent_jank" to percentJank, // floating-point number
        "duration_ms" to durationMs    // integer in ms
    )
)

I can see the log entries in Log Explorer. I want to create graphs on my dashboard that display the average percent_jank and duration_ms. I'd also like to create distribution graphs of those values but I have no idea how to reference them on my dashboard.

Can someone please explain or point me at the right docs, or at least tell me if it's even possible?

Upvotes: 2

Views: 149

Answers (1)

Sal
Sal

Reputation: 5693

You can do this by changing the 'measure' from all logs to a specific attribute: all logs measure

DataDog will then allow you to select an aggregation like an average on the attribute: attribute measure

Upvotes: 0

Related Questions