Skip to content

Add documentation for MRDs, MRAPs, and safe-start #964

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

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

negz
Copy link
Member

@negz negz commented Aug 8, 2025

Closes #958

Large Crossplane providers install hundreds of CRDs consuming significant API server resources, even when users only need a few resource types. The new alpha ManagedResourceDefinition (MRD) and ManagedResourceActivationPolicy
(MRAP) features in Crossplane v2.0+ solve this by enabling selective activation of provider resources, but lack user-facing documentation.

This change adds complete documentation covering both concepts and practical implementation. The MRD concepts page explains the CRD scaling problem and selective activation approach. The MRAP concepts page details pattern-based activation strategies and multiple policy coordination. Two how-to guides provide end-to-end workflows: one for users wanting to reduce CRD overhead through selective activation, and another for provider developers implementing
safe-start capability. The user guide was tested with simulated MRDs to verify the activation workflow and troubleshooting steps.

Copy link

netlify bot commented Aug 8, 2025

Deploy Preview for crossplane ready!

Name Link
🔨 Latest commit a8176fb
🔍 Latest deploy log https://app.netlify.com/projects/crossplane/deploys/689a52de94755f00087ba1a0
😎 Deploy Preview https://deploy-preview-964--crossplane.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 78 (🔴 down 1 from production)
Accessibility: 90 (🔴 down 2 from production)
Best Practices: 83 (no change from production)
SEO: 100 (no change from production)
PWA: 70 (no change from production)
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

@negz negz force-pushed the emm-arr-dee branch 21 times, most recently from d5ba59e to 94f0d80 Compare August 9, 2025 05:51
Same for CronOperation. This matches the established pattern.

Signed-off-by: Nic Cope <[email protected]>
@negz negz force-pushed the emm-arr-dee branch 3 times, most recently from 9018335 to 4150774 Compare August 9, 2025 06:18
@negz negz changed the title WIP: First pass at MRD/MRAP docs Add documentation for MRDs, MRAPs, and safe-start Aug 9, 2025
@negz negz marked this pull request as ready for review August 9, 2025 06:30
Large Crossplane providers install hundreds of CRDs consuming significant API
server resources, even when users only need a few resource types. The new
alpha ManagedResourceDefinition (MRD) and ManagedResourceActivationPolicy
(MRAP) features in Crossplane v2.0+ solve this by enabling selective
activation of provider resources, but lack user-facing documentation.

This change adds complete documentation covering both concepts and practical
implementation. The MRD concepts page explains the CRD scaling problem and
selective activation approach. The MRAP concepts page details pattern-based
activation strategies and multiple policy coordination. Two how-to guides
provide end-to-end workflows: one for users wanting to reduce CRD overhead
through selective activation, and another for provider developers implementing
safe-start capability. The user guide was tested with simulated MRDs to verify
the activation workflow and troubleshooting steps.

Signed-off-by: Nic Cope <[email protected]>
negz added 3 commits August 11, 2025 13:02
Without the quote it renders like a comment for some reason.

Signed-off-by: Nic Cope <[email protected]>
Copy link
Collaborator

@tr0njavolta tr0njavolta left a comment

Choose a reason for hiding this comment

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

Mostly consistency in formatting. Not sure about the formatting for "safe-start" if it's a component that needs proper noun-ing or wrapping in backticks.

{{</hint>}}

A `ManagedResourceDefinition` (MRD) is a lightweight abstraction over
Kubernetes CustomResourceDefinitions (CRDs) that enables selective activation of
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
Kubernetes CustomResourceDefinitions (CRDs) that enables selective activation of
Kubernetes `CustomResourceDefinitions` (CRDs) that enables selective activation of

<!-- vale Microsoft.HeadingAcronyms = YES -->
<!-- vale Google.Headings = YES -->

MRAPs contain activation patterns that match ManagedResourceDefinition names.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
MRAPs contain activation patterns that match ManagedResourceDefinition names.
MRAPs contain activation patterns that match `ManagedResourceDefinition` names.

