<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">2016-08-03 2:12 GMT+08:00 Jay Pipes <span dir="ltr"><<a href="mailto:jaypipes@gmail.com" target="_blank">jaypipes@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class="">On 08/02/2016 08:19 AM, Alex Xu wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Chris have a thought about using ResourceClass to describe Capabilities<br>
with an infinite inventory. In the beginning we brain storming the idea<br>
of Tags, Tan Lin have same thought, but we say no very quickly, due to<br>
the ResourceClass is really about Quantitative stuff. But Chris give<br>
very good point about simplify the ResourceProvider model and the API.<br>
<br>
After rethinking about those idea, I like simplify the ResourceProvider<br>
model and the API. But I think the direction is opposite. ResourceClass<br>
with infinite inventory is really hacky. The Placement API is simple,<br>
but the usage of those API isn't simple for user, they need create a<br>
ResourceClass, then create an infinite inventory. And ResourceClass<br>
isn't managable like Tags, look at the Tags API, there are many query<br>
parameter.<br>
<br>
But look at the ResourceClass and ResourceProviderTags, they are totally<br>
same, two columns: one is integer id, another one is string.<br>
ResourceClass is just for naming the quantitative stuff. So what we need<br>
is thing used to 'naming'. ResourceProviderTags is higher abstract, Tags<br>
is generic thing to name something, we totally can use Tag instead of<br>
ResourceClass. So user can create inventory with tags, also user can<br>
create ResourceProvider with tags.<br>
</blockquote>
<br></span>
No, this sounds like actually way more complexity than is needed and will make the schema less explicit.</blockquote><div><br></div><div>No, it simplify the ResourceProvider model and the API? maybe the complexity you pointed at other place.</div><div><br></div><div>Yes, it make the schema less explicit. Using higher layer abstraction, it will lose some characteristic. That is thing we have to pay.</div><div><br></div><div>Anyway let me put this in the alternative section...</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
But yes, there may still have problem isn't resolved, one of problem is<br>
pointed out when I discuss with YingXin about how to distinguish the Tag<br>
is about quantitative or qualitative. He think we need attribute for Tag<br>
to distinguish it. But the attribute isn't thing I like, I prefer leave<br>
that alone due to the user of placement API is admin-user.<br>
<br>
Any thought? or I'm too crazy at here...maybe I just need put this in<br>
the alternative section in the spec...<br>
</blockquote>
<br></span>
A resource class is not a capability, though. It's an indication of a type of quantitative consumable that is exposed on a resource provider.<br>
<br>
A capability is a string that indicates a feature that a resource provider offers. A capability isn't "consumed".<br></blockquote><div><br></div><div>Agree about the definition of resource class and capability. I think it is pretty clear for us.</div><div><br></div><div>What I want to say is the Placement Engine really don't know what is ResourceClass and Capability. They just need an indication for something. You can think about ResourceClass and Capability is sub-class, the Tag is the base-class for them. And think about a case, user can input 'cookie' as the name of ResourceClass, but Placement Engine won't say no to user. Because Placement Engine really don't care about the meaning of ResourceClass' name. Placement Engine just needs a 'tag' to distinguish the ResourceClass and Capability.</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
BTW, this is why I continue to think that using the term "tags" in the placement API is wrong. The placement API should clearly indicate that a resource provider has a set of capabilities. Tags, in Nova at least, are end-user-defined simple categorization strings that have no standardization and no cataloguing or collation to them.<br></blockquote><div><br></div><div>Yes, but we don't have standard string for all the capabilities. For shared storage, this is setup by deployer, not the OpenStack, so the capabilities of shared storage won't be defined by OpenStack, it is defined by deployer.</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
Capabilities are not end-user-defined -- they can be defined by an operator but they are not things that a normal end-user can simply create. And capabilities are specifically *not* for categorization purposes. They are an indication of a set of features that a resource provider exposes.<br></blockquote><div><br></div><div>I totally see your point. But there is one question I can't get answer. If we call Capabilities instead of tags, but user still can free to input any string. User can input 'fish' as a capabilities, and placement API won't say no. Is this OK? Why this is OK when user input non-capability into a capability field? Actually same question for ResourceClass. (ah, this is back to ResourceClass and Capability have same base-class Tags)</div><div><br></div><div>I think this is only question I can't pass through, otherwise I will update the spec :)</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
This is why I think the placement API for capabilities should use the term "capabilities" and not "tags".<br>
<br>
Best,<br>
-jay<br>
<br>
__________________________________________________________________________<br>
OpenStack Development Mailing List (not for usage questions)<br>
Unsubscribe: <a href="http://OpenStack-dev-request@lists.openstack.org?subject:unsubscribe" rel="noreferrer" target="_blank">OpenStack-dev-request@lists.openstack.org?subject:unsubscribe</a><br>
<a href="http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev" rel="noreferrer" target="_blank">http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev</a><br>
</blockquote></div><br></div></div>