-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Generalize label selectors #341
Comments
I've started working on this. I will submit a PR over the next day or so. |
If folks intend to use labels for constraint matching, there will likely need to be comparison operators. |
@timothysc Could you please provide a motivating example for comparisons? We could accept integer ranges, including open ranges. However, the restrictive selection semantics are careful chosen to facilitate set overlap detection, efficient indexing and reverse indexing, and human understandability. |
It is my understanding that Labels 'currently' only apply to pods. If labeling were extended to Kublets then users could define things such as: rank = memory requirements = memory > 4GB |
Ok, thanks. As I commented in #367 , labels / constraints shouldn't be used for resource-based placement or binpacking. The scheduler should place pods based on their minimum resource requirements and resources available. |
You could also view it as requirements = distance(podX) < 3 |
Labels are explicit and literal. Locality requirements need to be expressed at a higher level. Expressing them as individual hard constraints on pods is likely to lead to a greedy scheduler to paint itself into a corner. Scheduling is a nuanced service, with workload-specific and provider-specific objectives and constraints, topological and architectural considerations, security concerns, dependencies, QoS and fairness considerations, workload interference, etc. Let's not try to shoehorn too much into the label mechanism. |
I really think scheduling resources and scheduling constraints are two For your other example, distance to another pod, I would also not suggest I also started with the expectation that label selectors would be an Tim
|
Regular expressions and prefix/suffix matching are hostile to the goals I mentioned earlier. We should not support them. The escape hatch is attaching a new label using whatever arbitrary computation you wish to decide where to attach it, or to dump the data into a database and use SQL or whatever. |
I proposed the SQL method on NVP sets earlier today. |
I am behind on email, so I promise to digest the other threads tonight :)
|
P1 to decide how to surface this in v1beta3. |
Is there any spec around this? |
I'm not sure we should rename to LabelSelector, because NodeSelector will also be a form of label selector. |
I agree but I couldn't find a better name even if GeneralizedSelector looked better (finally everyone inside the project call in that way). If you've some ideas I can rename it. |
My 2 cents, if PodSelector is the generic one and it should be used as the primary, then LabelSelector @sdminonne proposes, will do the trick. From there you can always create a specialized selector (such as NodeSelector) which will cover the subset of LabelSelector with application to specific resource. |
On the side note, |
I think I found the |
@smarterclayton @bgrant0607 @erictune - I am looking for some guidance on how to handle existing resources, so input appreciated. I want to add an optional label and an optional field selector to Should I use the new label selector syntax as seen in |
@derekwaynecarr Use the new syntax. Copy/move LabelSelector to v1. |
@bgrant0607 - thanks for the quick reply. |
This is covered by more specific issues, so closing. |
Report error while fetching network stats.
support bring up baremetal cluster with CA signed cert.
support bring up baremetal cluster with CA signed cert.
support bring up baremetal cluster with CA signed cert.
support bring up baremetal cluster with CA signed cert.
support bring up baremetal cluster with CA signed cert.
caleb-bucket-4-updates
Add util functions to read/write manifest file and update sub commands
Update network_problem.sh
Right now, our label selectors support conjunctions of exact matches of key-value pairs. We should support conjunctions of:
Exact match can be expressed using "is in".
This would allow selectors such as:
service is in (foo),
environment is not in (qa),
stage is in (daily, weekly)
The text was updated successfully, but these errors were encountered: