[Add] Propagate labels from NB to StatefulSets#646
[Add] Propagate labels from NB to StatefulSets#646jstourac merged 2 commits intoopendatahub-io:mainfrom
Conversation
|
Skipping CI for Draft Pull Request. |
WalkthroughThe changes update the notebook controller to ensure that all labels from a Notebook resource are copied to the corresponding StatefulSet's metadata. The associated test is updated to include a custom label and asserts that the StatefulSet's labels match those of the Notebook. Changes
Suggested labels
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (2)
🧰 Additional context used🧠 Learnings (3)📓 Common learningscomponents/notebook-controller/controllers/notebook_controller_bdd_test.go (3)components/notebook-controller/controllers/notebook_controller.go (3)⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🔇 Additional comments (5)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #646 +/- ##
===========================================
- Coverage 57.47% 35.09% -22.38%
===========================================
Files 11 2 -9
Lines 3071 966 -2105
===========================================
- Hits 1765 339 -1426
+ Misses 1136 586 -550
+ Partials 170 41 -129 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
This commit propagates labels from Notebooks to statefulsets. This is required to enable NBs to be managed by Kueue. When a user adds the label to point a NB to the right LocalQueue where it needs to be admitted, it needs to propagate to the underlying StatefulSet, so that Kueue can manage it. Signed-off-by: Varsha Prasad Narsing <varshaprasad96@gmail.com> (cherry picked from commit f6abf13)
|
/lgtm |
|
@varshaprasad96 can you please review this? we're cherry-picking your change that you've originally proposed in kubeflow notebooks controller upstream repo |
varshaprasad96
left a comment
There was a problem hiding this comment.
@jiridanek the last I tested this change in NBs, it worked as intended to get labels into the pods from SS for Kueue to pickup. So looks good from my end.
/lgtm
I'm not super familiar with the latest changes that may have been made in NB controller implementation, so probably someone from that team can verify it again. But all good from my end.
|
@varshaprasad96 do you recall whether you just tested the labels propagation or also whether the kueue integration works as expected with such change? |
|
/lgtm |
harshad16
left a comment
There was a problem hiding this comment.
/lgtm
/approve
Thanks for the work 💯
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: harshad16, varshaprasad96 The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
This patch seems to not have been applied to kubeflow upstream. I created kubeflow/notebooks#788 so that others could benefit from this. Please let me know if this is no longer valid anymore. I don't follow the notebook development at all. |




This commit propagates labels from Notebooks to statefulsets. This is required to enable NBs to be managed by Kueue. When a user adds the label to point a NB to the right LocalQueue where it needs to be admitted, it needs to propagate to the underlying StatefulSet, so that Kueue can manage it.
(cherry picked from commit f6abf13) --- kubeflow#7674
https://issues.redhat.com/browse/RHOAIENG-28544
How Has This Been Tested?
I created a very simple test to the existing bdd ginkgo suite.
Regarding the manual testing I did:
rhods-operatordeployment to 0I haven't performed any actual functional checks with the kueue yet.
Merge criteria:
Summary by CodeRabbit
Bug Fixes
Tests