supported, consuming unnecessary cluster resources.

MRAPs solve this by providing pattern-based activation of
ManagedResourceDefinitions, letting you choose which provider resources to
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
ManagedResourceDefinitions, letting you choose which provider resources to
`ManagedResourceDefinitions`, letting you choose which provider resources to

Comment on lines +19 to +25
Large Crossplane providers can install 100+ managed resource CRDs, consuming
significant cluster resources even when you only need one or two resource
types. This guide shows how to use
[ManagedResourceDefinitions]({{<ref "../managed-resources/managed-resource-definitions">}})
and
[ManagedResourceActivationPolicies]({{<ref "../managed-resources/managed-resource-activation-policies">}})
to install only the provider resources you actually need.
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
Large Crossplane providers can install 100+ managed resource CRDs, consuming
significant cluster resources even when you only need one or two resource
types. This guide shows how to use
[ManagedResourceDefinitions]({{<ref "../managed-resources/managed-resource-definitions">}})
and
[ManagedResourceActivationPolicies]({{<ref "../managed-resources/managed-resource-activation-policies">}})
to install only the provider resources you actually need.
Large Crossplane providers can install 100+ managed resource CRDs, consuming
significant cluster resources even when you only need one or two resource
types. This guide shows how to use
[`ManagedResourceDefinitions`]({{<ref "../managed-resources/managed-resource-definitions">}})
and
[`ManagedResourceActivationPolicies`]({{<ref "../managed-resources/managed-resource-activation-policies">}})
to install only the provider resources you actually need.

- Basic familiarity with Kubernetes and Crossplane concepts

{{<hint "important">}}
ManagedResourceDefinitions and ManagedResourceActivationPolicies are alpha
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
ManagedResourceDefinitions and ManagedResourceActivationPolicies are alpha
`ManagedResourceDefinitions` and `ManagedResourceActivationPolicies` are alpha


## What safe-start provides

safe-start changes how your provider handles CRD installation:
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
safe-start changes how your provider handles CRD installation:
Safe-start changes how your provider handles CRD installation:

or safe-start? Not sure, but I didn't add suggestions for the other instances.

- Higher memory usage and API server load

**With safe-start:**
- Providers create ManagedResourceDefinitions but CRDs only when activated
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
- Providers create ManagedResourceDefinitions but CRDs only when activated
- Providers create `ManagedResourceDefinitions` but CRDs only when activated


**With safe-start:**
- Providers create ManagedResourceDefinitions but CRDs only when activated
- Users activate only needed resources through ManagedResourceActivationPolicies
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
- Users activate only needed resources through ManagedResourceActivationPolicies
- Users activate only needed resources through `ManagedResourceActivationPolicies`


- Provider built with crossplane-runtime v2.0+
- Understanding of
[ManagedResourceDefinitions]({{<ref "../managed-resources/managed-resource-definitions">}})
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
[ManagedResourceDefinitions]({{<ref "../managed-resources/managed-resource-definitions">}})
[`ManagedResourceDefinitions`]({{<ref "../managed-resources/managed-resource-definitions">}})


### Step 2: Add required imports

Update your main.go imports (see
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
Update your main.go imports (see
Update your `main.go` imports (see

---

This guide shows provider developers how to implement safe-start capability in
their Crossplane providers. safe-start enables
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
their Crossplane providers. safe-start enables
their Crossplane providers. `safe-start` enables

or Safe-start?

@negz
Copy link
Member Author

negz commented Aug 12, 2025

Mostly consistency in formatting

I just chatted to @tr0njavolta on Slack and they don't feel strongly about the formatting changes. We're pretty inconsistent and I lean these days toward not using the backticks as much (e.g. see the Operations docs), so I'd prefer to avoid reformatting.

I think separately we should probably agree on a style for this and do a pass over the whole docs.

@tr0njavolta tr0njavolta self-requested a review August 12, 2025 00:54
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.

2 participants