Skip to content
This repository has been archived by the owner on Aug 28, 2024. It is now read-only.

Child Resources having no owner references are created more than once #489

Closed
wants to merge 1 commit into from

Conversation

neowulf
Copy link

@neowulf neowulf commented Mar 4, 2024

fixes #488

@neowulf neowulf marked this pull request as draft March 4, 2024 20:18
@neowulf neowulf marked this pull request as ready for review March 4, 2024 20:19
Copy link

codecov bot commented Mar 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 61.06%. Comparing base (ae28210) to head (47cb73d).
Report is 3 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #489      +/-   ##
==========================================
+ Coverage   60.87%   61.06%   +0.18%     
==========================================
  Files          26       27       +1     
  Lines        2546     2558      +12     
==========================================
+ Hits         1550     1562      +12     
  Misses        909      909              
  Partials       87       87              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@neowulf neowulf marked this pull request as draft March 4, 2024 20:20
client.InNamespace(resource.GetNamespace()),
opts := []client.ListOption{}
if !r.SkipOwnerReference {
opts = append(opts, client.InNamespace(resource.GetNamespace()))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OwnerRefs do not work across namespaces. However, skipping an owner reference doesn't mean I dont want children in the same namespace.

I think you should just set the list options you want in special cases.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i see, thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Issues related to Child Resources having no owner references
3 participants