)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e1cf4b99f1a6f51da3113edba5de398032c6175c","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     He Jie Xu \u003chejie.xu@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2018-05-17 12:45:01 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Count quota based on resource class"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This spec is about BP count-quota-base-on-resource-class"},{"line_number":10,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"5f7c97a3_c11f95b5","line":7,"range":{"start_line":7,"start_character":0,"end_line":7,"end_character":35},"updated":"2018-05-17 04:49:58.000000000","message":"I have kind of feel, this title will confuse people with this spec https://review.openstack.org/509042","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     He Jie Xu \u003chejie.xu@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2018-05-17 12:45:01 +0800"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Count quota based on resource class"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This spec is about BP count-quota-base-on-resource-class"},{"line_number":10,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"5f7c97a3_b67cfd72","line":7,"range":{"start_line":7,"start_character":0,"end_line":7,"end_character":35},"in_reply_to":"5f7c97a3_c11f95b5","updated":"2018-05-18 14:26:40.000000000","message":"Alex, yeah, you\u0027re probably right :) Might be worth putting a sentence or two in the commit message explaining the difference. Something like this would work I think?\n\nNote that there is another related proposal called \"count-quota-usage-from-placement\" (https://review.openstack.org/509042). That proposal focuses on converting the existing cell-by-cell quota usage calculations for *existing* quota-limited resources (cores, RAM, instances) into one or more calls to the Placement service\u0027s /usages API endpoint. This proposal, on the other hand, focuses on expanding the set of quota-limited resources to any resource class supported by the Placement API, not just the ones traditionally referenced by Nova.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"}],"specs/rocky/approved/count-quota-based-on-resource-class.rst":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":16,"context_line":"Problem description"},{"line_number":17,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Currently, Nova only supports few built-in resources, like instances, cores,"},{"line_number":20,"context_line":"ram, and disk, etc. Since Placement was introduced, Nova is more flexible to"},{"line_number":21,"context_line":"manage more kind of resources in the cluster, Like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_f6d11531","line":19,"range":{"start_line":19,"start_character":43,"end_line":19,"end_character":52},"updated":"2018-05-18 14:26:40.000000000","message":"recommend being explicit about what kind of resource you are talking about here. You\u0027re talking here about types of resources that are limited by quota as opposed to resources that are consumed in the placement API.\n\nFor example, the quota-limited resource is called \"cores\", but that resource class is called VCPU in the placement API (and elsewhere in Nova as well, as you know).\n\nMaybe something like this would help?\n\n .. note::\n\n     The terminology around resources can be quite confusing. There\n     are things that are limited by quota, and there are things\n     that are consumed by an instance. Both are referred to as \"resources\"\n     in most of the documentation. In this spec, when we\n     say \"resources\", we refer to the things that are limited\n     by quota.\n\n     Some of these quota-limited resources are directly related\n     to the resources that are consumed by an instance in Nova, however\n     the quota-limited resource is named differently. An example\n     of this would be the \"cores\" quota-limited resource is a\n     direct relation to the \"VCPU\" resource that is consumed\n     by instances.\n\n     Other quota-limited resources have no direct relationship\n     to resources that are consumed by instances. An example of \n     one of these would be the \"instances\" quota-limited resource.\n     This quota-limited resource refers to the total number of\n     Nova instances that the user/project is able to have active.\n     Clearly, there is no resource that is consumed by a single\n     Nova instance that represents a count of *all* the instances\n     able to be created by a user.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"21641cf21eb5a6f30581f733239509d9126c69da","unresolved":false,"context_lines":[{"line_number":16,"context_line":"Problem description"},{"line_number":17,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Currently, Nova only supports few built-in resources, like instances, cores,"},{"line_number":20,"context_line":"ram, and disk, etc. Since Placement was introduced, Nova is more flexible to"},{"line_number":21,"context_line":"manage more kind of resources in the cluster, Like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_3ca0c3a5","line":19,"range":{"start_line":19,"start_character":43,"end_line":19,"end_character":52},"in_reply_to":"5f7c97a3_f6d11531","updated":"2018-05-19 00:20:03.000000000","message":"yes, agree with you, we create another confusing word in the nova :) Thanks for the note","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":17,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Currently, Nova only supports few built-in resources, like instances, cores,"},{"line_number":20,"context_line":"ram, and disk, etc. Since Placement was introduced, Nova is more flexible to"},{"line_number":21,"context_line":"manage more kind of resources in the cluster, Like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"},{"line_number":23,"context_line":"Nova. For example, for an end user, it is allowed to create 100 instances, but"},{"line_number":24,"context_line":"the operator wants to limit the end user on the number of VGPU created to 20."}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_969ea152","line":21,"range":{"start_line":20,"start_character":52,"end_line":21,"end_character":20},"updated":"2018-05-18 14:26:40.000000000","message":"s/Nova is more flexible to manage more kind of/Nova manages additional kinds of/","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":20,"context_line":"ram, and disk, etc. Since Placement was introduced, Nova is more flexible to"},{"line_number":21,"context_line":"manage more kind of resources in the cluster, Like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"},{"line_number":23,"context_line":"Nova. For example, for an end user, it is allowed to create 100 instances, but"},{"line_number":24,"context_line":"the operator wants to limit the end user on the number of VGPU created to 20."},{"line_number":25,"context_line":"Currently, there is no way to limit that, the end user can choose the flavor"},{"line_number":26,"context_line":"which has VGPU and created 100 instances."}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_56c1e92d","line":23,"range":{"start_line":23,"start_character":19,"end_line":23,"end_character":78},"updated":"2018-05-18 14:26:40.000000000","message":"s/for an end user, it is allowed to create 100 instances, but/an end user may have an \"instances\" quota of 100 instances, but/","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":21,"context_line":"manage more kind of resources in the cluster, Like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"},{"line_number":23,"context_line":"Nova. For example, for an end user, it is allowed to create 100 instances, but"},{"line_number":24,"context_line":"the operator wants to limit the end user on the number of VGPU created to 20."},{"line_number":25,"context_line":"Currently, there is no way to limit that, the end user can choose the flavor"},{"line_number":26,"context_line":"which has VGPU and created 100 instances."},{"line_number":27,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_b6fe3d69","line":24,"range":{"start_line":24,"start_character":19,"end_line":24,"end_character":77},"updated":"2018-05-18 14:26:40.000000000","message":"s/to limit the end user on the number of VGPU created to 20/to limit the number of VGPUs the end user can create to 20/","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"},{"line_number":23,"context_line":"Nova. For example, for an end user, it is allowed to create 100 instances, but"},{"line_number":24,"context_line":"the operator wants to limit the end user on the number of VGPU created to 20."},{"line_number":25,"context_line":"Currently, there is no way to limit that, the end user can choose the flavor"},{"line_number":26,"context_line":"which has VGPU and created 100 instances."},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"Use Cases"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_76f8a57b","line":25,"range":{"start_line":25,"start_character":66,"end_line":25,"end_character":69},"updated":"2018-05-18 14:26:40.000000000","message":"s/the/a/","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":23,"context_line":"Nova. For example, for an end user, it is allowed to create 100 instances, but"},{"line_number":24,"context_line":"the operator wants to limit the end user on the number of VGPU created to 20."},{"line_number":25,"context_line":"Currently, there is no way to limit that, the end user can choose the flavor"},{"line_number":26,"context_line":"which has VGPU and created 100 instances."},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"Use Cases"},{"line_number":29,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_36f22d9c","line":26,"range":{"start_line":26,"start_character":31,"end_line":26,"end_character":40},"updated":"2018-05-18 14:26:40.000000000","message":"instances, thereby creating 100 VGPUs.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":23,"context_line":"Nova. For example, for an end user, it is allowed to create 100 instances, but"},{"line_number":24,"context_line":"the operator wants to limit the end user on the number of VGPU created to 20."},{"line_number":25,"context_line":"Currently, there is no way to limit that, the end user can choose the flavor"},{"line_number":26,"context_line":"which has VGPU and created 100 instances."},{"line_number":27,"context_line":""},{"line_number":28,"context_line":"Use Cases"},{"line_number":29,"context_line":"---------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_96f54186","line":26,"range":{"start_line":26,"start_character":19,"end_line":26,"end_character":26},"updated":"2018-05-18 14:26:40.000000000","message":"s/created/create","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":28,"context_line":"Use Cases"},{"line_number":29,"context_line":"---------"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"* The operator wants to limit the VGPU consuming for each single end user."},{"line_number":32,"context_line":"* The operator wants to limit the custom resources consuming for each single"},{"line_number":33,"context_line":"  end user."},{"line_number":34,"context_line":"* The bare-metal operator wants to limit specific kind of bare-metal node"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_56efa9af","line":31,"range":{"start_line":31,"start_character":24,"end_line":31,"end_character":74},"updated":"2018-05-18 14:26:40.000000000","message":"\"wants to limit VGPU consumption\"","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":29,"context_line":"---------"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"* The operator wants to limit the VGPU consuming for each single end user."},{"line_number":32,"context_line":"* The operator wants to limit the custom resources consuming for each single"},{"line_number":33,"context_line":"  end user."},{"line_number":34,"context_line":"* The bare-metal operator wants to limit specific kind of bare-metal node"},{"line_number":35,"context_line":"  consuming for each single end user."},{"line_number":36,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_d638993e","line":33,"range":{"start_line":32,"start_character":24,"end_line":33,"end_character":11},"updated":"2018-05-18 14:26:40.000000000","message":"\"wants to limit the consumption of a particular custom resource\"","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":31,"context_line":"* The operator wants to limit the VGPU consuming for each single end user."},{"line_number":32,"context_line":"* The operator wants to limit the custom resources consuming for each single"},{"line_number":33,"context_line":"  end user."},{"line_number":34,"context_line":"* The bare-metal operator wants to limit specific kind of bare-metal node"},{"line_number":35,"context_line":"  consuming for each single end user."},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"Proposed change"},{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_963a2132","line":35,"range":{"start_line":34,"start_character":31,"end_line":35,"end_character":37},"updated":"2018-05-18 14:26:40.000000000","message":"\"wants to limit the consumption of a particular kind of baremetal node\"","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"Proposes to change the `os-quota-sets` and `os-quota-class-sets` APIs to allow"},{"line_number":41,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":42,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_f61275b4","line":42,"range":{"start_line":41,"start_character":54,"end_line":42,"end_character":52},"updated":"2018-05-18 14:26:40.000000000","message":"I believe we should be storing the quota limits in Keystone\u0027s limits API now, yes?\n\n\u003clater\u003e Never mind, I see you mention Keystone in the alternatives section :) and that Keystone\u0027s lack of user dimension is what prevents you from using it at the moment.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"91ee3c5c936fc7aa22eb94ff25ef4cb93cafb095","unresolved":false,"context_lines":[{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"Proposes to change the `os-quota-sets` and `os-quota-class-sets` APIs to allow"},{"line_number":41,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":42,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_c7942e47","line":42,"range":{"start_line":41,"start_character":54,"end_line":42,"end_character":52},"in_reply_to":"5f7c97a3_5cbc9fba","updated":"2018-05-22 21:58:01.000000000","message":"Looks like I\u0027ve been out of the loop on unified limits -- they were added in queens and include an optional user_id [1]. So, the user_id thing won\u0027t block us from using unified limits _but_ the lack of quota classes in unified limits will.\n\n[1] https://docs.openstack.org/keystone/queens/admin/identity-unified-limits.html","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"ab737221a84113d200b6c9e2d84d8b62fb7176b6","unresolved":false,"context_lines":[{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"Proposes to change the `os-quota-sets` and `os-quota-class-sets` APIs to allow"},{"line_number":41,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":42,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_88fce772","line":42,"range":{"start_line":41,"start_character":54,"end_line":42,"end_character":52},"in_reply_to":"5f7c97a3_6f02c4b6","updated":"2018-05-24 21:50:13.000000000","message":"Yes -- I had been thinking that there was no equivalent functionality in the keystone unified limits API _but_ I chatted with Lance yesterday and learned that there is indeed an equivalent API called \"registered limits\" [1]. So we can use that instead of the quota class API (if we\u0027re going to implement this using unified limits, that is).\n\n[1] https://developer.openstack.org/api-ref/identity/v3/index.html#create-registered-limits","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"21641cf21eb5a6f30581f733239509d9126c69da","unresolved":false,"context_lines":[{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"Proposes to change the `os-quota-sets` and `os-quota-class-sets` APIs to allow"},{"line_number":41,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":42,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_5cbc9fba","line":42,"range":{"start_line":41,"start_character":54,"end_line":42,"end_character":52},"in_reply_to":"5f7c97a3_ace58ade","updated":"2018-05-19 00:20:03.000000000","message":"What we should consider at here, like, what the progress of keystone limits, whether deprecate the user quota,  when we can migrate to keystone limits. Then we will know whether we should do this in the nova quota or keystone limit.\n\nThinking of what I can do now","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e7f4eb942bbb6e62481a130e782f601441d28c9a","unresolved":false,"context_lines":[{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"Proposes to change the `os-quota-sets` and `os-quota-class-sets` APIs to allow"},{"line_number":41,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":42,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_6f02c4b6","line":42,"range":{"start_line":41,"start_character":54,"end_line":42,"end_character":52},"in_reply_to":"5f7c97a3_c7942e47","updated":"2018-05-23 17:44:44.000000000","message":"Do you mean the quota class API?","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"280088aaa8d71d89d3541b84b1b44262f6a79663","unresolved":false,"context_lines":[{"line_number":38,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"Proposes to change the `os-quota-sets` and `os-quota-class-sets` APIs to allow"},{"line_number":41,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":42,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_ace58ade","line":42,"range":{"start_line":41,"start_character":54,"end_line":42,"end_character":52},"in_reply_to":"5f7c97a3_f61275b4","updated":"2018-05-18 15:43:24.000000000","message":"Just FYI, it\u0027s been discussed before at the Boston Forum that we\u0027re thinking to drop \"user quota\" going forward to keystone unified limits and that nova doesn\u0027t actually have need of the user dimension [1]. Originally, quotas in nova were project-only and the user dimension was added later and awkwardly.\n\nSince it\u0027s been so long, it probably has to be discussed and refreshed again but at the time, operators in the room were supportive of the idea of dropping user quota going toward keystone and thus dropping it from nova when nova moves to keystone limits.\n\n[1] https://etherpad.openstack.org/p/BOS-forum-quotas","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"280088aaa8d71d89d3541b84b1b44262f6a79663","unresolved":false,"context_lines":[{"line_number":43,"context_line":""},{"line_number":44,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":45,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"},{"line_number":46,"context_line":"value for a specific project or a specific user."},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_a7e5a5de","line":46,"updated":"2018-05-18 15:43:24.000000000","message":"++ thanks for making this clear. os-quota-class-sets needs to be used if the operator wants to set default quota that spans across projects, os-quota-sets needs to be used to set a value for a specific project or user.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"19de874a76d7ca7991495336f9472bd38785bec6","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_0e8efb26","line":51,"updated":"2018-05-18 09:07:36.000000000","message":"That\u0027s where I\u0027m confused. You should mention that a CountableResource can have a specific method for counting it, so a \"Placement resource class\" quota class should implement that method for calling GET /usages","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"3ec2a697c938c7310641ed08764c28918aff3dc0","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_b8170c52","line":51,"in_reply_to":"5f7c97a3_0e8efb26","updated":"2018-05-18 12:21:17.000000000","message":"Yes, I plan to have sub-class PlacementCountableResource of CountableResource, and overwrite the count_as_dict method.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"3af032beff4f45bac99380ea98717868da75c960","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_6a32f1a9","line":51,"in_reply_to":"5f7c97a3_27ee7488","updated":"2018-05-18 17:08:25.000000000","message":"OK, I understand your point better now.\n\nSo, instead of prefixing resource class names with the service name, we could add a namespace field to the resource_classes table.\n\nFor the existing resource classes we could default resource_classes.namespace to \"compute\".","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"d820d7d8ad4bab7704472c2465749332da054ea3","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_8aef4de8","line":51,"in_reply_to":"5f7c97a3_6a32f1a9","updated":"2018-05-18 17:11:24.000000000","message":"To handle the \"2 Novas, 1 Placement\" problem, we can use aggregates and allow GET /usages to filter on an aggregate.\n\nFor example, let all the resource providers in Nova 1 be associated with aggregate X. Let all the resource providers in Nova 2 be associated with aggregate Y.\n\nWe could get the quota usage counts in Nova 2 by doing:\n\n GET /usages?project_id\u003d$PROJECT\u0026member_of\u003d$AGG_Y","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"280088aaa8d71d89d3541b84b1b44262f6a79663","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_ec9382ff","line":51,"in_reply_to":"5f7c97a3_766bc51e","updated":"2018-05-18 15:43:24.000000000","message":"As mentioned on the other spec (counting usage from placement), I wanted to remind everybody that we might still be potentially blocked from using placement /usages as a count because of the lack of ability to specify an \"owner\" or \"type\" when we request usages. There was been discussion the past couple of cycles about whether or not we can assume that _nova_ PUT the allocations associated with the usages we want in placement. If another service could PUT VCPU or RAM resources, for example, we could have ambiguity and be unsure the usage is what we actually wanted.\n\nI have been wondering, could we do something like namespace resource classes so that whichever service PUT the resource (example, nova:VCPU and nova:RAM) and then when calling GET /usages the caller can access the namespace of their own (if that is what they wish to count). Would that be a simple solution for being able to differentiate resources for the purposes of querying /usages?","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"21641cf21eb5a6f30581f733239509d9126c69da","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_fcfecb69","line":51,"in_reply_to":"5f7c97a3_8aef4de8","updated":"2018-05-19 00:20:03.000000000","message":"Another remind, for the consumer type, we also have migration uuid as the consumer, that is also the one we want to filter out in the usage count.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"19058c09d22885bb80de479801d830786bedbbb0","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_27ee7488","line":51,"in_reply_to":"5f7c97a3_a75044d6","updated":"2018-05-18 16:41:48.000000000","message":"Yeah, sorry, let me try to explain what I meant there. I\u0027m not talking about non-quantifiable resources like \"instances\" here (though true, originally when \"owner\" or \"type\" came up in the past, it was in the context of counting \"instances\").\n\nTotally agree we can slice and dice via project/user, which gets us most of the way there. The last potential wrinkle is the assumption that VCPU and MEMORY_MB came from nova. That nova is the service that PUT /allocations of them. So that when we see them in /usages, we know we are getting VCPU and MEMORY_MB about instances.\n\nIn the past discussions about allocations, in placement land it was pointed out that _any service_ can put allocations in placement. So, (hypothetical) what if some service WhizBang PUT /allocations for VCPU and MEMORY_MB. And nova also PUT /allocations for VCPU and MEMORY_MB. Then, when nova goes to GET /usages, the VCPU and MEMORY_MB contain usage for both the nova service and the WhizBang service.\n\nI was thinking, to solve that problem, would it make sense to simply allow namespacing of resources? So that if nova PUT /allocations for VCPU and MEMORY_MB, it could know which ones are nova by instead PUTing /allocations for nova:VCPU and nova:MEMORY_MB and GET /usages will have entries for nova:VCPU nova:MEMORY_MB whizbang:VCPU whizbang:MEMORY_MB.\n\nI was just trying to think if the \"owner\" or \"type\" problem could be as simply solved with allowing namespacing of resources.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_766bc51e","line":51,"in_reply_to":"5f7c97a3_b8170c52","updated":"2018-05-18 14:26:40.000000000","message":"This is starting to get into the territory that https://review.openstack.org/#/c/509042/3/specs/rocky/approved/count-quota-usage-from-placement.rst covers. Probably worth limiting the scope of this blueprint to expanding the set of *resources* that may be quota-limited to include any resource class that is tracked via the placement API (and the associated resources\u003d$RESOURCE_CLASS:$AMOUNT extra-spec keys in Nova).","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"826ee6799436de1aa436a2c4660c620257c9fcb9","unresolved":false,"context_lines":[{"line_number":48,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":49,"context_line":"requested in the flavor will be counted."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"The quota usage is counting by the placement `GET /usages` API."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"Alternatives"},{"line_number":54,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_a75044d6","line":51,"in_reply_to":"5f7c97a3_ec9382ff","updated":"2018-05-18 16:13:55.000000000","message":"Well, any allocation created after or at placement API version 1.8 will include a user and project identifier. So, all allocations for any resource will be sliceable/diceable by both the user and project.\n\nOf course, that doesn\u0027t allow us to query for non-quantifiable quota classes like \"instances\". But that\u0027s not due to anything related to the placement API. That\u0027s primarily due to the fact that those types of resources are inherently non-quantifiable. They aren\u0027t quantifiable because \"number of instances\" isn\u0027t actually able to be expressed as an amount of some underlying resources (VCPU, MEMORY_MB, etc).\n\nFor that reason, I\u0027m afraid as long as we continue to require quota counts for non-quantifiable resources like \"instances\", then we will need to express those counts using non-placement API queries -- which is what you\u0027ve suggested in your spec in using a query on the instance_mappings table to do just that.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"d1ef8a5684614597a406c3b44a258bdcb4196fc6","unresolved":false,"context_lines":[{"line_number":54,"context_line":"------------"},{"line_number":55,"context_line":""},{"line_number":56,"context_line":"The keystone limits support a unified way defined quota for all the OpenStack"},{"line_number":57,"context_line":"projects. But keystone limits is still under development. And in the first"},{"line_number":58,"context_line":"implementation, there are no user quota supports which is needed by Nova. So"},{"line_number":59,"context_line":"it still needs a little time to reach that."},{"line_number":60,"context_line":""},{"line_number":61,"context_line":"Data model impact"},{"line_number":62,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_83d19d32","line":59,"range":{"start_line":57,"start_character":58,"end_line":59,"end_character":43},"updated":"2018-05-17 10:20:37.000000000","message":"I just saw the comment from Melanie at https://review.openstack.org/#/c/565412/5/specs/keystone/rocky/strict-two-level-enforcement-model.rst@485","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":67,"context_line":"---------------"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Allows the `PUT /os-quota-sets/{project_id}` and"},{"line_number":70,"context_line":"`PUT /os-quota-class-sets/{quota_class}` APIs to accept resource class as quota"},{"line_number":71,"context_line":"name."},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"The `PUT /os-quota-sets/{project_id}` API\u0027s JSON schema as below::"},{"line_number":74,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_36e30da7","line":71,"range":{"start_line":70,"start_character":74,"end_line":71,"end_character":5},"updated":"2018-05-18 14:26:40.000000000","message":"as the quota *class* name, right?","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"21641cf21eb5a6f30581f733239509d9126c69da","unresolved":false,"context_lines":[{"line_number":67,"context_line":"---------------"},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"Allows the `PUT /os-quota-sets/{project_id}` and"},{"line_number":70,"context_line":"`PUT /os-quota-class-sets/{quota_class}` APIs to accept resource class as quota"},{"line_number":71,"context_line":"name."},{"line_number":72,"context_line":""},{"line_number":73,"context_line":"The `PUT /os-quota-sets/{project_id}` API\u0027s JSON schema as below::"},{"line_number":74,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_7cf2bb9c","line":71,"range":{"start_line":70,"start_character":74,"end_line":71,"end_character":5},"in_reply_to":"5f7c97a3_36e30da7","updated":"2018-05-19 00:20:03.000000000","message":"It is quota resource name. We only use \u0027default\u0027 quota class in the real world, that in the url, I need to clarify that.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":91,"context_line":"same as above."},{"line_number":92,"context_line":""},{"line_number":93,"context_line":"The valid quota will be checked by the API layer python code. Only the"},{"line_number":94,"context_line":"valid resource class and built-in resource are allowed, otherwise, the"},{"line_number":95,"context_line":"`HTTPBadRequest 400` will be returned."},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"The above API change needs new microversion."}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_7602e540","line":94,"range":{"start_line":94,"start_character":67,"end_line":94,"end_character":70},"updated":"2018-05-18 14:26:40.000000000","message":"s/the/a/","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":120,"context_line":"Performance Impact"},{"line_number":121,"context_line":"------------------"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"The Placement `GET /usages` API will return all the resource class consuming"},{"line_number":124,"context_line":"in a single call. So the performance won\u0027t be changed by the number of quotas"},{"line_number":125,"context_line":"counted."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Other deployer impact"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_16c291ea","line":124,"range":{"start_line":123,"start_character":32,"end_line":124,"end_character":16},"updated":"2018-05-18 14:26:40.000000000","message":"\"will return the consumed amount of all resource classes in a single call\"","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"19de874a76d7ca7991495336f9472bd38785bec6","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"The Placement `GET /usages` API will return all the resource class consuming"},{"line_number":124,"context_line":"in a single call. So the performance won\u0027t be changed by the number of quotas"},{"line_number":125,"context_line":"counted."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Other deployer impact"},{"line_number":128,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_aed6e7c2","line":125,"updated":"2018-05-18 09:07:36.000000000","message":"How do you plan to get *all* the resource classes usage in a single call, given the existing ?","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"The Placement `GET /usages` API will return all the resource class consuming"},{"line_number":124,"context_line":"in a single call. So the performance won\u0027t be changed by the number of quotas"},{"line_number":125,"context_line":"counted."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Other deployer impact"},{"line_number":128,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_76b0a58c","line":125,"in_reply_to":"5f7c97a3_5b111253","updated":"2018-05-18 14:26:40.000000000","message":"Right, as Alex says, the GET /usages endpoint returns the amounts used for all resource classes, optionally limited to a specific project and/or user.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"3ec2a697c938c7310641ed08764c28918aff3dc0","unresolved":false,"context_lines":[{"line_number":122,"context_line":""},{"line_number":123,"context_line":"The Placement `GET /usages` API will return all the resource class consuming"},{"line_number":124,"context_line":"in a single call. So the performance won\u0027t be changed by the number of quotas"},{"line_number":125,"context_line":"counted."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Other deployer impact"},{"line_number":128,"context_line":"---------------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_5b111253","line":125,"in_reply_to":"5f7c97a3_aed6e7c2","updated":"2018-05-18 12:21:17.000000000","message":"That is what `GET /usages` API doing now https://github.com/openstack/nova/blob/master/nova/api/openstack/placement/objects/resource_provider.py#L2400\n\nI just need to call with \u0027project_id\u0027 or \u0027user_id\u0027 query parameter based on the query is about project quota or user quota.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"19de874a76d7ca7991495336f9472bd38785bec6","unresolved":false,"context_lines":[{"line_number":123,"context_line":"The Placement `GET /usages` API will return all the resource class consuming"},{"line_number":124,"context_line":"in a single call. So the performance won\u0027t be changed by the number of quotas"},{"line_number":125,"context_line":"counted."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Other deployer impact"},{"line_number":128,"context_line":"---------------------"},{"line_number":129,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_4efcf33d","line":126,"updated":"2018-05-18 09:07:36.000000000","message":"It will also add another Placement API roundtrip (before the scheduler) but I don\u0027t think it\u0027s a problem.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"3ec2a697c938c7310641ed08764c28918aff3dc0","unresolved":false,"context_lines":[{"line_number":123,"context_line":"The Placement `GET /usages` API will return all the resource class consuming"},{"line_number":124,"context_line":"in a single call. So the performance won\u0027t be changed by the number of quotas"},{"line_number":125,"context_line":"counted."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Other deployer impact"},{"line_number":128,"context_line":"---------------------"},{"line_number":129,"context_line":""}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_fb2b3e7f","line":126,"in_reply_to":"5f7c97a3_4efcf33d","updated":"2018-05-18 12:21:17.000000000","message":"yea, there also another Placement API roundtrip after the scheduler if the quota_recheck option enabled.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":127,"context_line":"Other deployer impact"},{"line_number":128,"context_line":"---------------------"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"There is no default quota value in the configure options, like built-in quota"},{"line_number":131,"context_line":"resources. The operator can create default quota value by the quota class API."},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"Developer impact"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_56a7a950","line":130,"range":{"start_line":130,"start_character":39,"end_line":130,"end_character":48},"updated":"2018-05-18 14:26:40.000000000","message":"configuration","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"70196da4fe6ec6521c9e8bd607d09f123cf0fdb1","unresolved":false,"context_lines":[{"line_number":128,"context_line":"---------------------"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"There is no default quota value in the configure options, like built-in quota"},{"line_number":131,"context_line":"resources. The operator can create default quota value by the quota class API."},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"Developer impact"},{"line_number":134,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_3658ed54","line":131,"range":{"start_line":131,"start_character":11,"end_line":131,"end_character":78},"updated":"2018-05-18 14:26:40.000000000","message":"did you plan on allowing an operator to set default limits via the configuration file for any placement-known resource class?\n\nNote that the \"set default values via configuration file\" has the problem of \"what happens when multiple nodes have different values for the defaults?\" issue, similar to the problem we currently have with aggregate allocation ratio defaults (though not configuration-file related... for aggregate allocation ratios, the problem lies in the fact that multiple aggregates can define the same allocation ratio metadata key with different values) :)","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"280088aaa8d71d89d3541b84b1b44262f6a79663","unresolved":false,"context_lines":[{"line_number":128,"context_line":"---------------------"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"There is no default quota value in the configure options, like built-in quota"},{"line_number":131,"context_line":"resources. The operator can create default quota value by the quota class API."},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"Developer impact"},{"line_number":134,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_6711cd53","line":131,"range":{"start_line":131,"start_character":11,"end_line":131,"end_character":78},"in_reply_to":"5f7c97a3_3658ed54","updated":"2018-05-18 15:43:24.000000000","message":"Yeah ... I don\u0027t think the default values via config could work (per resource) given that PlacementCountableResource can represent multiple resource classes (as users create quota limits dynamically via the os-quota-sets API). That means N resource classes map to one PlacementCountableResource. Which means you would need N configuration options, one per resource class, and you would have to know them ahead of time and can\u0027t know them ahead of time because they are created on-the-fly via os-quota-class-sets.\n\nThe quota class API will work nicely for setting a default per resource that spans across projects as the order of checking goes: quota set via os-quota-sets, quota set via os-quota-class-sets, config option [1].\n\n[1] https://docs.openstack.org/nova/pike/user/quotas.html#checking-quota","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"21641cf21eb5a6f30581f733239509d9126c69da","unresolved":false,"context_lines":[{"line_number":128,"context_line":"---------------------"},{"line_number":129,"context_line":""},{"line_number":130,"context_line":"There is no default quota value in the configure options, like built-in quota"},{"line_number":131,"context_line":"resources. The operator can create default quota value by the quota class API."},{"line_number":132,"context_line":""},{"line_number":133,"context_line":"Developer impact"},{"line_number":134,"context_line":"----------------"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_fc0c8b95","line":131,"range":{"start_line":131,"start_character":11,"end_line":131,"end_character":78},"in_reply_to":"5f7c97a3_6711cd53","updated":"2018-05-19 00:20:03.000000000","message":"Yes, my initial plan is only about os-quota-class API. deployer can have a script in the deploy tools to create default value by the os-quota-class API, does that work same as the configuration options?","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"19de874a76d7ca7991495336f9472bd38785bec6","unresolved":false,"context_lines":[{"line_number":138,"context_line":"Upgrade impact"},{"line_number":139,"context_line":"--------------"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":"N/A"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"Implementation"},{"line_number":144,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_ae84a7b2","line":141,"updated":"2018-05-18 09:07:36.000000000","message":"Well, it needs to have Placement API be upgraded before nova-api, which isn\u0027t something we ask for the moment (just for the scheduler and the compute nodes, AFAIK)","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"3ec2a697c938c7310641ed08764c28918aff3dc0","unresolved":false,"context_lines":[{"line_number":138,"context_line":"Upgrade impact"},{"line_number":139,"context_line":"--------------"},{"line_number":140,"context_line":""},{"line_number":141,"context_line":"N/A"},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"Implementation"},{"line_number":144,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":1,"id":"5f7c97a3_3b31b6ed","line":141,"in_reply_to":"5f7c97a3_ae84a7b2","updated":"2018-05-18 12:21:17.000000000","message":"If the \u0027GET /usages\u0027 API match our requirement, then it needn\u0027t.","commit_id":"7370adf671671471896f465053a7544bd5cf8cf8"},{"author":{"_account_id":7166,"name":"Sylvain Bauza","email":"sbauza@redhat.com","username":"sbauza"},"change_message_id":"60dafd15fbadbe054ed9365571862df5ecc6ea53","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Currently, Nova only supports few built-in resources, like instances, cores,"},{"line_number":20,"context_line":"ram, and disk, etc. Since Placement was introduced, Nova manages additional"},{"line_number":21,"context_line":"kinds of resources in the cluster, like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"},{"line_number":23,"context_line":"Nova. For example, an end user may have an \"instances\" quota of 100 instances,"},{"line_number":24,"context_line":"but the operator wants to limit the number of VGPU the end user can created to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_8a639bdc","line":21,"range":{"start_line":21,"start_character":45,"end_line":21,"end_character":54},"updated":"2018-05-22 22:43:22.000000000","message":"well, surely Nova manages SR-IOV resources but not by using Placement (yet). Please clarify.","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e7f4eb942bbb6e62481a130e782f601441d28c9a","unresolved":false,"context_lines":[{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Currently, Nova only supports few built-in resources, like instances, cores,"},{"line_number":20,"context_line":"ram, and disk, etc. Since Placement was introduced, Nova manages additional"},{"line_number":21,"context_line":"kinds of resources in the cluster, like GPU, PCI/SRIOV device, and"},{"line_number":22,"context_line":"custom resources etc. But there is no way to count quota for those resources in"},{"line_number":23,"context_line":"Nova. For example, an end user may have an \"instances\" quota of 100 instances,"},{"line_number":24,"context_line":"but the operator wants to limit the number of VGPU the end user can created to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_ef59f4fd","line":21,"range":{"start_line":21,"start_character":45,"end_line":21,"end_character":54},"in_reply_to":"5f7c97a3_8a639bdc","updated":"2018-05-23 17:44:44.000000000","message":"Yes, I will update","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"b23485e02da29c54185e1fa8ee16c59cc958552e","unresolved":false,"context_lines":[{"line_number":61,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":62,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":65,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"},{"line_number":66,"context_line":"value for a specific project or a specific user."},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":69,"context_line":"requested in the flavor will be counted."},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_7214baa0","line":69,"range":{"start_line":64,"start_character":0,"end_line":69,"end_character":40},"updated":"2018-05-29 07:40:12.000000000","message":"do we have a way to onboard the existing quota usage? \ne.g some system already consume some resource , will it be auto calcuated when the resource quota created?","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"5bf781a6b00c9022c55f7167dda71251b204ceac","unresolved":false,"context_lines":[{"line_number":61,"context_line":"the operator to create a quota for any resource class. The quota of resource"},{"line_number":62,"context_line":"class will be stored in the existed quota DB tables."},{"line_number":63,"context_line":""},{"line_number":64,"context_line":"The `os-quota-class-sets` API allows the operator to create default quota on"},{"line_number":65,"context_line":"a specific resource class. Then using the `os-quota-sets` API to set a quota"},{"line_number":66,"context_line":"value for a specific project or a specific user."},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":69,"context_line":"requested in the flavor will be counted."},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_33d1d130","line":69,"range":{"start_line":64,"start_character":0,"end_line":69,"end_character":40},"in_reply_to":"5f7c97a3_7214baa0","updated":"2018-06-06 01:53:30.000000000","message":"yes, we will take care the existing quota usage. But that will be covered by Melanie\u0027s spec https://review.openstack.org/509042","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":27961,"name":"Konstantinos Samaras-Tsakiris","email":"konstantinos.samaras-tsakiris@cern.ch","username":"kosamara"},"change_message_id":"f0ff48afcb265018a757f1100f50bdad4efb7667","unresolved":false,"context_lines":[{"line_number":68,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":69,"context_line":"requested in the flavor will be counted."},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_d439313f","line":71,"range":{"start_line":71,"start_character":16,"end_line":71,"end_character":30},"updated":"2018-05-23 17:10:18.000000000","message":"s/counting/counted ?","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e7f4eb942bbb6e62481a130e782f601441d28c9a","unresolved":false,"context_lines":[{"line_number":68,"context_line":"When instance booting, only the resource class which has a quota limit and"},{"line_number":69,"context_line":"requested in the flavor will be counted."},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_0f5d50e8","line":71,"range":{"start_line":71,"start_character":16,"end_line":71,"end_character":30},"in_reply_to":"5f7c97a3_d439313f","updated":"2018-05-23 17:44:44.000000000","message":"Done","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":27961,"name":"Konstantinos Samaras-Tsakiris","email":"konstantinos.samaras-tsakiris@cern.ch","username":"kosamara"},"change_message_id":"f0ff48afcb265018a757f1100f50bdad4efb7667","unresolved":false,"context_lines":[{"line_number":69,"context_line":"requested in the flavor will be counted."},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_f40d4d90","line":72,"range":{"start_line":72,"start_character":9,"end_line":72,"end_character":18},"updated":"2018-05-23 17:10:18.000000000","message":"s/reference/refer","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e7f4eb942bbb6e62481a130e782f601441d28c9a","unresolved":false,"context_lines":[{"line_number":69,"context_line":"requested in the flavor will be counted."},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Alternatives"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_af73fc7f","line":72,"range":{"start_line":72,"start_character":9,"end_line":72,"end_character":18},"in_reply_to":"5f7c97a3_f40d4d90","updated":"2018-05-23 17:44:44.000000000","message":"Done","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"a3655ea318617f9a9b7ff484594c754a3def843f","unresolved":false,"context_lines":[{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Alternatives"},{"line_number":76,"context_line":"------------"},{"line_number":77,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_223430fb","line":74,"updated":"2018-06-05 10:03:01.000000000","message":"So I think we should move to os_limits (i.e. unified limits) using keystone before we do that.\n\nThat way we avoid all the API changes, so I think it would actually be less work using os_limits.","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"4ac74c1960ebd2074abcccb05656a28e603773f9","unresolved":false,"context_lines":[{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Alternatives"},{"line_number":76,"context_line":"------------"},{"line_number":77,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_8b82d4ff","line":74,"in_reply_to":"5f7c97a3_13f615fb","updated":"2018-06-06 19:14:58.000000000","message":"Unified limits are already implemented since queens [1][2] and designated as experimental. We haven\u0027t really talked seriously about moving to unified limits in nova. But it would involve migrating our config-option based limits/quota classes/etc to keystone and replacing any database query for quota limits with a call to keystone for limits. It would take some time and effort to come up with a smooth upgrade and migration path.\n\n[1] https://docs.openstack.org/keystone/queens/admin/identity-unified-limits.html\n[2] https://developer.openstack.org/api-ref/identity/v3/index.html#unified-limits","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"5bf781a6b00c9022c55f7167dda71251b204ceac","unresolved":false,"context_lines":[{"line_number":71,"context_line":"The quota usage is counting by the placement `GET /usages` API. For the detail"},{"line_number":72,"context_line":", please reference to the spec"},{"line_number":73,"context_line":"`Propose counting quota usage from placement and API database`_."},{"line_number":74,"context_line":""},{"line_number":75,"context_line":"Alternatives"},{"line_number":76,"context_line":"------------"},{"line_number":77,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_13f615fb","line":74,"in_reply_to":"5f7c97a3_223430fb","updated":"2018-06-06 01:53:30.000000000","message":"John, I may need your guide to the keystone limits. Do you know the timeline for keystone unified limits? or in summit, do we have talk about when we begin to move nova to the keystone limits?\n\nThis sounds like a feature a lot of people needs. And this implementation is quite easy. I think the tradeoff is only about the time, I guess people doesn\u0027t want to wait for too many releases for this feature.","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"a3655ea318617f9a9b7ff484594c754a3def843f","unresolved":false,"context_lines":[{"line_number":79,"context_line":"projects. But keystone limits is still under development. And in the first"},{"line_number":80,"context_line":"implementation, there are no user quota supports which is needed by Nova. So"},{"line_number":81,"context_line":"it still needs a little time to reach that."},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"Data model impact"},{"line_number":84,"context_line":"-----------------"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_02181482","line":82,"updated":"2018-06-05 10:03:01.000000000","message":"Per flavor limits are discussed quite widely. It is clearly not quite the same thing, but its a similar set of use cases that folks are worried.\n\nIn particular I am thinking about bare metal / ironic clouds. per flavor and per resource class are the same thing for many of those clouds right now.\n\nFWIW, I much prefer per resource class quota rather than per flavor quota. It feels more general. Unsure if all operators support my view on that, as they don\u0027t really understand resource classes right now (generally speaking).","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"5bf781a6b00c9022c55f7167dda71251b204ceac","unresolved":false,"context_lines":[{"line_number":79,"context_line":"projects. But keystone limits is still under development. And in the first"},{"line_number":80,"context_line":"implementation, there are no user quota supports which is needed by Nova. So"},{"line_number":81,"context_line":"it still needs a little time to reach that."},{"line_number":82,"context_line":""},{"line_number":83,"context_line":"Data model impact"},{"line_number":84,"context_line":"-----------------"},{"line_number":85,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_533a4d98","line":82,"in_reply_to":"5f7c97a3_02181482","updated":"2018-06-06 01:53:30.000000000","message":"yea, I saw the history, we have multiple proposals about per flavor quota, but nothing happened in real.","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"b23485e02da29c54185e1fa8ee16c59cc958552e","unresolved":false,"context_lines":[{"line_number":92,"context_line":"`PUT /os-quota-class-sets/{quota_class}` APIs to accept resource class as quota"},{"line_number":93,"context_line":"resource."},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"The `PUT /os-quota-sets/{project_id}` API\u0027s JSON schema as below::"},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"  {"},{"line_number":98,"context_line":"    \u0027type\u0027: \u0027object\u0027,"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_d2a4ae4d","line":95,"range":{"start_line":95,"start_character":5,"end_line":95,"end_character":8},"updated":"2018-05-29 07:40:12.000000000","message":"didn\u0027t check previous comments, but looks like \nPOST Is better? \n\nhttps://developer.openstack.org/api-ref/compute/#update-quotas\n\nsays it\u0027s update the quotas for a project or a project and a user. while here we are creating a new class ?","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"5bf781a6b00c9022c55f7167dda71251b204ceac","unresolved":false,"context_lines":[{"line_number":92,"context_line":"`PUT /os-quota-class-sets/{quota_class}` APIs to accept resource class as quota"},{"line_number":93,"context_line":"resource."},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"The `PUT /os-quota-sets/{project_id}` API\u0027s JSON schema as below::"},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"  {"},{"line_number":98,"context_line":"    \u0027type\u0027: \u0027object\u0027,"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_d3789d2c","line":95,"range":{"start_line":95,"start_character":5,"end_line":95,"end_character":8},"in_reply_to":"5f7c97a3_d2a4ae4d","updated":"2018-06-06 01:53:30.000000000","message":"I\u0027m trying to match the current API behavior. You can think about all the resource class\u0027s default quota is -1 (unlimited). Using the PUT API to update a new value.","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"b23485e02da29c54185e1fa8ee16c59cc958552e","unresolved":false,"context_lines":[{"line_number":100,"context_line":"        \u0027type\u0027: \u0027object\u0027,"},{"line_number":101,"context_line":"        \u0027quota_set\u0027: {"},{"line_number":102,"context_line":"            \u0027patternProperties\u0027: {"},{"line_number":103,"context_line":"                \u0027^[A-Za-z0-9_]+$\u0027: common_quota"},{"line_number":104,"context_line":"            }"},{"line_number":105,"context_line":"            \u0027additionalProperties\u0027: False,"},{"line_number":106,"context_line":"        },"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_12254609","line":103,"range":{"start_line":103,"start_character":16,"end_line":103,"end_character":32},"updated":"2018-05-29 07:40:12.000000000","message":"not sure do we need some prefix here..","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"5bf781a6b00c9022c55f7167dda71251b204ceac","unresolved":false,"context_lines":[{"line_number":100,"context_line":"        \u0027type\u0027: \u0027object\u0027,"},{"line_number":101,"context_line":"        \u0027quota_set\u0027: {"},{"line_number":102,"context_line":"            \u0027patternProperties\u0027: {"},{"line_number":103,"context_line":"                \u0027^[A-Za-z0-9_]+$\u0027: common_quota"},{"line_number":104,"context_line":"            }"},{"line_number":105,"context_line":"            \u0027additionalProperties\u0027: False,"},{"line_number":106,"context_line":"        },"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_73c3c939","line":103,"range":{"start_line":103,"start_character":16,"end_line":103,"end_character":32},"in_reply_to":"5f7c97a3_12254609","updated":"2018-06-06 01:53:30.000000000","message":"yea, I\u0027m also thinking about that. But I think it is ok, we have different name between the resource class and built-in quota.","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":27961,"name":"Konstantinos Samaras-Tsakiris","email":"konstantinos.samaras-tsakiris@cern.ch","username":"kosamara"},"change_message_id":"f0ff48afcb265018a757f1100f50bdad4efb7667","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"When booting new instance, the resource class which is required by the flavor"},{"line_number":122,"context_line":"and has quota limit in the DB, it will be checked by the quota limit. If"},{"line_number":123,"context_line":"it\u0027s over the quota, the instance booting will be failed, a"},{"line_number":124,"context_line":"`HTTPForbidden 403` will be returned. This doesn\u0027t require new microversion,"},{"line_number":125,"context_line":"since this is en existed API behavior."},{"line_number":126,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_74761d09","line":123,"range":{"start_line":123,"start_character":46,"end_line":123,"end_character":56},"updated":"2018-05-23 17:10:18.000000000","message":"s/be failed/fail","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e7f4eb942bbb6e62481a130e782f601441d28c9a","unresolved":false,"context_lines":[{"line_number":120,"context_line":""},{"line_number":121,"context_line":"When booting new instance, the resource class which is required by the flavor"},{"line_number":122,"context_line":"and has quota limit in the DB, it will be checked by the quota limit. If"},{"line_number":123,"context_line":"it\u0027s over the quota, the instance booting will be failed, a"},{"line_number":124,"context_line":"`HTTPForbidden 403` will be returned. This doesn\u0027t require new microversion,"},{"line_number":125,"context_line":"since this is en existed API behavior."},{"line_number":126,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_cf6e7895","line":123,"range":{"start_line":123,"start_character":46,"end_line":123,"end_character":56},"in_reply_to":"5f7c97a3_74761d09","updated":"2018-05-23 17:44:44.000000000","message":"Done","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":27961,"name":"Konstantinos Samaras-Tsakiris","email":"konstantinos.samaras-tsakiris@cern.ch","username":"kosamara"},"change_message_id":"f0ff48afcb265018a757f1100f50bdad4efb7667","unresolved":false,"context_lines":[{"line_number":122,"context_line":"and has quota limit in the DB, it will be checked by the quota limit. If"},{"line_number":123,"context_line":"it\u0027s over the quota, the instance booting will be failed, a"},{"line_number":124,"context_line":"`HTTPForbidden 403` will be returned. This doesn\u0027t require new microversion,"},{"line_number":125,"context_line":"since this is en existed API behavior."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Security impact"},{"line_number":128,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_54652144","line":125,"range":{"start_line":125,"start_character":17,"end_line":125,"end_character":24},"updated":"2018-05-23 17:10:18.000000000","message":"s/existed/existing","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"},{"author":{"_account_id":5754,"name":"Alex Xu","email":"hejie.xu@intel.com","username":"xuhj"},"change_message_id":"e7f4eb942bbb6e62481a130e782f601441d28c9a","unresolved":false,"context_lines":[{"line_number":122,"context_line":"and has quota limit in the DB, it will be checked by the quota limit. If"},{"line_number":123,"context_line":"it\u0027s over the quota, the instance booting will be failed, a"},{"line_number":124,"context_line":"`HTTPForbidden 403` will be returned. This doesn\u0027t require new microversion,"},{"line_number":125,"context_line":"since this is en existed API behavior."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Security impact"},{"line_number":128,"context_line":"---------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"5f7c97a3_6f6de496","line":125,"range":{"start_line":125,"start_character":17,"end_line":125,"end_character":24},"in_reply_to":"5f7c97a3_54652144","updated":"2018-05-23 17:44:44.000000000","message":"Done","commit_id":"722a4d3eb11b793a629ad91c18982f547307324e"}]}
