)]}'
{"nova/api/openstack/placement/handlers/aggregate.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"c2a85cf657d5872ee41d79b97adb8236e9193112","unresolved":false,"context_lines":[{"line_number":16,"context_line":"from oslo_utils import timeutils"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from nova.api.openstack.placement import microversion"},{"line_number":19,"context_line":"from nova.api.openstack.placement.objects import resource_provider as rp_obj"},{"line_number":20,"context_line":"from nova.api.openstack.placement.schemas import aggregate as schema"},{"line_number":21,"context_line":"from nova.api.openstack.placement import util"},{"line_number":22,"context_line":"from nova.api.openstack.placement import wsgi_wrapper"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_f76637bb","line":19,"updated":"2018-02-02 16:01:13.000000000","message":"Maybe this has already been brought up, but why aren\u0027t we creating a root placement.* namespace for this stuff?","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"6f484a938987a4203d6d895ba53c74be8ab16354","unresolved":false,"context_lines":[{"line_number":16,"context_line":"from oslo_utils import timeutils"},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"from nova.api.openstack.placement import microversion"},{"line_number":19,"context_line":"from nova.api.openstack.placement.objects import resource_provider as rp_obj"},{"line_number":20,"context_line":"from nova.api.openstack.placement.schemas import aggregate as schema"},{"line_number":21,"context_line":"from nova.api.openstack.placement import util"},{"line_number":22,"context_line":"from nova.api.openstack.placement import wsgi_wrapper"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_eb788bc4","line":19,"in_reply_to":"5f93b717_f76637bb","updated":"2018-02-02 17:13:48.000000000","message":"Because when everything does eventually move, the only stuff that will matter is the stuff that\u0027s in the directory nova/api/openstack/placement so it makes little sense to either have two places where stuff lives, or to move all this stuff into a new location (as that makes it harder to see the incremental changes).\n\nWe probably should have put everything in a higher package in the first place but this is the location that made people comfy.","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"}],"nova/api/openstack/placement/objects/__init__.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"11e3aee44fa2f3da291d7c03fbc1deed1fe24623","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":11,"id":"df7087c5_63946438","line":1,"updated":"2018-03-08 15:55:13.000000000","message":"It seems weird to throw these under the API handler subdirectory rather than something like nova/placement/objects/ like we have for the versioned notifications (nova/notifications/objects/...).\n\nWhen placement is split out I expect they\u0027d be in yet another directory just as placement/objects/...","commit_id":"5f41ff997db22af74af78aaeae1d2c6740c2e9a5"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"996ef6c2637193d025f2dee397b354136488ff9d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":11,"id":"df7087c5_e685e2ae","line":1,"in_reply_to":"df7087c5_63946438","updated":"2018-03-08 16:41:39.000000000","message":"As discussed in IRC \u003chttp://p.anticdent.org/1tyY\u003e and repeating here just for the sake of history, the idea is that the current nova/api/openstack/placement directory becomes the future root of the code in the future placement repo, since placement is a) relatively simple (for now), b) only an http api (for now), c) having it in one place allows a migration that preserves history\n\n(a bit more in http://lists.openstack.org/pipermail/openstack-dev/2018-March/128004.html )\n\nAnother way to say this: there\u0027s no immediate plan to have a placement/api directory, just placement","commit_id":"5f41ff997db22af74af78aaeae1d2c6740c2e9a5"}],"nova/api/openstack/placement/objects/resource_provider.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"c2a85cf657d5872ee41d79b97adb8236e9193112","unresolved":false,"context_lines":[{"line_number":41,"context_line":"from nova.db.sqlalchemy import resource_class_cache as rc_cache"},{"line_number":42,"context_line":"from nova import exception"},{"line_number":43,"context_line":"from nova.i18n import _"},{"line_number":44,"context_line":"from nova import rc_fields"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"_TRAIT_TBL \u003d models.Trait.__table__"},{"line_number":47,"context_line":"_ALLOC_TBL \u003d models.Allocation.__table__"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_1d22e1b9","line":44,"range":{"start_line":44,"start_character":0,"end_line":44,"end_character":26},"updated":"2018-02-02 16:01:13.000000000","message":"Is this also slated to be moved?  In this change set or later?","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"6f484a938987a4203d6d895ba53c74be8ab16354","unresolved":false,"context_lines":[{"line_number":41,"context_line":"from nova.db.sqlalchemy import resource_class_cache as rc_cache"},{"line_number":42,"context_line":"from nova import exception"},{"line_number":43,"context_line":"from nova.i18n import _"},{"line_number":44,"context_line":"from nova import rc_fields"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"_TRAIT_TBL \u003d models.Trait.__table__"},{"line_number":47,"context_line":"_ALLOC_TBL \u003d models.Allocation.__table__"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_eb264bce","line":44,"range":{"start_line":44,"start_character":0,"end_line":44,"end_character":26},"in_reply_to":"5f93b717_1d22e1b9","updated":"2018-02-02 17:13:48.000000000","message":"As mentioned in the commit message, this information needs to be in both placement and in nova so for now it is moved to nova/rc_fields.py to indicate that it is special.\n\nI think we may want to consider having an os-resource-classes, like traits, and implement the sync of standard classes in the same way we sync standard traits.\n\nAnd in both cases get rid of the cache mechanisms.","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"}],"nova/db/sqlalchemy/resource_class_cache.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"301366695cabc6047a228422d146b29d69c097ee","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from nova.db.sqlalchemy import api as db_api"},{"line_number":18,"context_line":"from nova.db.sqlalchemy import api_models as models"},{"line_number":19,"context_line":"from nova import exception"},{"line_number":20,"context_line":"from nova import rc_fields"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"_RC_TBL \u003d models.ResourceClass.__table__"},{"line_number":23,"context_line":"_LOCKNAME \u003d \u0027rc_cache\u0027"}],"source_content_type":"text/x-python","patch_set":14,"id":"df7087c5_9fc18983","line":20,"updated":"2018-03-12 15:22:08.000000000","message":"apologies if I missed a discussion in an earlier patch set, but why not `as fields` here to minimize the delta?","commit_id":"e3ebd85f7cb89595ef7b0e59f354a0b93efd8b40"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"d76dd3d31b3776f56d4c21922681e33cc520f1aa","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from nova.db.sqlalchemy import api as db_api"},{"line_number":18,"context_line":"from nova.db.sqlalchemy import api_models as models"},{"line_number":19,"context_line":"from nova import exception"},{"line_number":20,"context_line":"from nova import rc_fields"},{"line_number":21,"context_line":""},{"line_number":22,"context_line":"_RC_TBL \u003d models.ResourceClass.__table__"},{"line_number":23,"context_line":"_LOCKNAME \u003d \u0027rc_cache\u0027"}],"source_content_type":"text/x-python","patch_set":14,"id":"df7087c5_f4d2275c","line":20,"in_reply_to":"df7087c5_9fc18983","updated":"2018-03-12 17:16:38.000000000","message":"Good catch, probably the result of some energetic grepping.","commit_id":"e3ebd85f7cb89595ef7b0e59f354a0b93efd8b40"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"9ab484fd2ffd91c303ffbd4ec868102ce9599c8b","unresolved":false,"context_lines":[{"line_number":86,"context_line":"        \"\"\"Given a string representation of a resource class -- e.g. \"DISK_GB\""},{"line_number":87,"context_line":"        or \"IRON_SILVER\" -- return the integer code for the resource class. For"},{"line_number":88,"context_line":"        standard resource classes, this integer code will match the list of"},{"line_number":89,"context_line":"        resource classes on the fields.ResourceClass field type. Other"},{"line_number":90,"context_line":"        custom resource classes will cause a DB lookup into the"},{"line_number":91,"context_line":"        resource_classes table, however the results of these DB lookups are"},{"line_number":92,"context_line":"        cached since the lookups are so frequent."}],"source_content_type":"text/x-python","patch_set":15,"id":"df7087c5_f998d81b","line":89,"updated":"2018-03-12 23:14:35.000000000","message":"this whitespace change can be reverted now.","commit_id":"8c1120321b50ab1067fc44d622e3757969fc1501"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"155ae325eabdddae5b0a9cae2ec0ebe8e3b5baec","unresolved":false,"context_lines":[{"line_number":86,"context_line":"        \"\"\"Given a string representation of a resource class -- e.g. \"DISK_GB\""},{"line_number":87,"context_line":"        or \"IRON_SILVER\" -- return the integer code for the resource class. For"},{"line_number":88,"context_line":"        standard resource classes, this integer code will match the list of"},{"line_number":89,"context_line":"        resource classes on the fields.ResourceClass field type. Other"},{"line_number":90,"context_line":"        custom resource classes will cause a DB lookup into the"},{"line_number":91,"context_line":"        resource_classes table, however the results of these DB lookups are"},{"line_number":92,"context_line":"        cached since the lookups are so frequent."}],"source_content_type":"text/x-python","patch_set":15,"id":"df7087c5_4690f3ed","line":89,"in_reply_to":"df7087c5_f998d81b","updated":"2018-03-13 08:51:38.000000000","message":"Indeed, thanks.","commit_id":"8c1120321b50ab1067fc44d622e3757969fc1501"}],"nova/objects/resource_provider.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"301366695cabc6047a228422d146b29d69c097ee","unresolved":false,"context_lines":[{"line_number":41,"context_line":"from nova.i18n import _"},{"line_number":42,"context_line":"from nova.objects import base"},{"line_number":43,"context_line":"from nova.objects import fields"},{"line_number":44,"context_line":"from nova import rc_fields"},{"line_number":45,"context_line":""},{"line_number":46,"context_line":"_TRAIT_TBL \u003d models.Trait.__table__"},{"line_number":47,"context_line":"_ALLOC_TBL \u003d models.Allocation.__table__"}],"source_content_type":"text/x-python","patch_set":14,"id":"df7087c5_ff3765af","line":44,"updated":"2018-03-12 15:22:08.000000000","message":"Here it makes sense to avoid conflict with nova.objects.fields","commit_id":"e3ebd85f7cb89595ef7b0e59f354a0b93efd8b40"}],"nova/rc_fields.py":[{"author":{"_account_id":7,"name":"Jay Pipes","email":"jaypipes@gmail.com","username":"jaypipes"},"change_message_id":"ab5a008e3d147ad46206cee4dabe9102e82d7966","unresolved":false,"context_lines":[{"line_number":16,"context_line":"# both the placement and nova sides of the placement interaction. On the"},{"line_number":17,"context_line":"# placement side we don\u0027t want to import all the nova fields, nor all the"},{"line_number":18,"context_line":"# nova objects (which are automatically loaded and registed if the"},{"line_number":19,"context_line":"# nova.object package is imported)."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"import re"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"df7087c5_6c3f96d6","line":19,"updated":"2018-03-07 12:56:33.000000000","message":"Good as-is. Would be great to move this out into an os-resource-classes library ala os-traits eventually.","commit_id":"5f41ff997db22af74af78aaeae1d2c6740c2e9a5"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"301366695cabc6047a228422d146b29d69c097ee","unresolved":false,"context_lines":[{"line_number":15,"context_line":"# NOTE(cdent): This is kept as its own independent file as it is used by"},{"line_number":16,"context_line":"# both the placement and nova sides of the placement interaction. On the"},{"line_number":17,"context_line":"# placement side we don\u0027t want to import all the nova fields, nor all the"},{"line_number":18,"context_line":"# nova objects (which are automatically loaded and registed if the"},{"line_number":19,"context_line":"# nova.object package is imported)."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"import re"}],"source_content_type":"text/x-python","patch_set":14,"id":"df7087c5_9f466921","line":18,"range":{"start_line":18,"start_character":51,"end_line":18,"end_character":59},"updated":"2018-03-12 15:22:08.000000000","message":"registered","commit_id":"e3ebd85f7cb89595ef7b0e59f354a0b93efd8b40"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"301366695cabc6047a228422d146b29d69c097ee","unresolved":false,"context_lines":[{"line_number":16,"context_line":"# both the placement and nova sides of the placement interaction. On the"},{"line_number":17,"context_line":"# placement side we don\u0027t want to import all the nova fields, nor all the"},{"line_number":18,"context_line":"# nova objects (which are automatically loaded and registed if the"},{"line_number":19,"context_line":"# nova.object package is imported)."},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"import re"},{"line_number":22,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"df7087c5_7ff915c6","line":19,"range":{"start_line":19,"start_character":7,"end_line":19,"end_character":13},"updated":"2018-03-12 15:22:08.000000000","message":"objects","commit_id":"e3ebd85f7cb89595ef7b0e59f354a0b93efd8b40"}],"nova/test.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"c2a85cf657d5872ee41d79b97adb8236e9193112","unresolved":false,"context_lines":[{"line_number":309,"context_line":"        # caching of that value."},{"line_number":310,"context_line":"        utils._IS_NEUTRON \u003d None"},{"line_number":311,"context_line":""},{"line_number":312,"context_line":"        # Reset the traits sync flag and rc cache"},{"line_number":313,"context_line":"        resource_provider._TRAITS_SYNCED \u003d False"},{"line_number":314,"context_line":"        resource_provider._RC_CACHE \u003d None"},{"line_number":315,"context_line":"        # Reset the global QEMU version flag."},{"line_number":316,"context_line":"        images.QEMU_VERSION \u003d None"},{"line_number":317,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_1d0bc129","line":314,"range":{"start_line":312,"start_character":0,"end_line":314,"end_character":42},"updated":"2018-02-02 16:01:13.000000000","message":"Guess this will fall out when you rebase on https://review.openstack.org/#/c/540404/","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"6f484a938987a4203d6d895ba53c74be8ab16354","unresolved":false,"context_lines":[{"line_number":309,"context_line":"        # caching of that value."},{"line_number":310,"context_line":"        utils._IS_NEUTRON \u003d None"},{"line_number":311,"context_line":""},{"line_number":312,"context_line":"        # Reset the traits sync flag and rc cache"},{"line_number":313,"context_line":"        resource_provider._TRAITS_SYNCED \u003d False"},{"line_number":314,"context_line":"        resource_provider._RC_CACHE \u003d None"},{"line_number":315,"context_line":"        # Reset the global QEMU version flag."},{"line_number":316,"context_line":"        images.QEMU_VERSION \u003d None"},{"line_number":317,"context_line":""}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_cb27cfc6","line":314,"range":{"start_line":312,"start_character":0,"end_line":314,"end_character":42},"in_reply_to":"5f93b717_1d0bc129","updated":"2018-02-02 17:13:48.000000000","message":"Yeah, the problem showed up in the testing of these changes, so I left it here for now.","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"}],"nova/tests/unit/compute/test_resource_tracker.py":[{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"c2a85cf657d5872ee41d79b97adb8236e9193112","unresolved":false,"context_lines":[{"line_number":1352,"context_line":"        # allocation_ratio or reserved amounts for some resources. Verify that"},{"line_number":1353,"context_line":"        # the information on the compute node fills in this information..."},{"line_number":1354,"context_line":"        inv \u003d {"},{"line_number":1355,"context_line":"            rc_fields.ResourceClass.VCPU: {"},{"line_number":1356,"context_line":"                \u0027total\u0027: vcpus,"},{"line_number":1357,"context_line":"                \u0027min_unit\u0027: 1,"},{"line_number":1358,"context_line":"                \u0027max_unit\u0027: vcpus,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_4055def8","line":1355,"range":{"start_line":1355,"start_character":12,"end_line":1355,"end_character":40},"updated":"2018-02-02 16:01:13.000000000","message":"Eventually we\u0027re going to run up against the issue where placement is newer than compute and yet compute wants to use a new standard resource class.  In that case (as with custom resource classes) we\u0027ll have to use strings that aren\u0027t in the ResourceClass class.  I can\u0027t think of a good way to make that look consistent and pretty; so really this is just me thinking out loud.","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"6f484a938987a4203d6d895ba53c74be8ab16354","unresolved":false,"context_lines":[{"line_number":1352,"context_line":"        # allocation_ratio or reserved amounts for some resources. Verify that"},{"line_number":1353,"context_line":"        # the information on the compute node fills in this information..."},{"line_number":1354,"context_line":"        inv \u003d {"},{"line_number":1355,"context_line":"            rc_fields.ResourceClass.VCPU: {"},{"line_number":1356,"context_line":"                \u0027total\u0027: vcpus,"},{"line_number":1357,"context_line":"                \u0027min_unit\u0027: 1,"},{"line_number":1358,"context_line":"                \u0027max_unit\u0027: vcpus,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_ab05a315","line":1355,"range":{"start_line":1355,"start_character":12,"end_line":1355,"end_character":40},"in_reply_to":"5f93b717_4055def8","updated":"2018-02-02 17:13:48.000000000","message":"Do we have the same problem with os-traits?\n\nPresumably. And I think that\u0027s just the way it goes.\n\nIn either case the old compute _shouldn\u0027t_ use the new resource class or trait because it simply doesn\u0027t (and can\u0027t) know it exists, if it is os-traits as its authority.","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"},{"author":{"_account_id":14070,"name":"Eric Fried","email":"openstack@fried.cc","username":"efried"},"change_message_id":"d79248c2ed2bef14d93c89b6a9434acb61933d4b","unresolved":false,"context_lines":[{"line_number":1352,"context_line":"        # allocation_ratio or reserved amounts for some resources. Verify that"},{"line_number":1353,"context_line":"        # the information on the compute node fills in this information..."},{"line_number":1354,"context_line":"        inv \u003d {"},{"line_number":1355,"context_line":"            rc_fields.ResourceClass.VCPU: {"},{"line_number":1356,"context_line":"                \u0027total\u0027: vcpus,"},{"line_number":1357,"context_line":"                \u0027min_unit\u0027: 1,"},{"line_number":1358,"context_line":"                \u0027max_unit\u0027: vcpus,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5f93b717_63625fb0","line":1355,"range":{"start_line":1355,"start_character":12,"end_line":1355,"end_character":40},"in_reply_to":"5f93b717_ab05a315","updated":"2018-02-02 21:05:15.000000000","message":"Yes, we have the same problem with os-traits.  Which is why we don\u0027t (and shouldn\u0027t) try to use os-traits from compute (or any \"remote\" placement client) to assume what traits are and aren\u0027t standard.\n\nSame thing with resource classes.\n\nAnd whereas I agree that an old compute probably shouldn\u0027t be using new resource classes explicitly (that\u0027s the kind of thing that a g-r bump to the new os-resource-classes would take care of) BUT consider the fact that trait and resource class names can be funneled through compute from some other source.  Case in point, the ironic stuff that\u0027s just gone in: gets its traits from ironic inspector.  In the general case, that source may or may not be (able to be) tied to the identical os-traits/os-resource-classes that\u0027s running on the placement server.","commit_id":"05de25544ea147915e7d8e7ab916e15276b62371"}]}
