You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently there seems to be no way to specify the logtype for logs originating from containers running on Kubernetes.
Describe the solution you'd like
I would like to be able to set this logtype attribute in the object metadata via Kubernetes API (e.g. something like metadata > annotations > "newrelic.com/logtype" = "nginx").
Describe alternatives you've considered
I do not see any way to achieve the result of parsing structured logs for containers running on Kubernetes with current New Relic capabilities.
To work around a setup a custom parsing in the application ui targeting the containers in kubernetes.
If you going to implement it make sure to ignore the start of the messages because is getting from the docker container and not from kubernetes, all messges get prefixed with a "tiimestamp stdout F ".
In order to parse json I did setup the following:
%{TIMESTAMP_ISO8601:containerTimestamp} stdout F %{GREEDYDATA:message:json}
Is your feature request related to a problem? Please describe.
According to New Relic documentation, a
logtype
attribute can be set on logs in order to parse them in a certain way (e.g. to automatically extract structured information from Nginx logs): https://docs.newrelic.com/docs/logs/log-management/ui-data/logs-parsing-built-rules-custom-parsing#logtypeCurrently there seems to be no way to specify the
logtype
for logs originating from containers running on Kubernetes.Describe the solution you'd like
I would like to be able to set this
logtype
attribute in the object metadata via Kubernetes API (e.g. something likemetadata > annotations > "newrelic.com/logtype" = "nginx"
).Describe alternatives you've considered
I do not see any way to achieve the result of parsing structured logs for containers running on Kubernetes with current New Relic capabilities.
Additional context
Originally asked as a question, but received no reply with a solution that would achieve the desired result: https://discuss.newrelic.com/t/kubernetes-helm-nri-bundle-logtype/120712
This might be somewhat related to #78 (they both are about using Kubernetes object metadata to influence New Relic log ingest behaviour).
The text was updated successfully, but these errors were encountered: