)]}'
{"nova/compute/api.py":[{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":2985,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2986,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2987,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":2988,"context_line":"                                         \u0027set.host.enable.start\u0027, payload)"},{"line_number":2989,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":2990,"context_line":"                host\u003dhost_name)"},{"line_number":2991,"context_line":"        compute_utils.notify_about_host_update(context,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2FswM%3D","line":2988,"updated":"2013-10-11 01:14:22.000000000","message":"nit: alignment","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":2985,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2986,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2987,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":2988,"context_line":"                                         \u0027set.host.enable.start\u0027, payload)"},{"line_number":2989,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":2990,"context_line":"                host\u003dhost_name)"},{"line_number":2991,"context_line":"        compute_utils.notify_about_host_update(context,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2FsvA%3D","line":2988,"in_reply_to":"AAAATH%2F%2FswM%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":2989,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":2990,"context_line":"                host\u003dhost_name)"},{"line_number":2991,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":2992,"context_line":"                                         \u0027set.host.enable.end\u0027, payload)"},{"line_number":2993,"context_line":"        return result"},{"line_number":2994,"context_line":""},{"line_number":2995,"context_line":"    def get_host_uptime(self, context, host_name):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2FswI%3D","line":2992,"updated":"2013-10-11 01:14:22.000000000","message":"ditto","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":2989,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":2990,"context_line":"                host\u003dhost_name)"},{"line_number":2991,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":2992,"context_line":"                                         \u0027set.host.enable.end\u0027, payload)"},{"line_number":2993,"context_line":"        return result"},{"line_number":2994,"context_line":""},{"line_number":2995,"context_line":"    def get_host_uptime(self, context, host_name):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsu8%3D","line":2992,"in_reply_to":"AAAATH%2F%2FswI%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":3004,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3005,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027action\u0027: action}"},{"line_number":3006,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3007,"context_line":"                                      \u0027host.power.action.start\u0027, payload)"},{"line_number":3008,"context_line":"        result \u003d self.rpcapi.host_power_action(context, action\u003daction,"},{"line_number":3009,"context_line":"                host\u003dhost_name)"},{"line_number":3010,"context_line":"        compute_utils.notify_about_host_update(context,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsvs%3D","line":3007,"updated":"2013-10-11 01:14:22.000000000","message":"ditto","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":3004,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3005,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027action\u0027: action}"},{"line_number":3006,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3007,"context_line":"                                      \u0027host.power.action.start\u0027, payload)"},{"line_number":3008,"context_line":"        result \u003d self.rpcapi.host_power_action(context, action\u003daction,"},{"line_number":3009,"context_line":"                host\u003dhost_name)"},{"line_number":3010,"context_line":"        compute_utils.notify_about_host_update(context,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsu0%3D","line":3007,"in_reply_to":"AAAATH%2F%2Fsvs%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":3008,"context_line":"        result \u003d self.rpcapi.host_power_action(context, action\u003daction,"},{"line_number":3009,"context_line":"                host\u003dhost_name)"},{"line_number":3010,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3011,"context_line":"                                      \u0027host.power.action.end\u0027, payload)"},{"line_number":3012,"context_line":"        return result"},{"line_number":3013,"context_line":""},{"line_number":3014,"context_line":"    @wrap_exception()"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsvo%3D","line":3011,"updated":"2013-10-11 01:14:22.000000000","message":"ditto","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":3008,"context_line":"        result \u003d self.rpcapi.host_power_action(context, action\u003daction,"},{"line_number":3009,"context_line":"                host\u003dhost_name)"},{"line_number":3010,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3011,"context_line":"                                      \u0027host.power.action.end\u0027, payload)"},{"line_number":3012,"context_line":"        return result"},{"line_number":3013,"context_line":""},{"line_number":3014,"context_line":"    @wrap_exception()"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2FsuI%3D","line":3011,"in_reply_to":"AAAATH%2F%2Fsvo%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":3019,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3020,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027mode\u0027: mode}"},{"line_number":3021,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3022,"context_line":"                                   \u0027set.host.maintenance.start\u0027, payload)"},{"line_number":3023,"context_line":"        result \u003d self.rpcapi.host_maintenance_mode(context,"},{"line_number":3024,"context_line":"                host_param\u003dhost_name, mode\u003dmode, host\u003dhost_name)"},{"line_number":3025,"context_line":"        compute_utils.notify_about_host_update(context,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsvg%3D","line":3022,"updated":"2013-10-11 01:14:22.000000000","message":"ditto","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":3019,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3020,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027mode\u0027: mode}"},{"line_number":3021,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3022,"context_line":"                                   \u0027set.host.maintenance.start\u0027, payload)"},{"line_number":3023,"context_line":"        result \u003d self.rpcapi.host_maintenance_mode(context,"},{"line_number":3024,"context_line":"                host_param\u003dhost_name, mode\u003dmode, host\u003dhost_name)"},{"line_number":3025,"context_line":"        compute_utils.notify_about_host_update(context,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsuw%3D","line":3022,"in_reply_to":"AAAATH%2F%2Fsvg%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":3023,"context_line":"        result \u003d self.rpcapi.host_maintenance_mode(context,"},{"line_number":3024,"context_line":"                host_param\u003dhost_name, mode\u003dmode, host\u003dhost_name)"},{"line_number":3025,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3026,"context_line":"                                   \u0027set.host.maintenance.end\u0027, payload)"},{"line_number":3027,"context_line":"        return result"},{"line_number":3028,"context_line":""},{"line_number":3029,"context_line":"    def service_get_all(self, context, filters\u003dNone, set_zones\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsvc%3D","line":3026,"updated":"2013-10-11 01:14:22.000000000","message":"ditto","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":3023,"context_line":"        result \u003d self.rpcapi.host_maintenance_mode(context,"},{"line_number":3024,"context_line":"                host_param\u003dhost_name, mode\u003dmode, host\u003dhost_name)"},{"line_number":3025,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3026,"context_line":"                                   \u0027set.host.maintenance.end\u0027, payload)"},{"line_number":3027,"context_line":"        return result"},{"line_number":3028,"context_line":""},{"line_number":3029,"context_line":"    def service_get_all(self, context, filters\u003dNone, set_zones\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsus%3D","line":3026,"in_reply_to":"AAAATH%2F%2Fsvc%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"3ee4a01046dbe594a68d4c860e66a2cdd71a9c2e","unresolved":false,"context_lines":[{"line_number":2997,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2998,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2999,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3000,"context_line":"                                               \u0027set.host.enable.start\u0027,"},{"line_number":3001,"context_line":"                                               payload)"},{"line_number":3002,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":3003,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FPRw%3D","line":3000,"updated":"2013-10-20 00:40:37.000000000","message":"nit: do we really need the word set? feels like host.enable.start is sufficient enough, thoughts?","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"400b5c24a083cbe85338d51cc5123b2853304bbc","unresolved":false,"context_lines":[{"line_number":2997,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2998,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2999,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3000,"context_line":"                                               \u0027set.host.enable.start\u0027,"},{"line_number":3001,"context_line":"                                               payload)"},{"line_number":3002,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":3003,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FPQo%3D","line":3000,"in_reply_to":"AAAATH%2F%2FPRw%3D","updated":"2013-10-20 00:56:16.000000000","message":"Done","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"aa998ad90f8187badf584ab4626af91c977e5a7f","unresolved":false,"context_lines":[{"line_number":3035,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3036,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027mode\u0027: mode}"},{"line_number":3037,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3038,"context_line":"                                               \u0027set.host.maintenance.start\u0027,"},{"line_number":3039,"context_line":"                                               payload)"},{"line_number":3040,"context_line":"        result \u003d self.rpcapi.host_maintenance_mode(context,"},{"line_number":3041,"context_line":"                host_param\u003dhost_name, mode\u003dmode, host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FPQY%3D","line":3038,"updated":"2013-10-20 00:58:47.000000000","message":"This will also be changed to host.maintenance.start","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":1501,"name":"Phil Day","email":"philip.day@hp.com","username":"philip-day"},"change_message_id":"864412a122af28a32115b4e470dbb30255ae5973","unresolved":false,"context_lines":[{"line_number":2997,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2998,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2999,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3000,"context_line":"                                               \u0027host.enable.start\u0027,"},{"line_number":3001,"context_line":"                                               payload)"},{"line_number":3002,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":3003,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F%2F6KE%3D","line":3000,"updated":"2013-10-25 12:16:56.000000000","message":"I think it would be clearer if these were something like:\n\"set_host_enabled.start\" \u0026 \"set_host_enabled.end\"\n\n\"enable\" sounds like its always a positive action, but this could be enabling or disabling a host.","commit_id":"08abd060c88fa1603922b908db163856fc226f56"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"2ecc644e028c97f6ef387200aaef3d52af43eff7","unresolved":false,"context_lines":[{"line_number":2997,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2998,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2999,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3000,"context_line":"                                               \u0027host.enable.start\u0027,"},{"line_number":3001,"context_line":"                                               payload)"},{"line_number":3002,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":3003,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F%2F3bw%3D","line":3000,"in_reply_to":"AAAATn%2F%2F6KE%3D","updated":"2013-10-26 04:39:12.000000000","message":"Thanks Phil, I changed it to host.set_enabled.start/end, hope it is OK.","commit_id":"08abd060c88fa1603922b908db163856fc226f56"},{"author":{"_account_id":1501,"name":"Phil Day","email":"philip.day@hp.com","username":"philip-day"},"change_message_id":"864412a122af28a32115b4e470dbb30255ae5973","unresolved":false,"context_lines":[{"line_number":3018,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3019,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027action\u0027: action}"},{"line_number":3020,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3021,"context_line":"                                               \u0027host.power.action.start\u0027,"},{"line_number":3022,"context_line":"                                               payload)"},{"line_number":3023,"context_line":"        result \u003d self.rpcapi.host_power_action(context, action\u003daction,"},{"line_number":3024,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F%2F6Jo%3D","line":3021,"updated":"2013-10-25 12:16:56.000000000","message":"\"power_action\" instead of \"power.action\" please - otherwise it looks like \"power\" is a  new hierarchy","commit_id":"08abd060c88fa1603922b908db163856fc226f56"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"2ecc644e028c97f6ef387200aaef3d52af43eff7","unresolved":false,"context_lines":[{"line_number":3018,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":3019,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027action\u0027: action}"},{"line_number":3020,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3021,"context_line":"                                               \u0027host.power.action.start\u0027,"},{"line_number":3022,"context_line":"                                               payload)"},{"line_number":3023,"context_line":"        result \u003d self.rpcapi.host_power_action(context, action\u003daction,"},{"line_number":3024,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":10,"id":"AAAATn%2F%2F3bs%3D","line":3021,"in_reply_to":"AAAATn%2F%2F6Jo%3D","updated":"2013-10-26 04:39:12.000000000","message":"Thanks Phil, I used host.power_action.start/end, hope it is OK.","commit_id":"08abd060c88fa1603922b908db163856fc226f56"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"24ea4524500d3abf78ba4f7e348cad69f96770b9","unresolved":false,"context_lines":[{"line_number":2997,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2998,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2999,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3000,"context_line":"                                               \u0027host.set_enabled.start\u0027,"},{"line_number":3001,"context_line":"                                               payload)"},{"line_number":3002,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":3003,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAATn%2F%2FpAM%3D","line":3000,"updated":"2013-10-31 01:35:18.000000000","message":"I actually don\u0027t like the \"host.\" prefix now that Phil pointed this out.  When you look at the utils method, it\u0027s prefixing the notification with \"HostAPI.\" so putting \"host.\" in the event_suffix is redundant.  If you look at some of the other notifications for aggregates in this file you don\u0027t see them putting \u0027aggregate\u0027 in the event suffix because it\u0027s redundant when utils put\u0027s \u0027aggregate\u0027 as the prefix.","commit_id":"7d76e0332cf4ce4df8bb38fd63a6a0ba8470490d"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"5870506813d7b01eeffd40a76bc43aff6dd97a0a","unresolved":false,"context_lines":[{"line_number":2997,"context_line":"        host_name \u003d self._assert_host_exists(context, host_name)"},{"line_number":2998,"context_line":"        payload \u003d {\u0027host_name\u0027: host_name, \u0027enabled\u0027: enabled}"},{"line_number":2999,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3000,"context_line":"                                               \u0027host.set_enabled.start\u0027,"},{"line_number":3001,"context_line":"                                               payload)"},{"line_number":3002,"context_line":"        result \u003d self.rpcapi.set_host_enabled(context, enabled\u003denabled,"},{"line_number":3003,"context_line":"                host\u003dhost_name)"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAATn%2F%2Fo9k%3D","line":3000,"in_reply_to":"AAAATn%2F%2FpAM%3D","updated":"2013-10-31 01:48:38.000000000","message":"Done","commit_id":"7d76e0332cf4ce4df8bb38fd63a6a0ba8470490d"},{"author":{"_account_id":1779,"name":"Daniel Berrange","email":"berrange@redhat.com","username":"berrange"},"change_message_id":"6259b3dcd813ada2223d6585264d19df965a0f2a","unresolved":false,"context_lines":[{"line_number":3003,"context_line":"                host\u003dhost_name)"},{"line_number":3004,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3005,"context_line":"                                               \u0027host.set_enabled.end\u0027,"},{"line_number":3006,"context_line":"                                               payload)"},{"line_number":3007,"context_line":"        return result"},{"line_number":3008,"context_line":""},{"line_number":3009,"context_line":"    def get_host_uptime(self, context, host_name):"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAATn%2F%2FxHg%3D","line":3006,"updated":"2013-10-29 11:04:28.000000000","message":"I don\u0027t really know what the intended semantics of notifications are, so this might be  bogus question..\n\nWhat if \u0027set_host_enabled\u0027 raises an exception ? In such a case we notify \u0027host.set_enabled.start\u0027, with a payload showing enabled\u003denabled but will not notify \u0027host.set_enabled.end\u0027 at all.  Is there a case for notifying host.set_enabled.end with enabled\u003d!enabled ? Or should consumes just expect that  \u0027host.set_enabled.end\u0027 notification may never arrive ?","commit_id":"7d76e0332cf4ce4df8bb38fd63a6a0ba8470490d"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"2c111c947b426a9e08b8ef4a7ec34db1ecf9a876","unresolved":false,"context_lines":[{"line_number":3003,"context_line":"                host\u003dhost_name)"},{"line_number":3004,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3005,"context_line":"                                               \u0027host.set_enabled.end\u0027,"},{"line_number":3006,"context_line":"                                               payload)"},{"line_number":3007,"context_line":"        return result"},{"line_number":3008,"context_line":""},{"line_number":3009,"context_line":"    def get_host_uptime(self, context, host_name):"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAATn%2F%2FxGM%3D","line":3006,"in_reply_to":"AAAATn%2F%2FxHg%3D","updated":"2013-10-29 11:06:30.000000000","message":"Thanks Dan,  the decorator @wrap_exception() will handle the exception case and send exception notification.","commit_id":"7d76e0332cf4ce4df8bb38fd63a6a0ba8470490d"},{"author":{"_account_id":2468,"name":"unicell","email":"unicell@gmail.com","username":"unicell"},"change_message_id":"24b51e43fb016fefaed0e53bb748d999b8cef699","unresolved":false,"context_lines":[{"line_number":3003,"context_line":"                host\u003dhost_name)"},{"line_number":3004,"context_line":"        compute_utils.notify_about_host_update(context,"},{"line_number":3005,"context_line":"                                               \u0027host.set_enabled.end\u0027,"},{"line_number":3006,"context_line":"                                               payload)"},{"line_number":3007,"context_line":"        return result"},{"line_number":3008,"context_line":""},{"line_number":3009,"context_line":"    def get_host_uptime(self, context, host_name):"}],"source_content_type":"text/x-python","patch_set":11,"id":"AAAATn%2F%2Fshs%3D","line":3006,"in_reply_to":"AAAATn%2F%2FxHg%3D","updated":"2013-10-30 10:26:02.000000000","message":"To Daniel, I think that depends on how notification message consumer behaves. I just had a quick scan on Ceilometer code, and there\u0027s seems to no assumption that one \"start\" notification will follow by another \"end\" notification.\n\nAnd such notification consumer should not have such presumption in mind, IMHO.","commit_id":"7d76e0332cf4ce4df8bb38fd63a6a0ba8470490d"}],"nova/compute/utils.py":[{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"7db30f8d7dc7e93b06ce533f17052ea6083602d5","unresolved":false,"context_lines":[{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027HostAPI\u0027,"},{"line_number":361,"context_line":"                                   host\u003dhost_identifier)"},{"line_number":362,"context_line":""},{"line_number":363,"context_line":"    notifier.info(context, \u0027HostAPI.%s\u0027 % event_suffix, host_payload)"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAATH%2F%2FwcA%3D","line":360,"updated":"2013-10-10 09:18:55.000000000","message":"there is a discussion regarding the service param should be the *service* which generating the event rather than a abstract thing, I feel it is make sense and should be the common practice IMHO, refer it in this patch https://review.openstack.org/#/c/50717/2","commit_id":"a55012c7c773e1dffbd97ea4036ebae2354335bb"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"a3fe300e9526d3921ad7e565e26cc62715406be8","unresolved":false,"context_lines":[{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027HostAPI\u0027,"},{"line_number":361,"context_line":"                                   host\u003dhost_identifier)"},{"line_number":362,"context_line":""},{"line_number":363,"context_line":"    notifier.info(context, \u0027HostAPI.%s\u0027 % event_suffix, host_payload)"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAATH%2F%2Fva4%3D","line":360,"in_reply_to":"AAAATH%2F%2FvvU%3D","updated":"2013-10-10 13:11:54.000000000","message":"Done","commit_id":"a55012c7c773e1dffbd97ea4036ebae2354335bb"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"72a7f7efd3e4880d2aa036cedbe614c965ddd8cc","unresolved":false,"context_lines":[{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027HostAPI\u0027,"},{"line_number":361,"context_line":"                                   host\u003dhost_identifier)"},{"line_number":362,"context_line":""},{"line_number":363,"context_line":"    notifier.info(context, \u0027HostAPI.%s\u0027 % event_suffix, host_payload)"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAATH%2F%2FvvU%3D","line":360,"in_reply_to":"AAAATH%2F%2FwXU%3D","updated":"2013-10-10 12:09:12.000000000","message":"You misunderstand my meaning, I am not saying hard code \"service\", instead,  in this example it would make more sense to use \u0027api\u0027 IMHO, since the event will be generated by api, make sense? after searching there are many different pattern exist, we might need common practice about this.","commit_id":"a55012c7c773e1dffbd97ea4036ebae2354335bb"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"cf3944294d91b399cd888664787cbc212e9cd5ca","unresolved":false,"context_lines":[{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027HostAPI\u0027,"},{"line_number":361,"context_line":"                                   host\u003dhost_identifier)"},{"line_number":362,"context_line":""},{"line_number":363,"context_line":"    notifier.info(context, \u0027HostAPI.%s\u0027 % event_suffix, host_payload)"}],"source_content_type":"text/x-python","patch_set":3,"id":"AAAATH%2F%2FwXU%3D","line":360,"in_reply_to":"AAAATH%2F%2FwcA%3D","updated":"2013-10-10 09:34:49.000000000","message":"Thanks Guo Hui. But I think that we should use different service but not only \"service\". If someone want to use publish id, then he can classify different publish id based on different service name.","commit_id":"a55012c7c773e1dffbd97ea4036ebae2354335bb"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"072ff51dc822c9558fce7f326ba91316db9934f4","unresolved":false,"context_lines":[{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification\""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027api\u0027,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2FsvY%3D","line":357,"updated":"2013-10-11 01:14:22.000000000","message":"we need a blank between notification and and.","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"4df8d1ea8448446578fba3244daad852701d214a","unresolved":false,"context_lines":[{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification\""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027api\u0027,"}],"source_content_type":"text/x-python","patch_set":4,"id":"AAAATH%2F%2Fsuo%3D","line":357,"in_reply_to":"AAAATH%2F%2FsvY%3D","updated":"2013-10-11 01:26:11.000000000","message":"Done","commit_id":"7d05c6f9ea4d9fca72f7b65924e9a77fc519d9b3"},{"author":{"_account_id":7040,"name":"GuoHui LIu","email":"liuguohui@gmail.com","username":"guohliu"},"change_message_id":"3ee4a01046dbe594a68d4c860e66a2cdd71a9c2e","unresolved":false,"context_lines":[{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification \""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FPR0%3D","line":356,"updated":"2013-10-20 00:40:37.000000000","message":"ni: how about to log the host_name here for debugging?","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"400b5c24a083cbe85338d51cc5123b2853304bbc","unresolved":false,"context_lines":[{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification \""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FPQ0%3D","line":356,"in_reply_to":"AAAATH%2F%2FPR0%3D","updated":"2013-10-20 00:56:16.000000000","message":"The host name is None for such case.","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":1653,"name":"garyk","email":"gkotton@vmware.com","username":"garyk"},"change_message_id":"a244b9e1847603cb010fa6d48851eeac80e58648","unresolved":false,"context_lines":[{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027api\u0027,"},{"line_number":361,"context_line":"                                   host\u003dhost_identifier)"},{"line_number":362,"context_line":""},{"line_number":363,"context_line":"    notifier.info(context, \u0027HostAPI.%s\u0027 % event_suffix, host_payload)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FRMQ%3D","line":360,"updated":"2013-10-18 17:32:29.000000000","message":"Is \u0027api\u0027 correct for the service here? I am not familiar with this.","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"e012bd8ee373fc296db346af42d83db286100134","unresolved":false,"context_lines":[{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":"    notifier \u003d notify.get_notifier(service\u003d\u0027api\u0027,"},{"line_number":361,"context_line":"                                   host\u003dhost_identifier)"},{"line_number":362,"context_line":""},{"line_number":363,"context_line":"    notifier.info(context, \u0027HostAPI.%s\u0027 % event_suffix, host_payload)"}],"source_content_type":"text/x-python","patch_set":7,"id":"AAAATH%2F%2FQVw%3D","line":360,"in_reply_to":"AAAATH%2F%2FRMQ%3D","updated":"2013-10-19 01:09:53.000000000","message":"Thanks Gary, please refer to https://review.openstack.org/#/c/46642/3/nova/compute/utils.py for some discussion of this. ;-)","commit_id":"6adfa10f2ae1b7f5b569e46f6ee82ddaf2dff11d"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6e4eecf31cf61908afaa9e822c13a03fe2d1e3dc","unresolved":false,"context_lines":[{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""},{"line_number":351,"context_line":"    :param event_suffix: Event type like \"create.start\" or \"create.end\""},{"line_number":352,"context_line":"    :param aggregate_payload: payload for host update"},{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAATH%2F%2FI8s%3D","line":352,"updated":"2013-10-22 16:01:44.000000000","message":"Wrong arg name. You should point out this is expected to be a dict and list the required keys.","commit_id":"b567561d0cb775e963e5b1d72ee6d6db9d425a35"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"9b7a9b3c11477df832b8878bd4be87933c9e9d0e","unresolved":false,"context_lines":[{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""},{"line_number":351,"context_line":"    :param event_suffix: Event type like \"create.start\" or \"create.end\""},{"line_number":352,"context_line":"    :param aggregate_payload: payload for host update"},{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAATH%2F%2FHJM%3D","line":352,"in_reply_to":"AAAATH%2F%2FI8s%3D","updated":"2013-10-23 05:27:28.000000000","message":"Done","commit_id":"b567561d0cb775e963e5b1d72ee6d6db9d425a35"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6e4eecf31cf61908afaa9e822c13a03fe2d1e3dc","unresolved":false,"context_lines":[{"line_number":351,"context_line":"    :param event_suffix: Event type like \"create.start\" or \"create.end\""},{"line_number":352,"context_line":"    :param aggregate_payload: payload for host update"},{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification \""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAATH%2F%2FI8g%3D","line":354,"updated":"2013-10-22 16:01:44.000000000","message":"Isn\u0027t dict.get(\u0027key\u0027, None) redundant?  It returns None by default.","commit_id":"b567561d0cb775e963e5b1d72ee6d6db9d425a35"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"9b7a9b3c11477df832b8878bd4be87933c9e9d0e","unresolved":false,"context_lines":[{"line_number":351,"context_line":"    :param event_suffix: Event type like \"create.start\" or \"create.end\""},{"line_number":352,"context_line":"    :param aggregate_payload: payload for host update"},{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification \""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAATX%2F%2F%2F2k%3D","line":354,"in_reply_to":"AAAATH%2F%2FI8g%3D","updated":"2013-10-23 05:27:28.000000000","message":"Done","commit_id":"b567561d0cb775e963e5b1d72ee6d6db9d425a35"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6e4eecf31cf61908afaa9e822c13a03fe2d1e3dc","unresolved":false,"context_lines":[{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification \""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAATH%2F%2FI8Q%3D","line":356,"updated":"2013-10-22 16:01:44.000000000","message":"suggestion: put the event_suffix in the debug message for context.","commit_id":"b567561d0cb775e963e5b1d72ee6d6db9d425a35"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"9b7a9b3c11477df832b8878bd4be87933c9e9d0e","unresolved":false,"context_lines":[{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027, None)"},{"line_number":355,"context_line":"    if not host_identifier:"},{"line_number":356,"context_line":"        LOG.debug(_(\"No host name specified for this notification \""},{"line_number":357,"context_line":"                    \"and it will be ignored\"))"},{"line_number":358,"context_line":"        return"},{"line_number":359,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"AAAATX%2F%2F%2F2c%3D","line":356,"in_reply_to":"AAAATH%2F%2FI8Q%3D","updated":"2013-10-23 05:27:28.000000000","message":"Done","commit_id":"b567561d0cb775e963e5b1d72ee6d6db9d425a35"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"656008d323358a8becfbacd184ed2ebe1eba081c","unresolved":false,"context_lines":[{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""},{"line_number":351,"context_line":"    :param event_suffix: Event type like \"create.start\" or \"create.end\""},{"line_number":352,"context_line":"    :param host_payload: payload for host update"},{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027)"},{"line_number":355,"context_line":"    if not host_identifier:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATX%2F%2F%2BSI%3D","line":352,"updated":"2013-10-23 13:28:50.000000000","message":"I still think you should point out this is a dict and you expect at least the \u0027host_name\u0027 key to be set in there.  This is a public utility method so it should be well documented for usage.\n\nI see that notify_about_aggregate_update has the same level of doc string, but I think we can do better here.","commit_id":"ca30624d71b1a965205935742c211a407615868a"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"9b48df69b325ebc8b0fa0e8bd4456921a8f06145","unresolved":false,"context_lines":[{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""},{"line_number":351,"context_line":"    :param event_suffix: Event type like \"create.start\" or \"create.end\""},{"line_number":352,"context_line":"    :param host_payload: payload for host update"},{"line_number":353,"context_line":"    \"\"\""},{"line_number":354,"context_line":"    host_identifier \u003d host_payload.get(\u0027host_name\u0027)"},{"line_number":355,"context_line":"    if not host_identifier:"}],"source_content_type":"text/x-python","patch_set":9,"id":"AAAATn%2F%2F7zY%3D","line":352,"in_reply_to":"AAAATX%2F%2F%2BSI%3D","updated":"2013-10-24 23:58:50.000000000","message":"Done","commit_id":"ca30624d71b1a965205935742c211a407615868a"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"155e4f628e2d5b34bc09225ea8e5d7b43a6fd525","unresolved":false,"context_lines":[{"line_number":344,"context_line":"    notifier.info(context, \u0027aggregate.%s\u0027 % event_suffix, aggregate_payload)"},{"line_number":345,"context_line":""},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"def notify_about_host_update(context, event_suffix, host_payload):"},{"line_number":348,"context_line":"    \"\"\""},{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F%2FmfM%3D","line":347,"updated":"2013-10-31 15:57:48.000000000","message":"Since the only callers of this are in the HostAPI, I probably would have just put the method there.  I tend to this of this module as being for code more likely to get re-used.","commit_id":"d8ffb4bf424c73babbeb5ce1c19476ba95940f94"},{"author":{"_account_id":2835,"name":"Brian Elliott","email":"bdelliott@gmail.com","username":"belliott"},"change_message_id":"95077bd763252454ee1e3173715987d9911235b7","unresolved":false,"context_lines":[{"line_number":344,"context_line":"    notifier.info(context, \u0027aggregate.%s\u0027 % event_suffix, aggregate_payload)"},{"line_number":345,"context_line":""},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"def notify_about_host_update(context, event_suffix, host_payload):"},{"line_number":348,"context_line":"    \"\"\""},{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F%2Fi1I%3D","line":347,"in_reply_to":"AAAATn%2F%2FlXE%3D","updated":"2013-11-01 16:38:55.000000000","message":"notify_about_aggregate_update is also used in objects/aggreate, but I understand the point you and Matt are making.\n\nPersonally, I wouldn\u0027t extract it to a utils module unless it is a utility, which to me means that there is more than one caller.  I don\u0027t feel terribly strongly about this, though, and if you want to do it solely for consistency then I won\u0027t hold the review up.","commit_id":"d8ffb4bf424c73babbeb5ce1c19476ba95940f94"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"78466ace5e0d755d4e6045eb20a41866e41960da","unresolved":false,"context_lines":[{"line_number":344,"context_line":"    notifier.info(context, \u0027aggregate.%s\u0027 % event_suffix, aggregate_payload)"},{"line_number":345,"context_line":""},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"def notify_about_host_update(context, event_suffix, host_payload):"},{"line_number":348,"context_line":"    \"\"\""},{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F%2FlXE%3D","line":347,"in_reply_to":"AAAATn%2F%2FlkU%3D","updated":"2013-10-31 22:07:57.000000000","message":"Thanks Brian and Matt. \n\n@Brian, my original thinking was that this call might also be used in nova compute manager.py, so I put it here to be a public method for future reference.\n\nAs now host operations will call nova compute manager, it is better that we keep it here so that nova compute manager can still use it if needed.\n\nYes, agree with Matt, both notify_about_instance_usage and notify_about_aggregate_update are designed for such reason, the difference is that notify_about_instance_usage was now used in nova compute manager and api but notify_about_aggregate_update was only used in api part.\n\nThanks.","commit_id":"d8ffb4bf424c73babbeb5ce1c19476ba95940f94"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"555192c9ce3319b5a85b28cebbb3c40e0aa5a884","unresolved":false,"context_lines":[{"line_number":344,"context_line":"    notifier.info(context, \u0027aggregate.%s\u0027 % event_suffix, aggregate_payload)"},{"line_number":345,"context_line":""},{"line_number":346,"context_line":""},{"line_number":347,"context_line":"def notify_about_host_update(context, event_suffix, host_payload):"},{"line_number":348,"context_line":"    \"\"\""},{"line_number":349,"context_line":"    Send a notification about host update."},{"line_number":350,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"AAAATn%2F%2FlkU%3D","line":347,"in_reply_to":"AAAATn%2F%2FmfM%3D","updated":"2013-10-31 20:12:14.000000000","message":"You could make the same argument about notify_about_instance_usage and *maybe* notify_about_aggregate_update, right?  I think ht\u0027s just here to be consistent with those others which are used in nova.compute.api.","commit_id":"d8ffb4bf424c73babbeb5ce1c19476ba95940f94"}],"nova/tests/compute/test_host_api.py":[{"author":{"_account_id":1501,"name":"Phil Day","email":"philip.day@hp.com","username":"philip-day"},"change_message_id":"cdf9fa9465f07c1f7f5b3d766aaad4a4b1963688","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        self.assertEqual(\u0027fake-result\u0027, result)"},{"line_number":73,"context_line":"        self.assertEqual(len(fake_notifier.NOTIFICATIONS), 2)"},{"line_number":74,"context_line":"        msg \u003d fake_notifier.NOTIFICATIONS[0]"},{"line_number":75,"context_line":"        self.assertEqual(msg.event_type,"},{"line_number":76,"context_line":"                         \u0027HostAPI.set.host.enable.start\u0027)"},{"line_number":77,"context_line":"        msg \u003d fake_notifier.NOTIFICATIONS[1]"},{"line_number":78,"context_line":"        self.assertEqual(msg.event_type,"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAATH%2F%2FqyI%3D","line":75,"updated":"2013-10-11 13:42:35.000000000","message":"Why not also verify the payload ?","commit_id":"cd2d88b8685036df593cac282f95f492147ab766"},{"author":{"_account_id":7494,"name":"Guangya Liu","email":"gyliu513@gmail.com","username":"JayLau"},"change_message_id":"f38ac7258bc7cfd795a29a833d1e64ee9e9fff63","unresolved":false,"context_lines":[{"line_number":72,"context_line":"        self.assertEqual(\u0027fake-result\u0027, result)"},{"line_number":73,"context_line":"        self.assertEqual(len(fake_notifier.NOTIFICATIONS), 2)"},{"line_number":74,"context_line":"        msg \u003d fake_notifier.NOTIFICATIONS[0]"},{"line_number":75,"context_line":"        self.assertEqual(msg.event_type,"},{"line_number":76,"context_line":"                         \u0027HostAPI.set.host.enable.start\u0027)"},{"line_number":77,"context_line":"        msg \u003d fake_notifier.NOTIFICATIONS[1]"},{"line_number":78,"context_line":"        self.assertEqual(msg.event_type,"}],"source_content_type":"text/x-python","patch_set":5,"id":"AAAATH%2F%2Foqk%3D","line":75,"in_reply_to":"AAAATH%2F%2FqyI%3D","updated":"2013-10-11 23:55:05.000000000","message":"Thanks Phil, a new patch will be uploaded later.","commit_id":"cd2d88b8685036df593cac282f95f492147ab766"}]}
