kuberay icon indicating copy to clipboard operation
kuberay copied to clipboard

[Refactor] Move MatchingLabels to association.go

Open rueian opened this issue 1 year ago • 1 comments

Following the PR https://github.com/ray-project/kuberay/pull/1948 and https://github.com/ray-project/kuberay/pull/2023,

We like to move all MatchingLabels to the association.go, so that we can maintain consistency in the association methods by not scattering MatchingLabels everywhere.

This issue is a todo list for tracking refactor progress and collaboration with other contributors.

  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L441
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L476
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L509
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L1252
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L1305
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L1319
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller.go#L1340
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayservice_controller.go#L436
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayservice_controller.go#L1232
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayjob_controller_suspended_test.go#L168
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayjob_controller_suspended_test.go#L181
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/suite_helpers_test.go#L210
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayjob_controller_test.go#L174
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayjob_controller_test.go#L182
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/rayservice_controller_test.go#L250
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller_fake_test.go#L2253
  • [ ] https://github.com/ray-project/kuberay/blob/bbb65b4649f03f9b69554b857da4a4376e721d77/ray-operator/controllers/ray/raycluster_controller_fake_test.go#L2264

@evalaiyc98 is already working on the suite_helpers_test.go part. cc @kevin85421

rueian avatar Mar 26 '24 14:03 rueian

Appendix: Here is a MatchingLabels association diagram I previously figured out. Hope that can help someone who is interested in how CRD controllers associate each CR. associations

rueian avatar Mar 26 '24 14:03 rueian