Skip to content

Commit 21b4e92

Browse files
authored
Merge pull request #82517 from adellape/object_ownership
OSDOCS#11115: Add OLMv1 object ownership docs
2 parents 52d2f5a + e8f700f commit 21b4e92

File tree

2 files changed

+51
-0
lines changed

2 files changed

+51
-0
lines changed

extensions/arch/operator-controller.adoc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,5 @@ include::modules/olmv1-clusterextension-api.adoc[leveloffset=+1]
1818
* xref:../../operators/understanding/olm/olm-colocation.adoc#olm-colocation[Operator Lifecycle Manager (OLM) -> Multitenancy and Operator colocation]
1919
2020
include::modules/olmv1-about-target-versions.adoc[leveloffset=+2]
21+
22+
include::modules/olmv1-object-ownership.adoc[leveloffset=+1]

modules/olmv1-object-ownership.adoc

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * extensions/arch/operator-controller.adoc
4+
5+
:_mod-docs-content-type: CONCEPT
6+
7+
[id="olmv1-object-ownership_{context}"]
8+
= Object ownership for cluster extensions
9+
10+
In {olmv1-first}, a Kubernetes object can only be owned by a single `ClusterExtension` object at a time. This ensures that objects within an {product-title} cluster are managed consistently and prevents conflicts between multiple cluster extensions attempting to control the same object.
11+
12+
[id="olmv1-single-ownership_{context}"]
13+
== Single ownership
14+
15+
The core ownership principle enforced by {olmv1} is that each object can only have one cluster extension as its owner. This prevents overlapping or conflicting management by multiple cluster extensions, ensuring that each object is uniquely associated with only one bundle.
16+
17+
.Implications of single ownership
18+
19+
* Bundles that provide a `CustomResourceDefinition` (CRD) object can only be installed once.
20+
+
21+
Bundles provide CRDs, which are part of a `ClusterExtension` object. This means you can install a bundle only once in a cluster. Attempting to install another bundle that provides the same CRD results in failure, as each custom resource can have only one cluster extension as its owner.
22+
23+
* Cluster extensions cannot share objects.
24+
+
25+
The single-owner policy of {olmv1} means that cluster extensions cannot share ownership of any objects. If one cluster extension manages a specific object, such as a `Deployment`, `CustomResourceDefinition`, or `Service` object, another cluster extension cannot claim ownership of the same object. Any attempt to do so is blocked by {olmv1}.
26+
27+
[id="olmv1-error-messages_{context}"]
28+
== Error messages
29+
30+
When a conflict occurs due to multiple cluster extensions attempting to manage the same object, Operator Controller returns an error message indicating the ownership conflict, such as the following:
31+
32+
.Example error message
33+
[source,text]
34+
----
35+
CustomResourceDefinition 'logfilemetricexporters.logging.kubernetes.io' already exists in namespace 'kubernetes-logging' and cannot be managed by operator-controller
36+
----
37+
38+
This error message signals that the object is already being managed by another cluster extension and cannot be reassigned or shared.
39+
40+
[id="olmv1-ownership-considerations_{context}"]
41+
== Considerations
42+
43+
As a cluster or extension administrator, review the following considerations:
44+
45+
Uniqueness of bundles::
46+
Ensure that Operator bundles providing the same CRDs are not installed more than once. This can prevent potential installation failures due to ownership conflicts.
47+
48+
Avoid object sharing::
49+
If you need different cluster extensions to interact with similar resources, ensure they are managing separate objects. Cluster extensions cannot jointly manage the same object due to the single-owner enforcement.

0 commit comments

Comments
 (0)