)]}'
{"ironic/conductor/manager.py":[{"author":{"_account_id":7711,"name":"Yuriy Zveryanskyy","email":"yzveryanskyy@mirantis.com","username":"yuriyz"},"change_message_id":"6b404cfe808f07997eb5b56fc0da29acf84745e5","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                                   exception.NodeLocked,"},{"line_number":138,"context_line":"                                   exception.InvalidState,"},{"line_number":139,"context_line":"                                   exception.DriverNotFound)"},{"line_number":140,"context_line":"    def update_node(self, context, node_obj):"},{"line_number":141,"context_line":"        \"\"\"Update a node with the supplied data."},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        This method is the main \"hub\" for PUT and PATCH requests in the API."}],"source_content_type":"text/x-python","patch_set":1,"id":"5ff73747_f26ad77e","line":140,"updated":"2017-04-28 11:23:11.000000000","message":"Maintenance can be set here by operator request, in maintenance node can be totally unplugged for example. Maybe reset state to None for this case?","commit_id":"eb6b1c019bca7fcdbd5c7eaf68f98bf9d489566b"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"1eae027d7f8831e899edf0cfa8791737f76fd7ee","unresolved":false,"context_lines":[{"line_number":137,"context_line":"                                   exception.NodeLocked,"},{"line_number":138,"context_line":"                                   exception.InvalidState,"},{"line_number":139,"context_line":"                                   exception.DriverNotFound)"},{"line_number":140,"context_line":"    def update_node(self, context, node_obj):"},{"line_number":141,"context_line":"        \"\"\"Update a node with the supplied data."},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"        This method is the main \"hub\" for PUT and PATCH requests in the API."}],"source_content_type":"text/x-python","patch_set":1,"id":"3f044301_9675f966","line":140,"in_reply_to":"5ff73747_f26ad77e","updated":"2017-05-10 11:45:50.000000000","message":"Done","commit_id":"eb6b1c019bca7fcdbd5c7eaf68f98bf9d489566b"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"6c907a93ac67fea2f5c59af0a2723307effdf4c3","unresolved":false,"context_lines":[{"line_number":156,"context_line":""},{"line_number":157,"context_line":"        delta \u003d node_obj.obj_what_changed()"},{"line_number":158,"context_line":"        if \u0027maintenance\u0027 in delta:"},{"line_number":159,"context_line":"            if node_obj.maintenance:"},{"line_number":160,"context_line":"                # NOTE(dtantsur): clear power state if maintenance is set, as"},{"line_number":161,"context_line":"                # it can quickly get outdated without the power state sync."},{"line_number":162,"context_line":"                node_obj.power_state \u003d states.NOSTATE"},{"line_number":163,"context_line":"            else:"},{"line_number":164,"context_line":"                # NOTE(jroll) clear maintenance_reason if node.update sets"},{"line_number":165,"context_line":"                # maintenance to False for backwards compatibility, for tools"},{"line_number":166,"context_line":"                # not using the maintenance endpoint."},{"line_number":167,"context_line":"                node_obj.maintenance_reason \u003d None"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"        # TODO(dtantsur): reconsider allowing changing some (but not all)"},{"line_number":170,"context_line":"        # interfaces for active nodes in the future."}],"source_content_type":"text/x-python","patch_set":2,"id":"3f044301_d89ba363","line":167,"range":{"start_line":159,"start_character":11,"end_line":167,"end_character":50},"updated":"2017-05-10 21:43:56.000000000","message":"Instead of changing here can we call utils.set_maintenance_node() from api/node.py at https://github.com/openstack/ironic/blob/5071b99835143ebcae876432e2982fd27faece10/ironic/api/controllers/v1/node.py#L1097\nI think that would be good, because we are adding a new method,wdyt?","commit_id":"81047bd0e04d569ab3722a435d1b0c2ff31dbb44"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"9b0bfc6c31632aabb7006ecb5df20b162999c6fb","unresolved":false,"context_lines":[{"line_number":156,"context_line":""},{"line_number":157,"context_line":"        delta \u003d node_obj.obj_what_changed()"},{"line_number":158,"context_line":"        if \u0027maintenance\u0027 in delta:"},{"line_number":159,"context_line":"            if node_obj.maintenance:"},{"line_number":160,"context_line":"                # NOTE(dtantsur): clear power state if maintenance is set, as"},{"line_number":161,"context_line":"                # it can quickly get outdated without the power state sync."},{"line_number":162,"context_line":"                node_obj.power_state \u003d states.NOSTATE"},{"line_number":163,"context_line":"            else:"},{"line_number":164,"context_line":"                # NOTE(jroll) clear maintenance_reason if node.update sets"},{"line_number":165,"context_line":"                # maintenance to False for backwards compatibility, for tools"},{"line_number":166,"context_line":"                # not using the maintenance endpoint."},{"line_number":167,"context_line":"                node_obj.maintenance_reason \u003d None"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"        # TODO(dtantsur): reconsider allowing changing some (but not all)"},{"line_number":170,"context_line":"        # interfaces for active nodes in the future."}],"source_content_type":"text/x-python","patch_set":2,"id":"ff0f0b1f_104d0a3d","line":167,"range":{"start_line":159,"start_character":11,"end_line":167,"end_character":50},"in_reply_to":"3f044301_d89ba363","updated":"2017-05-25 08:50:50.000000000","message":"Hi! The API method you mention is not the only way to set maintenance - it can also be set directly via node update (which is discouraged, but possible).","commit_id":"81047bd0e04d569ab3722a435d1b0c2ff31dbb44"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"4a03867fc83d9d83245222a87bc0100281fcc786","unresolved":false,"context_lines":[{"line_number":156,"context_line":""},{"line_number":157,"context_line":"        delta \u003d node_obj.obj_what_changed()"},{"line_number":158,"context_line":"        if \u0027maintenance\u0027 in delta:"},{"line_number":159,"context_line":"            if node_obj.maintenance:"},{"line_number":160,"context_line":"                # NOTE(dtantsur): clear power state if maintenance is set, as"},{"line_number":161,"context_line":"                # it can quickly get outdated without the power state sync."},{"line_number":162,"context_line":"                node_obj.power_state \u003d states.NOSTATE"},{"line_number":163,"context_line":"            else:"},{"line_number":164,"context_line":"                # NOTE(jroll) clear maintenance_reason if node.update sets"},{"line_number":165,"context_line":"                # maintenance to False for backwards compatibility, for tools"},{"line_number":166,"context_line":"                # not using the maintenance endpoint."},{"line_number":167,"context_line":"                node_obj.maintenance_reason \u003d None"},{"line_number":168,"context_line":""},{"line_number":169,"context_line":"        # TODO(dtantsur): reconsider allowing changing some (but not all)"},{"line_number":170,"context_line":"        # interfaces for active nodes in the future."}],"source_content_type":"text/x-python","patch_set":2,"id":"df140735_22687df3","line":167,"range":{"start_line":159,"start_character":11,"end_line":167,"end_character":50},"in_reply_to":"ff0f0b1f_104d0a3d","updated":"2017-05-30 18:59:17.000000000","message":"Hi! yeah well i just thought because we already have that method pointed above so why not to use it, not insisting :)","commit_id":"81047bd0e04d569ab3722a435d1b0c2ff31dbb44"}],"ironic/conductor/utils.py":[{"author":{"_account_id":7711,"name":"Yuriy Zveryanskyy","email":"yzveryanskyy@mirantis.com","username":"yuriyz"},"change_message_id":"92d14c444e5ec6125b601d85bebcfdbb36055418","unresolved":false,"context_lines":[{"line_number":283,"context_line":"    node.maintenance \u003d True"},{"line_number":284,"context_line":"    node.maintenance_reason \u003d reason"},{"line_number":285,"context_line":"    # Clean power state, as we stop syncing it."},{"line_number":286,"context_line":"    node.power_state \u003d None"},{"line_number":287,"context_line":"    LOG.debug(\u0027Node %s entered maintenance mode\u0027, node.uuid)"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"5ff73747_9766e5c0","line":286,"updated":"2017-04-28 11:13:17.000000000","message":"nit: better to use states.NOSTATE here","commit_id":"eb6b1c019bca7fcdbd5c7eaf68f98bf9d489566b"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"1eae027d7f8831e899edf0cfa8791737f76fd7ee","unresolved":false,"context_lines":[{"line_number":283,"context_line":"    node.maintenance \u003d True"},{"line_number":284,"context_line":"    node.maintenance_reason \u003d reason"},{"line_number":285,"context_line":"    # Clean power state, as we stop syncing it."},{"line_number":286,"context_line":"    node.power_state \u003d None"},{"line_number":287,"context_line":"    LOG.debug(\u0027Node %s entered maintenance mode\u0027, node.uuid)"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"3f044301_566bf183","line":286,"in_reply_to":"5ff73747_9766e5c0","updated":"2017-05-10 11:45:50.000000000","message":"Done","commit_id":"eb6b1c019bca7fcdbd5c7eaf68f98bf9d489566b"},{"author":{"_account_id":7711,"name":"Yuriy Zveryanskyy","email":"yzveryanskyy@mirantis.com","username":"yuriyz"},"change_message_id":"92d14c444e5ec6125b601d85bebcfdbb36055418","unresolved":false,"context_lines":[{"line_number":284,"context_line":"    node.maintenance_reason \u003d reason"},{"line_number":285,"context_line":"    # Clean power state, as we stop syncing it."},{"line_number":286,"context_line":"    node.power_state \u003d None"},{"line_number":287,"context_line":"    LOG.debug(\u0027Node %s entered maintenance mode\u0027, node.uuid)"},{"line_number":288,"context_line":""},{"line_number":289,"context_line":""},{"line_number":290,"context_line":"def cleaning_error_handler(task, msg, tear_down_cleaning\u003dTrue,"}],"source_content_type":"text/x-python","patch_set":1,"id":"5ff73747_57ecdd8d","line":287,"updated":"2017-04-28 11:13:17.000000000","message":"This is only for automatic maintenance set, does not cover maintenance set by operator. Please add something like \"automatically by conductor\".","commit_id":"eb6b1c019bca7fcdbd5c7eaf68f98bf9d489566b"}]}
