The Wayback Machine - https://web.archive.org/web/20210917222842/https://github.com/crossplane/crossplane/issues/2263
Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Late initialize XRC spec.compositionRef #2263

Open
negz opened this issue Apr 13, 2021 · 0 comments
Open

Late initialize XRC spec.compositionRef #2263

negz opened this issue Apr 13, 2021 · 0 comments

Comments

@negz
Copy link
Member

@negz negz commented Apr 13, 2021

What happened?

A composite resource claim (XRC) is a namespaced proxy for a composite resource (XR). Both types have an almost identical schema. When an XRC is created an XR is typically created in response, and the claim's spec.compositionRef and spec.compositionSelector are propagated to the XR. Currently if you create a claim with only a composition selector, or with neither a reference or a selector (relying on the XRD's default or enforced composition) the claim's composition reference is never updated to reflect the composition selected by the XR.

We mostly "late initialize" a claim from its XR, but when doing so we ignore any fields shared with the XR. This includes the composition reference, selector, etc per

withSrcFilter(xcrd.GetPropFields(xcrd.CompositeResourceSpecProps())...)); err != nil {
.

How can we reproduce it?

Create a claim with a composition selector and no composition reference (e.g. the GCP claim from the Crossplane 1.1 getting started guide) and observe that the XR has its composition reference set, but the claim never does.

What environment did it happen in?

Crossplane version: 1.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant