Skip to content
This repository has been archived by the owner on Apr 25, 2023. It is now read-only.

KubeFed controller crash when meeting negative array index in overrides #1466

Closed
zqzten opened this issue Oct 27, 2021 · 1 comment · Fixed by #1467
Closed

KubeFed controller crash when meeting negative array index in overrides #1466

zqzten opened this issue Oct 27, 2021 · 1 comment · Fixed by #1467
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@zqzten
Copy link
Contributor

zqzten commented Oct 27, 2021

What happened:
When we use negative array index in overrides of one federated object as below, KubeFed controller panicked and crashed when reconciling that object.

...
spec:
  overrides:
  - clusterName: foo
    clusterOverrides:
    - op: replace
      path: /spec/somearray/-1
      value: bar
...

What you expected to happen:
KubeFed controller applies that override correctly as evanphx/json-patch#123 does.

/kind bug

@k8s-ci-robot k8s-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Oct 27, 2021
@zqzten
Copy link
Contributor Author

zqzten commented Oct 27, 2021

/assign

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants