)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"60da8ef417c44a2ad42acc9672c538a8dfe21bbe","unresolved":false,"context_lines":[{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"},{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to declare a get_agents_resource_versions which is used the current"},{"line_number":15,"context_line":"cache of known resource consumers (agents) and versions."},{"line_number":16,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"9abb7d3a_f73d34bc","line":13,"range":{"start_line":13,"start_character":12,"end_line":13,"end_character":32},"updated":"2016-05-30 16:19:26.000000000","message":"Should we then document it somewhere in devref?","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"2ab33351349a95576b0d58e2e3679fd7d889c0b9","unresolved":false,"context_lines":[{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"},{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to declare a get_agents_resource_versions which is used the current"},{"line_number":15,"context_line":"cache of known resource consumers (agents) and versions."},{"line_number":16,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"9abb7d3a_f4219bfc","line":13,"range":{"start_line":13,"start_character":12,"end_line":13,"end_character":32},"in_reply_to":"9abb7d3a_f73d34bc","updated":"2016-05-31 07:49:59.000000000","message":"Yes, makes sense.","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"60da8ef417c44a2ad42acc9672c538a8dfe21bbe","unresolved":false,"context_lines":[{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to declare a get_agents_resource_versions which is used the current"},{"line_number":15,"context_line":"cache of known resource consumers (agents) and versions."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"If we eventually need to have more consumer types (for example, other"},{"line_number":18,"context_line":"neutron-servers consuming specific resources as they change) this mechanism"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"9abb7d3a_b75bac2d","line":15,"range":{"start_line":14,"start_character":13,"end_line":15,"end_character":5},"updated":"2016-05-30 16:19:26.000000000","message":"Grammar seems broken here but I am not sure what you mean.","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"2ab33351349a95576b0d58e2e3679fd7d889c0b9","unresolved":false,"context_lines":[{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to declare a get_agents_resource_versions which is used the current"},{"line_number":15,"context_line":"cache of known resource consumers (agents) and versions."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"If we eventually need to have more consumer types (for example, other"},{"line_number":18,"context_line":"neutron-servers consuming specific resources as they change) this mechanism"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"9abb7d3a_b46ef32c","line":15,"range":{"start_line":14,"start_character":13,"end_line":15,"end_character":5},"in_reply_to":"9abb7d3a_b75bac2d","updated":"2016-05-31 07:49:59.000000000","message":"Lol \u0027:) , this is badly broken, will fix it.","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Miguel Angel Ajo \u003cmangelajo@redhat.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-08 06:43:06 -0400"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Refactor the rpc callback version discovery mechanism."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The previous version depended on the AgentDbMixin to be loaded by"},{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7aa08908_cbe3d8a2","line":7,"range":{"start_line":7,"start_character":53,"end_line":7,"end_character":54},"updated":"2016-06-08 10:59:10.000000000","message":"nit: remove dot","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Miguel Angel Ajo \u003cmangelajo@redhat.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-06-08 06:43:06 -0400"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Refactor the rpc callback version discovery mechanism."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The previous version depended on the AgentDbMixin to be loaded by"},{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7aa08908_fcbbfce2","line":7,"range":{"start_line":7,"start_character":53,"end_line":7,"end_character":54},"in_reply_to":"7aa08908_cbe3d8a2","updated":"2016-06-08 12:33:54.000000000","message":"Done","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":14,"context_line":"to provide the AgentDbMixin which is used to refresh cache of known"},{"line_number":15,"context_line":"resource consumers (agents) and versions on demand, this way"},{"line_number":16,"context_line":"we make it more clear that the rpc_callback api is currently designed"},{"line_number":17,"context_line":"to be used with agents only, despite of it\u0027s extensibility to other"},{"line_number":18,"context_line":"areas."},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Change-Id: Ie96b52dbe3a1f32cd4c11de8d8a5eff663fbf7f6"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7aa08908_4bcfe828","line":17,"range":{"start_line":17,"start_character":40,"end_line":17,"end_character":44},"updated":"2016-06-08 10:59:10.000000000","message":"its","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":14,"context_line":"to provide the AgentDbMixin which is used to refresh cache of known"},{"line_number":15,"context_line":"resource consumers (agents) and versions on demand, this way"},{"line_number":16,"context_line":"we make it more clear that the rpc_callback api is currently designed"},{"line_number":17,"context_line":"to be used with agents only, despite of it\u0027s extensibility to other"},{"line_number":18,"context_line":"areas."},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Change-Id: Ie96b52dbe3a1f32cd4c11de8d8a5eff663fbf7f6"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"7aa08908_dcc0c052","line":17,"range":{"start_line":17,"start_character":40,"end_line":17,"end_character":44},"in_reply_to":"7aa08908_4bcfe828","updated":"2016-06-08 12:33:54.000000000","message":"Done","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"e88a9da3dbd6f0ee701f43445b11e72094be1c98","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The previous version depended on the AgentDbMixin to be loaded by"},{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"},{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to provide the AgentDbMixin which is used to refresh cache of known"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"7aa08908_4ab99b2d","line":11,"updated":"2016-06-08 12:37:42.000000000","message":"Can you please explain why?","commit_id":"d7ada80a9b7e9e6539da5b286fe035405e4a1881"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"a2deaba4a56cf5ef5c87758934b35a831af0a24e","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The previous version depended on the AgentDbMixin to be loaded by"},{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"},{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to provide the AgentDbMixin which is used to refresh cache of known"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"7aa08908_b43de4c5","line":11,"in_reply_to":"7aa08908_3aa7250c","updated":"2016-06-08 20:52:10.000000000","message":"The exact failure mode was due to a plugin that had one of the elements of MRO not calling to super().__init__() and hence not triggering the __init__ that we put into AgentDbMixin. Overall, mixins are not supposed to be used as general inheritance mechanisms. Instead, they are a bunch of methods that can be melded into a class, and used from there. The whole idea of mixins in that sense is in contradiction to maintaining inheritance super() call ordering. We may not expect that all parents of all plugins call to super() and don\u0027t miss the callback setup.","commit_id":"d7ada80a9b7e9e6539da5b286fe035405e4a1881"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"9296fd1c104beea7bb97731193e387b055e55c1d","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The previous version depended on the AgentDbMixin to be loaded by"},{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"},{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to provide the AgentDbMixin which is used to refresh cache of known"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"7aa08908_3aa7250c","line":11,"in_reply_to":"7aa08908_4ab99b2d","updated":"2016-06-08 18:47:59.000000000","message":"Because it was the one and only mixing with an __init__, and in some condition (I can\u0027t recall now) super( ..) MRO was unable to resolve the order of __inits__ in inheritance.\n\nIhar, do you remember the exact details?","commit_id":"d7ada80a9b7e9e6539da5b286fe035405e4a1881"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"937c857a35d0921e5659da2686bd9219ff73fcb3","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"The previous version depended on the AgentDbMixin to be loaded by"},{"line_number":10,"context_line":"any plugin, and also introduced an __init__ on the mixin which"},{"line_number":11,"context_line":"is troublesome."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"This change requires the plugins using the rpc callback mechanism"},{"line_number":14,"context_line":"to provide the AgentDbMixin which is used to refresh cache of known"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"7aa08908_127b177c","line":11,"in_reply_to":"7aa08908_b43de4c5","updated":"2016-06-09 07:52:35.000000000","message":"Let me extend the commit message to explain this.","commit_id":"d7ada80a9b7e9e6539da5b286fe035405e4a1881"}],"doc/source/devref/rpc_callbacks.rst":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"8f82e067b188929b7413bf0aa3984381b0e7aff3","unresolved":false,"context_lines":[{"line_number":163,"context_line":"should iteratively call tracker.set_version(consumer, versions) for every"},{"line_number":164,"context_line":"consumer."},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"The consumer parameter should be an AgentConsumer object, with agent_type "},{"line_number":167,"context_line":"and host set, and acts as an unique ID for the agent."},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"The versions parameter is a dictionary with the following format::"}],"source_content_type":"text/x-rst","patch_set":2,"id":"9abb7d3a_eedb684d","line":166,"updated":"2016-05-31 16:01:45.000000000","message":"red thingy!","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"8f82e067b188929b7413bf0aa3984381b0e7aff3","unresolved":false,"context_lines":[{"line_number":164,"context_line":"consumer."},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"The consumer parameter should be an AgentConsumer object, with agent_type "},{"line_number":167,"context_line":"and host set, and acts as an unique ID for the agent."},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"The versions parameter is a dictionary with the following format::"},{"line_number":170,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"9abb7d3a_6ef018ca","line":167,"range":{"start_line":167,"start_character":26,"end_line":167,"end_character":28},"updated":"2016-05-31 16:01:45.000000000","message":"a","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"8f82e067b188929b7413bf0aa3984381b0e7aff3","unresolved":false,"context_lines":[{"line_number":168,"context_line":""},{"line_number":169,"context_line":"The versions parameter is a dictionary with the following format::"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"    {\u0027QoSPolicy\u0027: \u00271.1\u0027,"},{"line_number":172,"context_line":"     \u0027SecurityGroup\u0027: \u00271.0\u0027,"},{"line_number":173,"context_line":"     \u0027Port\u0027: \u00271.0\u0027}"},{"line_number":174,"context_line":""}],"source_content_type":"text/x-rst","patch_set":2,"id":"9abb7d3a_ceb784f3","line":171,"range":{"start_line":171,"start_character":6,"end_line":171,"end_character":15},"updated":"2016-05-31 16:01:45.000000000","message":"QosPolicy","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":154,"context_line":"should report their resource/version tuples of interest (the resource type/"},{"line_number":155,"context_line":"version pairs they\u0027re subscribed to)."},{"line_number":156,"context_line":""},{"line_number":157,"context_line":"The plugins interested in this RPC mechanism must the AgentDbMixin,"},{"line_number":158,"context_line":"since this mechanism is only intended to be used from agents at the moment,"},{"line_number":159,"context_line":"while it could be extended to be consumed from other components if necessary."},{"line_number":160,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_ebf4d45b","line":157,"range":{"start_line":157,"start_character":45,"end_line":157,"end_character":54},"updated":"2016-06-08 10:59:10.000000000","message":"must inherit","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":154,"context_line":"should report their resource/version tuples of interest (the resource type/"},{"line_number":155,"context_line":"version pairs they\u0027re subscribed to)."},{"line_number":156,"context_line":""},{"line_number":157,"context_line":"The plugins interested in this RPC mechanism must the AgentDbMixin,"},{"line_number":158,"context_line":"since this mechanism is only intended to be used from agents at the moment,"},{"line_number":159,"context_line":"while it could be extended to be consumed from other components if necessary."},{"line_number":160,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_e69b6916","line":157,"range":{"start_line":157,"start_character":45,"end_line":157,"end_character":54},"in_reply_to":"7aa08908_ebf4d45b","updated":"2016-06-08 12:33:54.000000000","message":"Done","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":163,"context_line":"   def get_agents_resource_versions(self, tracker):"},{"line_number":164,"context_line":"      ..."},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"Where tracker is a ResourceConsumerTracker, and"},{"line_number":167,"context_line":"the get_agents_resource_versions iteratively calls"},{"line_number":168,"context_line":"tracker.set_version(consumer, versions) for every consumer."},{"line_number":169,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_cbfab842","line":166,"range":{"start_line":166,"start_character":0,"end_line":166,"end_character":1},"updated":"2016-06-08 10:59:10.000000000","message":"-\u003e lowercase","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":163,"context_line":"   def get_agents_resource_versions(self, tracker):"},{"line_number":164,"context_line":"      ..."},{"line_number":165,"context_line":""},{"line_number":166,"context_line":"Where tracker is a ResourceConsumerTracker, and"},{"line_number":167,"context_line":"the get_agents_resource_versions iteratively calls"},{"line_number":168,"context_line":"tracker.set_version(consumer, versions) for every consumer."},{"line_number":169,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_469d1d09","line":166,"range":{"start_line":166,"start_character":0,"end_line":166,"end_character":1},"in_reply_to":"7aa08908_cbfab842","updated":"2016-06-08 12:33:54.000000000","message":"Done","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":167,"context_line":"the get_agents_resource_versions iteratively calls"},{"line_number":168,"context_line":"tracker.set_version(consumer, versions) for every consumer."},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"The consumer parameter should is an AgentConsumer object, with agent_type"},{"line_number":171,"context_line":"and host set, and acts as a unique ID for the agent."},{"line_number":172,"context_line":""},{"line_number":173,"context_line":"The versions parameter is a dictionary with the following format::"}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_4b9d2809","line":170,"range":{"start_line":170,"start_character":23,"end_line":170,"end_character":32},"updated":"2016-06-08 10:59:10.000000000","message":"should be","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":167,"context_line":"the get_agents_resource_versions iteratively calls"},{"line_number":168,"context_line":"tracker.set_version(consumer, versions) for every consumer."},{"line_number":169,"context_line":""},{"line_number":170,"context_line":"The consumer parameter should is an AgentConsumer object, with agent_type"},{"line_number":171,"context_line":"and host set, and acts as a unique ID for the agent."},{"line_number":172,"context_line":""},{"line_number":173,"context_line":"The versions parameter is a dictionary with the following format::"}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_26473178","line":170,"range":{"start_line":170,"start_character":23,"end_line":170,"end_character":32},"in_reply_to":"7aa08908_4b9d2809","updated":"2016-06-08 12:33:54.000000000","message":"Done","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":174,"context_line":""},{"line_number":175,"context_line":"    {\u0027QosPolicy\u0027: \u00271.1\u0027,"},{"line_number":176,"context_line":"     \u0027SecurityGroup\u0027: \u00271.0\u0027,"},{"line_number":177,"context_line":"     \u0027Port\u0027: \u00271.0\u0027}"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"Caching mechanism"},{"line_number":180,"context_line":"\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027"}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_cb9118f3","line":177,"updated":"2016-06-08 10:59:10.000000000","message":"I highly doubt that those additions belong to devref at all. It seems more like a docstring to the method in question.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":174,"context_line":""},{"line_number":175,"context_line":"    {\u0027QosPolicy\u0027: \u00271.1\u0027,"},{"line_number":176,"context_line":"     \u0027SecurityGroup\u0027: \u00271.0\u0027,"},{"line_number":177,"context_line":"     \u0027Port\u0027: \u00271.0\u0027}"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"Caching mechanism"},{"line_number":180,"context_line":"\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027\u0027"}],"source_content_type":"text/x-rst","patch_set":5,"id":"7aa08908_61c92359","line":177,"in_reply_to":"7aa08908_cb9118f3","updated":"2016-06-08 12:33:54.000000000","message":"Makes sense, I\u0027m moving this to a docstring on the specific methods.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"}],"neutron/api/rpc/callbacks/version_manager.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"60da8ef417c44a2ad42acc9672c538a8dfe21bbe","unresolved":false,"context_lines":[{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"class ResourceConsumerTracker(object):"},{"line_number":52,"context_line":"    \"\"\"Class to be provided back by passed down to collect resource usage."},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"    This class is responsible for fetching the local versions of"},{"line_number":55,"context_line":"    resources, and letting the called function register every consumer\u0027s"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_972788b5","line":52,"range":{"start_line":52,"start_character":36,"end_line":52,"end_character":73},"updated":"2016-05-30 16:19:26.000000000","message":"Not sure I follow grammar here","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"2ab33351349a95576b0d58e2e3679fd7d889c0b9","unresolved":false,"context_lines":[{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"class ResourceConsumerTracker(object):"},{"line_number":52,"context_line":"    \"\"\"Class to be provided back by passed down to collect resource usage."},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"    This class is responsible for fetching the local versions of"},{"line_number":55,"context_line":"    resources, and letting the called function register every consumer\u0027s"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_94fe4f36","line":52,"range":{"start_line":52,"start_character":36,"end_line":52,"end_character":73},"in_reply_to":"9abb7d3a_972788b5","updated":"2016-05-31 07:49:59.000000000","message":"Brain not functioning here.","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"60da8ef417c44a2ad42acc9672c538a8dfe21bbe","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        new_tracker \u003d ResourceConsumerTracker()"},{"line_number":199,"context_line":"        neutron_plugin \u003d manager.NeutronManager.get_plugin()"},{"line_number":200,"context_line":"        # If you use rpc callbacks, your plugin needs to implement"},{"line_number":201,"context_line":"        # get_agents_resource_versions to us know what versions"},{"line_number":202,"context_line":"        # your agents consume via RPC"},{"line_number":203,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":204,"context_line":"        self._versions \u003d new_tracker"},{"line_number":205,"context_line":"        self._versions.report()"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_ec08cb2f","line":202,"range":{"start_line":201,"start_character":39,"end_line":202,"end_character":37},"updated":"2016-05-30 16:19:26.000000000","message":"so that we know which resource versions your agents consume via RPC","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"2ab33351349a95576b0d58e2e3679fd7d889c0b9","unresolved":false,"context_lines":[{"line_number":198,"context_line":"        new_tracker \u003d ResourceConsumerTracker()"},{"line_number":199,"context_line":"        neutron_plugin \u003d manager.NeutronManager.get_plugin()"},{"line_number":200,"context_line":"        # If you use rpc callbacks, your plugin needs to implement"},{"line_number":201,"context_line":"        # get_agents_resource_versions to us know what versions"},{"line_number":202,"context_line":"        # your agents consume via RPC"},{"line_number":203,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":204,"context_line":"        self._versions \u003d new_tracker"},{"line_number":205,"context_line":"        self._versions.report()"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_349683f0","line":202,"range":{"start_line":201,"start_character":39,"end_line":202,"end_character":37},"in_reply_to":"9abb7d3a_ec08cb2f","updated":"2016-05-31 07:49:59.000000000","message":"Ack.","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"22ccec17961edf13bedc6f56a849135c54dd3315","unresolved":false,"context_lines":[{"line_number":28,"context_line":"# This is the list of agents that started using this rpc push/pull mechanism"},{"line_number":29,"context_line":"# for versioned objects, but at that time stable/liberty, they were not"},{"line_number":30,"context_line":"# reporting versions, so we need to assume they need QosPolicy 1.0"},{"line_number":31,"context_line":"#TODO(mangelajo): Remove this logic in Newton, since those agents will be"},{"line_number":32,"context_line":"#                 already reporting From N to O"},{"line_number":33,"context_line":"NON_REPORTING_AGENT_TYPES \u003d [constants.AGENT_TYPE_OVS,"},{"line_number":34,"context_line":"                             constants.AGENT_TYPE_NIC_SWITCH]"}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_13a9a390","line":31,"updated":"2016-05-31 21:34:50.000000000","message":"and this one?","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"f44e3d56a631b2c598e58b0af8ed2d080ff495e9","unresolved":false,"context_lines":[{"line_number":28,"context_line":"# This is the list of agents that started using this rpc push/pull mechanism"},{"line_number":29,"context_line":"# for versioned objects, but at that time stable/liberty, they were not"},{"line_number":30,"context_line":"# reporting versions, so we need to assume they need QosPolicy 1.0"},{"line_number":31,"context_line":"#TODO(mangelajo): Remove this logic in Newton, since those agents will be"},{"line_number":32,"context_line":"#                 already reporting From N to O"},{"line_number":33,"context_line":"NON_REPORTING_AGENT_TYPES \u003d [constants.AGENT_TYPE_OVS,"},{"line_number":34,"context_line":"                             constants.AGENT_TYPE_NIC_SWITCH]"}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_2ab7fcf5","line":31,"in_reply_to":"9abb7d3a_13a9a390","updated":"2016-06-01 08:03:05.000000000","message":"There\u0027s already a follow up patch to this one.\n\nhttps://review.openstack.org/#/c/323268/1 :-)","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"22ccec17961edf13bedc6f56a849135c54dd3315","unresolved":false,"context_lines":[{"line_number":38,"context_line":"#                  long) circular dependency, this can be fixed if we"},{"line_number":39,"context_line":"#                  stop importing all exposed classes in"},{"line_number":40,"context_line":"#                  neutron.api.rpc.callbacks.resources and provide"},{"line_number":41,"context_line":"#                  a decorator to expose classes"},{"line_number":42,"context_line":"def _import_resources():"},{"line_number":43,"context_line":"    return importutils.import_module(\u0027neutron.api.rpc.callbacks.resources\u0027)"},{"line_number":44,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_f3adff9b","line":41,"updated":"2016-05-31 21:34:50.000000000","message":"and this one?","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"ea63c0b36cdaf934d24a10a19555bf60c822bf94","unresolved":false,"context_lines":[{"line_number":38,"context_line":"#                  long) circular dependency, this can be fixed if we"},{"line_number":39,"context_line":"#                  stop importing all exposed classes in"},{"line_number":40,"context_line":"#                  neutron.api.rpc.callbacks.resources and provide"},{"line_number":41,"context_line":"#                  a decorator to expose classes"},{"line_number":42,"context_line":"def _import_resources():"},{"line_number":43,"context_line":"    return importutils.import_module(\u0027neutron.api.rpc.callbacks.resources\u0027)"},{"line_number":44,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_80c07f51","line":41,"in_reply_to":"9abb7d3a_8b4d459c","updated":"2016-06-01 11:35:16.000000000","message":"Sounds reasonable:\n\nhave a general ovo registration decorator, and a flag for RPC-callback enablement.\n\nI\u0027ll do that.","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"df31c85ed70d6330721d666635bd182d8ccb7744","unresolved":false,"context_lines":[{"line_number":38,"context_line":"#                  long) circular dependency, this can be fixed if we"},{"line_number":39,"context_line":"#                  stop importing all exposed classes in"},{"line_number":40,"context_line":"#                  neutron.api.rpc.callbacks.resources and provide"},{"line_number":41,"context_line":"#                  a decorator to expose classes"},{"line_number":42,"context_line":"def _import_resources():"},{"line_number":43,"context_line":"    return importutils.import_module(\u0027neutron.api.rpc.callbacks.resources\u0027)"},{"line_number":44,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_8b4d459c","line":41,"in_reply_to":"9abb7d3a_aa9acc6b","updated":"2016-06-01 10:27:36.000000000","message":"I think it\u0027s fair to introduce a decorator for that. Actually, we may even have it replacing existing registration decorator from oslo.versionedobjects, so that it handles ovo registration as well as rpc callbacks one (probably based on a class attribute defined on the class).","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"f44e3d56a631b2c598e58b0af8ed2d080ff495e9","unresolved":false,"context_lines":[{"line_number":38,"context_line":"#                  long) circular dependency, this can be fixed if we"},{"line_number":39,"context_line":"#                  stop importing all exposed classes in"},{"line_number":40,"context_line":"#                  neutron.api.rpc.callbacks.resources and provide"},{"line_number":41,"context_line":"#                  a decorator to expose classes"},{"line_number":42,"context_line":"def _import_resources():"},{"line_number":43,"context_line":"    return importutils.import_module(\u0027neutron.api.rpc.callbacks.resources\u0027)"},{"line_number":44,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_aa9acc6b","line":41,"in_reply_to":"9abb7d3a_f3adff9b","updated":"2016-06-01 08:03:05.000000000","message":"I will start another patch to see improve this. It feels good to kill technical debt of any kind, specially when its yours.\n\n@Ihar, as what do you think of a decorator to expose objects and kill this dependency chain...\n\n\nsomething like....\n\n\nfrom neutron.api.rpc.callbacks import resources\n\n@resources.expose_via_rpc_callbacks\nclass MyNeutronObject(......):","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"8f82e067b188929b7413bf0aa3984381b0e7aff3","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":204,"context_line":"        # get_agents_resource_versions so that we know which resource"},{"line_number":205,"context_line":"        # versions your agents consume via RPC"},{"line_number":206,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":207,"context_line":"        self._versions \u003d new_tracker"},{"line_number":208,"context_line":"        self._versions.report()"},{"line_number":209,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_a9eb1a12","line":206,"updated":"2016-05-31 16:01:45.000000000","message":"If it\u0027s not defined, we could at least fall back to a default implementation that would return the latest versions registered in objects registry. This may be fragile on rolling upgrade for plugins that actually use agents, but then I guess we can\u0027t do better than that. Maybe a single-shot INFO message could be of use to inform there may be problems with the fallback.","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"df31c85ed70d6330721d666635bd182d8ccb7744","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":204,"context_line":"        # get_agents_resource_versions so that we know which resource"},{"line_number":205,"context_line":"        # versions your agents consume via RPC"},{"line_number":206,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":207,"context_line":"        self._versions \u003d new_tracker"},{"line_number":208,"context_line":"        self._versions.report()"},{"line_number":209,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_ab3da9de","line":206,"in_reply_to":"9abb7d3a_8ad38803","updated":"2016-06-01 10:27:36.000000000","message":"One problem here is that the patch should be easily backportable. If we assume breakage for all core plugins that don\u0027t inherit AgentDbMixin, it is pretty scary for a backport.","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"5f50bf2627f0860962afe980c5296da19c669cd8","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":204,"context_line":"        # get_agents_resource_versions so that we know which resource"},{"line_number":205,"context_line":"        # versions your agents consume via RPC"},{"line_number":206,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":207,"context_line":"        self._versions \u003d new_tracker"},{"line_number":208,"context_line":"        self._versions.report()"},{"line_number":209,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_591dee64","line":206,"in_reply_to":"9abb7d3a_a0b943ce","updated":"2016-06-01 12:13:09.000000000","message":"I think your 2-step plan is more safe. We would avoid backporting the second piece to Mitaka.\n\n\u003d\u003d\n\nOne thing that we may consider is actually decoupling existing \u0027callback\u0027 method from any plugin instances, and make it a simple function that is called directly from the versions manager. AFAIK there is no deep reason to keep that method defined on a plugin, except that it uses _get_collection from common_db_mixin that itself does not really depend on any specific plugin but in essence a class method (yes, we don\u0027t define it that way, but that\u0027s what it really is).\n\nSo, could we try to refactor the callback out of AgentDbMixin and make it a simple function? That would solve it once and for all for all plugins, because then we would not require plugins to define anything, we would always use agent based callback.","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"f44e3d56a631b2c598e58b0af8ed2d080ff495e9","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":204,"context_line":"        # get_agents_resource_versions so that we know which resource"},{"line_number":205,"context_line":"        # versions your agents consume via RPC"},{"line_number":206,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":207,"context_line":"        self._versions \u003d new_tracker"},{"line_number":208,"context_line":"        self._versions.report()"},{"line_number":209,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_8ad38803","line":206,"in_reply_to":"9abb7d3a_a9eb1a12","updated":"2016-06-01 08:03:05.000000000","message":"Mixed feelings about this.\n\nOn one side, yes, we provide out of the box compatibility with plugins using this, but on the other hand, they could not get the message, and in the end, the bug would be there for them, and the upgrade history would be broken.\n\nIsn\u0027t it better if we just break them once and let them fix it ? . That\u0027s my thinking here.\n\nI should probably add an entry to the breakages document.","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"ea63c0b36cdaf934d24a10a19555bf60c822bf94","unresolved":false,"context_lines":[{"line_number":203,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":204,"context_line":"        # get_agents_resource_versions so that we know which resource"},{"line_number":205,"context_line":"        # versions your agents consume via RPC"},{"line_number":206,"context_line":"        neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":207,"context_line":"        self._versions \u003d new_tracker"},{"line_number":208,"context_line":"        self._versions.report()"},{"line_number":209,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_a0b943ce","line":206,"in_reply_to":"9abb7d3a_ab3da9de","updated":"2016-06-01 11:35:16.000000000","message":"Ok, that\u0027s a really good point, so... why don\u0027t I split it in two:\n\n1) Patch which does not break by having a default fallback\n2) Patch that removes the fallback, and breaks plugins so they are forced to fix it now, instead when they find upgrades broken.\n\nDoes it sound like a reasonable action plan?","commit_id":"267455a83a229b72c276cf10bc9b38f24954aee1"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":45,"context_line":""},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"def _import_agents_db():"},{"line_number":48,"context_line":"    return importutils.import_module(\u0027neutron.db.agents_db\u0027)"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"AgentConsumer \u003d collections.namedtuple(\u0027AgentConsumer\u0027, [\u0027agent_type\u0027,"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_eb37b4fc","line":48,"updated":"2016-06-08 10:59:10.000000000","message":"(No action required) That\u0027s a sad thing, but I believe it\u0027s the least invasive way to do it to keep it easily backportable.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d8e7c49ea5d58be7726c12450e8713bd1d663b52","unresolved":false,"context_lines":[{"line_number":45,"context_line":""},{"line_number":46,"context_line":""},{"line_number":47,"context_line":"def _import_agents_db():"},{"line_number":48,"context_line":"    return importutils.import_module(\u0027neutron.db.agents_db\u0027)"},{"line_number":49,"context_line":""},{"line_number":50,"context_line":""},{"line_number":51,"context_line":"AgentConsumer \u003d collections.namedtuple(\u0027AgentConsumer\u0027, [\u0027agent_type\u0027,"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_86cc256b","line":48,"in_reply_to":"7aa08908_eb37b4fc","updated":"2016-06-08 11:08:38.000000000","message":"Yup, we will kill the L43 one with the decorator, this one needs more thought.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":209,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":210,"context_line":"        # AgentsDbMixin so that we know which resource versions your"},{"line_number":211,"context_line":"        # agents consume via RPC, please note that rpc_callbacks are"},{"line_number":212,"context_line":"        # only designed to work with Agents currently."},{"line_number":213,"context_line":"        if isinstance(neutron_plugin, agents_db.AgentDbMixin):"},{"line_number":214,"context_line":"            neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":215,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_6612d958","line":212,"range":{"start_line":212,"start_character":37,"end_line":212,"end_character":38},"updated":"2016-06-08 10:59:10.000000000","message":"nit: lowercase","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"0f946f6bd32ef224a47334e0fcf65cfc38cf0199","unresolved":false,"context_lines":[{"line_number":209,"context_line":"        # If you use RPC callbacks, your plugin needs to implement"},{"line_number":210,"context_line":"        # AgentsDbMixin so that we know which resource versions your"},{"line_number":211,"context_line":"        # agents consume via RPC, please note that rpc_callbacks are"},{"line_number":212,"context_line":"        # only designed to work with Agents currently."},{"line_number":213,"context_line":"        if isinstance(neutron_plugin, agents_db.AgentDbMixin):"},{"line_number":214,"context_line":"            neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":215,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_413987f1","line":212,"range":{"start_line":212,"start_character":37,"end_line":212,"end_character":38},"in_reply_to":"7aa08908_6612d958","updated":"2016-06-08 12:33:54.000000000","message":"Done","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":213,"context_line":"        if isinstance(neutron_plugin, agents_db.AgentDbMixin):"},{"line_number":214,"context_line":"            neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":215,"context_line":"        else:"},{"line_number":216,"context_line":"            # NOTE-TO-REVIEWERS: may be we should just exit here and stop"},{"line_number":217,"context_line":"            # the process, as this is a fatal programming error."},{"line_number":218,"context_line":"            raise exceptions.NoAgentDbMixinImplemented()"},{"line_number":219,"context_line":""},{"line_number":220,"context_line":"        self._versions \u003d new_tracker"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_66401935","line":217,"range":{"start_line":216,"start_character":12,"end_line":217,"end_character":64},"updated":"2016-06-08 10:59:10.000000000","message":"It could be wise to exit if we do sanity check on startup. I don\u0027t think it\u0027s wise to completely shutdown in the middle of production cycle though.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d8e7c49ea5d58be7726c12450e8713bd1d663b52","unresolved":false,"context_lines":[{"line_number":213,"context_line":"        if isinstance(neutron_plugin, agents_db.AgentDbMixin):"},{"line_number":214,"context_line":"            neutron_plugin.get_agents_resource_versions(new_tracker)"},{"line_number":215,"context_line":"        else:"},{"line_number":216,"context_line":"            # NOTE-TO-REVIEWERS: may be we should just exit here and stop"},{"line_number":217,"context_line":"            # the process, as this is a fatal programming error."},{"line_number":218,"context_line":"            raise exceptions.NoAgentDbMixinImplemented()"},{"line_number":219,"context_line":""},{"line_number":220,"context_line":"        self._versions \u003d new_tracker"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_2601f16a","line":217,"range":{"start_line":216,"start_character":12,"end_line":217,"end_character":64},"in_reply_to":"7aa08908_66401935","updated":"2016-06-08 11:08:38.000000000","message":"Yes, that\u0027s true. I wonder if there\u0027s any simple way to make the check on startup once plugin is loaded.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"}],"neutron/db/agents_db.py":[{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"22ccec17961edf13bedc6f56a849135c54dd3315","unresolved":false,"context_lines":[{"line_number":180,"context_line":"class AgentDbMixin(ext_agent.AgentPluginBase, AgentAvailabilityZoneMixin):"},{"line_number":181,"context_line":"    \"\"\"Mixin class to add agent extension to db_base_plugin_v2.\"\"\""},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"    def __init__(self, *args, **kwargs):"},{"line_number":184,"context_line":"        version_manager.set_consumer_versions_callback("},{"line_number":185,"context_line":"            self._get_agents_resource_versions)"},{"line_number":186,"context_line":"        super(AgentDbMixin, self).__init__(*args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_f3b69ff7","side":"PARENT","line":183,"updated":"2016-05-31 21:34:50.000000000","message":"what about the todo down below?","commit_id":"4e39d3e0700dfa92dcb51c7e210f0742e4a2b5b0"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"f44e3d56a631b2c598e58b0af8ed2d080ff495e9","unresolved":false,"context_lines":[{"line_number":180,"context_line":"class AgentDbMixin(ext_agent.AgentPluginBase, AgentAvailabilityZoneMixin):"},{"line_number":181,"context_line":"    \"\"\"Mixin class to add agent extension to db_base_plugin_v2.\"\"\""},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"    def __init__(self, *args, **kwargs):"},{"line_number":184,"context_line":"        version_manager.set_consumer_versions_callback("},{"line_number":185,"context_line":"            self._get_agents_resource_versions)"},{"line_number":186,"context_line":"        super(AgentDbMixin, self).__init__(*args, **kwargs)"}],"source_content_type":"text/x-python","patch_set":2,"id":"9abb7d3a_0af03866","side":"PARENT","line":183,"in_reply_to":"9abb7d3a_f3b69ff7","updated":"2016-06-01 08:03:05.000000000","message":"The circular deps?, it\u0027s the same one that can be fixed by a decorator for the exposed classes, let\u0027s do it!.","commit_id":"4e39d3e0700dfa92dcb51c7e210f0742e4a2b5b0"}],"neutron/tests/unit/api/rpc/callbacks/test_version_manager.py":[{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"60da8ef417c44a2ad42acc9672c538a8dfe21bbe","unresolved":false,"context_lines":[{"line_number":120,"context_line":"    @staticmethod"},{"line_number":121,"context_line":"    def _patch_consumer_versions(_get_agents_resource_versions\u003dNone):"},{"line_number":122,"context_line":"        class _FakePlugin(object):"},{"line_number":123,"context_line":"            def get_agents_resource_versions(self, rct):"},{"line_number":124,"context_line":"                if _get_agents_resource_versions:"},{"line_number":125,"context_line":"                    _get_agents_resource_versions(rct)"},{"line_number":126,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_77782490","line":123,"range":{"start_line":123,"start_character":51,"end_line":123,"end_character":54},"updated":"2016-05-30 16:19:26.000000000","message":"What does \u0027rct\u0027 stand for?","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"2ab33351349a95576b0d58e2e3679fd7d889c0b9","unresolved":false,"context_lines":[{"line_number":120,"context_line":"    @staticmethod"},{"line_number":121,"context_line":"    def _patch_consumer_versions(_get_agents_resource_versions\u003dNone):"},{"line_number":122,"context_line":"        class _FakePlugin(object):"},{"line_number":123,"context_line":"            def get_agents_resource_versions(self, rct):"},{"line_number":124,"context_line":"                if _get_agents_resource_versions:"},{"line_number":125,"context_line":"                    _get_agents_resource_versions(rct)"},{"line_number":126,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_746e4b02","line":123,"range":{"start_line":123,"start_character":51,"end_line":123,"end_character":54},"in_reply_to":"9abb7d3a_77782490","updated":"2016-05-31 07:49:59.000000000","message":"resource tracker, I will change to tracker.","commit_id":"6515313a31ee40580bf1a053e74b8355bb725a47"},{"author":{"_account_id":9656,"name":"Ihar Hrachyshka","email":"ihrachys@redhat.com","username":"ihrachys","status":"Red Hat Networking Systems Engineer"},"change_message_id":"e70f7d5de6d6c70e50b68de99a9b846a098dcd20","unresolved":false,"context_lines":[{"line_number":173,"context_line":"        with mock.patch(\u0027time.time\u0027) as time_patch:"},{"line_number":174,"context_line":"            time_patch.return_value \u003d 1"},{"line_number":175,"context_line":"            cached_tracker.get_resource_versions(TEST_RESOURCE_TYPE)"},{"line_number":176,"context_line":"            self.get_plugin.assert_called_once_with()"},{"line_number":177,"context_line":"            self.get_plugin.reset_mock()"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"            time_patch.return_value \u003d 2"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_066035a4","line":176,"updated":"2016-06-08 10:59:10.000000000","message":"I think what we really should check here is that get_agents_resource_versions was triggered, not just get_plugin. The latter is an implementation detail that is loosely related to the intent of the test case.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"},{"author":{"_account_id":8788,"name":"Miguel Angel Ajo","email":"mangelajo@redhat.com","username":"mangelajo"},"change_message_id":"d8e7c49ea5d58be7726c12450e8713bd1d663b52","unresolved":false,"context_lines":[{"line_number":173,"context_line":"        with mock.patch(\u0027time.time\u0027) as time_patch:"},{"line_number":174,"context_line":"            time_patch.return_value \u003d 1"},{"line_number":175,"context_line":"            cached_tracker.get_resource_versions(TEST_RESOURCE_TYPE)"},{"line_number":176,"context_line":"            self.get_plugin.assert_called_once_with()"},{"line_number":177,"context_line":"            self.get_plugin.reset_mock()"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"            time_patch.return_value \u003d 2"}],"source_content_type":"text/x-python","patch_set":5,"id":"7aa08908_c61e2dba","line":176,"in_reply_to":"7aa08908_066035a4","updated":"2016-06-08 11:08:38.000000000","message":"Ack, I\u0027ll move it back to the self.refreshed strategy check.","commit_id":"2c1985db994eda331cd854a7c31a96a09089f4b8"}]}
