This product is not supported for your selected
Datadog site. (
).
Overview
This processor parses the specified JSON field into objects. For example, if you have a message field that contains stringified JSON:
{
"foo": "bar",
"team": "my-team",
"message": "{\"level\":\"info\",\"timestamp\":\"2024-01-15T10:30:00Z\",\"service\":\"user-service\",\"user_id\":\"12345\",\"action\":\"login\",\"success\":true,\"ip_address\":\"192.168.1.100\"}"
"app_id":"streaming-services",
"ddtags": [
"kube_service:my-service",
"k8_deployment :your-host"
]
}
Use the Parse JSON processor to parse the message field so the message field has all the attributes within a nested object.
This output contains the message field with the parsed JSON:
{
"foo": "bar",
"team": "my-team",
"message": {
"action": "login",
"ip_address": "192.168.1.100",
"level": "info",
"service": "user-service",
"success": true,
"timestamp": "2024-01-15T10:30:00Z",
"user_id": "12345"
}
"app_id":"streaming-services",
"ddtags": [
"kube_service:my-service",
"k8_deployment :your-host"
]
}
Setup
To set up this processor:
- Define a filter query. Only logs that match the specified filter query are processed. All logs, regardless of whether they do or do not match the filter query, are sent to the next step in the pipeline. See Search Syntax for more information.
- Enter the name of the field you want to parse JSON on.
Note: The parsed JSON overwrites what was originally contained in the field.
Further reading
Additional helpful documentation, links, and articles: