Skip to content

Attached resource changes were not synchronized to the cluster in dependencies distributor #6924

@XiShanYongYe-Chang

Description

@XiShanYongYe-Chang

What happened:

In the dependency distributor scenario, workload resources depend on multiple resources of the same kind. When one of these resources changes, there may be a case of unsynchronization.

For example, a deployment depends on two ConfigMap resources, cm-01 and cm-02. After the user modifies cm-02, Karmada does not synchronize this change to the member clusters.

What you expected to happen:

Resource changes can be properly synchronized to the member cluster.

How to reproduce it (as minimally and precisely as possible):

As the example suggests, multiple tests can be conducted.

Anything else we need to know?:

In current logic, when a name mismatch is detected, it returns directly instead of continuing:

if resourceTemplateKey.GroupVersion().String() == dependency.APIVersion &&
resourceTemplateKey.Kind == dependency.Kind &&
resourceTemplateKey.Namespace == dependency.Namespace {
if len(dependency.Name) != 0 {
return dependency.Name == resourceTemplateKey.Name
}

Environment:

  • Karmada version:
  • kubectl-karmada or karmadactl version (the result of kubectl-karmada version or karmadactl version):
  • Others:

Metadata

Metadata

Labels

kind/bugCategorizes issue or PR as related to a bug.

Type

No type

Projects

Status

No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions