Skip to content

Add a one-pager regarding controlled rollout of composition functions#6398

Merged
negz merged 2 commits intocrossplane:mainfrom
adamwg:awg/function-revisions-design
May 2, 2025
Merged

Add a one-pager regarding controlled rollout of composition functions#6398
negz merged 2 commits intocrossplane:mainfrom
adamwg:awg/function-revisions-design

Conversation

@adamwg
Copy link
Copy Markdown
Member

@adamwg adamwg commented Apr 22, 2025

Description of your changes

This one-pager proposes two changes that will allow Crossplane users to control rollout of composition function revisions:

  1. Allow multiple function revisions to be active at once, controlled by a new field in the Function resource.
  2. Allow composition pipeline steps to reference a specific function revision.

Toward #6139

I have:

Signed-off-by: Adam Wolfe Gordon <awg@upbound.io>
@adamwg adamwg requested review from a team and negz as code owners April 22, 2025 15:25
@adamwg adamwg requested a review from phisco April 22, 2025 15:25
Copy link
Copy Markdown
Member

@negz negz left a comment

Choose a reason for hiding this comment

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

Thanks @adamwg! I like this approach.

Copy link
Copy Markdown
Member

@jbw976 jbw976 left a comment

Choose a reason for hiding this comment

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

This looks great @adamwg, thanks for the write-up!

I'm getting a bit confused about the UX for using multiple function revisions, so helping me understand that a bit better would be appreciated 🙇‍♂️

Comment on lines +125 to +127
For example, a user wishing to roll out a new version of
`function-patch-and-transform` to only certain XRs may install the function
using the following manifest:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

one thing i didn't quite catch from the description of this scenario is how the user interacts with Function objects to create new revisions. For a given function, the user will only interact with a single Function object, right? i.e. If the user wants multiple revisions, they first create a Function object with .spec.package that points to version 1, then later on they update that same Function object to point to version 2. Along with that update, they would also add this alpha label at the same time. Is that right?

The example here was making me second guess that flow because the way its described here it sounds like to create a new revision/version, the user creates another new Function object - but I don't think that's right 🤔

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Your initial understanding is correct - the user updates the .spec.package (and any labels they want) in the existing object. I've updated the text in the example to clarify that.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Awesome, thank you for making that workflow more clear here!

@negz
Copy link
Copy Markdown
Member

negz commented Apr 28, 2025

@adamwg would this interact negatively with #4662? At a glance I don't think it would.

@adamwg
Copy link
Copy Markdown
Member Author

adamwg commented Apr 28, 2025

@adamwg would this interact negatively with #4662? At a glance I don't think it would.

Agreed, I don't see any negative interaction. #4662 proposes another way to select composition revisions; with the change proposed in this PR those composition revisions may select function revisions, but there's no change to how composition revisions are selected.

Signed-off-by: Adam Wolfe Gordon <awg@upbound.io>
@adamwg adamwg force-pushed the awg/function-revisions-design branch from 9c802d1 to 5681480 Compare April 28, 2025 19:20
@adamwg
Copy link
Copy Markdown
Member Author

adamwg commented Apr 28, 2025

Force pushed to pass the DCO check.

@adamwg adamwg mentioned this pull request May 1, 2025
6 tasks
@negz negz merged commit 3c27d58 into crossplane:main May 2, 2025
15 of 17 checks passed
@negz negz mentioned this pull request May 6, 2025
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants