)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"d625836b545b354894a5017d2e7d7429f113b873","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Register/unregister hardware interfaces for conductors"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This registers the intersection of supported and enabled interfaces for"},{"line_number":10,"context_line":"each hardware type enabled in the conductor at conductor startup, and"},{"line_number":11,"context_line":"unregisters them at conductor shutdown. Validation is left as a todo for"},{"line_number":12,"context_line":"now."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":15,"id":"5a3905b3_57cc6835","line":10,"range":{"start_line":10,"start_character":47,"end_line":10,"end_character":56},"updated":"2017-01-19 15:04:24.000000000","message":"nit: s/conductor// \n\nsecond conductor sounds redundant","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"d625836b545b354894a5017d2e7d7429f113b873","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"This registers the intersection of supported and enabled interfaces for"},{"line_number":10,"context_line":"each hardware type enabled in the conductor at conductor startup, and"},{"line_number":11,"context_line":"unregisters them at conductor shutdown. Validation is left as a todo for"},{"line_number":12,"context_line":"now."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"Change-Id: I14e88bfc304de9414de008d1cc8568dda9115ecc"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":15,"id":"5a3905b3_b702ec3c","line":11,"range":{"start_line":11,"start_character":20,"end_line":11,"end_character":29},"updated":"2017-01-19 15:04:24.000000000","message":"ditto","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"}],"ironic/common/driver_factory.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"20498d1f3a07b708681ce76549a31f7e1cadf79d","unresolved":false,"context_lines":[{"line_number":448,"context_line":"        cls._extension_manager.map(cls._extension_manager.names(),"},{"line_number":449,"context_line":"                                   _warn_if_unsupported)"},{"line_number":450,"context_line":""},{"line_number":451,"context_line":"        LOG.info(_LI(\"Loaded the following drivers: %s\"),"},{"line_number":452,"context_line":"                 cls._extension_manager.names())"},{"line_number":453,"context_line":""},{"line_number":454,"context_line":"    @property"}],"source_content_type":"text/x-python","patch_set":10,"id":"ba5201f7_1134b448","line":451,"range":{"start_line":451,"start_character":22,"end_line":451,"end_character":54},"updated":"2017-01-09 16:52:08.000000000","message":"side thought: we need to fix this, it\u0027s extremely misleading","commit_id":"5cd4a02d16da50c315591324ac2b142285a3007b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":310,"context_line":""},{"line_number":311,"context_line":""},{"line_number":312,"context_line":"def hardware_types():"},{"line_number":313,"context_line":"    \"\"\"Get all drivers as a dict name -\u003e driver object.\"\"\""},{"line_number":314,"context_line":"    return _get_all_drivers(HardwareTypesFactory())"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_d669c9bf","line":313,"updated":"2017-01-11 17:54:28.000000000","message":"i think this gets hardware types, not drivers?","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":310,"context_line":""},{"line_number":311,"context_line":""},{"line_number":312,"context_line":"def hardware_types():"},{"line_number":313,"context_line":"    \"\"\"Get all drivers as a dict name -\u003e driver object.\"\"\""},{"line_number":314,"context_line":"    return _get_all_drivers(HardwareTypesFactory())"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_30511637","line":313,"in_reply_to":"ba5201f7_d669c9bf","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":315,"context_line":""},{"line_number":316,"context_line":""},{"line_number":317,"context_line":"def interfaces(interface_type):"},{"line_number":318,"context_line":"    return _get_all_drivers(_INTERFACE_LOADERS[interface_type]())"},{"line_number":319,"context_line":""},{"line_number":320,"context_line":""},{"line_number":321,"context_line":"def enabled_supported_interfaces(hardware_type):"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_56831956","line":318,"updated":"2017-01-11 17:54:28.000000000","message":"docstring? gets all interfaces for the specified interface type? As dict interface-name -\u003e interface object?","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":315,"context_line":""},{"line_number":316,"context_line":""},{"line_number":317,"context_line":"def interfaces(interface_type):"},{"line_number":318,"context_line":"    return _get_all_drivers(_INTERFACE_LOADERS[interface_type]())"},{"line_number":319,"context_line":""},{"line_number":320,"context_line":""},{"line_number":321,"context_line":"def enabled_supported_interfaces(hardware_type):"}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_50422269","line":318,"in_reply_to":"ba5201f7_56831956","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":319,"context_line":""},{"line_number":320,"context_line":""},{"line_number":321,"context_line":"def enabled_supported_interfaces(hardware_type):"},{"line_number":322,"context_line":"    \"\"\"Get the intersection of enabled and supported interfaces for each type."},{"line_number":323,"context_line":""},{"line_number":324,"context_line":"    :param hardware_type: The hardware type object to search."},{"line_number":325,"context_line":"    :returns: a dict mapping interface types to a list of enabled and supported"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_5606b9ce","line":322,"updated":"2017-01-11 17:54:28.000000000","message":"by \u0027for each type\u0027, you mean \u0027for each interface type\u0027, right? And only for the specified hardware type? (Are we lost yet?)","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":319,"context_line":""},{"line_number":320,"context_line":""},{"line_number":321,"context_line":"def enabled_supported_interfaces(hardware_type):"},{"line_number":322,"context_line":"    \"\"\"Get the intersection of enabled and supported interfaces for each type."},{"line_number":323,"context_line":""},{"line_number":324,"context_line":"    :param hardware_type: The hardware type object to search."},{"line_number":325,"context_line":"    :returns: a dict mapping interface types to a list of enabled and supported"}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_50106259","line":322,"in_reply_to":"ba5201f7_5606b9ce","updated":"2017-01-17 17:14:59.000000000","message":"Yes, I ran out of space on this line. Will elaborate.","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"d625836b545b354894a5017d2e7d7429f113b873","unresolved":false,"context_lines":[{"line_number":354,"context_line":"            enabled.add(name)"},{"line_number":355,"context_line":"            if iface.__class__ in supported_ifaces:"},{"line_number":356,"context_line":"                supported.add(name)"},{"line_number":357,"context_line":"        mapping[interface_type] \u003d enabled.intersection(supported)"},{"line_number":358,"context_line":"    return mapping"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"5a3905b3_9a5fd571","line":357,"updated":"2017-01-19 15:04:24.000000000","message":"I think we don\u0027t need the enabled variable at all in this method. If we are intersectioning with the supported set it\u0027s better to just do:\n\n mapping[interface_type] \u003d supported","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"aa8877158bfa14b639baeb419b86f90fbaa0e0e0","unresolved":false,"context_lines":[{"line_number":354,"context_line":"            enabled.add(name)"},{"line_number":355,"context_line":"            if iface.__class__ in supported_ifaces:"},{"line_number":356,"context_line":"                supported.add(name)"},{"line_number":357,"context_line":"        mapping[interface_type] \u003d enabled.intersection(supported)"},{"line_number":358,"context_line":"    return mapping"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"5a3905b3_7963051b","line":357,"in_reply_to":"5a3905b3_29185484","updated":"2017-01-19 20:41:15.000000000","message":"So, interfaces() only returns loaded drivers, so they are enabled (which is why there\u0027s no if statement around enabled.add(...).\n\nSupported is not always a subset of enabled, but as we\u0027re iterating over enabled here we only need to find which of those enabled interfaces is supported.\n\nDone.","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"439b412c0d3ba2d02fb8024a2c1bf7fc9d7917c3","unresolved":false,"context_lines":[{"line_number":354,"context_line":"            enabled.add(name)"},{"line_number":355,"context_line":"            if iface.__class__ in supported_ifaces:"},{"line_number":356,"context_line":"                supported.add(name)"},{"line_number":357,"context_line":"        mapping[interface_type] \u003d enabled.intersection(supported)"},{"line_number":358,"context_line":"    return mapping"},{"line_number":359,"context_line":""},{"line_number":360,"context_line":""}],"source_content_type":"text/x-python","patch_set":15,"id":"5a3905b3_29185484","line":357,"in_reply_to":"5a3905b3_9a5fd571","updated":"2017-01-19 17:34:54.000000000","message":"@Lucas, you lost me. We want only the interfaces that are both enabled AND supported. Or are supported interfaces always a subset of enabled? (I can\u0027t keep track...)","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"}],"ironic/common/exception.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"583492cb434e714fe6b96233b5a7c637af15a438","unresolved":false,"context_lines":[{"line_number":430,"context_line":""},{"line_number":431,"context_line":""},{"line_number":432,"context_line":"class ConductorHardwareInterfaceAlreadyRegistered(IronicException):"},{"line_number":433,"context_line":"    _msg_fmt \u003d _(\"Conductor interfaces already registered for hardware type \""},{"line_number":434,"context_line":"                 \" %(hardware_type)s, interface type %(interface_type)s, \""},{"line_number":435,"context_line":"                 \"interfaces %(interfaces)s\")"},{"line_number":436,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"9a57fde8_4b3121a2","line":433,"range":{"start_line":433,"start_character":28,"end_line":433,"end_character":38},"updated":"2017-01-12 18:41:34.000000000","message":"Might make more sense to add %(interfaces)s after this one.","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"b99f213b6f61009946b6aaa3194ff8872d247faf","unresolved":false,"context_lines":[{"line_number":430,"context_line":""},{"line_number":431,"context_line":""},{"line_number":432,"context_line":"class ConductorHardwareInterfaceAlreadyRegistered(IronicException):"},{"line_number":433,"context_line":"    _msg_fmt \u003d _(\"Conductor interfaces already registered for hardware type \""},{"line_number":434,"context_line":"                 \" %(hardware_type)s, interface type %(interface_type)s, \""},{"line_number":435,"context_line":"                 \"interfaces %(interfaces)s\")"},{"line_number":436,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"7a3c09a3_e5718645","line":433,"range":{"start_line":433,"start_character":28,"end_line":433,"end_character":38},"in_reply_to":"9a57fde8_4b3121a2","updated":"2017-01-17 17:18:13.000000000","message":"Done","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":429,"context_line":"    _msg_fmt \u003d _(\"Conductor %(conductor)s already registered.\")"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":""},{"line_number":432,"context_line":"class ConductorHardwareInterfaceAlreadyRegistered(IronicException):"},{"line_number":433,"context_line":"    _msg_fmt \u003d _(\"Conductor interfaces %(interfaces)s already registered for \""},{"line_number":434,"context_line":"                 \"hardware type %(hardware_type)s, interface type \""},{"line_number":435,"context_line":"                 \"%(interface_type)s.\")"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_fa070e16","line":432,"updated":"2017-01-18 22:49:38.000000000","message":"this is a really small small nit, but I thought that this was for only one interface. Could be more than one interface so s/Interface/Interfaces/","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":429,"context_line":"    _msg_fmt \u003d _(\"Conductor %(conductor)s already registered.\")"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":""},{"line_number":432,"context_line":"class ConductorHardwareInterfaceAlreadyRegistered(IronicException):"},{"line_number":433,"context_line":"    _msg_fmt \u003d _(\"Conductor interfaces %(interfaces)s already registered for \""},{"line_number":434,"context_line":"                 \"hardware type %(hardware_type)s, interface type \""},{"line_number":435,"context_line":"                 \"%(interface_type)s.\")"}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_2fe22f04","line":432,"in_reply_to":"7a3c09a3_fa070e16","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":430,"context_line":""},{"line_number":431,"context_line":""},{"line_number":432,"context_line":"class ConductorHardwareInterfaceAlreadyRegistered(IronicException):"},{"line_number":433,"context_line":"    _msg_fmt \u003d _(\"Conductor interfaces %(interfaces)s already registered for \""},{"line_number":434,"context_line":"                 \"hardware type %(hardware_type)s, interface type \""},{"line_number":435,"context_line":"                 \"%(interface_type)s.\")"},{"line_number":436,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_5f21f4b3","line":433,"updated":"2017-01-18 22:49:38.000000000","message":"nit. not all the interfaces are already registered, so maybe something like: \n\ns/Conductor/At least one of these (hardware type %s, interface type %s) interfaces ... are already registered in a conductor./","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":430,"context_line":""},{"line_number":431,"context_line":""},{"line_number":432,"context_line":"class ConductorHardwareInterfaceAlreadyRegistered(IronicException):"},{"line_number":433,"context_line":"    _msg_fmt \u003d _(\"Conductor interfaces %(interfaces)s already registered for \""},{"line_number":434,"context_line":"                 \"hardware type %(hardware_type)s, interface type \""},{"line_number":435,"context_line":"                 \"%(interface_type)s.\")"},{"line_number":436,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_4fa3fb9e","line":433,"in_reply_to":"7a3c09a3_5f21f4b3","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"}],"ironic/conductor/base_manager.py":[{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"c63640ce8592c1dfcd512f9cfa3d28402d7e5c1a","unresolved":false,"context_lines":[{"line_number":229,"context_line":"                interfaces \u003d driver_factory.interfaces(interface_type)"},{"line_number":230,"context_line":"                enabled \u003d set([name for name in interfaces.keys()])"},{"line_number":231,"context_line":"                supported \u003d getattr(ht,"},{"line_number":232,"context_line":"                                    \u0027supported_%s_interfaces\u0027 % interface_type)"},{"line_number":233,"context_line":"                intersection \u003d enabled.intersection(supported)"},{"line_number":234,"context_line":"                self.conductor.register_interfaces(ht_name,"},{"line_number":235,"context_line":"                                                   interface_type,"}],"source_content_type":"text/x-python","patch_set":2,"id":"1a6eadb0_fcfe0237","line":232,"updated":"2016-12-19 22:39:06.000000000","message":"There\u0027s a bug here; these are the extension objects, not the name. Need to find a way to get the name of these from the hardware type that\u0027s loaded.","commit_id":"88ae915de07a4fdc6f38dd3f6d10c7b77778fdb9"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"8e949b1fd6def12f21a49785dc3e16c7b8ff0332","unresolved":false,"context_lines":[{"line_number":228,"context_line":"        hardware_types \u003d driver_factory.hardware_types()"},{"line_number":229,"context_line":"        for ht_name, ht in hardware_types.items():"},{"line_number":230,"context_line":"            # register the intersection of enabled and supported interfaces"},{"line_number":231,"context_line":"            for interface_type in driver_base.ALL_INTERFACES:"},{"line_number":232,"context_line":"                supported \u003d set()"},{"line_number":233,"context_line":"                enabled \u003d set()"},{"line_number":234,"context_line":"                interfaces \u003d driver_factory.interfaces(interface_type)"},{"line_number":235,"context_line":"                supported_ifaces \u003d getattr(ht,"},{"line_number":236,"context_line":"                                           \u0027supported_%s_interfaces\u0027 %"},{"line_number":237,"context_line":"                                           interface_type)"},{"line_number":238,"context_line":"                for name, iface in interfaces.items():"},{"line_number":239,"context_line":"                    enabled.add(name)"},{"line_number":240,"context_line":"                    if iface.__class__ in supported_ifaces:"},{"line_number":241,"context_line":"                        supported.add(name)"},{"line_number":242,"context_line":"                intersection \u003d enabled.intersection(supported)"},{"line_number":243,"context_line":"                self.conductor.register_interfaces(ht_name,"},{"line_number":244,"context_line":"                                                   interface_type,"},{"line_number":245,"context_line":"                                                   intersection)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba5201f7_d782ee51","line":242,"range":{"start_line":231,"start_character":0,"end_line":242,"end_character":62},"updated":"2017-01-03 13:22:09.000000000","message":"let\u0027s move this logic to driver_factory.py, we already have similar bits there.","commit_id":"adc47f81bf60de1e0fff5d51982696b53f135fe1"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"a3582cc8c3d4e546543e78bd3a877d2e65b5d6e4","unresolved":false,"context_lines":[{"line_number":228,"context_line":"        hardware_types \u003d driver_factory.hardware_types()"},{"line_number":229,"context_line":"        for ht_name, ht in hardware_types.items():"},{"line_number":230,"context_line":"            # register the intersection of enabled and supported interfaces"},{"line_number":231,"context_line":"            for interface_type in driver_base.ALL_INTERFACES:"},{"line_number":232,"context_line":"                supported \u003d set()"},{"line_number":233,"context_line":"                enabled \u003d set()"},{"line_number":234,"context_line":"                interfaces \u003d driver_factory.interfaces(interface_type)"},{"line_number":235,"context_line":"                supported_ifaces \u003d getattr(ht,"},{"line_number":236,"context_line":"                                           \u0027supported_%s_interfaces\u0027 %"},{"line_number":237,"context_line":"                                           interface_type)"},{"line_number":238,"context_line":"                for name, iface in interfaces.items():"},{"line_number":239,"context_line":"                    enabled.add(name)"},{"line_number":240,"context_line":"                    if iface.__class__ in supported_ifaces:"},{"line_number":241,"context_line":"                        supported.add(name)"},{"line_number":242,"context_line":"                intersection \u003d enabled.intersection(supported)"},{"line_number":243,"context_line":"                self.conductor.register_interfaces(ht_name,"},{"line_number":244,"context_line":"                                                   interface_type,"},{"line_number":245,"context_line":"                                                   intersection)"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba5201f7_05519d0e","line":242,"range":{"start_line":231,"start_character":0,"end_line":242,"end_character":62},"in_reply_to":"ba5201f7_d782ee51","updated":"2017-01-03 15:27:33.000000000","message":"Done","commit_id":"adc47f81bf60de1e0fff5d51982696b53f135fe1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":150,"context_line":""},{"line_number":151,"context_line":"        # register hardware types and interfaces supported by this conductor"},{"line_number":152,"context_line":"        # and validate them against other conductors"},{"line_number":153,"context_line":"        self._register_and_validate_hardware_interfaces()"},{"line_number":154,"context_line":""},{"line_number":155,"context_line":"        # Start periodic tasks"},{"line_number":156,"context_line":"        self._periodic_tasks_worker \u003d self._executor.submit("}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_9da12449","line":153,"updated":"2017-01-11 17:54:28.000000000","message":"I\u0027m curious why you made the call here as opposed to earlier, eg before clearing any node locks at L133. This seems something that could be done after L96 or L101?\n\nHmm, I looked at ._register_and_validate_hardware_interfaces(). Maybe I mean that this call should be done sooner: \n    hardware_types \u003d driver_factory.hardware_types()\n\nIf that raises Loading errors if the hardware type cannot be loaded, similar to getting drivers (and network interface, storage interfaces?) I don\u0027t recall the details now of L84-90, and whether the hardware types/interfaces should be treated similarly or not...\n\nSo what I\u0027m saying, is that I don\u0027t know which parts of ._register_and_validate_hardware_interfaces() we might want to do before we actually register the conductor to the cluster. If anything.","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":150,"context_line":""},{"line_number":151,"context_line":"        # register hardware types and interfaces supported by this conductor"},{"line_number":152,"context_line":"        # and validate them against other conductors"},{"line_number":153,"context_line":"        self._register_and_validate_hardware_interfaces()"},{"line_number":154,"context_line":""},{"line_number":155,"context_line":"        # Start periodic tasks"},{"line_number":156,"context_line":"        self._periodic_tasks_worker \u003d self._executor.submit("}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_93df3468","line":153,"in_reply_to":"ba5201f7_9da12449","updated":"2017-01-17 17:14:59.000000000","message":"We have a foreign key from the conductor_hardware_interfaces table into the conductors table, so we need to ensure that the conductor is registered before doing this.\n\nThat said, your comment makes me realize some gotchas with this, so I\u0027ll fix those up (not sure if here or in another patch).","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"ebcda513316c4805df43d9843ab038f2e0846009","unresolved":false,"context_lines":[{"line_number":235,"context_line":"                                                   interface_type,"},{"line_number":236,"context_line":"                                                   interface_names)"},{"line_number":237,"context_line":""},{"line_number":238,"context_line":"        # TODO(jroll) validate against other conductor, warn if different"},{"line_number":239,"context_line":"        # how do we do this performantly? :|"},{"line_number":240,"context_line":""},{"line_number":241,"context_line":"    def _collect_periodic_tasks(self, obj, args):"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_1a2a9d90","line":238,"updated":"2017-01-11 16:19:21.000000000","message":"maybe keep all (ht_name, interface_type, interface_name) as a list of tuples above, and use this with a negation? \n\nhttp://docs.sqlalchemy.org/en/latest/core/sqlelement.html?highlight\u003dtuple_#sqlalchemy.sql.expression.tuple_\n\nIt\u0027d be a race between conductors, but I think you\u0027d be guaranteed that at least 1 conductor would warn if there\u0027s any mismatch since the rows are all flushed out at once during registration","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":235,"context_line":"                                                   interface_type,"},{"line_number":236,"context_line":"                                                   interface_names)"},{"line_number":237,"context_line":""},{"line_number":238,"context_line":"        # TODO(jroll) validate against other conductor, warn if different"},{"line_number":239,"context_line":"        # how do we do this performantly? :|"},{"line_number":240,"context_line":""},{"line_number":241,"context_line":"    def _collect_periodic_tasks(self, obj, args):"}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_53aeac81","line":238,"in_reply_to":"ba5201f7_1a2a9d90","updated":"2017-01-17 17:14:59.000000000","message":"Maybe, going to leave this for later though.","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":14525,"name":"Vasyl Saienko","email":"vsaienko@mirantis.com","username":"vsaienko"},"change_message_id":"8e20e14403f3c623e4d4d21fc3af69f683136e79","unresolved":false,"context_lines":[{"line_number":231,"context_line":"        for ht_name, ht in hardware_types.items():"},{"line_number":232,"context_line":"            interface_map \u003d driver_factory.enabled_supported_interfaces(ht)"},{"line_number":233,"context_line":"            for interface_type, interface_names in interface_map.items():"},{"line_number":234,"context_line":"                self.conductor.register_interfaces(ht_name,"},{"line_number":235,"context_line":"                                                   interface_type,"},{"line_number":236,"context_line":"                                                   interface_names)"},{"line_number":237,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"7a3c09a3_26941536","line":234,"updated":"2017-01-13 10:56:33.000000000","message":"May raise ConductorHardwareInterfaceAlreadyRegistered, should it be catched and wrapped like at L145","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"b99f213b6f61009946b6aaa3194ff8872d247faf","unresolved":false,"context_lines":[{"line_number":231,"context_line":"        for ht_name, ht in hardware_types.items():"},{"line_number":232,"context_line":"            interface_map \u003d driver_factory.enabled_supported_interfaces(ht)"},{"line_number":233,"context_line":"            for interface_type, interface_names in interface_map.items():"},{"line_number":234,"context_line":"                self.conductor.register_interfaces(ht_name,"},{"line_number":235,"context_line":"                                                   interface_type,"},{"line_number":236,"context_line":"                                                   interface_names)"},{"line_number":237,"context_line":""}],"source_content_type":"text/x-python","patch_set":13,"id":"7a3c09a3_c5e3aaa2","line":234,"in_reply_to":"7a3c09a3_26941536","updated":"2017-01-17 17:18:13.000000000","message":"I\u0027m intentionally letting that bubble up, and will be handling it in the next patch set.","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"7b23bf46e10c3838a024429f93ea552e9ca9430d","unresolved":false,"context_lines":[{"line_number":86,"context_line":"        # startup so that all the interfaces are loaded at the very"},{"line_number":87,"context_line":"        # beginning, and failures prevent the conductor from starting."},{"line_number":88,"context_line":"        drivers \u003d driver_factory.drivers()"},{"line_number":89,"context_line":"        driver_factory.NetworkInterfaceFactory()"},{"line_number":90,"context_line":"        driver_factory.StorageInterfaceFactory()"},{"line_number":91,"context_line":"        if not drivers:"},{"line_number":92,"context_line":"            msg \u003d _LE(\"Conductor %s cannot be started because no drivers \""},{"line_number":93,"context_line":"                      \"were loaded.  This could be because no drivers were \""}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_bafbf877","line":90,"range":{"start_line":89,"start_character":8,"end_line":90,"end_character":48},"updated":"2017-01-18 10:02:37.000000000","message":"can be dropped now? Seems like it will be called in _register_and_validate_hardware_interfaces anyway.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"2461be151db383f268dec03de63b5290309f326e","unresolved":false,"context_lines":[{"line_number":86,"context_line":"        # startup so that all the interfaces are loaded at the very"},{"line_number":87,"context_line":"        # beginning, and failures prevent the conductor from starting."},{"line_number":88,"context_line":"        drivers \u003d driver_factory.drivers()"},{"line_number":89,"context_line":"        driver_factory.NetworkInterfaceFactory()"},{"line_number":90,"context_line":"        driver_factory.StorageInterfaceFactory()"},{"line_number":91,"context_line":"        if not drivers:"},{"line_number":92,"context_line":"            msg \u003d _LE(\"Conductor %s cannot be started because no drivers \""},{"line_number":93,"context_line":"                      \"were loaded.  This could be because no drivers were \""}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_15d593b8","line":90,"range":{"start_line":89,"start_character":8,"end_line":90,"end_character":48},"in_reply_to":"7a3c09a3_bafbf877","updated":"2017-01-18 20:07:53.000000000","message":"It needs to be called for classic drivers here, if no hardware types are loaded it won\u0027t be called below (yet).","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"7b23bf46e10c3838a024429f93ea552e9ca9430d","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        # and validate them against other conductors"},{"line_number":153,"context_line":"        try:"},{"line_number":154,"context_line":"            self._register_and_validate_hardware_interfaces()"},{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_fae66042","line":155,"range":{"start_line":155,"start_character":16,"end_line":155,"end_character":67},"updated":"2017-01-18 10:02:37.000000000","message":"I might be wrong, but if I read the code correctly, this can also raise InterfaceNotFoundInEntrypoint, if some of the classes set as default_%s_interface do not have an entrypoint registered.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"2461be151db383f268dec03de63b5290309f326e","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        # and validate them against other conductors"},{"line_number":153,"context_line":"        try:"},{"line_number":154,"context_line":"            self._register_and_validate_hardware_interfaces()"},{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_95e1839d","line":155,"range":{"start_line":155,"start_character":16,"end_line":155,"end_character":67},"in_reply_to":"7a3c09a3_fae66042","updated":"2017-01-18 20:07:53.000000000","message":"+1, will fix","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"7b23bf46e10c3838a024429f93ea552e9ca9430d","unresolved":false,"context_lines":[{"line_number":154,"context_line":"            self._register_and_validate_hardware_interfaces()"},{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_d5f7b5d0","line":157,"updated":"2017-01-18 10:02:37.000000000","message":"no test on this new bit.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":154,"context_line":"            self._register_and_validate_hardware_interfaces()"},{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_8fe5e3a9","line":157,"in_reply_to":"7a3c09a3_b55e7f77","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"2461be151db383f268dec03de63b5290309f326e","unresolved":false,"context_lines":[{"line_number":154,"context_line":"            self._register_and_validate_hardware_interfaces()"},{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_b55e7f77","line":157,"in_reply_to":"7a3c09a3_d5f7b5d0","updated":"2017-01-18 20:07:53.000000000","message":"Will fix.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"},{"line_number":161,"context_line":"        # hardware interfaces loaded, if not call del_host and bail out."}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_9c3367f6","line":158,"updated":"2017-01-18 22:49:38.000000000","message":"Maybe we should use with excutils.save_and_reraise_exception():... instead of this.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":155,"context_line":"        except (exception.DriverLoadError, exception.DriverNotFound,"},{"line_number":156,"context_line":"                exception.ConductorHardwareInterfaceAlreadyRegistered):"},{"line_number":157,"context_line":"            self.del_host()"},{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"},{"line_number":161,"context_line":"        # hardware interfaces loaded, if not call del_host and bail out."}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_ef64a74a","line":158,"in_reply_to":"7a3c09a3_9c3367f6","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"},{"line_number":161,"context_line":"        # hardware interfaces loaded, if not call del_host and bail out."},{"line_number":162,"context_line":""},{"line_number":163,"context_line":"        # Start periodic tasks"},{"line_number":164,"context_line":"        self._periodic_tasks_worker \u003d self._executor.submit("}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_693b5e39","line":161,"updated":"2017-01-18 22:49:38.000000000","message":"do you mean\n\nIf there are no drivers or hardware interfaces loaded for this conductor, call del_host and bail out?","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":158,"context_line":"            raise"},{"line_number":159,"context_line":""},{"line_number":160,"context_line":"        # TODO(jroll) validate here instead if there are no drivers OR"},{"line_number":161,"context_line":"        # hardware interfaces loaded, if not call del_host and bail out."},{"line_number":162,"context_line":""},{"line_number":163,"context_line":"        # Start periodic tasks"},{"line_number":164,"context_line":"        self._periodic_tasks_worker \u003d self._executor.submit("}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_0f5ad383","line":161,"in_reply_to":"7a3c09a3_693b5e39","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":233,"context_line":""},{"line_number":234,"context_line":"    def _register_and_validate_hardware_interfaces(self):"},{"line_number":235,"context_line":"        # NOTE(jroll) may raise ConductorHardwareInterfaceAlreadyRegistered,"},{"line_number":236,"context_line":"        # we intentionally let this bubble up to the caller."},{"line_number":237,"context_line":""},{"line_number":238,"context_line":"        # first unregister, in case we have cruft laying around"},{"line_number":239,"context_line":"        self.conductor.unregister_all_interfaces()"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_fc61cba9","line":236,"updated":"2017-01-18 22:49:38.000000000","message":"instead of this note, you could add :raises: ConductorHardware...","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        # first unregister, in case we have cruft laying around"},{"line_number":239,"context_line":"        self.conductor.unregister_all_interfaces()"},{"line_number":240,"context_line":""},{"line_number":241,"context_line":"        hardware_types \u003d driver_factory.hardware_types()"},{"line_number":242,"context_line":"        for ht_name, ht in hardware_types.items():"},{"line_number":243,"context_line":"            interface_map \u003d driver_factory.enabled_supported_interfaces(ht)"},{"line_number":244,"context_line":"            for interface_type, interface_names in interface_map.items():"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_9a544a22","line":241,"updated":"2017-01-18 22:49:38.000000000","message":"If the comment @L85-87 make sense for all interfaces, it seems to me that we should make this call up there as well. Then pass hardware_types as a parameter to this method.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6773,"name":"Lucas Alvares Gomes","email":"lucasagomes@gmail.com","username":"lucasagomes"},"change_message_id":"d625836b545b354894a5017d2e7d7429f113b873","unresolved":false,"context_lines":[{"line_number":235,"context_line":"        self._started \u003d False"},{"line_number":236,"context_line":""},{"line_number":237,"context_line":"    def _register_and_validate_hardware_interfaces(self):"},{"line_number":238,"context_line":"        # NOTE(jroll) may raise ConductorHardwareInterfacesAlreadyRegistered"},{"line_number":239,"context_line":"        # or InterfaceNotFoundInEntrypoint,"},{"line_number":240,"context_line":"        # we intentionally let this bubble up to the caller."},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"        # first unregister, in case we have cruft laying around"},{"line_number":243,"context_line":"        self.conductor.unregister_all_hardware_interfaces()"}],"source_content_type":"text/x-python","patch_set":15,"id":"5a3905b3_ba2571c3","line":240,"range":{"start_line":238,"start_character":0,"end_line":240,"end_character":60},"updated":"2017-01-19 15:04:24.000000000","message":"this should be a docstring","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"aa8877158bfa14b639baeb419b86f90fbaa0e0e0","unresolved":false,"context_lines":[{"line_number":235,"context_line":"        self._started \u003d False"},{"line_number":236,"context_line":""},{"line_number":237,"context_line":"    def _register_and_validate_hardware_interfaces(self):"},{"line_number":238,"context_line":"        # NOTE(jroll) may raise ConductorHardwareInterfacesAlreadyRegistered"},{"line_number":239,"context_line":"        # or InterfaceNotFoundInEntrypoint,"},{"line_number":240,"context_line":"        # we intentionally let this bubble up to the caller."},{"line_number":241,"context_line":""},{"line_number":242,"context_line":"        # first unregister, in case we have cruft laying around"},{"line_number":243,"context_line":"        self.conductor.unregister_all_hardware_interfaces()"}],"source_content_type":"text/x-python","patch_set":15,"id":"5a3905b3_1411e852","line":240,"range":{"start_line":238,"start_character":0,"end_line":240,"end_character":60},"in_reply_to":"5a3905b3_ba2571c3","updated":"2017-01-19 20:41:15.000000000","message":"Done","commit_id":"b7e6b737d7aea841e718d66776894986dbcab2a2"}],"ironic/db/api.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":538,"context_line":"        \"\"\""},{"line_number":539,"context_line":""},{"line_number":540,"context_line":"    @abc.abstractmethod"},{"line_number":541,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":542,"context_line":"        \"\"\"List all registered interfaces for a conductor."},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"        :param conductor_id: Database ID of conductor to register for."}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_80ce1b2b","line":541,"updated":"2017-01-11 17:54:28.000000000","message":"nit, although it\u0027ll make it longer, but I\u0027d prefer \u0027list_conductor_hw_interfaces\u0027\n\nI\u0027d also be fine with \u0027list_hardware_interfaces\u0027 since the conductor_id is being passed to the method.","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":538,"context_line":"        \"\"\""},{"line_number":539,"context_line":""},{"line_number":540,"context_line":"    @abc.abstractmethod"},{"line_number":541,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":542,"context_line":"        \"\"\"List all registered interfaces for a conductor."},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"        :param conductor_id: Database ID of conductor to register for."}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_24f55456","line":541,"in_reply_to":"ba5201f7_80ce1b2b","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":539,"context_line":""},{"line_number":540,"context_line":"    @abc.abstractmethod"},{"line_number":541,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":542,"context_line":"        \"\"\"List all registered interfaces for a conductor."},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"        :param conductor_id: Database ID of conductor to register for."},{"line_number":545,"context_line":"        :returns: List of ``ConductorHardwareInterfaces`` objects."}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_0056ab29","line":542,"updated":"2017-01-11 17:54:28.000000000","message":"I guess these are all nits, but we\u0027re talking about hardware interfaces. (I shudder to think what will happen if we add some other (non-hardware) set of interfaces to the conductor...)","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":539,"context_line":""},{"line_number":540,"context_line":"    @abc.abstractmethod"},{"line_number":541,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":542,"context_line":"        \"\"\"List all registered interfaces for a conductor."},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"        :param conductor_id: Database ID of conductor to register for."},{"line_number":545,"context_line":"        :returns: List of ``ConductorHardwareInterfaces`` objects."}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_64ebdc78","line":542,"in_reply_to":"ba5201f7_0056ab29","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":541,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":542,"context_line":"        \"\"\"List all registered interfaces for a conductor."},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"        :param conductor_id: Database ID of conductor to register for."},{"line_number":545,"context_line":"        :returns: List of ``ConductorHardwareInterfaces`` objects."},{"line_number":546,"context_line":"        \"\"\""},{"line_number":547,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_c07d831d","line":544,"updated":"2017-01-11 17:54:28.000000000","message":"maybe s/to register for//","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":541,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":542,"context_line":"        \"\"\"List all registered interfaces for a conductor."},{"line_number":543,"context_line":""},{"line_number":544,"context_line":"        :param conductor_id: Database ID of conductor to register for."},{"line_number":545,"context_line":"        :returns: List of ``ConductorHardwareInterfaces`` objects."},{"line_number":546,"context_line":"        \"\"\""},{"line_number":547,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_8404484a","line":544,"in_reply_to":"ba5201f7_c07d831d","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    @abc.abstractmethod"},{"line_number":562,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":563,"context_line":"        \"\"\"Unregisters all interfaces for a conductor."},{"line_number":564,"context_line":""},{"line_number":565,"context_line":"        :param conductor_id: Database ID of conductor to unregister for."},{"line_number":566,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_fb3878d5","line":563,"updated":"2017-01-11 17:54:28.000000000","message":"s/interfaces/hardware interfaces/","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":560,"context_line":""},{"line_number":561,"context_line":"    @abc.abstractmethod"},{"line_number":562,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":563,"context_line":"        \"\"\"Unregisters all interfaces for a conductor."},{"line_number":564,"context_line":""},{"line_number":565,"context_line":"        :param conductor_id: Database ID of conductor to unregister for."},{"line_number":566,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_a401443a","line":563,"in_reply_to":"ba5201f7_fb3878d5","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":546,"context_line":"        \"\"\""},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"    @abc.abstractmethod"},{"line_number":549,"context_line":"    def register_conductor_interfaces(self, conductor_id, hardware_type,"},{"line_number":550,"context_line":"                                      interface_type, interfaces,"},{"line_number":551,"context_line":"                                      default_interface):"},{"line_number":552,"context_line":"        \"\"\"Registers hardware interfaces for a conductor."}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_c486f715","line":549,"updated":"2017-01-18 22:49:38.000000000","message":"register_conductor_hardware_interfaces (to be consistent with list_conductor_hardware_interfaces)","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":546,"context_line":"        \"\"\""},{"line_number":547,"context_line":""},{"line_number":548,"context_line":"    @abc.abstractmethod"},{"line_number":549,"context_line":"    def register_conductor_interfaces(self, conductor_id, hardware_type,"},{"line_number":550,"context_line":"                                      interface_type, interfaces,"},{"line_number":551,"context_line":"                                      default_interface):"},{"line_number":552,"context_line":"        \"\"\"Registers hardware interfaces for a conductor."}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_6aad0531","line":549,"in_reply_to":"7a3c09a3_c486f715","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":557,"context_line":"        :param interfaces: List of interface names to register."},{"line_number":558,"context_line":"        :param default_interface: String, the default interface for this"},{"line_number":559,"context_line":"                                  hardware type and interface type."},{"line_number":560,"context_line":"        :raises: ConductorHardwareInterfaceAlreadyRegistered if the combination"},{"line_number":561,"context_line":"                 of all parameters is already registered."},{"line_number":562,"context_line":"        \"\"\""},{"line_number":563,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_dc8def2b","line":560,"updated":"2017-01-18 22:49:38.000000000","message":"if at least one of the interfaces in the combination of ...","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":557,"context_line":"        :param interfaces: List of interface names to register."},{"line_number":558,"context_line":"        :param default_interface: String, the default interface for this"},{"line_number":559,"context_line":"                                  hardware type and interface type."},{"line_number":560,"context_line":"        :raises: ConductorHardwareInterfaceAlreadyRegistered if the combination"},{"line_number":561,"context_line":"                 of all parameters is already registered."},{"line_number":562,"context_line":"        \"\"\""},{"line_number":563,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_8aaa3118","line":560,"in_reply_to":"7a3c09a3_dc8def2b","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":562,"context_line":"        \"\"\""},{"line_number":563,"context_line":""},{"line_number":564,"context_line":"    @abc.abstractmethod"},{"line_number":565,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":566,"context_line":"        \"\"\"Unregisters all hardware interfaces for a conductor."},{"line_number":567,"context_line":""},{"line_number":568,"context_line":"        :param conductor_id: Database ID of conductor to unregister for."}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_447be729","line":565,"updated":"2017-01-18 22:49:38.000000000","message":"unregister_conductor_hardware_interfaces (to be consistent with list_conductor_hardware_interfaces)","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":562,"context_line":"        \"\"\""},{"line_number":563,"context_line":""},{"line_number":564,"context_line":"    @abc.abstractmethod"},{"line_number":565,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":566,"context_line":"        \"\"\"Unregisters all hardware interfaces for a conductor."},{"line_number":567,"context_line":""},{"line_number":568,"context_line":"        :param conductor_id: Database ID of conductor to unregister for."}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_aaa7ed4d","line":565,"in_reply_to":"7a3c09a3_447be729","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"}],"ironic/db/sqlalchemy/api.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"8e949b1fd6def12f21a49785dc3e16c7b8ff0332","unresolved":false,"context_lines":[{"line_number":803,"context_line":"                  .all())"},{"line_number":804,"context_line":"        return [row[\u0027hostname\u0027] for row in result]"},{"line_number":805,"context_line":""},{"line_number":806,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":807,"context_line":"        query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":808,"context_line":"                 .filter_by(conductor_id\u003dconductor_id))"},{"line_number":809,"context_line":"        return query.all()"},{"line_number":810,"context_line":""},{"line_number":811,"context_line":"    def register_conductor_interfaces(self, conductor_id, hardware_type,"},{"line_number":812,"context_line":"                                      interface_type, interfaces):"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba5201f7_b78c8a80","line":809,"range":{"start_line":806,"start_character":0,"end_line":809,"end_character":26},"updated":"2017-01-03 13:22:09.000000000","message":"this does not seem particularly useful to me, I think we rather need information on all conductors. I started some (duplicating) work on it in the previous patch - https://review.openstack.org/#/c/409812/7/ironic/db/sqlalchemy/api.py","commit_id":"adc47f81bf60de1e0fff5d51982696b53f135fe1"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"a3582cc8c3d4e546543e78bd3a877d2e65b5d6e4","unresolved":false,"context_lines":[{"line_number":803,"context_line":"                  .all())"},{"line_number":804,"context_line":"        return [row[\u0027hostname\u0027] for row in result]"},{"line_number":805,"context_line":""},{"line_number":806,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":807,"context_line":"        query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":808,"context_line":"                 .filter_by(conductor_id\u003dconductor_id))"},{"line_number":809,"context_line":"        return query.all()"},{"line_number":810,"context_line":""},{"line_number":811,"context_line":"    def register_conductor_interfaces(self, conductor_id, hardware_type,"},{"line_number":812,"context_line":"                                      interface_type, interfaces):"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba5201f7_0578bd8e","line":809,"range":{"start_line":806,"start_character":0,"end_line":809,"end_character":26},"in_reply_to":"ba5201f7_b78c8a80","updated":"2017-01-03 15:27:33.000000000","message":"Fair enough, I\u0027ll drop it. Going to leave startup validation to another patch, I think.\n\nOh, wait, the reason I added this was to be able to test register/unregister_conductor_interfaces... going to leave it unless you have another suggestion.","commit_id":"adc47f81bf60de1e0fff5d51982696b53f135fe1"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"8e949b1fd6def12f21a49785dc3e16c7b8ff0332","unresolved":false,"context_lines":[{"line_number":821,"context_line":"            # TODO(jroll) handle duplicate records here or above?"},{"line_number":822,"context_line":"            session.flush()"},{"line_number":823,"context_line":""},{"line_number":824,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":825,"context_line":"        with _session_for_write():"},{"line_number":826,"context_line":"            query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":827,"context_line":"                     .filter_by(conductor_id\u003dconductor_id))"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba5201f7_57defe6d","line":824,"range":{"start_line":824,"start_character":0,"end_line":824,"end_character":60},"updated":"2017-01-03 13:22:09.000000000","message":"I wonder if we should just roll this into unregister_conductor..","commit_id":"adc47f81bf60de1e0fff5d51982696b53f135fe1"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"a3582cc8c3d4e546543e78bd3a877d2e65b5d6e4","unresolved":false,"context_lines":[{"line_number":821,"context_line":"            # TODO(jroll) handle duplicate records here or above?"},{"line_number":822,"context_line":"            session.flush()"},{"line_number":823,"context_line":""},{"line_number":824,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":825,"context_line":"        with _session_for_write():"},{"line_number":826,"context_line":"            query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":827,"context_line":"                     .filter_by(conductor_id\u003dconductor_id))"}],"source_content_type":"text/x-python","patch_set":6,"id":"ba5201f7_85d90d86","line":824,"range":{"start_line":824,"start_character":0,"end_line":824,"end_character":60},"in_reply_to":"ba5201f7_57defe6d","updated":"2017-01-03 15:27:33.000000000","message":"Well, in the case of a crash, unregister_conductor doesn\u0027t get called. We need to call this at startup in that case, otherwise we\u0027ll have problems due to the unique constraints.","commit_id":"adc47f81bf60de1e0fff5d51982696b53f135fe1"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"ee84588711d4dc25f7cf1508a1401f91cd886186","unresolved":false,"context_lines":[{"line_number":803,"context_line":"                  .all())"},{"line_number":804,"context_line":"        return [row[\u0027hostname\u0027] for row in result]"},{"line_number":805,"context_line":""},{"line_number":806,"context_line":"    def list_conductor_interfaces(self, conductor_id):"},{"line_number":807,"context_line":"        query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":808,"context_line":"                 .filter_by(conductor_id\u003dconductor_id))"},{"line_number":809,"context_line":"        return query.all()"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba5201f7_a5cb4652","line":806,"updated":"2017-01-04 14:11:41.000000000","message":"you add methods to this file, but you don\u0027t seem to update ironic/db/api.py with abstract methods (should we get rid of it eventually btw?)","commit_id":"a2b91de067392be379e4c8b4710b0a7f29850adc"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"ee84588711d4dc25f7cf1508a1401f91cd886186","unresolved":false,"context_lines":[{"line_number":818,"context_line":"                conductor_hw_iface[\u0027interface_type\u0027] \u003d interface_type"},{"line_number":819,"context_line":"                conductor_hw_iface[\u0027interface_name\u0027] \u003d iface"},{"line_number":820,"context_line":"                session.add(conductor_hw_iface)"},{"line_number":821,"context_line":"            # TODO(jroll) handle duplicate records here or above?"},{"line_number":822,"context_line":"            session.flush()"},{"line_number":823,"context_line":""},{"line_number":824,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":825,"context_line":"        with _session_for_write():"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba5201f7_a5a426a6","line":822,"range":{"start_line":821,"start_character":0,"end_line":822,"end_character":27},"updated":"2017-01-04 14:11:41.000000000","message":"1. I don\u0027t think you need session.flush(), 2. I suggest we do handle duplicate records in a big try..except block (for simplicity)","commit_id":"a2b91de067392be379e4c8b4710b0a7f29850adc"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"20498d1f3a07b708681ce76549a31f7e1cadf79d","unresolved":false,"context_lines":[{"line_number":819,"context_line":"                    conductor_hw_iface[\u0027interface_type\u0027] \u003d interface_type"},{"line_number":820,"context_line":"                    conductor_hw_iface[\u0027interface_name\u0027] \u003d iface"},{"line_number":821,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":822,"context_line":"                # TODO(jroll) handle duplicate records here or above?"},{"line_number":823,"context_line":"                session.flush()"},{"line_number":824,"context_line":"            except db_exc.DBDuplicateEntry:"},{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("}],"source_content_type":"text/x-python","patch_set":10,"id":"ba5201f7_91f0a4cb","line":822,"range":{"start_line":822,"start_character":16,"end_line":822,"end_character":69},"updated":"2017-01-09 16:52:08.000000000","message":"no longer a todo","commit_id":"5cd4a02d16da50c315591324ac2b142285a3007b"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"ebcda513316c4805df43d9843ab038f2e0846009","unresolved":false,"context_lines":[{"line_number":819,"context_line":"                    conductor_hw_iface[\u0027interface_type\u0027] \u003d interface_type"},{"line_number":820,"context_line":"                    conductor_hw_iface[\u0027interface_name\u0027] \u003d iface"},{"line_number":821,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":822,"context_line":"                # TODO(jroll) handle duplicate records here or above?"},{"line_number":823,"context_line":"                session.flush()"},{"line_number":824,"context_line":"            except db_exc.DBDuplicateEntry:"},{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_0f726111","line":822,"updated":"2017-01-11 16:19:21.000000000","message":"nit: looks like you\u0027re already handling it below?","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":819,"context_line":"                    conductor_hw_iface[\u0027interface_type\u0027] \u003d interface_type"},{"line_number":820,"context_line":"                    conductor_hw_iface[\u0027interface_name\u0027] \u003d iface"},{"line_number":821,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":822,"context_line":"                # TODO(jroll) handle duplicate records here or above?"},{"line_number":823,"context_line":"                session.flush()"},{"line_number":824,"context_line":"            except db_exc.DBDuplicateEntry:"},{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_e4a50c47","line":822,"in_reply_to":"ba5201f7_0f726111","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("},{"line_number":826,"context_line":"                    hardware_type\u003dhardware_type,"},{"line_number":827,"context_line":"                    interface_type\u003dinterface_type,"},{"line_number":828,"context_line":"                    interfaces\u003dinterfaces)"},{"line_number":829,"context_line":""},{"line_number":830,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":831,"context_line":"        with _session_for_write():"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_bb5a70f0","line":828,"updated":"2017-01-11 17:54:28.000000000","message":"I know it is icky, but wouldn\u0027t it be useful to know the conductor (hostname)? Also, would the exception provide more info as to which interface(s) were duplicated?","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("},{"line_number":826,"context_line":"                    hardware_type\u003dhardware_type,"},{"line_number":827,"context_line":"                    interface_type\u003dinterface_type,"},{"line_number":828,"context_line":"                    interfaces\u003dinterfaces)"},{"line_number":829,"context_line":""},{"line_number":830,"context_line":"    def unregister_conductor_interfaces(self, conductor_id):"},{"line_number":831,"context_line":"        with _session_for_write():"}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_3ff1e101","line":828,"in_reply_to":"ba5201f7_bb5a70f0","updated":"2017-01-17 17:14:59.000000000","message":"For the hostname, it would be another db query (which I guess is fine), but I tend to think people will read the logs in two ways: 1) on the machine itself, or 2) in an aggregator that will show the hostname it\u0027s from, so I don\u0027t think it\u0027s a big improvement.\n\nFor the \"which is duplicate\", this is a group of inserts happening at the same time. So I suspect we\u0027ll only get the first one. We may be able to log that, but I suspect if one is a duplicate, they all are (because this means something went horribly wrong, and really the table needs to be cleared for this conductor).","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"583492cb434e714fe6b96233b5a7c637af15a438","unresolved":false,"context_lines":[{"line_number":821,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":822,"context_line":"                # TODO(jroll) handle duplicate records here or above?"},{"line_number":823,"context_line":"                session.flush()"},{"line_number":824,"context_line":"            except db_exc.DBDuplicateEntry:"},{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("},{"line_number":826,"context_line":"                    hardware_type\u003dhardware_type,"},{"line_number":827,"context_line":"                    interface_type\u003dinterface_type,"}],"source_content_type":"text/x-python","patch_set":13,"id":"9a57fde8_6b0c2595","line":824,"range":{"start_line":824,"start_character":19,"end_line":824,"end_character":42},"updated":"2017-01-12 18:41:34.000000000","message":"Can\u0027t we just convert interfaces to set and avoid this? Or do you expect this will be called anywhere apart from init_host, where all conductor interfaces are deleted from DB first? Or is this trying to handle the case when we have multiple entries of the same hw type/interface in config options? This could be handled separately too. Not sure if it\u0027s better to just try db write instead of checking in code.","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"c3d5e67a18982bc44bbbc017577dc1f79c4eaccb","unresolved":false,"context_lines":[{"line_number":821,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":822,"context_line":"                # TODO(jroll) handle duplicate records here or above?"},{"line_number":823,"context_line":"                session.flush()"},{"line_number":824,"context_line":"            except db_exc.DBDuplicateEntry:"},{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("},{"line_number":826,"context_line":"                    hardware_type\u003dhardware_type,"},{"line_number":827,"context_line":"                    interface_type\u003dinterface_type,"}],"source_content_type":"text/x-python","patch_set":13,"id":"7a3c09a3_95e9adb9","line":824,"range":{"start_line":824,"start_character":19,"end_line":824,"end_character":42},"in_reply_to":"7a3c09a3_450a5a7a","updated":"2017-01-18 10:03:48.000000000","message":"Gotcha, thanks for explaining.","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"b99f213b6f61009946b6aaa3194ff8872d247faf","unresolved":false,"context_lines":[{"line_number":821,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":822,"context_line":"                # TODO(jroll) handle duplicate records here or above?"},{"line_number":823,"context_line":"                session.flush()"},{"line_number":824,"context_line":"            except db_exc.DBDuplicateEntry:"},{"line_number":825,"context_line":"                raise exception.ConductorHardwareInterfaceAlreadyRegistered("},{"line_number":826,"context_line":"                    hardware_type\u003dhardware_type,"},{"line_number":827,"context_line":"                    interface_type\u003dinterface_type,"}],"source_content_type":"text/x-python","patch_set":13,"id":"7a3c09a3_450a5a7a","line":824,"range":{"start_line":824,"start_character":19,"end_line":824,"end_character":42},"in_reply_to":"9a57fde8_6b0c2595","updated":"2017-01-17 17:18:13.000000000","message":"This is really just a last-ditch effort in case something goes very wrong and somehow things are registered even after deleting them in init_host. For example, two conductors started on the same host at the same time could both do the delete and then try to register.","commit_id":"3e79666a0f2f6d8eac898be719ac674bcf966ae0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":803,"context_line":"                  .all())"},{"line_number":804,"context_line":"        return [row[\u0027hostname\u0027] for row in result]"},{"line_number":805,"context_line":""},{"line_number":806,"context_line":"    def list_conductor_hardware_interfaces(self, conductor_id):"},{"line_number":807,"context_line":"        query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":808,"context_line":"                 .filter_by(conductor_id\u003dconductor_id))"},{"line_number":809,"context_line":"        return query.all()"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_dfe7a144","line":806,"updated":"2017-01-18 22:49:38.000000000","message":"we don\u0027t have any code that calls this. Should we be adding it? And/or if it were to be used, would it be via ironic/objects/conductor.py?","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":803,"context_line":"                  .all())"},{"line_number":804,"context_line":"        return [row[\u0027hostname\u0027] for row in result]"},{"line_number":805,"context_line":""},{"line_number":806,"context_line":"    def list_conductor_hardware_interfaces(self, conductor_id):"},{"line_number":807,"context_line":"        query \u003d (model_query(models.ConductorHardwareInterfaces)"},{"line_number":808,"context_line":"                 .filter_by(conductor_id\u003dconductor_id))"},{"line_number":809,"context_line":"        return query.all()"}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_6a7425cf","line":806,"in_reply_to":"7a3c09a3_dfe7a144","updated":"2017-01-19 11:26:37.000000000","message":"It\u0027s useful for testing in this patch, and I think it may get used in the future later anyway. If we remove it, we\u0027ll just need the same code in the tests, so I\u0027d prefer keeping it here.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":820,"context_line":"                    conductor_hw_iface[\u0027interface_type\u0027] \u003d interface_type"},{"line_number":821,"context_line":"                    conductor_hw_iface[\u0027interface_name\u0027] \u003d iface"},{"line_number":822,"context_line":"                    if iface \u003d\u003d default_interface:"},{"line_number":823,"context_line":"                        conductor_hw_iface[\u0027default\u0027] \u003d True"},{"line_number":824,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":825,"context_line":"                session.flush()"},{"line_number":826,"context_line":"            except db_exc.DBDuplicateEntry:"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_7cfebb39","line":823,"updated":"2017-01-18 22:49:38.000000000","message":"I know the default is False but wdyt about getting rid of L822 and changing this to ... \u003d iface \u003d\u003d default_interface","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":820,"context_line":"                    conductor_hw_iface[\u0027interface_type\u0027] \u003d interface_type"},{"line_number":821,"context_line":"                    conductor_hw_iface[\u0027interface_name\u0027] \u003d iface"},{"line_number":822,"context_line":"                    if iface \u003d\u003d default_interface:"},{"line_number":823,"context_line":"                        conductor_hw_iface[\u0027default\u0027] \u003d True"},{"line_number":824,"context_line":"                    session.add(conductor_hw_iface)"},{"line_number":825,"context_line":"                session.flush()"},{"line_number":826,"context_line":"            except db_exc.DBDuplicateEntry:"}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_8a815192","line":823,"in_reply_to":"7a3c09a3_7cfebb39","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"}],"ironic/objects/conductor.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"ee84588711d4dc25f7cf1508a1401f91cd886186","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    # Version 1.0: Initial version"},{"line_number":28,"context_line":"    # Version 1.1: Add register() and unregister(), make the context parameter"},{"line_number":29,"context_line":"    #              to touch() optional."},{"line_number":30,"context_line":"    # Version 1.2: Add register_conductor_interfaces()"},{"line_number":31,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"    dbapi \u003d db_api.get_instance()"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba5201f7_85b802e7","line":30,"updated":"2017-01-04 14:11:41.000000000","message":"and unregister_interfaces()","commit_id":"a2b91de067392be379e4c8b4710b0a7f29850adc"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"ee84588711d4dc25f7cf1508a1401f91cd886186","unresolved":false,"context_lines":[{"line_number":126,"context_line":"                                                 interface_type,"},{"line_number":127,"context_line":"                                                 interfaces)"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"    def unregister_interfaces(self):"},{"line_number":130,"context_line":"        \"\"\"Unregister all hardware interfaces for this conductor.\"\"\""},{"line_number":131,"context_line":"        self.dbapi.unregister_conductor_interfaces(self.id)"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba5201f7_65acfea0","line":129,"range":{"start_line":129,"start_character":8,"end_line":129,"end_character":29},"updated":"2017-01-04 14:11:41.000000000","message":"I see some inconsistency here: register_interfaces is called many times, but unregister_interfaces only once. Let\u0027s maybe call it unregister_all_interfaces?","commit_id":"a2b91de067392be379e4c8b4710b0a7f29850adc"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"ebcda513316c4805df43d9843ab038f2e0846009","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    # Version 1.0: Initial version"},{"line_number":28,"context_line":"    # Version 1.1: Add register() and unregister(), make the context parameter"},{"line_number":29,"context_line":"    #              to touch() optional."},{"line_number":30,"context_line":"    # Version 1.2: Add register_conductor_interfaces() and"},{"line_number":31,"context_line":"    #              unregister_all_interfaces()"},{"line_number":32,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":33,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_d5c2a684","line":30,"range":{"start_line":30,"start_character":23,"end_line":30,"end_character":52},"updated":"2017-01-11 16:19:21.000000000","message":"nit: this is called register_interfaces","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":27,"context_line":"    # Version 1.0: Initial version"},{"line_number":28,"context_line":"    # Version 1.1: Add register() and unregister(), make the context parameter"},{"line_number":29,"context_line":"    #              to touch() optional."},{"line_number":30,"context_line":"    # Version 1.2: Add register_conductor_interfaces() and"},{"line_number":31,"context_line":"    #              unregister_all_interfaces()"},{"line_number":32,"context_line":"    VERSION \u003d \u00271.2\u0027"},{"line_number":33,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_85e9a2e8","line":30,"range":{"start_line":30,"start_character":23,"end_line":30,"end_character":52},"in_reply_to":"ba5201f7_d5c2a684","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c5287defc8900d1755dff448c3b113ba7944111e","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces):"},{"line_number":124,"context_line":"        \"\"\"Register hardware interfaces with the conductor.\"\"\""},{"line_number":125,"context_line":"        self.dbapi.register_conductor_interfaces(self.id,"},{"line_number":126,"context_line":"                                                 hardware_type,"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_9d112407","line":123,"updated":"2017-01-11 17:54:28.000000000","message":"would be nice to have :param: for hardware_type, etc.","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"f90e39ee5fcde083f6f352f3bee2b92490d754c1","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces):"},{"line_number":124,"context_line":"        \"\"\"Register hardware interfaces with the conductor.\"\"\""},{"line_number":125,"context_line":"        self.dbapi.register_conductor_interfaces(self.id,"},{"line_number":126,"context_line":"                                                 hardware_type,"}],"source_content_type":"text/x-python","patch_set":12,"id":"7a3c09a3_65e036fb","line":123,"in_reply_to":"ba5201f7_9d112407","updated":"2017-01-17 17:14:59.000000000","message":"Done","commit_id":"4ffee10c77680c3b4519fe7b01e5b118ffd6ed85"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"7b23bf46e10c3838a024429f93ea552e9ca9430d","unresolved":false,"context_lines":[{"line_number":117,"context_line":"    # @object_base.remotable"},{"line_number":118,"context_line":"    def unregister(self, context\u003dNone):"},{"line_number":119,"context_line":"        \"\"\"Remove this conductor from the service registry.\"\"\""},{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces,"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_b59949c6","line":120,"updated":"2017-01-18 10:02:37.000000000","message":"test ensuring this is called?","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":117,"context_line":"    # @object_base.remotable"},{"line_number":118,"context_line":"    def unregister(self, context\u003dNone):"},{"line_number":119,"context_line":"        \"\"\"Remove this conductor from the service registry.\"\"\""},{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces,"}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_b53112ef","line":120,"in_reply_to":"7a3c09a3_75fb3748","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"2461be151db383f268dec03de63b5290309f326e","unresolved":false,"context_lines":[{"line_number":117,"context_line":"    # @object_base.remotable"},{"line_number":118,"context_line":"    def unregister(self, context\u003dNone):"},{"line_number":119,"context_line":"        \"\"\"Remove this conductor from the service registry.\"\"\""},{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces,"}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_75fb3748","line":120,"in_reply_to":"7a3c09a3_b59949c6","updated":"2017-01-18 20:07:53.000000000","message":"Can do!","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces,"},{"line_number":124,"context_line":"                            default_interface):"},{"line_number":125,"context_line":"        \"\"\"Register hardware interfaces with the conductor."},{"line_number":126,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"7a3c09a3_9f3359f6","line":123,"updated":"2017-01-18 22:49:38.000000000","message":"nit: i\u0027d prefer register_hardware_interfaces but this is fine.","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        self.unregister_all_interfaces()"},{"line_number":121,"context_line":"        self.dbapi.unregister_conductor(self.hostname)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":"    def register_interfaces(self, hardware_type, interface_type, interfaces,"},{"line_number":124,"context_line":"                            default_interface):"},{"line_number":125,"context_line":"        \"\"\"Register hardware interfaces with the conductor."},{"line_number":126,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"5a3905b3_f5ed5a26","line":123,"in_reply_to":"7a3c09a3_9f3359f6","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"}],"ironic/tests/unit/conductor/test_base_manager.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"ee84588711d4dc25f7cf1508a1401f91cd886186","unresolved":false,"context_lines":[{"line_number":228,"context_line":"                          self.service._spawn_worker, \u0027fake\u0027)"},{"line_number":229,"context_line":""},{"line_number":230,"context_line":""},{"line_number":231,"context_line":"@mock.patch(\u0027ironic.objects.Conductor.unregister_interfaces\u0027)"},{"line_number":232,"context_line":"@mock.patch(\u0027ironic.objects.Conductor.register_interfaces\u0027)"},{"line_number":233,"context_line":"@mock.patch.object(driver_factory, \u0027hardware_types\u0027)"},{"line_number":234,"context_line":"@mock.patch.object(driver_factory, \u0027enabled_supported_interfaces\u0027)"},{"line_number":235,"context_line":"@mgr_utils.mock_record_keepalive"},{"line_number":236,"context_line":"class RegisterInterfacesTestCase(mgr_utils.ServiceSetUpMixin,"},{"line_number":237,"context_line":"                                 tests_db_base.DbTestCase):"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba5201f7_2513d6b9","line":234,"range":{"start_line":231,"start_character":0,"end_line":234,"end_character":66},"updated":"2017-01-04 14:11:41.000000000","message":"please add autospec\u003dTrue","commit_id":"a2b91de067392be379e4c8b4710b0a7f29850adc"}],"releasenotes/notes/hardware-interfaces-register-4566f2834fef1b5d.yaml":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - Hardware interfaces are now loaded at conductor startup,"},{"line_number":4,"context_line":"    and registered in the database. ``[default]/enabled_*_interfaces``"},{"line_number":5,"context_line":"    and ``[default]/default_*_interfaces`` now have an effect on this."},{"line_number":6,"context_line":"upgrade:"},{"line_number":7,"context_line":"  - Hardware interfaces are now loaded at conductor startup,"},{"line_number":8,"context_line":"    and registered in the database. ``[default]/enabled_*_interfaces``"}],"source_content_type":"text/x-yaml","patch_set":14,"id":"7a3c09a3_a4ee4bb2","line":5,"updated":"2017-01-18 22:49:38.000000000","message":"maybe s/now/configuration options  now/","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - Hardware interfaces are now loaded at conductor startup,"},{"line_number":4,"context_line":"    and registered in the database. ``[default]/enabled_*_interfaces``"},{"line_number":5,"context_line":"    and ``[default]/default_*_interfaces`` now have an effect on this."},{"line_number":6,"context_line":"upgrade:"},{"line_number":7,"context_line":"  - Hardware interfaces are now loaded at conductor startup,"},{"line_number":8,"context_line":"    and registered in the database. ``[default]/enabled_*_interfaces``"}],"source_content_type":"text/x-yaml","patch_set":14,"id":"5a3905b3_f5d47a48","line":5,"in_reply_to":"7a3c09a3_a4ee4bb2","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"07e679380564292771045cd7d1765f539e1242ae","unresolved":false,"context_lines":[{"line_number":6,"context_line":"upgrade:"},{"line_number":7,"context_line":"  - Hardware interfaces are now loaded at conductor startup,"},{"line_number":8,"context_line":"    and registered in the database. ``[default]/enabled_*_interfaces``"},{"line_number":9,"context_line":"    and ``[default]/default_*_interfaces`` now have an effect on this."}],"source_content_type":"text/x-yaml","patch_set":14,"id":"7a3c09a3_e42e93f9","line":9,"updated":"2017-01-18 22:49:38.000000000","message":"ditto","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d1f858c897fe4e20b4b0bc393b183a887ca98fd7","unresolved":false,"context_lines":[{"line_number":6,"context_line":"upgrade:"},{"line_number":7,"context_line":"  - Hardware interfaces are now loaded at conductor startup,"},{"line_number":8,"context_line":"    and registered in the database. ``[default]/enabled_*_interfaces``"},{"line_number":9,"context_line":"    and ``[default]/default_*_interfaces`` now have an effect on this."}],"source_content_type":"text/x-yaml","patch_set":14,"id":"5a3905b3_15cae6a1","line":9,"in_reply_to":"7a3c09a3_e42e93f9","updated":"2017-01-19 11:26:37.000000000","message":"Done","commit_id":"d68f1af14dd7ee8e42cc7c5cae02d75f52218cc0"}]}
