Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(controller): deprecation of propagation controller #788

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

gciezkowski-acc
Copy link
Contributor

@gciezkowski-acc gciezkowski-acc commented Nov 28, 2024

Description

The Propagation Controller is deprecated, so right now we need only clean up and remove finalizer.
The tests have not been written so we should focus to make very carefully code review.

What type of PR is this? (check all applicable)

  • 🍕 Feature
  • 🐛 Bug Fix
  • 📝 Documentation Update
  • 🎨 Style
  • 🧑‍💻 Code Refactor
  • 🔥 Performance Improvements
  • ✅ Test
  • 🤖 Build
  • 🔁 CI
  • 📦 Chore (Release)
  • ⏩ Revert

Related Tickets & Documents

Added tests?

  • 👍 yes
  • 🙅 no, because they aren't needed
  • 🙋 no, because I need help
  • Separate ticket for tests # (issue/pr)

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration

Added to documentation?

  • 📜 README.md
  • 🤝 Documentation pages updated
  • 🙅 no documentation needed
  • (if applicable) generated OpenAPI docs for CRD changes

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • My changes generate no new warnings
  • New and existing unit tests pass locally with my changes

@gciezkowski-acc gciezkowski-acc changed the title feat(controllers) Deprecation of propagation controller (#777) feat(controllers): Deprecation of propagation controller Nov 28, 2024
@gciezkowski-acc gciezkowski-acc changed the title feat(controllers): Deprecation of propagation controller feat(controller): Deprecation of propagation controller Nov 28, 2024
@gciezkowski-acc gciezkowski-acc changed the title feat(controller): Deprecation of propagation controller feat(controllers): deprecation of propagation controller Nov 28, 2024
@gciezkowski-acc gciezkowski-acc force-pushed the feat/777_deprecation_of_propagated_controller branch from 7a7cf77 to 586bc88 Compare November 28, 2024 15:01
@gciezkowski-acc gciezkowski-acc changed the title feat(controllers): deprecation of propagation controller feat(controller): deprecation of propagation controller Nov 28, 2024
@gciezkowski-acc gciezkowski-acc force-pushed the feat/777_deprecation_of_propagated_controller branch 2 times, most recently from bbe6d6f to 9616539 Compare November 29, 2024 12:24
@gciezkowski-acc gciezkowski-acc marked this pull request as ready for review November 29, 2024 13:02
@gciezkowski-acc gciezkowski-acc requested a review from a team as a code owner November 29, 2024 13:02
@gciezkowski-acc gciezkowski-acc force-pushed the feat/777_deprecation_of_propagated_controller branch from 9616539 to f5d8e3d Compare December 2, 2024 09:19
Copy link
Contributor

@IvoGoman IvoGoman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The logic for removing the resources from the remote system and the finalizer on successful deletion is missing.

@gciezkowski-acc
Copy link
Contributor Author

The logic for removing the resources from the remote system and the finalizer on successful deletion is missing

The logic of removing resources from remote is here. I didn't touch it.
/https://github.com/cloudoperators/greenhouse/pull/788/files#diff-ad100e6e1bfb9a5e365411f8a9ba2f40784c2f224474b80754b0199aab201df9R125-R138:~:text=%7D-,//%20cleanup,%7D,-remoteObjectResource%2C%20err

Removing finalizer when it is success is here:
https://github.com/cloudoperators/greenhouse/pull/788/files#diff-ad100e6e1bfb9a5e365411f8a9ba2f40784c2f224474b80754b0199aab201df9L106-L110:~:text=%7D-,if%20removeFinalizer%20%7B,%7D,-return%20ctrl.

I left the existing logic as it was.

@IvoGoman
Copy link
Contributor

IvoGoman commented Dec 5, 2024

The logic for removing the resources from the remote system and the finalizer on successful deletion is missing

The logic of removing resources from remote is here. I didn't touch it. /https://github.com/cloudoperators/greenhouse/pull/788/files#diff-ad100e6e1bfb9a5e365411f8a9ba2f40784c2f224474b80754b0199aab201df9R125-R138:~:text=%7D-,//%20cleanup,%7D,-remoteObjectResource%2C%20err

Removing finalizer when it is success is here: https://github.com/cloudoperators/greenhouse/pull/788/files#diff-ad100e6e1bfb9a5e365411f8a9ba2f40784c2f224474b80754b0199aab201df9L106-L110:~:text=%7D-,if%20removeFinalizer%20%7B,%7D,-return%20ctrl.

I left the existing logic as it was.

That logic only kicks in if the resource (team, cluster etc.) in the central cluster is deleted. This PR should remove all propagated resources from the remote cluster.

This would require to run the deletion logic to remove the resources from the remote cluster and remove the finalizer if all of the resoruces were removed from the remote cluster.

@gciezkowski-acc
Copy link
Contributor Author

The logic for removing the resources from the remote system and the finalizer on successful deletion is missing

The logic of removing resources from remote is here. I didn't touch it. /https://github.com/cloudoperators/greenhouse/pull/788/files#diff-ad100e6e1bfb9a5e365411f8a9ba2f40784c2f224474b80754b0199aab201df9R125-R138:~:text=%7D-,//%20cleanup,%7D,-remoteObjectResource%2C%20err
Removing finalizer when it is success is here: https://github.com/cloudoperators/greenhouse/pull/788/files#diff-ad100e6e1bfb9a5e365411f8a9ba2f40784c2f224474b80754b0199aab201df9L106-L110:~:text=%7D-,if%20removeFinalizer%20%7B,%7D,-return%20ctrl.
I left the existing logic as it was.

That logic only kicks in if the resource (team, cluster etc.) in the central cluster is deleted. This PR should remove all propagated resources from the remote cluster.

This would require to run the deletion logic to remove the resources from the remote cluster and remove the finalizer if all of the resoruces were removed from the remote cluster.

I remove filter from login so right now it should remove all resources from remote cluster.

@gciezkowski-acc gciezkowski-acc force-pushed the feat/777_deprecation_of_propagated_controller branch from 1c91145 to 2f514f6 Compare December 19, 2024 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants