From f27be626dcfb43a1be5441ab9bb50aba330114eb Mon Sep 17 00:00:00 2001 From: Nikita Tkachenko Date: Mon, 6 May 2024 09:45:45 +0200 Subject: [PATCH] Fix log spamming for builds that do not have upstream parent --- .../jenkins/plugins/datadog/listeners/DatadogBuildListener.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/datadog/jenkins/plugins/datadog/listeners/DatadogBuildListener.java b/src/main/java/org/datadog/jenkins/plugins/datadog/listeners/DatadogBuildListener.java index ff8b16b7..c67b13ee 100644 --- a/src/main/java/org/datadog/jenkins/plugins/datadog/listeners/DatadogBuildListener.java +++ b/src/main/java/org/datadog/jenkins/plugins/datadog/listeners/DatadogBuildListener.java @@ -119,7 +119,7 @@ public void onInitialize(Run run) { BuildSpanManager.get().put(buildData.getBuildTag(""), buildSpanContext); TraceSpan.TraceSpanContext upstreamBuildSpanContext = null; - String upstreamBuildTag = buildData.getUpstreamBuildTag(""); + String upstreamBuildTag = buildData.getUpstreamBuildTag(null); if (upstreamBuildTag != null) { // try to find upstream build context saved earlier upstreamBuildSpanContext = BuildSpanManager.get().get(upstreamBuildTag);