-
Notifications
You must be signed in to change notification settings - Fork 64
add default quota to AW #396
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
Conversation
What is not clear from this PR how are "default" quota contexts going to be handled? Where do you intend to add the default values and what are those default values? As this PR stands now, it seems incomplete. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The PR is missing the logic for handling default
quota tree nodes and the logic for adding default labels should simplified.
After a conversation with @tardieu, I understand what will need to happen to have the "default" quota tree nodes. The only outstanding objection is symplication of the logic |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR. Please see suggested for the more general design.
… is a label associated with every quota-sub-tree for the AppWrapper; if there is none, then it adds it with 'default' value. This way, AppWrappers submitted without labels can be dispatched using the quota management library. Added tests for this, and fixed 'quota_service' sub tree to have a 'default' node. This code assumes the quota administrator created a leaf node name 'default' that can be used to schedule AppWrappers without quota labels.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made the changes to the logic @z103cb requested as well as implementing the behavior discussed with @tardieu (and some of the suggestions by @dmatch01). @z103cb you are the gatekeeper right now, so we'll wait for your feedback. In the meantime, I'll deploy this version of quota management (with the newest changes) to the DEV cluster while the PR is reviewed.
… The code would think there is no quota (even without quota management) because the new code wasn't inside the proper scope.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- The changes in
queuejob_controller_ex.go
have a bug, it does not preserve any prior labels. - The new method name in the
quota_manager_interface.go
leaks information about how the quota subsystem in implemented. I suggest chaninging is name to something a little bit more abstract, and indicative of its usage.
…nd updates the Kubernetes object correctly. New tests added to check for AppWrappers with no labels at all and with existing labels but no quota labels.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Revising
* add default quota to AW * add default quota * resolve merge * Added support to query existing QuotaSubTrees. MCAD checks that there is a label associated with every quota-sub-tree for the AppWrapper; if there is none, then it adds it with 'default' value. This way, AppWrappers submitted without labels can be dispatched using the quota management library. Added tests for this, and fixed 'quota_service' sub tree to have a 'default' node. This code assumes the quota administrator created a leaf node name 'default' that can be used to schedule AppWrappers without quota labels. * Fixed bug that manifested when running MCAD without quota management. The code would think there is no quota (even without quota management) because the new code wasn't inside the proper scope. * Renamed the function 'GetTreeNames' to 'GetValidQuotaLabels' * Default quota labels code fixed. Code preserves the existing labels and updates the Kubernetes object correctly. New tests added to check for AppWrappers with no labels at all and with existing labels but no quota labels. * relax testing scenario --------- Co-authored-by: Pedro D. Bello-Maldonado <[email protected]>
No description provided.