From 29e7f6b396ffc6dcd33241e4d9052285f6a76d48 Mon Sep 17 00:00:00 2001 From: brettj-newrelic <142850040+brettj-newrelic@users.noreply.github.com> Date: Wed, 14 Feb 2024 07:35:36 -0800 Subject: [PATCH] feat: K8s daemonset synthesis from ksm->otel (#1432) --- .../infra-kubernetes_daemonset/definition.yml | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/entity-types/infra-kubernetes_daemonset/definition.yml b/entity-types/infra-kubernetes_daemonset/definition.yml index ef114f1d0..986a98443 100644 --- a/entity-types/infra-kubernetes_daemonset/definition.yml +++ b/entity-types/infra-kubernetes_daemonset/definition.yml @@ -7,3 +7,34 @@ goldenTags: - k8s.daemonsetName - k8s.clusterName - k8s.namespaceName +synthesis: + rules: + # kube-state-metrics data via opentelemetry prometheusReceiver + - compositeIdentifier: + separator: ":" + attributes: + - k8s.cluster.name + - namespace + - daemonset + encodeIdentifierInGUID: true + name: daemonset + conditions: + # kube-state-metrics daemonset prefix + - attribute: metricName + prefix: kube_daemonset_ + # identifier attributes + - attribute: daemonset + present: true + - attribute: namespace + present: true + - attribute: k8s.cluster.name + present: true + # open telemetry + - attribute: newrelic.source + value: 'api.metrics.otlp' + # if service.name is present, it's a service + - attribute: service.name + present: false + # value added for test entities only + - attribute: newrelicOnly + value: "true" \ No newline at end of file