)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"1bebb5e97cfba3599a2666cc512ca40ef1171b07","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"neutron.api.rpc.callbacks interface rework"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Split rpc.callbacks interface into consumer and producer parts."},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"Co-Authored-By: Ihar Hrachyshka \u003cihrachys@redhat.com\u003e"},{"line_number":12,"context_line":"Partially-Implements: blueprint quantum-qos-api"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a4dcd0f_de30610a","line":9,"updated":"2015-08-03 14:06:10.000000000","message":"(partially implementing consumer too).","commit_id":"ef94077fdaa4eb50372db06a54f66e86d517b77f"},{"author":{"_account_id":6598,"name":"Berezovsky Irena","email":"irenab.dev@gmail.com","username":"irenab"},"change_message_id":"60111d860a383f44ffb09a39264519f05abfb962","unresolved":false,"context_lines":[{"line_number":24,"context_line":"singletons), so introduced a common qos base test class to mock the"},{"line_number":25,"context_line":"manager with per-test instance of it)."},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"Co-Authored-By: Ihar Hrachyshka \u003cihrachys@redhat.com\u003e"},{"line_number":28,"context_line":"Partially-Implements: blueprint quantum-qos-api"},{"line_number":29,"context_line":"Change-Id: I130cfbc8b78da6df4405b90ea1ab47899491ba41"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":23,"id":"1a4dcd0f_1e7b6ef6","line":27,"updated":"2015-08-06 14:09:22.000000000","message":"Not sure why you need co-authored-by","commit_id":"5d7f7a650536695e5e2cabf11eab4b155265df56"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"6ee37c0e06185f5000e80719de9baaac87f6af1f","unresolved":false,"context_lines":[{"line_number":24,"context_line":"singletons), so introduced a common qos base test class to mock the"},{"line_number":25,"context_line":"manager with per-test instance of it)."},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"Co-Authored-By: Ihar Hrachyshka \u003cihrachys@redhat.com\u003e"},{"line_number":28,"context_line":"Partially-Implements: blueprint quantum-qos-api"},{"line_number":29,"context_line":"Change-Id: I130cfbc8b78da6df4405b90ea1ab47899491ba41"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":23,"id":"1a4dcd0f_8ffaea73","line":27,"in_reply_to":"1a4dcd0f_1e7b6ef6","updated":"2015-08-06 14:54:40.000000000","message":"Because the original commit authorship is on Miguel (see above).","commit_id":"5d7f7a650536695e5e2cabf11eab4b155265df56"}],"doc/source/devref/rpc_callbacks.rst":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d74555770e84cc04cada7f9780f74356d29a798f","unresolved":false,"context_lines":[{"line_number":84,"context_line":"In the future, we may want to get oslo messaging to support subscribing"},{"line_number":85,"context_line":"topics dynamically, then we may want to use:"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"neutron_vo_\u003cresource_class_name\u003e_\u003cresoure_id\u003e_\u003cversion\u003e instead,"},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"or something equivalent which would allow fine granularity for the receivers"},{"line_number":90,"context_line":"to only get interesting information to them."}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_061e4e63","line":87,"updated":"2015-08-04 12:34:49.000000000","message":"nit resoure-\u003eresource","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"55990db309c7d84b789eaa1b31bff8d7a6f60bfc","unresolved":false,"context_lines":[{"line_number":84,"context_line":"In the future, we may want to get oslo messaging to support subscribing"},{"line_number":85,"context_line":"topics dynamically, then we may want to use:"},{"line_number":86,"context_line":""},{"line_number":87,"context_line":"neutron_vo_\u003cresource_class_name\u003e_\u003cresoure_id\u003e_\u003cversion\u003e instead,"},{"line_number":88,"context_line":""},{"line_number":89,"context_line":"or something equivalent which would allow fine granularity for the receivers"},{"line_number":90,"context_line":"to only get interesting information to them."}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_53e88c10","line":87,"in_reply_to":"1a4dcd0f_061e4e63","updated":"2015-08-04 14:07:24.000000000","message":"Done","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d74555770e84cc04cada7f9780f74356d29a798f","unresolved":false,"context_lines":[{"line_number":162,"context_line":"    from neutron.api.rpc.callbacks.producer import registry"},{"line_number":163,"context_line":"    from neutron.api.rpc.callbacks import events"},{"line_number":164,"context_line":""},{"line_number":165,"context_line":"    def create_qos_rule(...):"},{"line_number":166,"context_line":"        policy \u003d fetch_policy(...)"},{"line_number":167,"context_line":"        update_the_db(...)"},{"line_number":168,"context_line":"        registry.notify(policy, events.UPDATED)"}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_8641fe0d","line":165,"updated":"2015-08-04 12:34:49.000000000","message":"BTW, we could drop all the *_rule part and leave only the *_qos_policy since we only support policies, and having rules within policies is implementation detail of QoS.","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"55990db309c7d84b789eaa1b31bff8d7a6f60bfc","unresolved":false,"context_lines":[{"line_number":162,"context_line":"    from neutron.api.rpc.callbacks.producer import registry"},{"line_number":163,"context_line":"    from neutron.api.rpc.callbacks import events"},{"line_number":164,"context_line":""},{"line_number":165,"context_line":"    def create_qos_rule(...):"},{"line_number":166,"context_line":"        policy \u003d fetch_policy(...)"},{"line_number":167,"context_line":"        update_the_db(...)"},{"line_number":168,"context_line":"        registry.notify(policy, events.UPDATED)"}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_53bf2cfb","line":165,"in_reply_to":"1a4dcd0f_8641fe0d","updated":"2015-08-04 14:07:24.000000000","message":"Done","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d74555770e84cc04cada7f9780f74356d29a798f","unresolved":false,"context_lines":[{"line_number":165,"context_line":"    def create_qos_rule(...):"},{"line_number":166,"context_line":"        policy \u003d fetch_policy(...)"},{"line_number":167,"context_line":"        update_the_db(...)"},{"line_number":168,"context_line":"        registry.notify(policy, events.UPDATED)"},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"    def update_qos_rule(...):"},{"line_number":171,"context_line":"        policy \u003d fetch_policy(...)"}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_26b7ca3a","line":168,"updated":"2015-08-04 12:34:49.000000000","message":"events.CREATED","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"55990db309c7d84b789eaa1b31bff8d7a6f60bfc","unresolved":false,"context_lines":[{"line_number":165,"context_line":"    def create_qos_rule(...):"},{"line_number":166,"context_line":"        policy \u003d fetch_policy(...)"},{"line_number":167,"context_line":"        update_the_db(...)"},{"line_number":168,"context_line":"        registry.notify(policy, events.UPDATED)"},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"    def update_qos_rule(...):"},{"line_number":171,"context_line":"        policy \u003d fetch_policy(...)"}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_b347901c","line":168,"in_reply_to":"1a4dcd0f_26b7ca3a","updated":"2015-08-04 14:07:24.000000000","message":"Nope since we were creating a rule but update a policy. But I\u0027ll kill those.","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d74555770e84cc04cada7f9780f74356d29a798f","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    def delete_qos_rule(...):"},{"line_number":176,"context_line":"        policy \u003d fetch_policy(...)"},{"line_number":177,"context_line":"        update_the_db(...)"},{"line_number":178,"context_line":"        registry.notify(policy, events.UPDATED)"},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"    def create_qos_policy(...):"},{"line_number":181,"context_line":"        policy \u003d fetch_policy(...)"}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_6694f28a","line":178,"updated":"2015-08-04 12:34:49.000000000","message":"DELETED","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"55990db309c7d84b789eaa1b31bff8d7a6f60bfc","unresolved":false,"context_lines":[{"line_number":175,"context_line":"    def delete_qos_rule(...):"},{"line_number":176,"context_line":"        policy \u003d fetch_policy(...)"},{"line_number":177,"context_line":"        update_the_db(...)"},{"line_number":178,"context_line":"        registry.notify(policy, events.UPDATED)"},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"    def create_qos_policy(...):"},{"line_number":181,"context_line":"        policy \u003d fetch_policy(...)"}],"source_content_type":"text/x-rst","patch_set":14,"id":"1a4dcd0f_53564cd3","line":178,"in_reply_to":"1a4dcd0f_6694f28a","updated":"2015-08-04 14:07:24.000000000","message":"Same","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":79,"context_line":"Topic names for every resource type RPC endpoint"},{"line_number":80,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"neutron_vo-\u003cresource_class_name\u003e-\u003cversion\u003e"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"In the future, we may want to get oslo messaging to support subscribing"},{"line_number":85,"context_line":"topics dynamically, then we may want to use:"}],"source_content_type":"text/x-rst","patch_set":19,"id":"1a4dcd0f_e1cbc751","line":82,"updated":"2015-08-05 13:07:50.000000000","message":"Nit: It\u0027s neutron-vo-... dash instead of underscore","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":79,"context_line":"Topic names for every resource type RPC endpoint"},{"line_number":80,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":81,"context_line":""},{"line_number":82,"context_line":"neutron_vo-\u003cresource_class_name\u003e-\u003cversion\u003e"},{"line_number":83,"context_line":""},{"line_number":84,"context_line":"In the future, we may want to get oslo messaging to support subscribing"},{"line_number":85,"context_line":"topics dynamically, then we may want to use:"}],"source_content_type":"text/x-rst","patch_set":19,"id":"1a4dcd0f_57c83922","line":82,"in_reply_to":"1a4dcd0f_e1cbc751","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":105,"name":"Kyle Mestery","email":"mestery@mestery.com","username":"mestery"},"change_message_id":"e15aab8623acf5e87d7658abf87ef19fa280e6e7","unresolved":false,"context_lines":[{"line_number":58,"context_line":""},{"line_number":59,"context_line":"The strategy for upgrades will be:"},{"line_number":60,"context_line":"   During upgrades, we pin neutron-server to a compatible version for resource"},{"line_number":61,"context_line":"   fanout updates, and server sends both the old, and the newer version"},{"line_number":62,"context_line":"   new agents process updates taking the newer version."},{"line_number":63,"context_line":"   When the whole system upgraded, we un-pin the compatible version fanout."},{"line_number":64,"context_line":""}],"source_content_type":"text/x-rst","patch_set":30,"id":"1a4dcd0f_ed5567fa","line":61,"updated":"2015-08-08 02:35:12.000000000","message":"Nit: \"and the server\".\n\nNit: period after the last \"version\".","commit_id":"eda63f1e868cca9836edbd22848503b2c1077075"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"a16e35978c85f0224de9c6e8cd9723488640b2b2","unresolved":false,"context_lines":[{"line_number":58,"context_line":""},{"line_number":59,"context_line":"The strategy for upgrades will be:"},{"line_number":60,"context_line":"   During upgrades, we pin neutron-server to a compatible version for resource"},{"line_number":61,"context_line":"   fanout updates, and server sends both the old, and the newer version"},{"line_number":62,"context_line":"   new agents process updates taking the newer version."},{"line_number":63,"context_line":"   When the whole system upgraded, we un-pin the compatible version fanout."},{"line_number":64,"context_line":""}],"source_content_type":"text/x-rst","patch_set":30,"id":"1a4dcd0f_619e4065","line":61,"in_reply_to":"1a4dcd0f_ed5567fa","updated":"2015-08-08 08:24:28.000000000","message":"Done","commit_id":"eda63f1e868cca9836edbd22848503b2c1077075"},{"author":{"_account_id":105,"name":"Kyle Mestery","email":"mestery@mestery.com","username":"mestery"},"change_message_id":"e15aab8623acf5e87d7658abf87ef19fa280e6e7","unresolved":false,"context_lines":[{"line_number":59,"context_line":"The strategy for upgrades will be:"},{"line_number":60,"context_line":"   During upgrades, we pin neutron-server to a compatible version for resource"},{"line_number":61,"context_line":"   fanout updates, and server sends both the old, and the newer version"},{"line_number":62,"context_line":"   new agents process updates taking the newer version."},{"line_number":63,"context_line":"   When the whole system upgraded, we un-pin the compatible version fanout."},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"Serialized versioned objects look like::"}],"source_content_type":"text/x-rst","patch_set":30,"id":"1a4dcd0f_6d4ab757","line":62,"updated":"2015-08-08 02:35:12.000000000","message":"Nit: \"The new agents process updates, taking the newer version of the resource fanout updates.\"","commit_id":"eda63f1e868cca9836edbd22848503b2c1077075"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"a16e35978c85f0224de9c6e8cd9723488640b2b2","unresolved":false,"context_lines":[{"line_number":59,"context_line":"The strategy for upgrades will be:"},{"line_number":60,"context_line":"   During upgrades, we pin neutron-server to a compatible version for resource"},{"line_number":61,"context_line":"   fanout updates, and server sends both the old, and the newer version"},{"line_number":62,"context_line":"   new agents process updates taking the newer version."},{"line_number":63,"context_line":"   When the whole system upgraded, we un-pin the compatible version fanout."},{"line_number":64,"context_line":""},{"line_number":65,"context_line":"Serialized versioned objects look like::"}],"source_content_type":"text/x-rst","patch_set":30,"id":"1a4dcd0f_819b4c72","line":62,"in_reply_to":"1a4dcd0f_6d4ab757","updated":"2015-08-08 08:24:28.000000000","message":"Done","commit_id":"eda63f1e868cca9836edbd22848503b2c1077075"}],"neutron/api/rpc/callbacks/consumer/registry.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"39ac5762b08adc560f1f1cf40d37fc2a2a26292a","unresolved":false,"context_lines":[{"line_number":48,"context_line":""},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"#TODO(QoS): consider changing get_info to get_resource, in RPC too?"},{"line_number":51,"context_line":"def get_info(resource_type, resource_id, context\u003dNone):"},{"line_number":52,"context_line":"    return _get_resource_server_rpc().get_info(resource_type, resource_id,"},{"line_number":53,"context_line":"                                               context)"},{"line_number":54,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a4dcd0f_3ec5c55a","line":51,"updated":"2015-08-03 14:01:37.000000000","message":"get_object here too, this is actually what consumers will use.","commit_id":"ef94077fdaa4eb50372db06a54f66e86d517b77f"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d74555770e84cc04cada7f9780f74356d29a798f","unresolved":false,"context_lines":[{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"def get_resource(resource_type, resource_id):"},{"line_number":34,"context_line":"    raise NotImplementedError()"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"def subscribe(callback, resource_type):"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a4dcd0f_a6e2fa01","line":34,"updated":"2015-08-04 12:34:49.000000000","message":"moving to a follow up patch?","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"55990db309c7d84b789eaa1b31bff8d7a6f60bfc","unresolved":false,"context_lines":[{"line_number":31,"context_line":""},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"def get_resource(resource_type, resource_id):"},{"line_number":34,"context_line":"    raise NotImplementedError()"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"def subscribe(callback, resource_type):"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a4dcd0f_d3833ccb","line":34,"in_reply_to":"1a4dcd0f_a6e2fa01","updated":"2015-08-04 14:07:24.000000000","message":"I\u0027ll do it in this one.","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    return _CALLBACK_MANAGER"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"def get_resource(context, resource_type, resource_id):"},{"line_number":35,"context_line":"    api \u003d resources_rpc.ResourcesServerRpcApi()"},{"line_number":36,"context_line":"    return api.get_resource(context, resource_type, resource_id)"},{"line_number":37,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_4102bb70","line":34,"updated":"2015-08-05 13:07:50.000000000","message":"Item to think about - should we call rpc api via registry. Seems like this function has nothing to do with registry.","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":31,"context_line":"    return _CALLBACK_MANAGER"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"def get_resource(context, resource_type, resource_id):"},{"line_number":35,"context_line":"    api \u003d resources_rpc.ResourcesServerRpcApi()"},{"line_number":36,"context_line":"    return api.get_resource(context, resource_type, resource_id)"},{"line_number":37,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_d778c9c6","line":34,"in_reply_to":"1a4dcd0f_4102bb70","updated":"2015-08-05 13:45:17.000000000","message":"I\u0027ll add TODO","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"926c468d6d2dcf5baaa5374a788dca4df33cfa49","unresolved":false,"context_lines":[{"line_number":32,"context_line":""},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"# TODO(QoS): rename into pull"},{"line_number":35,"context_line":"# TODO(QoS): move out of registry module"},{"line_number":36,"context_line":"def get_resource(context, resource_type, resource_id):"},{"line_number":37,"context_line":"    api \u003d resources_rpc.ResourcesServerRpcApi()"},{"line_number":38,"context_line":"    return api.get_resource(context, resource_type, resource_id)"}],"source_content_type":"text/x-python","patch_set":20,"id":"1a4dcd0f_d1e9b4e7","line":35,"updated":"2015-08-05 14:03:14.000000000","message":"may be just to __init__ of consumer ? if that\u0027s not too ugly... or a separate module (ondemand?).","commit_id":"029466c2fc500caa92ebf50201ff04b16c9cea9f"},{"author":{"_account_id":12171,"name":"Moshe Levi","email":"moshele@nvidia.com","username":"moshele"},"change_message_id":"f8c8250732a6f58cd202c0c608dcfc1cacb6652f","unresolved":false,"context_lines":[{"line_number":26,"context_line":"def _get_manager():"},{"line_number":27,"context_line":"    global _CALLBACK_MANAGER"},{"line_number":28,"context_line":"    if _CALLBACK_MANAGER is None:"},{"line_number":29,"context_line":"        _CALLBACK_MANAGER \u003d ("},{"line_number":30,"context_line":"            resource_manager.ResourceConsumerCallbacksManager())"},{"line_number":31,"context_line":"    return _CALLBACK_MANAGER"},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_8c1a217c","line":29,"updated":"2015-08-05 20:05:47.000000000","message":"don\u0027t you want to change the singleton like you told me in the SR-IOV patch?","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"b973f2fd68a50b189019744440a897f21e1b13e5","unresolved":false,"context_lines":[{"line_number":26,"context_line":"def _get_manager():"},{"line_number":27,"context_line":"    global _CALLBACK_MANAGER"},{"line_number":28,"context_line":"    if _CALLBACK_MANAGER is None:"},{"line_number":29,"context_line":"        _CALLBACK_MANAGER \u003d ("},{"line_number":30,"context_line":"            resource_manager.ResourceConsumerCallbacksManager())"},{"line_number":31,"context_line":"    return _CALLBACK_MANAGER"},{"line_number":32,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_3b33e115","line":29,"in_reply_to":"1a4dcd0f_8c1a217c","updated":"2015-08-06 12:15:43.000000000","message":"Done","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"1495843e6a417f9072faa959e983e80734808eb4","unresolved":false,"context_lines":[{"line_number":21,"context_line":"#TODO(ajo): consider adding locking to _get_manager, it\u0027s"},{"line_number":22,"context_line":"#           safe for eventlet, but not for normal threading."},{"line_number":23,"context_line":"def _get_manager():"},{"line_number":24,"context_line":"    return resource_manager.ResourceCallbacksManager()"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"def subscribe(callback, resource_type):"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a4dcd0f_fb078b15","line":24,"updated":"2015-08-07 08:25:02.000000000","message":"Oh, this might be more severe - I think we should raise the number of max_callbacks here or better set default to 0 which will mean \"infinite\" number of callbacks.","commit_id":"78ea98ddbd576575728f8a2e334d1606ce0fec08"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"783a84c59663b80234396daf70f4bb3e30d3adc8","unresolved":false,"context_lines":[{"line_number":21,"context_line":"#TODO(ajo): consider adding locking to _get_manager, it\u0027s"},{"line_number":22,"context_line":"#           safe for eventlet, but not for normal threading."},{"line_number":23,"context_line":"def _get_manager():"},{"line_number":24,"context_line":"    return resource_manager.ResourceCallbacksManager()"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":""},{"line_number":27,"context_line":"def subscribe(callback, resource_type):"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a4dcd0f_5b66bf51","line":24,"in_reply_to":"1a4dcd0f_fb078b15","updated":"2015-08-07 08:38:16.000000000","message":"Ouch. I\u0027ll update both in here.","commit_id":"78ea98ddbd576575728f8a2e334d1606ce0fec08"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"3b44ed3810fa887e44284b2224e8b7fde3009b37","unresolved":false,"context_lines":[{"line_number":19,"context_line":""},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"#TODO(ajo): consider adding locking to _get_manager, it\u0027s"},{"line_number":22,"context_line":"#           safe for eventlet, but not for normal threading."},{"line_number":23,"context_line":"def _get_manager():"},{"line_number":24,"context_line":"    return resource_manager.ConsumerResourceCallbacksManager()"},{"line_number":25,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a4dcd0f_16579726","line":22,"updated":"2015-08-07 16:25:01.000000000","message":"this TODO now belongs to the __new__ handler in the callback manager, but, since it\u0027s targeted to me, I totally understand what it means and how to handle it.\n\nNo need to move it now, just do it if you needed to respin for any serious reason.","commit_id":"c60a5d4eebc4545331f90b5bb7687e50aef07b0e"}],"neutron/api/rpc/callbacks/producer/registry.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"8ba5190efe52abd29434b5f8371ccd45a1fdb8ed","unresolved":false,"context_lines":[{"line_number":79,"context_line":"    if obj:"},{"line_number":80,"context_line":"        type_is_valid \u003d False"},{"line_number":81,"context_line":"        try:"},{"line_number":82,"context_line":"            if resource_type \u003d\u003d obj.obj_name():"},{"line_number":83,"context_line":"                type_is_valid \u003d True"},{"line_number":84,"context_line":"        finally:"},{"line_number":85,"context_line":"            if not type_is_valid:"}],"source_content_type":"text/x-python","patch_set":6,"id":"1a4dcd0f_67ee5dee","line":82,"updated":"2015-08-03 16:09:05.000000000","message":"This is sick. I\u0027ll rework.","commit_id":"0b5d7748785493f99d642f9ad43034079f4206b5"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d74555770e84cc04cada7f9780f74356d29a798f","unresolved":false,"context_lines":[{"line_number":57,"context_line":"    :param obj: a supported resource object that we want to notify about."},{"line_number":58,"context_line":"    :param event_type: the type of event (CREATED, UPDATED, DELETED)"},{"line_number":59,"context_line":"    \"\"\""},{"line_number":60,"context_line":"    raise NotImplementedError()"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"def clear():"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a4dcd0f_e6a6c2c0","line":60,"updated":"2015-08-04 12:34:49.000000000","message":"I guess also moved to a follow up?","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"55990db309c7d84b789eaa1b31bff8d7a6f60bfc","unresolved":false,"context_lines":[{"line_number":57,"context_line":"    :param obj: a supported resource object that we want to notify about."},{"line_number":58,"context_line":"    :param event_type: the type of event (CREATED, UPDATED, DELETED)"},{"line_number":59,"context_line":"    \"\"\""},{"line_number":60,"context_line":"    raise NotImplementedError()"},{"line_number":61,"context_line":""},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"def clear():"}],"source_content_type":"text/x-python","patch_set":14,"id":"1a4dcd0f_d957db00","line":60,"in_reply_to":"1a4dcd0f_e6a6c2c0","updated":"2015-08-04 14:07:24.000000000","message":"We don\u0027t have that one yet in this patch, so follow up.","commit_id":"8ba204a7da408e0eb10f9d0ff7fb33fb60f4596d"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    _get_manager().unregister(resource_type)"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"def notify(context, resource, event_type):"},{"line_number":51,"context_line":"    \"\"\"Notify about a resource event."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    All remote consumers subscribed to the resource type will receive it"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_817d23e9","line":50,"updated":"2015-08-05 13:07:50.000000000","message":"As we agreed, this is not needed. Should we remove it later or take advantage of broken gate and fix it in this patch?","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":47,"context_line":"    _get_manager().unregister(resource_type)"},{"line_number":48,"context_line":""},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"def notify(context, resource, event_type):"},{"line_number":51,"context_line":"    \"\"\"Notify about a resource event."},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    All remote consumers subscribed to the resource type will receive it"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_2bb749f6","line":50,"in_reply_to":"1a4dcd0f_817d23e9","updated":"2015-08-05 13:45:17.000000000","message":"This is still needed to hide rpc details from pushers. They just call to registry.notify and don\u0027t care more how it\u0027s implemented. We could even extend this function to also call to consumer.registry.notify directly in addition to rpc, to support cases where separate parts of the same process may want to share objects in loose manner.","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":73,"context_line":"    :returns: NeutronObject"},{"line_number":74,"context_line":"    \"\"\""},{"line_number":75,"context_line":"    callback \u003d _get_manager().get_callback(resource_type)"},{"line_number":76,"context_line":"    if not callback:"},{"line_number":77,"context_line":"        raise exceptions.CallbackNotFound(resource_type\u003dresource_type)"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    obj \u003d callback(resource_type, resource_id, **kwargs)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_61325712","line":76,"updated":"2015-08-05 13:07:50.000000000","message":"This can\u0027t happen, get_callback() raises (imho correctly) CallbackNotFound in case callback is not registered.","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":73,"context_line":"    :returns: NeutronObject"},{"line_number":74,"context_line":"    \"\"\""},{"line_number":75,"context_line":"    callback \u003d _get_manager().get_callback(resource_type)"},{"line_number":76,"context_line":"    if not callback:"},{"line_number":77,"context_line":"        raise exceptions.CallbackNotFound(resource_type\u003dresource_type)"},{"line_number":78,"context_line":""},{"line_number":79,"context_line":"    obj \u003d callback(resource_type, resource_id, **kwargs)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_eb940144","line":76,"in_reply_to":"1a4dcd0f_61325712","updated":"2015-08-05 13:45:17.000000000","message":"You are absolutely right. :)","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"926c468d6d2dcf5baaa5374a788dca4df33cfa49","unresolved":false,"context_lines":[{"line_number":33,"context_line":"    return _CALLBACK_MANAGER"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"# TODO(QoS): rename into provide"},{"line_number":37,"context_line":"def register(callback, resource_type):"},{"line_number":38,"context_line":"    \"\"\"Register a callback as a producer for the resource type."},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"1a4dcd0f_31857806","line":36,"updated":"2015-08-05 14:03:14.000000000","message":"register/unregister seems also fine here, since this is producer.register ... quite idiomatic.\n\nproducer.provide(\u003cresouce_type\u003e, callback) is also quite idiomatic.","commit_id":"029466c2fc500caa92ebf50201ff04b16c9cea9f"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"1ab8ad055c2f02f711c0c0adf547c9eede78dea3","unresolved":false,"context_lines":[{"line_number":33,"context_line":"    return _CALLBACK_MANAGER"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"# TODO(QoS): rename into provide"},{"line_number":37,"context_line":"def register(callback, resource_type):"},{"line_number":38,"context_line":"    \"\"\"Register a callback as a producer for the resource type."},{"line_number":39,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"1a4dcd0f_2a7ada77","line":36,"in_reply_to":"1a4dcd0f_31857806","updated":"2015-08-05 15:54:55.000000000","message":"The problem with \u0027register\u0027 is that subscription is also registration. We need something more specific, and I find provide a better term.","commit_id":"029466c2fc500caa92ebf50201ff04b16c9cea9f"},{"author":{"_account_id":12171,"name":"Moshe Levi","email":"moshele@nvidia.com","username":"moshele"},"change_message_id":"f8c8250732a6f58cd202c0c608dcfc1cacb6652f","unresolved":false,"context_lines":[{"line_number":78,"context_line":"    \"\"\""},{"line_number":79,"context_line":"    callback \u003d _get_manager().get_callback(resource_type)"},{"line_number":80,"context_line":"    obj \u003d callback(resource_type, resource_id, **kwargs)"},{"line_number":81,"context_line":"    if obj:"},{"line_number":82,"context_line":"        if (not isinstance(obj, base.NeutronObject) or"},{"line_number":83,"context_line":"            resource_type !\u003d obj.obj_name()):"},{"line_number":84,"context_line":"            raise exceptions.CallbackWrongResourceType("}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_7723dea7","line":81,"updated":"2015-08-05 20:05:47.000000000","message":"why ignoring if  callback return none? should not  you throw exception?","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"b973f2fd68a50b189019744440a897f21e1b13e5","unresolved":false,"context_lines":[{"line_number":78,"context_line":"    \"\"\""},{"line_number":79,"context_line":"    callback \u003d _get_manager().get_callback(resource_type)"},{"line_number":80,"context_line":"    obj \u003d callback(resource_type, resource_id, **kwargs)"},{"line_number":81,"context_line":"    if obj:"},{"line_number":82,"context_line":"        if (not isinstance(obj, base.NeutronObject) or"},{"line_number":83,"context_line":"            resource_type !\u003d obj.obj_name()):"},{"line_number":84,"context_line":"            raise exceptions.CallbackWrongResourceType("}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_fb3819f0","line":81,"in_reply_to":"1a4dcd0f_7723dea7","updated":"2015-08-06 12:15:43.000000000","message":"I think that is a way that callback identifies it does not have an object.","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"5f7f8b28cace9ec96d36f14a4c2cc8ed633df167","unresolved":false,"context_lines":[{"line_number":1,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":2,"context_line":"#    not use this file except in compliance with the License. You may obtain"},{"line_number":3,"context_line":"#    a copy of the License at"},{"line_number":4,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_e82d71fe","line":1,"updated":"2015-08-07 14:13:02.000000000","message":"where is the push()","commit_id":"f6de663712fc5d63e9e8dda87ca3e26c0ae76101"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"dc30945eb467445e92ca97f7632462f9accc9027","unresolved":false,"context_lines":[{"line_number":1,"context_line":"#    Licensed under the Apache License, Version 2.0 (the \"License\"); you may"},{"line_number":2,"context_line":"#    not use this file except in compliance with the License. You may obtain"},{"line_number":3,"context_line":"#    a copy of the License at"},{"line_number":4,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_b3583a8b","line":1,"in_reply_to":"1a4dcd0f_e82d71fe","updated":"2015-08-07 14:28:36.000000000","message":"Push is in the next patch.","commit_id":"f6de663712fc5d63e9e8dda87ca3e26c0ae76101"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"5f7f8b28cace9ec96d36f14a4c2cc8ed633df167","unresolved":false,"context_lines":[{"line_number":45,"context_line":"    _get_manager().clear()"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"def pull(resource_type, resource_id, **kwargs):"},{"line_number":49,"context_line":"    \"\"\"Get resource object that corresponds to resource id."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"    The function will return an object that is provided by resource producer."}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_48fd85af","line":48,"updated":"2015-08-07 14:13:02.000000000","message":"should provider needs a pull, I think it is used by consumer?","commit_id":"f6de663712fc5d63e9e8dda87ca3e26c0ae76101"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"dc30945eb467445e92ca97f7632462f9accc9027","unresolved":false,"context_lines":[{"line_number":45,"context_line":"    _get_manager().clear()"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"def pull(resource_type, resource_id, **kwargs):"},{"line_number":49,"context_line":"    \"\"\"Get resource object that corresponds to resource id."},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"    The function will return an object that is provided by resource producer."}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_13f48e58","line":48,"in_reply_to":"1a4dcd0f_48fd85af","updated":"2015-08-07 14:28:36.000000000","message":"This pull function is a server side handler for pull requests. And it relies on providers to get the needed resource.","commit_id":"f6de663712fc5d63e9e8dda87ca3e26c0ae76101"}],"neutron/api/rpc/callbacks/resource_manager.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":49,"context_line":"    def unregister(self, resource_type):"},{"line_number":50,"context_line":"        \"\"\"Unregister callback from the registry."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        :param resource: must be a valid resource type."},{"line_number":53,"context_line":"        \"\"\""},{"line_number":54,"context_line":"        LOG.debug(\"Unregistering producer for %s\", resource_type)"},{"line_number":55,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_1c321111","line":52,"updated":"2015-08-04 14:52:17.000000000","message":"Nit: resource_type","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[{"line_number":49,"context_line":"    def unregister(self, resource_type):"},{"line_number":50,"context_line":"        \"\"\"Unregister callback from the registry."},{"line_number":51,"context_line":""},{"line_number":52,"context_line":"        :param resource: must be a valid resource type."},{"line_number":53,"context_line":"        \"\"\""},{"line_number":54,"context_line":"        LOG.debug(\"Unregistering producer for %s\", resource_type)"},{"line_number":55,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_5c641448","line":52,"in_reply_to":"1a4dcd0f_1c321111","updated":"2015-08-04 19:57:14.000000000","message":"Done","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def clear(self):"},{"line_number":64,"context_line":"        \"\"\"Brings the manager to a clean state.\"\"\""},{"line_number":65,"context_line":"        self._callbacks \u003d collections.defaultdict(dict)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def get_callback(self, resource_type):"},{"line_number":68,"context_line":"        \"\"\"Return the callback if found, None otherwise."}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_c7505661","line":65,"updated":"2015-08-04 14:52:17.000000000","message":"Sorry for commenting on unrelated stuff :) but why is this defaultdict? Do I get it correctly that if callback for given resource_type is registered, a callback is returned on L75 but if it\u0027s not registered, than empty dict is returned? I think simple dict() should be here instead and return None or better raise exception.","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def clear(self):"},{"line_number":64,"context_line":"        \"\"\"Brings the manager to a clean state.\"\"\""},{"line_number":65,"context_line":"        self._callbacks \u003d collections.defaultdict(dict)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def get_callback(self, resource_type):"},{"line_number":68,"context_line":"        \"\"\"Return the callback if found, None otherwise."}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_dc502461","line":65,"in_reply_to":"1a4dcd0f_c7505661","updated":"2015-08-04 19:57:14.000000000","message":"Indeed. That\u0027s the weird code.","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":98,"context_line":"        :param resource_type: must be a valid resource type."},{"line_number":99,"context_line":"        \"\"\""},{"line_number":100,"context_line":"        LOG.debug(\"Registering consumer for %s\", resource_type)"},{"line_number":101,"context_line":"        if not resources.is_valid_resource_type(resource_type):"},{"line_number":102,"context_line":"            raise exceptions.Invalid(element\u003d\u0027resource\u0027, value\u003dresource_type)"},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        self._callbacks[resource_type].add(callback)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_dcdeae6c","line":101,"updated":"2015-08-05 13:07:50.000000000","message":"Optional: The same construction of validation is used twice here. We could make a function out of it and call it.","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"9a4815b117a2ce5037e8d87c365b99fc33b1ada2","unresolved":false,"context_lines":[{"line_number":98,"context_line":"        :param resource_type: must be a valid resource type."},{"line_number":99,"context_line":"        \"\"\""},{"line_number":100,"context_line":"        LOG.debug(\"Registering consumer for %s\", resource_type)"},{"line_number":101,"context_line":"        if not resources.is_valid_resource_type(resource_type):"},{"line_number":102,"context_line":"            raise exceptions.Invalid(element\u003d\u0027resource\u0027, value\u003dresource_type)"},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        self._callbacks[resource_type].add(callback)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_0e429b68","line":101,"in_reply_to":"1a4dcd0f_aba83978","updated":"2015-08-05 13:56:33.000000000","message":"I wanted to write six but I can only count to two.","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":98,"context_line":"        :param resource_type: must be a valid resource type."},{"line_number":99,"context_line":"        \"\"\""},{"line_number":100,"context_line":"        LOG.debug(\"Registering consumer for %s\", resource_type)"},{"line_number":101,"context_line":"        if not resources.is_valid_resource_type(resource_type):"},{"line_number":102,"context_line":"            raise exceptions.Invalid(element\u003d\u0027resource\u0027, value\u003dresource_type)"},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        self._callbacks[resource_type].add(callback)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_aba83978","line":101,"in_reply_to":"1a4dcd0f_dcdeae6c","updated":"2015-08-05 13:45:17.000000000","message":"You are absolutely wrong: it\u0027s used six times, not two! :-) Good catch.","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":12171,"name":"Moshe Levi","email":"moshele@nvidia.com","username":"moshele"},"change_message_id":"f8c8250732a6f58cd202c0c608dcfc1cacb6652f","unresolved":false,"context_lines":[{"line_number":31,"context_line":""},{"line_number":32,"context_line":"class ResourceProducerCallbacksManager(object):"},{"line_number":33,"context_line":"    \"\"\"A callback system that allows information providers in a loose manner."},{"line_number":34,"context_line":"    \"\"\""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    def __init__(self):"},{"line_number":37,"context_line":"        self.clear()"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_d7e51238","line":34,"updated":"2015-08-05 20:05:47.000000000","message":"most of the code is duplicate. the only difference is that ResourceProducerCallbacksManager can register one callback\nand ResourceConsumerCallbacksManager can register one unlimited \ncan you make base class that you can configure threshold of callback which one will have 0 (as unlimited) and the other with 1.","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"b973f2fd68a50b189019744440a897f21e1b13e5","unresolved":false,"context_lines":[{"line_number":31,"context_line":""},{"line_number":32,"context_line":"class ResourceProducerCallbacksManager(object):"},{"line_number":33,"context_line":"    \"\"\"A callback system that allows information providers in a loose manner."},{"line_number":34,"context_line":"    \"\"\""},{"line_number":35,"context_line":""},{"line_number":36,"context_line":"    def __init__(self):"},{"line_number":37,"context_line":"        self.clear()"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_bb27f1c8","line":34,"in_reply_to":"1a4dcd0f_d7e51238","updated":"2015-08-06 12:15:43.000000000","message":"Done","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"ceaff1492f7eee38d5b573c2d0aafdddfab46445","unresolved":false,"context_lines":[{"line_number":46,"context_line":"                len(self._callbacks[resource_type]) \u003e\u003d self.max_callbacks)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def _add_callback(self, callback, resource_type):"},{"line_number":49,"context_line":"        try:"},{"line_number":50,"context_line":"            self._callbacks[resource_type].add(callback)"},{"line_number":51,"context_line":"        except KeyError:"},{"line_number":52,"context_line":"            self._callbacks[resource_type] \u003d {callback}"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a4dcd0f_0db80174","line":49,"updated":"2015-08-07 07:55:26.000000000","message":"This sounds like collections.defaultdict(set) or am I missing something?","commit_id":"78ea98ddbd576575728f8a2e334d1606ce0fec08"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"9eec6748d187a944a91452171098e7d6068dac0b","unresolved":false,"context_lines":[{"line_number":46,"context_line":"                len(self._callbacks[resource_type]) \u003e\u003d self.max_callbacks)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def _add_callback(self, callback, resource_type):"},{"line_number":49,"context_line":"        try:"},{"line_number":50,"context_line":"            self._callbacks[resource_type].add(callback)"},{"line_number":51,"context_line":"        except KeyError:"},{"line_number":52,"context_line":"            self._callbacks[resource_type] \u003d {callback}"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a4dcd0f_d0c2ae84","line":49,"in_reply_to":"1a4dcd0f_0db80174","updated":"2015-08-07 08:06:06.000000000","message":"Ouch, I don\u0027t know why I did it. I will do a follow up for that: https://review.openstack.org/210239","commit_id":"78ea98ddbd576575728f8a2e334d1606ce0fec08"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"bea1b910e03f28829bd4cca47f007ae3c82191d1","unresolved":false,"context_lines":[{"line_number":46,"context_line":"                len(self._callbacks[resource_type]) \u003e\u003d self.max_callbacks)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def _add_callback(self, callback, resource_type):"},{"line_number":49,"context_line":"        try:"},{"line_number":50,"context_line":"            self._callbacks[resource_type].add(callback)"},{"line_number":51,"context_line":"        except KeyError:"},{"line_number":52,"context_line":"            self._callbacks[resource_type] \u003d {callback}"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a4dcd0f_96709e41","line":49,"in_reply_to":"1a4dcd0f_369e6ab9","updated":"2015-08-07 08:54:44.000000000","message":"Ah, so get_callbacks() should be\n\n callbacks \u003d self._callbacks[resource_type]\n if not callbacks and do_raise:\n    raise ...\n return callbacks","commit_id":"78ea98ddbd576575728f8a2e334d1606ce0fec08"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"268bb5d581db833d208573feaa76000bf9ebb58a","unresolved":false,"context_lines":[{"line_number":46,"context_line":"                len(self._callbacks[resource_type]) \u003e\u003d self.max_callbacks)"},{"line_number":47,"context_line":""},{"line_number":48,"context_line":"    def _add_callback(self, callback, resource_type):"},{"line_number":49,"context_line":"        try:"},{"line_number":50,"context_line":"            self._callbacks[resource_type].add(callback)"},{"line_number":51,"context_line":"        except KeyError:"},{"line_number":52,"context_line":"            self._callbacks[resource_type] \u003d {callback}"}],"source_content_type":"text/x-python","patch_set":24,"id":"1a4dcd0f_369e6ab9","line":49,"in_reply_to":"1a4dcd0f_d0c2ae84","updated":"2015-08-07 08:46:07.000000000","message":"actually, it would not allow us to raise KeyError on access attempt.","commit_id":"78ea98ddbd576575728f8a2e334d1606ce0fec08"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"5f7f8b28cace9ec96d36f14a4c2cc8ed633df167","unresolved":false,"context_lines":[{"line_number":9,"context_line":"#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the"},{"line_number":10,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":11,"context_line":"#    under the License."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"import collections"},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"from oslo_log import log as logging"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_08ef7d1e","side":"PARENT","line":12,"updated":"2015-08-07 14:13:02.000000000","message":"seems no need to remove this space.\nI remember we should have one","commit_id":"cc0ae6dd49da3e67c1d0400bc422e735c27e98fb"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"dc30945eb467445e92ca97f7632462f9accc9027","unresolved":false,"context_lines":[{"line_number":9,"context_line":"#    WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the"},{"line_number":10,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":11,"context_line":"#    under the License."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"import collections"},{"line_number":14,"context_line":""},{"line_number":15,"context_line":"from oslo_log import log as logging"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_f397a2e9","side":"PARENT","line":12,"in_reply_to":"1a4dcd0f_08ef7d1e","updated":"2015-08-07 14:28:36.000000000","message":"No, we don\u0027t. I don\u0027t want to respin for that one, sorry.","commit_id":"cc0ae6dd49da3e67c1d0400bc422e735c27e98fb"},{"author":{"_account_id":2874,"name":"yong sheng gong","email":"gong.yongsheng@99cloud.net","username":"gongysh"},"change_message_id":"5f7f8b28cace9ec96d36f14a4c2cc8ed633df167","unresolved":false,"context_lines":[{"line_number":92,"context_line":"    def get_callbacks(self, resource_type, do_raise\u003dFalse):"},{"line_number":93,"context_line":"        \"\"\"Return the callback if found, None otherwise."},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        :param resource_type: must be a valid resource type."},{"line_number":96,"context_line":"        \"\"\""},{"line_number":97,"context_line":"        _validate_resource_type(resource_type)"},{"line_number":98,"context_line":"        callbacks \u003d self._callbacks[resource_type]"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_1c0b43d7","line":95,"updated":"2015-08-07 14:13:02.000000000","message":"add comment for do_raise?","commit_id":"f6de663712fc5d63e9e8dda87ca3e26c0ae76101"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"dc30945eb467445e92ca97f7632462f9accc9027","unresolved":false,"context_lines":[{"line_number":92,"context_line":"    def get_callbacks(self, resource_type, do_raise\u003dFalse):"},{"line_number":93,"context_line":"        \"\"\"Return the callback if found, None otherwise."},{"line_number":94,"context_line":""},{"line_number":95,"context_line":"        :param resource_type: must be a valid resource type."},{"line_number":96,"context_line":"        \"\"\""},{"line_number":97,"context_line":"        _validate_resource_type(resource_type)"},{"line_number":98,"context_line":"        callbacks \u003d self._callbacks[resource_type]"}],"source_content_type":"text/x-python","patch_set":25,"id":"1a4dcd0f_93873eb4","line":95,"in_reply_to":"1a4dcd0f_1c0b43d7","updated":"2015-08-07 14:28:36.000000000","message":"Let\u0027s do it in follow up. BTW one of follow ups will just kill it.","commit_id":"f6de663712fc5d63e9e8dda87ca3e26c0ae76101"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"3b44ed3810fa887e44284b2224e8b7fde3009b37","unresolved":false,"context_lines":[{"line_number":47,"context_line":"            cls._instance \u003d super(ResourceCallbacksManager, cls).__new__(cls)"},{"line_number":48,"context_line":"        return cls._instance"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":"    @abc.abstractmethod"},{"line_number":51,"context_line":"    def _add_callback(self, callback, resource_type):"},{"line_number":52,"context_line":"        pass"},{"line_number":53,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"1a4dcd0f_1161e1d2","line":50,"updated":"2015-08-07 16:25:01.000000000","message":"Nice refactor for reuse.","commit_id":"c60a5d4eebc4545331f90b5bb7687e50aef07b0e"}],"neutron/api/rpc/handlers/resources_rpc.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"1bebb5e97cfba3599a2666cc512ca40ef1171b07","unresolved":false,"context_lines":[{"line_number":60,"context_line":"            namespace\u003dconstants.RPC_NAMESPACE_RESOURCES)"},{"line_number":61,"context_line":"        self.client \u003d n_rpc.get_client(target)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    @log_helpers.log_method_call"},{"line_number":64,"context_line":"    def get_info(self, context, resource_type, resource_id):"},{"line_number":65,"context_line":"        _validate_resource_type(resource_type)"},{"line_number":66,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a4dcd0f_bea3154f","line":63,"updated":"2015-08-03 14:06:10.000000000","message":"get_object","commit_id":"ef94077fdaa4eb50372db06a54f66e86d517b77f"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        # make it a singleton"},{"line_number":59,"context_line":"        if not hasattr(cls, \u0027_instance\u0027):"},{"line_number":60,"context_line":"            cls._instance \u003d super(ResourcesServerRpcApi, cls).__new__(cls)"},{"line_number":61,"context_line":"        return cls._instance"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def __init__(self):"},{"line_number":64,"context_line":"        target \u003d oslo_messaging.Target("}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_c278442e","line":61,"updated":"2015-08-04 14:52:17.000000000","message":"Python Singleton ftw!","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"}],"neutron/services/qos/notification_drivers/message_queue.py":[{"author":{"_account_id":12171,"name":"Moshe Levi","email":"moshele@nvidia.com","username":"moshele"},"change_message_id":"f8c8250732a6f58cd202c0c608dcfc1cacb6652f","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        pass"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def update_policy(self, policy):"},{"line_number":54,"context_line":"        # TODO(QoS): this is temporary until we get notify() implemented"},{"line_number":55,"context_line":"        try:"},{"line_number":56,"context_line":"            registry.notify(resources.QOS_POLICY, events.UPDATED, policy)"},{"line_number":57,"context_line":"        except NotImplementedError:"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_b765e6b5","line":54,"updated":"2015-08-05 20:05:47.000000000","message":"are the TODO still relevant here?","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"b973f2fd68a50b189019744440a897f21e1b13e5","unresolved":false,"context_lines":[{"line_number":51,"context_line":"        pass"},{"line_number":52,"context_line":""},{"line_number":53,"context_line":"    def update_policy(self, policy):"},{"line_number":54,"context_line":"        # TODO(QoS): this is temporary until we get notify() implemented"},{"line_number":55,"context_line":"        try:"},{"line_number":56,"context_line":"            registry.notify(resources.QOS_POLICY, events.UPDATED, policy)"},{"line_number":57,"context_line":"        except NotImplementedError:"}],"source_content_type":"text/x-python","patch_set":21,"id":"1a4dcd0f_9b2a358f","line":54,"in_reply_to":"1a4dcd0f_b765e6b5","updated":"2015-08-06 12:15:43.000000000","message":"they are since notify is still not implemented (it will be done in Jakub\u0027s patches).","commit_id":"65cc1e7871cf3376c3866af18e33deb032dcad22"}],"neutron/tests/unit/api/rpc/callbacks/consumer/test_registry.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"1a4dcd0f_7c1c75c1","updated":"2015-08-04 14:52:17.000000000","message":"I find consumer.registry just as a proxy for ResourceconsumerCallbacksManager() singleton encapsulation. Some of test cases below tests rather manager itself then proxying calls to the manager.","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"1a4dcd0f_7f78d52b","in_reply_to":"1a4dcd0f_7c1c75c1","updated":"2015-08-04 19:57:14.000000000","message":"Done","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from neutron.api.rpc.callbacks import resource_manager"},{"line_number":18,"context_line":"from neutron.api.rpc.callbacks import resources"},{"line_number":19,"context_line":"from neutron.api.rpc.handlers import resources_rpc"},{"line_number":20,"context_line":"from neutron.objects.qos import policy"},{"line_number":21,"context_line":"from neutron.tests import base"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_1ca211af","line":20,"updated":"2015-08-04 14:52:17.000000000","message":"What does qos have to do with this general consumer registry? :) I would rather use FakeResource.","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[{"line_number":17,"context_line":"from neutron.api.rpc.callbacks import resource_manager"},{"line_number":18,"context_line":"from neutron.api.rpc.callbacks import resources"},{"line_number":19,"context_line":"from neutron.api.rpc.handlers import resources_rpc"},{"line_number":20,"context_line":"from neutron.objects.qos import policy"},{"line_number":21,"context_line":"from neutron.tests import base"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_3f724d4a","line":20,"in_reply_to":"1a4dcd0f_1ca211af","updated":"2015-08-04 19:57:14.000000000","message":"Done","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":34,"context_line":"        self.assertEqual(registry._get_manager(),"},{"line_number":35,"context_line":"                         registry._get_manager())"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def test_subscribe(self):"},{"line_number":38,"context_line":"        self.called \u003d False"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        def _fake_policy_cb(resource_type, resources, event_type):"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_fc296538","line":37,"updated":"2015-08-04 14:52:17.000000000","message":"General comment to all below:\nAre there not used mocks just because of memory? e.g.\n\n _fake_policy_cb \u003d mock.Mock()\n ...\n self.assertTrue(_fake_policy_cb.called)\n\nor more explicit:\n\n _fake_policy_cb.assert_called_with(\n     resources.QOS_POLICY, policy_obj, events.CREATED)","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[{"line_number":34,"context_line":"        self.assertEqual(registry._get_manager(),"},{"line_number":35,"context_line":"                         registry._get_manager())"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def test_subscribe(self):"},{"line_number":38,"context_line":"        self.called \u003d False"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        def _fake_policy_cb(resource_type, resources, event_type):"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_ff07057f","line":37,"in_reply_to":"1a4dcd0f_fc296538","updated":"2015-08-04 19:57:14.000000000","message":"Done","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":35,"context_line":"                         registry._get_manager())"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def test_subscribe(self):"},{"line_number":38,"context_line":"        self.called \u003d False"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        def _fake_policy_cb(resource_type, resources, event_type):"},{"line_number":41,"context_line":"            self.called \u003d True"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_7c19d578","line":38,"updated":"2015-08-04 14:52:17.000000000","message":"Nit: not needed self, _fake_policy_cb will get it from test_subscribe\u0027s closure.","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[{"line_number":35,"context_line":"                         registry._get_manager())"},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"    def test_subscribe(self):"},{"line_number":38,"context_line":"        self.called \u003d False"},{"line_number":39,"context_line":""},{"line_number":40,"context_line":"        def _fake_policy_cb(resource_type, resources, event_type):"},{"line_number":41,"context_line":"            self.called \u003d True"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_3fd7adee","line":38,"in_reply_to":"1a4dcd0f_7c19d578","updated":"2015-08-04 19:57:14.000000000","message":"Actually needed: the function does not see it otherwise. Not sure why.","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":23,"context_line":"        super(ConsumerRegistryTestCase, self).setUp()"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"    def test__get_manager_is_singleton(self):"},{"line_number":26,"context_line":"        self.assertEqual(registry._get_manager(),"},{"line_number":27,"context_line":"                         registry._get_manager())"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    @mock.patch.object(resources_rpc.ResourcesServerRpcApi, \u0027get_resource\u0027)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_7c30ba9e","line":26,"updated":"2015-08-05 13:07:50.000000000","message":"We should test on identity here:\n\n self.assertIs()","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":23,"context_line":"        super(ConsumerRegistryTestCase, self).setUp()"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"    def test__get_manager_is_singleton(self):"},{"line_number":26,"context_line":"        self.assertEqual(registry._get_manager(),"},{"line_number":27,"context_line":"                         registry._get_manager())"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    @mock.patch.object(resources_rpc.ResourcesServerRpcApi, \u0027get_resource\u0027)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_eb25e108","line":26,"in_reply_to":"1a4dcd0f_7c30ba9e","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    @mock.patch.object(resources_rpc.ResourcesServerRpcApi, \u0027get_resource\u0027)"},{"line_number":30,"context_line":"    def test_get_resource(self, get_resource_mock):"},{"line_number":31,"context_line":"        context \u003d mock.Mock()"},{"line_number":32,"context_line":"        registry.get_resource(context, \u0027TYPE\u0027, \u0027fake_id\u0027)"},{"line_number":33,"context_line":"        get_resource_mock.assert_called_with(context, \u0027TYPE\u0027, \u0027fake_id\u0027)"},{"line_number":34,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_9cf266d1","line":31,"updated":"2015-08-05 13:07:50.000000000","message":"Nit: object() is less expensive","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":28,"context_line":""},{"line_number":29,"context_line":"    @mock.patch.object(resources_rpc.ResourcesServerRpcApi, \u0027get_resource\u0027)"},{"line_number":30,"context_line":"    def test_get_resource(self, get_resource_mock):"},{"line_number":31,"context_line":"        context \u003d mock.Mock()"},{"line_number":32,"context_line":"        registry.get_resource(context, \u0027TYPE\u0027, \u0027fake_id\u0027)"},{"line_number":33,"context_line":"        get_resource_mock.assert_called_with(context, \u0027TYPE\u0027, \u0027fake_id\u0027)"},{"line_number":34,"context_line":""}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_6b80f1c0","line":31,"in_reply_to":"1a4dcd0f_9cf266d1","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":55,"context_line":"        resource_ \u003d mock.Mock()"},{"line_number":56,"context_line":"        event_type_ \u003d mock.Mock()"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"        def _cb(resource_type, resource, event_type):"},{"line_number":59,"context_line":"            self.assertEqual(resource_type_, resource_type)"},{"line_number":60,"context_line":"            self.assertEqual(resource_, resource)"},{"line_number":61,"context_line":"            self.assertEqual(event_type_, event_type)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_dc40eea7","line":58,"updated":"2015-08-05 13:07:50.000000000","message":"Is this a leftover?","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":55,"context_line":"        resource_ \u003d mock.Mock()"},{"line_number":56,"context_line":"        event_type_ \u003d mock.Mock()"},{"line_number":57,"context_line":""},{"line_number":58,"context_line":"        def _cb(resource_type, resource, event_type):"},{"line_number":59,"context_line":"            self.assertEqual(resource_type_, resource_type)"},{"line_number":60,"context_line":"            self.assertEqual(resource_, resource)"},{"line_number":61,"context_line":"            self.assertEqual(event_type_, event_type)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_2b8669db","line":58,"in_reply_to":"1a4dcd0f_dc40eea7","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":63,"context_line":""},{"line_number":64,"context_line":"        callback1 \u003d mock.Mock()"},{"line_number":65,"context_line":"        callback2 \u003d mock.Mock()"},{"line_number":66,"context_line":"        callbacks \u003d [callback1, callback2]"},{"line_number":67,"context_line":"        manager_mock().get_callbacks.return_value \u003d set(callbacks)"},{"line_number":68,"context_line":"        registry.notify(resource_type_, resource_, event_type_)"},{"line_number":69,"context_line":"        for callback in callbacks:"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_bcd722ec","line":66,"updated":"2015-08-05 13:07:50.000000000","message":"Nit: {callbacks1, callback2}","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":63,"context_line":""},{"line_number":64,"context_line":"        callback1 \u003d mock.Mock()"},{"line_number":65,"context_line":"        callback2 \u003d mock.Mock()"},{"line_number":66,"context_line":"        callbacks \u003d [callback1, callback2]"},{"line_number":67,"context_line":"        manager_mock().get_callbacks.return_value \u003d set(callbacks)"},{"line_number":68,"context_line":"        registry.notify(resource_type_, resource_, event_type_)"},{"line_number":69,"context_line":"        for callback in callbacks:"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_ab72790f","line":66,"in_reply_to":"1a4dcd0f_bcd722ec","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"774df977d8942933bfe8153973de6f3a8c5da576","unresolved":false,"context_lines":[{"line_number":50,"context_line":""},{"line_number":51,"context_line":"    @mock.patch.object(registry, \u0027_get_manager\u0027)"},{"line_number":52,"context_line":"    def test_notify(self, manager_mock):"},{"line_number":53,"context_line":"        resource_type_ \u003d mock.Mock()"},{"line_number":54,"context_line":"        resource_ \u003d mock.Mock()"},{"line_number":55,"context_line":"        event_type_ \u003d mock.Mock()"},{"line_number":56,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"1a4dcd0f_310c983a","line":53,"updated":"2015-08-05 13:57:41.000000000","message":"I silently point out this could also be an object() but let\u0027s leave it as is and sacrifice a few bytes of memory :)","commit_id":"029466c2fc500caa92ebf50201ff04b16c9cea9f"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"1ab8ad055c2f02f711c0c0adf547c9eede78dea3","unresolved":false,"context_lines":[{"line_number":50,"context_line":""},{"line_number":51,"context_line":"    @mock.patch.object(registry, \u0027_get_manager\u0027)"},{"line_number":52,"context_line":"    def test_notify(self, manager_mock):"},{"line_number":53,"context_line":"        resource_type_ \u003d mock.Mock()"},{"line_number":54,"context_line":"        resource_ \u003d mock.Mock()"},{"line_number":55,"context_line":"        event_type_ \u003d mock.Mock()"},{"line_number":56,"context_line":""}],"source_content_type":"text/x-python","patch_set":20,"id":"1a4dcd0f_0add9e6e","line":53,"in_reply_to":"1a4dcd0f_310c983a","updated":"2015-08-05 15:54:55.000000000","message":"Done","commit_id":"029466c2fc500caa92ebf50201ff04b16c9cea9f"}],"neutron/tests/unit/api/rpc/callbacks/producer/test_registry.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":41,"context_line":"            registry.get_resource(resources.QOS_POLICY, \u0027fake_id\u0027))"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    def test_get_resource_does_not_raise_on_none(self):"},{"line_number":44,"context_line":"        def _wrong_type_cb(*args, **kwargs):"},{"line_number":45,"context_line":"            pass"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        registry.register(_wrong_type_cb, resources.QOS_POLICY)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_dc78eec6","line":44,"updated":"2015-08-05 13:07:50.000000000","message":"wrong type?","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":41,"context_line":"            registry.get_resource(resources.QOS_POLICY, \u0027fake_id\u0027))"},{"line_number":42,"context_line":""},{"line_number":43,"context_line":"    def test_get_resource_does_not_raise_on_none(self):"},{"line_number":44,"context_line":"        def _wrong_type_cb(*args, **kwargs):"},{"line_number":45,"context_line":"            pass"},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"        registry.register(_wrong_type_cb, resources.QOS_POLICY)"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_0bcfed29","line":44,"in_reply_to":"1a4dcd0f_dc78eec6","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"0adce1220e3469a67fb90fef42254d44b1fc6ae6","unresolved":false,"context_lines":[{"line_number":65,"context_line":"            registry.get_resource, resources.QOS_POLICY, \u0027fake_id\u0027)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def test__get_manager_is_singleton(self):"},{"line_number":68,"context_line":"        self.assertEqual(registry._get_manager(),"},{"line_number":69,"context_line":"                         registry._get_manager())"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"    def test_unregister(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_fc084a2f","line":68,"updated":"2015-08-05 13:07:50.000000000","message":"assertIs()","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"628391b70aae3bc3fecdc1cddd48104baa2a6ea4","unresolved":false,"context_lines":[{"line_number":65,"context_line":"            registry.get_resource, resources.QOS_POLICY, \u0027fake_id\u0027)"},{"line_number":66,"context_line":""},{"line_number":67,"context_line":"    def test__get_manager_is_singleton(self):"},{"line_number":68,"context_line":"        self.assertEqual(registry._get_manager(),"},{"line_number":69,"context_line":"                         registry._get_manager())"},{"line_number":70,"context_line":""},{"line_number":71,"context_line":"    def test_unregister(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"1a4dcd0f_8be3fda3","line":68,"in_reply_to":"1a4dcd0f_fc084a2f","updated":"2015-08-05 13:45:17.000000000","message":"Done","commit_id":"ccf773163232ed64726f22d4f44bc8ba12e36bb5"}],"neutron/tests/unit/api/rpc/callbacks/test_resource_manager.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"1bebb5e97cfba3599a2666cc512ca40ef1171b07","unresolved":false,"context_lines":[{"line_number":10,"context_line":"#    License for the specific language governing permissions and limitations"},{"line_number":11,"context_line":"#    under the License."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"#TODO(QoS): remove this test, is testing the same thing as"},{"line_number":14,"context_line":"#           tests.unit.api.rpc.callbacks.producer.test_registry"},{"line_number":15,"context_line":"#           but more lightly"},{"line_number":16,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"1a4dcd0f_dec62116","line":13,"updated":"2015-08-03 14:06:10.000000000","message":"We can fry it now.","commit_id":"ef94077fdaa4eb50372db06a54f66e86d517b77f"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"bf1aae7f8baaa6fdd7b427f863285afc450d7ad7","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"1a4dcd0f_82eebcb2","updated":"2015-08-04 14:53:56.000000000","message":"Do we miss tests for ResrouceConsumerCallbacksManager?","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"1a4dcd0f_ff2e25f9","in_reply_to":"1a4dcd0f_82eebcb2","updated":"2015-08-04 19:57:14.000000000","message":"Done","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"2c0089bb545a3303a16db0ff0952034970df9633","unresolved":false,"context_lines":[{"line_number":21,"context_line":"from neutron.tests import base"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"class ResourcesCallbackRequestTestCase(base.BaseTestCase):"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    def setUp(self):"},{"line_number":27,"context_line":"        super(ResourcesCallbackRequestTestCase, self).setUp()"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_671e2265","line":24,"updated":"2015-08-04 14:52:17.000000000","message":"ResourceProducerCallbacksManagerTestCase","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"ce9a5e68cbea62f0eea795bd2d79a08ef745601d","unresolved":false,"context_lines":[{"line_number":21,"context_line":"from neutron.tests import base"},{"line_number":22,"context_line":""},{"line_number":23,"context_line":""},{"line_number":24,"context_line":"class ResourcesCallbackRequestTestCase(base.BaseTestCase):"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    def setUp(self):"},{"line_number":27,"context_line":"        super(ResourcesCallbackRequestTestCase, self).setUp()"}],"source_content_type":"text/x-python","patch_set":16,"id":"1a4dcd0f_bf389d3e","line":24,"in_reply_to":"1a4dcd0f_671e2265","updated":"2015-08-04 19:57:14.000000000","message":"Done","commit_id":"9a04d56a3e852df8a28490f155bdf22de5254c76"}],"neutron/tests/unit/services/qos/base.py":[{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"3b44ed3810fa887e44284b2224e8b7fde3009b37","unresolved":false,"context_lines":[{"line_number":23,"context_line":"        super(BaseQosTestCase, self).setUp()"},{"line_number":24,"context_line":""},{"line_number":25,"context_line":"        with mock.patch.object("},{"line_number":26,"context_line":"            resource_manager.ResourceCallbacksManager, \u0027_singleton\u0027,"},{"line_number":27,"context_line":"            new_callable\u003dmock.PropertyMock(return_value\u003dFalse)):"},{"line_number":28,"context_line":""},{"line_number":29,"context_line":"            self.cons_mgr \u003d resource_manager.ConsumerResourceCallbacksManager()"}],"source_content_type":"text/x-python","patch_set":29,"id":"1a4dcd0f_717aa525","line":26,"updated":"2015-08-07 16:25:01.000000000","message":"Ahh, ok, I needed a few seconds to understand, You\u0027re de-enforcing them to be able to test both.\n\nWouldn\u0027t it be easier to:\n\n   def cleanup_singleton():\n          resource_manager.ResourceCallbacksManager._singleton \u003d None\n   self.add_cleanup(cleanup_singleton)\n\nThere are chances I\u0027m missing interactions.","commit_id":"c60a5d4eebc4545331f90b5bb7687e50aef07b0e"}]}
