Many-to-many relation with read-only dependent resource #2423
-
Hi, I have a use case very similar to the PrimaryToSecondaryDependent example. The difference is, however, that in my case a CRD (called Benchmark) refers to a list of ConfigMaps and a ConfigMap can be referred to from multiple Benchmarks. That means when a ConfigMap, for example, changes, 0 to many Benchmarks have to be reconciled. I modified the PrimaryToSecondaryDependent example accordingly, but get the error:
Is this behavior expected? If yes, what would be a possible workaround for this use case? If not, I can also share more details on what I implemented to identify what I did wrong. Thanks in advance! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 7 replies
-
Hi @SoerenHenning , When do you get exactly this error? Pls paste the logs that might be enough. Is it happening from a dependent or you calling Note that if you calling it from reconcile there is simply a version of this method that returns multiple configMaps: |
Beta Was this translation helpful? Give feedback.
Hi I would just not use dependents for now, as it described. Version 5 is not released and not sure when it will be, might be few months there are some decisions around still hanging.
So I would just not use dependents, use the informer from example that triggers the reconciliation, and implement the logic with low level API.