Skip to content

fix: make apm config a pointer#2995

Merged
betterengineering merged 1 commit into
mainfrom
mark.spicer/make-apm-pointer
May 8, 2026
Merged

fix: make apm config a pointer#2995
betterengineering merged 1 commit into
mainfrom
mark.spicer/make-apm-pointer

Conversation

@betterengineering

Copy link
Copy Markdown
Member

What does this PR do?

This commit makes the APM configuration a pointer so that we can properly nil check it in the handler.

Motivation

In the Datadog Agent, we want the handler for this config to look like:

func (h *SingleStepHandler) HasSection(cr *datadoghq.DatadogInstrumentation) bool {
	return cr != nil && cr.Spec.Config.APM != nil
}

We can't currently nil check it because it's not a pointer 🤦 .

Describe your test plan

I made sure the generation works as expected:

make generate manifests

Checklist

  • PR has at least one valid label: bug, enhancement, refactoring, documentation, tooling, and/or dependencies
  • PR has a milestone or the qa/skip-qa label
  • All commits are signed (see: signing commits)

This commit makes the APM configuration a pointer so that we can
properly nil check it in the handler.
@datadog-datadog-prod-us1-2

This comment has been minimized.

@codecov-commenter

codecov-commenter commented May 8, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 40.76%. Comparing base (4d64420) to head (384624a).

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##             main    #2995   +/-   ##
=======================================
  Coverage   40.76%   40.76%           
=======================================
  Files         332      332           
  Lines       28197    28197           
=======================================
  Hits        11494    11494           
  Misses      15928    15928           
  Partials      775      775           
Flag Coverage Δ
unittests 40.76% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4d64420...384624a. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@betterengineering
betterengineering merged commit 6416ca2 into main May 8, 2026
63 of 64 checks passed
@betterengineering
betterengineering deleted the mark.spicer/make-apm-pointer branch May 8, 2026 20:25
Mathew-Estafanous added a commit that referenced this pull request May 14, 2026
gh-worker-dd-mergequeue-cf854d Bot pushed a commit that referenced this pull request May 14, 2026
Revert "fix: make apm config a pointer (#2995)"

This reverts commit 6416ca2.

Revert "feat: Add APM to DatadogInstrumentation CRD (#2984)"

This reverts commit d97a3dc.

Co-authored-by: mathew.estafanous <[email protected]>
Mathew-Estafanous added a commit that referenced this pull request May 14, 2026
…3017)

Revert "fix: make apm config a pointer (#2995)"

This reverts commit 6416ca2.

Revert "feat: Add APM to DatadogInstrumentation CRD (#2984)"

This reverts commit d97a3dc.

Co-authored-by: mathew.estafanous <[email protected]>

(cherry picked from commit 6d3740a)
tbavelier pushed a commit that referenced this pull request May 20, 2026
Revert "fix: make apm config a pointer (#2995)"

This reverts commit 6416ca2.

Revert "feat: Add APM to DatadogInstrumentation CRD (#2984)"

This reverts commit d97a3dc.

Co-authored-by: mathew.estafanous <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants