)]}'
{"doc/source/cli/nova-status.rst":[{"author":{"_account_id":1063,"name":"Ed Leafe","email":"ed@leafe.com","username":"ed-leafe"},"change_message_id":"a02fdff263ae6ecbb0831c8e003e02364a88c7bb","unresolved":false,"context_lines":[{"line_number":101,"context_line":"  * Checks for the Placement API are modified to require version 1.4, that"},{"line_number":102,"context_line":"    is needed in Pike and further for nova-scheduler to work correctly."},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"  **17.0.0 (Queens)**"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"  * Checks for the Placement API are modified to require version 1.17."},{"line_number":107,"context_line":"  * Checks that ironic instances have had their embedded flavors migrated to"}],"source_content_type":"text/x-rst","patch_set":5,"id":"bf659307_634a1b56","line":104,"range":{"start_line":104,"start_character":12,"end_line":104,"end_character":18},"updated":"2018-03-26 20:10:58.000000000","message":"Do we need to move this to the Rocky release?","commit_id":"08fe2e59bbce42a56a5350d0c12d22680bd9d569"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"42b42c3ac06950a7047dc1c0adbf605496bb55bd","unresolved":false,"context_lines":[{"line_number":101,"context_line":"  * Checks for the Placement API are modified to require version 1.4, that"},{"line_number":102,"context_line":"    is needed in Pike and further for nova-scheduler to work correctly."},{"line_number":103,"context_line":""},{"line_number":104,"context_line":"  **17.0.0 (Queens)**"},{"line_number":105,"context_line":""},{"line_number":106,"context_line":"  * Checks for the Placement API are modified to require version 1.17."},{"line_number":107,"context_line":"  * Checks that ironic instances have had their embedded flavors migrated to"}],"source_content_type":"text/x-rst","patch_set":5,"id":"bf659307_3f2ab28f","line":104,"range":{"start_line":104,"start_character":12,"end_line":104,"end_character":18},"in_reply_to":"bf659307_634a1b56","updated":"2018-03-28 17:36:01.000000000","message":"Bleh, yeah, at this point I need to.","commit_id":"08fe2e59bbce42a56a5350d0c12d22680bd9d569"}],"nova/cmd/status.py":[{"author":{"_account_id":1063,"name":"Ed Leafe","email":"ed@leafe.com","username":"ed-leafe"},"change_message_id":"392907676b1fd10c2db7e740e0bf52449434b78d","unresolved":false,"context_lines":[{"line_number":377,"context_line":"                        compute_nodes.c.deleted \u003d\u003d 0"},{"line_number":378,"context_line":"                    )).execute().fetchall())"},{"line_number":379,"context_line":""},{"line_number":380,"context_line":"                if len(ironic_nodes):"},{"line_number":381,"context_line":"                    # We have ironic nodes in this cell, let\u0027s iterate over"},{"line_number":382,"context_line":"                    # them looking for instances."},{"line_number":383,"context_line":"                    instances \u003d Table(\u0027instances\u0027, meta, autoload\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":1,"id":"df87a7cf_44938aa4","line":380,"range":{"start_line":380,"start_character":19,"end_line":380,"end_character":36},"updated":"2017-12-13 13:36:54.000000000","message":"nit: simpler (and more pythonic) to say \"if ironic_nodes:\"","commit_id":"80b84459c4d19826107e138d0585d3cc0b221dd2"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f2a43f474e956da8cd54af626590e23c44c401f0","unresolved":false,"context_lines":[{"line_number":377,"context_line":"                        compute_nodes.c.deleted \u003d\u003d 0"},{"line_number":378,"context_line":"                    )).execute().fetchall())"},{"line_number":379,"context_line":""},{"line_number":380,"context_line":"                if len(ironic_nodes):"},{"line_number":381,"context_line":"                    # We have ironic nodes in this cell, let\u0027s iterate over"},{"line_number":382,"context_line":"                    # them looking for instances."},{"line_number":383,"context_line":"                    instances \u003d Table(\u0027instances\u0027, meta, autoload\u003dTrue)"}],"source_content_type":"text/x-python","patch_set":1,"id":"df87a7cf_c4347afe","line":380,"range":{"start_line":380,"start_character":19,"end_line":380,"end_character":36},"in_reply_to":"df87a7cf_44938aa4","updated":"2017-12-13 14:01:09.000000000","message":"Yeah I wasn\u0027t totally sure if ironic_nodes was a list, but it must be a collection.","commit_id":"80b84459c4d19826107e138d0585d3cc0b221dd2"},{"author":{"_account_id":1063,"name":"Ed Leafe","email":"ed@leafe.com","username":"ed-leafe"},"change_message_id":"392907676b1fd10c2db7e740e0bf52449434b78d","unresolved":false,"context_lines":[{"line_number":424,"context_line":""},{"line_number":425,"context_line":"        if unmigrated_instance_count_by_cell:"},{"line_number":426,"context_line":"            # There are unmigrated ironic instances, so we need to fail."},{"line_number":427,"context_line":"            msg \u003d (_(\u0027There are (cell\u003dx) number of unmigrated instances in \u0027"},{"line_number":428,"context_line":"                     \u0027each cell:%s. Run \\\u0027nova-manage db \u0027"},{"line_number":429,"context_line":"                     \u0027ironic_flavor_migration\\\u0027 on each cell.\u0027) %"},{"line_number":430,"context_line":"                   \u0027 \u0027.join(\u0027(%s\u003d%s)\u0027 % (cell, count) for cell, count in"}],"source_content_type":"text/x-python","patch_set":1,"id":"df87a7cf_2472067e","line":427,"range":{"start_line":427,"start_character":33,"end_line":427,"end_character":39},"updated":"2017-12-13 13:36:54.000000000","message":"Not sure what this means","commit_id":"80b84459c4d19826107e138d0585d3cc0b221dd2"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f2a43f474e956da8cd54af626590e23c44c401f0","unresolved":false,"context_lines":[{"line_number":424,"context_line":""},{"line_number":425,"context_line":"        if unmigrated_instance_count_by_cell:"},{"line_number":426,"context_line":"            # There are unmigrated ironic instances, so we need to fail."},{"line_number":427,"context_line":"            msg \u003d (_(\u0027There are (cell\u003dx) number of unmigrated instances in \u0027"},{"line_number":428,"context_line":"                     \u0027each cell:%s. Run \\\u0027nova-manage db \u0027"},{"line_number":429,"context_line":"                     \u0027ironic_flavor_migration\\\u0027 on each cell.\u0027) %"},{"line_number":430,"context_line":"                   \u0027 \u0027.join(\u0027(%s\u003d%s)\u0027 % (cell, count) for cell, count in"}],"source_content_type":"text/x-python","patch_set":1,"id":"df87a7cf_e42c1eae","line":427,"range":{"start_line":427,"start_character":33,"end_line":427,"end_character":39},"in_reply_to":"df87a7cf_2472067e","updated":"2017-12-13 14:01:09.000000000","message":"The output will be like:\n\n\"There are (cell\u003dx) number of unmigrated instances in each cell: (cell1\u003d4) (cell2\u003d10)\"\n\nSo I was trying to describe the format for the output.","commit_id":"80b84459c4d19826107e138d0585d3cc0b221dd2"},{"author":{"_account_id":1063,"name":"Ed Leafe","email":"ed@leafe.com","username":"ed-leafe"},"change_message_id":"728c41ca18038b69f1423c528f43a2d3c22f0b62","unresolved":false,"context_lines":[{"line_number":424,"context_line":""},{"line_number":425,"context_line":"        if unmigrated_instance_count_by_cell:"},{"line_number":426,"context_line":"            # There are unmigrated ironic instances, so we need to fail."},{"line_number":427,"context_line":"            msg \u003d (_(\u0027There are (cell\u003dx) number of unmigrated instances in \u0027"},{"line_number":428,"context_line":"                     \u0027each cell:%s. Run \\\u0027nova-manage db \u0027"},{"line_number":429,"context_line":"                     \u0027ironic_flavor_migration\\\u0027 on each cell.\u0027) %"},{"line_number":430,"context_line":"                   \u0027 \u0027.join(\u0027(%s\u003d%s)\u0027 % (cell, count) for cell, count in"}],"source_content_type":"text/x-python","patch_set":1,"id":"df87a7cf_63ec7af3","line":427,"range":{"start_line":427,"start_character":33,"end_line":427,"end_character":39},"in_reply_to":"df87a7cf_e42c1eae","updated":"2017-12-13 20:18:50.000000000","message":"maybe skip the initial description, and just change the cell listing to (cell1 count\u003d4) (cell2 count\u003d10) or similar.","commit_id":"80b84459c4d19826107e138d0585d3cc0b221dd2"},{"author":{"_account_id":1063,"name":"Ed Leafe","email":"ed@leafe.com","username":"ed-leafe"},"change_message_id":"728c41ca18038b69f1423c528f43a2d3c22f0b62","unresolved":false,"context_lines":[{"line_number":369,"context_line":"        # dict of cell identifier (name or uuid) to number of unmigrated"},{"line_number":370,"context_line":"        # instances"},{"line_number":371,"context_line":"        unmigrated_instance_count_by_cell \u003d collections.defaultdict(int)"},{"line_number":372,"context_line":"        flavor_extra_spec_key \u003d \u0027resources:CUSTOM_\u0027"},{"line_number":373,"context_line":"        for cell_mapping in cell_mappings:"},{"line_number":374,"context_line":"            cell_id \u003d cell_mapping[\u0027name\u0027] or cell_mapping[\u0027uuid\u0027]"},{"line_number":375,"context_line":"            with nova_context.target_cell(ctxt, cell_mapping) as cctxt:"}],"source_content_type":"text/x-python","patch_set":2,"id":"df87a7cf_e3b96ae9","line":372,"range":{"start_line":372,"start_character":8,"end_line":372,"end_character":29},"updated":"2017-12-13 20:18:50.000000000","message":"nit: this really feels like a CONSTANT","commit_id":"f7b0ffb5431710e60b43af1d9a3b6fd455727ae3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bf5793c46cae531d8f2a39ed08656c67f482e277","unresolved":false,"context_lines":[{"line_number":439,"context_line":"                     \u0027each cell: %s. Run \\\u0027nova-manage db \u0027"},{"line_number":440,"context_line":"                     \u0027ironic_flavor_migration\\\u0027 on each cell.\u0027) %"},{"line_number":441,"context_line":"                   \u0027 \u0027.join(\u0027(%s\u003d%s)\u0027 % (cell, count) for cell, count in"},{"line_number":442,"context_line":"                            unmigrated_instance_count_by_cell.items()))"},{"line_number":443,"context_line":"            return UpgradeCheckResult(UpgradeCheckCode.FAILURE, msg)"},{"line_number":444,"context_line":""},{"line_number":445,"context_line":"        # Either there were no ironic compute nodes or all instances for"}],"source_content_type":"text/x-python","patch_set":2,"id":"df87a7cf_032d6e45","line":442,"range":{"start_line":442,"start_character":28,"end_line":442,"end_character":68},"updated":"2017-12-13 20:11:03.000000000","message":"The keys have to be sorted here.","commit_id":"f7b0ffb5431710e60b43af1d9a3b6fd455727ae3"},{"author":{"_account_id":11564,"name":"Chris Dent","email":"cdent@anticdent.org","username":"chdent"},"change_message_id":"7bfe1851d8700bea4521d5947466cc2ca5048a96","unresolved":false,"context_lines":[{"line_number":359,"context_line":"        specs \u003d flavor[\u0027extra_specs\u0027] if \u0027extra_specs\u0027 in flavor else {}"},{"line_number":360,"context_line":"        for spec_key in specs:"},{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9f91af0f_3bf70562","line":362,"updated":"2018-01-08 13:50:45.000000000","message":"What if this is CUSTOM_\u003csomething else other than a baremetal custom flavor\u003e?","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"dc986d9a5db369f558fc608d69b831b72c02159b","unresolved":false,"context_lines":[{"line_number":359,"context_line":"        specs \u003d flavor[\u0027extra_specs\u0027] if \u0027extra_specs\u0027 in flavor else {}"},{"line_number":360,"context_line":"        for spec_key in specs:"},{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_9cff4f33","line":362,"in_reply_to":"7f96bb07_b32163a2","updated":"2018-01-29 18:12:46.000000000","message":"Ironic can only report one resource class per node, so I think this is OK.","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6db56fdbfa444a93afd98646fa6febe133614a03","unresolved":false,"context_lines":[{"line_number":359,"context_line":"        specs \u003d flavor[\u0027extra_specs\u0027] if \u0027extra_specs\u0027 in flavor else {}"},{"line_number":360,"context_line":"        for spec_key in specs:"},{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"7f96bb07_b32163a2","line":362,"in_reply_to":"9f91af0f_3bf70562","updated":"2018-01-12 02:24:08.000000000","message":"Then that sucks I guess, but this is the same logic in the online migration code so we\u0027d be broken there too.","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"dc986d9a5db369f558fc608d69b831b72c02159b","unresolved":false,"context_lines":[{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""},{"line_number":366,"context_line":"    def _check_ironic_flavor_migration(self):"},{"line_number":367,"context_line":"        \"\"\"In Pike, ironic instances and flavors need to be migrated to use"}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_1c99ff1d","line":364,"updated":"2018-01-29 18:12:46.000000000","message":"I wonder if we need to check for vcpu:0, etc? I guess we need to claim everything still, so this is a good first step.","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"a17b835ec15a5a52c22fe3c6486606f7df38dfa1","unresolved":false,"context_lines":[{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""},{"line_number":366,"context_line":"    def _check_ironic_flavor_migration(self):"},{"line_number":367,"context_line":"        \"\"\"In Pike, ironic instances and flavors need to be migrated to use"}],"source_content_type":"text/x-python","patch_set":4,"id":"3fa0c359_5812905a","line":364,"in_reply_to":"3fa0c359_3266cdef","updated":"2018-02-05 17:20:39.000000000","message":"I assume you\u0027re referring to this:\n\nhttps://docs.openstack.org/ironic/latest/install/configure-nova-flavors.html#scheduling-based-on-resource-classes\n\nI don\u0027t really think we need to care if the flavor vcpu is 0 at this point do we? If the flavor has the custom resource class on it, we should be good since that will be taken into account during scheduling, which is what we want. The vcpu/ram/disk can be set to 0 at some later point (which is not something we actually assert yet in the compute driver code when reporting inventory).","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5c1b6223fe6efe48b369b589fa9acbd433acf54","unresolved":false,"context_lines":[{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""},{"line_number":366,"context_line":"    def _check_ironic_flavor_migration(self):"},{"line_number":367,"context_line":"        \"\"\"In Pike, ironic instances and flavors need to be migrated to use"}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_5fd0d41f","line":364,"in_reply_to":"5f93b717_1c99ff1d","updated":"2018-01-29 22:11:44.000000000","message":"I\u0027m not sure why we\u0027d have to check for specific values, and this is matching how the in-driver flavor migration code works (and the nova-manage offline migration CLI which calls through to the driver).","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"5c2efdc5a484ee792c8b34d9e837f47e068cfa69","unresolved":false,"context_lines":[{"line_number":361,"context_line":"            if spec_key.startswith(\u0027resources:CUSTOM_\u0027):"},{"line_number":362,"context_line":"                # We found a match so this instance is good."},{"line_number":363,"context_line":"                return True"},{"line_number":364,"context_line":"        return False"},{"line_number":365,"context_line":""},{"line_number":366,"context_line":"    def _check_ironic_flavor_migration(self):"},{"line_number":367,"context_line":"        \"\"\"In Pike, ironic instances and flavors need to be migrated to use"}],"source_content_type":"text/x-python","patch_set":4,"id":"3fa0c359_3266cdef","line":364,"in_reply_to":"5f93b717_5fd0d41f","updated":"2018-02-05 09:55:43.000000000","message":"Sorry, crazy at the moment.\n\nIts more about the flavor transition. I think the sequence was, stop requesting vCPU and RAM in the flavor, then ironic instances stop reporting the availability of those resources, i.e. only report the CUSTOM resource class. But maybe the plan has changed now?","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"dc986d9a5db369f558fc608d69b831b72c02159b","unresolved":false,"context_lines":[{"line_number":407,"context_line":"                            instances.select().where(and_("},{"line_number":408,"context_line":"                                instances.c.node \u003d\u003d nodename,"},{"line_number":409,"context_line":"                                instances.c.deleted \u003d\u003d 0"},{"line_number":410,"context_line":"                            )).execute().fetchall())"},{"line_number":411,"context_line":"                        # Get the instance_extras for each instance so we can"},{"line_number":412,"context_line":"                        # find the flavors."},{"line_number":413,"context_line":"                        # TODO(mriedem): Borrow Jay\u0027s join-fu to get the extras"}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_bc148b4f","line":410,"range":{"start_line":410,"start_character":41,"end_line":410,"end_character":49},"updated":"2018-01-29 18:12:46.000000000","message":"Don\u0027t we normally do some level of batching, to avoid out of memory errors? Does the way the iteration works here protect us?","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"5c2efdc5a484ee792c8b34d9e837f47e068cfa69","unresolved":false,"context_lines":[{"line_number":407,"context_line":"                            instances.select().where(and_("},{"line_number":408,"context_line":"                                instances.c.node \u003d\u003d nodename,"},{"line_number":409,"context_line":"                                instances.c.deleted \u003d\u003d 0"},{"line_number":410,"context_line":"                            )).execute().fetchall())"},{"line_number":411,"context_line":"                        # Get the instance_extras for each instance so we can"},{"line_number":412,"context_line":"                        # find the flavors."},{"line_number":413,"context_line":"                        # TODO(mriedem): Borrow Jay\u0027s join-fu to get the extras"}],"source_content_type":"text/x-python","patch_set":4,"id":"3fa0c359_f2b4e537","line":410,"range":{"start_line":410,"start_character":41,"end_line":410,"end_character":49},"in_reply_to":"5f93b717_3fc5c85b","updated":"2018-02-05 09:55:43.000000000","message":"you are right, I totally miss read that, its good.","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5c1b6223fe6efe48b369b589fa9acbd433acf54","unresolved":false,"context_lines":[{"line_number":407,"context_line":"                            instances.select().where(and_("},{"line_number":408,"context_line":"                                instances.c.node \u003d\u003d nodename,"},{"line_number":409,"context_line":"                                instances.c.deleted \u003d\u003d 0"},{"line_number":410,"context_line":"                            )).execute().fetchall())"},{"line_number":411,"context_line":"                        # Get the instance_extras for each instance so we can"},{"line_number":412,"context_line":"                        # find the flavors."},{"line_number":413,"context_line":"                        # TODO(mriedem): Borrow Jay\u0027s join-fu to get the extras"}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_3fc5c85b","line":410,"range":{"start_line":410,"start_character":41,"end_line":410,"end_character":49},"in_reply_to":"5f93b717_bc148b4f","updated":"2018-01-29 22:11:44.000000000","message":"We would only have one non-deleted instance with a specific nodename, right? I guess I could change this to first()...","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"dc986d9a5db369f558fc608d69b831b72c02159b","unresolved":false,"context_lines":[{"line_number":414,"context_line":"                        # with the instances."},{"line_number":415,"context_line":"                        for inst in ironic_instances:"},{"line_number":416,"context_line":"                            if not self._is_ironic_instance_migrated("},{"line_number":417,"context_line":"                                    extras, inst):"},{"line_number":418,"context_line":"                                # We didn\u0027t find the extra spec key for this"},{"line_number":419,"context_line":"                                # instance so increment the number of"},{"line_number":420,"context_line":"                                # unmigrated instances in this cell."}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_1c357ff7","line":417,"updated":"2018-01-29 18:12:46.000000000","message":"(sorry, still getting my head around this bit, i.e. how extras works, vs inst.extra just doing it\u0027s thing).","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f5c1b6223fe6efe48b369b589fa9acbd433acf54","unresolved":false,"context_lines":[{"line_number":414,"context_line":"                        # with the instances."},{"line_number":415,"context_line":"                        for inst in ironic_instances:"},{"line_number":416,"context_line":"                            if not self._is_ironic_instance_migrated("},{"line_number":417,"context_line":"                                    extras, inst):"},{"line_number":418,"context_line":"                                # We didn\u0027t find the extra spec key for this"},{"line_number":419,"context_line":"                                # instance so increment the number of"},{"line_number":420,"context_line":"                                # unmigrated instances in this cell."}],"source_content_type":"text/x-python","patch_set":4,"id":"5f93b717_bfaeb895","line":417,"in_reply_to":"5f93b717_1c357ff7","updated":"2018-01-29 22:11:44.000000000","message":"We don\u0027t have an instance object here, so we have to do the instance extra shenanigans ourselves.","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"5c2efdc5a484ee792c8b34d9e837f47e068cfa69","unresolved":false,"context_lines":[{"line_number":414,"context_line":"                        # with the instances."},{"line_number":415,"context_line":"                        for inst in ironic_instances:"},{"line_number":416,"context_line":"                            if not self._is_ironic_instance_migrated("},{"line_number":417,"context_line":"                                    extras, inst):"},{"line_number":418,"context_line":"                                # We didn\u0027t find the extra spec key for this"},{"line_number":419,"context_line":"                                # instance so increment the number of"},{"line_number":420,"context_line":"                                # unmigrated instances in this cell."}],"source_content_type":"text/x-python","patch_set":4,"id":"3fa0c359_32d9ed82","line":417,"in_reply_to":"5f93b717_bfaeb895","updated":"2018-02-05 09:55:43.000000000","message":"So what I did was not look at the meta object, makes sense now.","commit_id":"cbfdc953a9d275311384c7f0612b4e1510bcd32c"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"d3d9bb75efafe4312a8bcaaf26515a54d9c6155f","unresolved":false,"context_lines":[{"line_number":383,"context_line":"        # instances"},{"line_number":384,"context_line":"        unmigrated_instance_count_by_cell \u003d collections.defaultdict(int)"},{"line_number":385,"context_line":"        for cell_mapping in cell_mappings:"},{"line_number":386,"context_line":"            cell_id \u003d cell_mapping[\u0027name\u0027] or cell_mapping[\u0027uuid\u0027]"},{"line_number":387,"context_line":"            with nova_context.target_cell(ctxt, cell_mapping) as cctxt:"},{"line_number":388,"context_line":"                # Get the (non-deleted) ironic compute nodes in this cell."},{"line_number":389,"context_line":"                meta \u003d MetaData(bind\u003ddb_session.get_engine(context\u003dcctxt))"}],"source_content_type":"text/x-python","patch_set":7,"id":"bf659307_c744ec49","line":386,"range":{"start_line":386,"start_character":22,"end_line":386,"end_character":45},"updated":"2018-03-29 20:57:07.000000000","message":"Do we really want to use \u0027name\u0027 at all here? There\u0027s no unique constraint on name, so in the (perhaps unlikely) event that multiple cells have the same \u0027name\u0027, we would glob them all into one cell_id in the unmigrated_instance_count_by_cell.","commit_id":"e515f738b363efbb38d708acd0631b768026aaa5"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3b908b05cec7d70b20e21f08f41445a39d4ee410","unresolved":false,"context_lines":[{"line_number":383,"context_line":"        # instances"},{"line_number":384,"context_line":"        unmigrated_instance_count_by_cell \u003d collections.defaultdict(int)"},{"line_number":385,"context_line":"        for cell_mapping in cell_mappings:"},{"line_number":386,"context_line":"            cell_id \u003d cell_mapping[\u0027name\u0027] or cell_mapping[\u0027uuid\u0027]"},{"line_number":387,"context_line":"            with nova_context.target_cell(ctxt, cell_mapping) as cctxt:"},{"line_number":388,"context_line":"                # Get the (non-deleted) ironic compute nodes in this cell."},{"line_number":389,"context_line":"                meta \u003d MetaData(bind\u003ddb_session.get_engine(context\u003dcctxt))"}],"source_content_type":"text/x-python","patch_set":7,"id":"bf659307_47377c4e","line":386,"range":{"start_line":386,"start_character":22,"end_line":386,"end_character":45},"in_reply_to":"bf659307_c744ec49","updated":"2018-03-29 21:27:09.000000000","message":"That\u0027s fair, I can just rely on uuid.","commit_id":"e515f738b363efbb38d708acd0631b768026aaa5"}],"nova/tests/unit/cmd/test_status.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6f2bfc0f3bb6cb6f16a96468009fad6dcaa2dbc3","unresolved":false,"context_lines":[{"line_number":777,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":778,"context_line":""},{"line_number":779,"context_line":"        # Create the ironic compute nodes in cell1"},{"line_number":780,"context_line":"        cell1_nodes \u003d []"},{"line_number":781,"context_line":"        for x in range(2):"},{"line_number":782,"context_line":"            cell \u003d self.cell_mappings[\u0027cell1\u0027]"},{"line_number":783,"context_line":"            ironic_node \u003d self._create_node_in_cell("}],"source_content_type":"text/x-python","patch_set":2,"id":"df87a7cf_833adeca","line":780,"range":{"start_line":780,"start_character":8,"end_line":780,"end_character":19},"updated":"2017-12-13 19:56:57.000000000","message":"Never ended up using this variable or the one below.","commit_id":"f7b0ffb5431710e60b43af1d9a3b6fd455727ae3"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bf5793c46cae531d8f2a39ed08656c67f482e277","unresolved":false,"context_lines":[{"line_number":805,"context_line":"        self.assertEqual(status.UpgradeCheckCode.FAILURE, result.code)"},{"line_number":806,"context_line":"        # Check the message - it should point out cell1 has one unmigrated"},{"line_number":807,"context_line":"        # instance and cell2 has two unmigrated instances."},{"line_number":808,"context_line":"        self.assertIn(\u0027There are (cell\u003dx) number of unmigrated instances in \u0027"},{"line_number":809,"context_line":"                      \u0027each cell: (cell1\u003d1) (cell2\u003d2).\u0027, result.details)"}],"source_content_type":"text/x-python","patch_set":2,"id":"df87a7cf_430136af","line":809,"range":{"start_line":808,"start_character":8,"end_line":809,"end_character":72},"updated":"2017-12-13 20:11:03.000000000","message":"Apparently despite the order_by when getting the cell mappings, this is unstable:\n\ntesttools.matchers._impl.MismatchError: \u0027There are (cell\u003dx) number of unmigrated instances in each cell: (cell1\u003d1) (cell2\u003d2).\u0027 not in u\"There are (cell\u003dx) number of unmigrated instances in each cell: (cell2\u003d2) (cell1\u003d1). Run \u0027nova-manage db ironic_flavor_migration\u0027 on each cell.\"\n\nWhich makes sense since I\u0027m pulling the values out of a dict...damn. Easy fix though.","commit_id":"f7b0ffb5431710e60b43af1d9a3b6fd455727ae3"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"ca361028ca354f2a87b63cfaf635e517d45dba34","unresolved":false,"context_lines":[{"line_number":806,"context_line":"            \u0027There are (cell\u003dx) number of unmigrated instances in each \u0027"},{"line_number":807,"context_line":"            \u0027cell: (%s\u003d1) (%s\u003d2).\u0027 % (self.cell_mappings[\u0027cell1\u0027].uuid,"},{"line_number":808,"context_line":"                                      self.cell_mappings[\u0027cell2\u0027].uuid),"},{"line_number":809,"context_line":"            result.details)"}],"source_content_type":"text/x-python","patch_set":8,"id":"bf659307_b252f0dd","line":809,"updated":"2018-04-04 19:20:02.000000000","message":"Looks like this assert is sensitive to the ordering of the cells in self.cell_mappings. Maybe split it into a few separate asserts? One for the prelude \"There are (cell\u003dx) number of unmigrated instances in each cell\" and one for each cell?","commit_id":"af21e952aafd5c532513f149a99b0a077e8755d8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"f48ee4ea396e6c3f7df25137b41c103f25626ff9","unresolved":false,"context_lines":[{"line_number":806,"context_line":"            \u0027There are (cell\u003dx) number of unmigrated instances in each \u0027"},{"line_number":807,"context_line":"            \u0027cell: (%s\u003d1) (%s\u003d2).\u0027 % (self.cell_mappings[\u0027cell1\u0027].uuid,"},{"line_number":808,"context_line":"                                      self.cell_mappings[\u0027cell2\u0027].uuid),"},{"line_number":809,"context_line":"            result.details)"}],"source_content_type":"text/x-python","patch_set":8,"id":"bf659307_cd99097a","line":809,"in_reply_to":"bf659307_b252f0dd","updated":"2018-04-04 20:16:46.000000000","message":"Blech, yeah, alternatively I could change _get_non_cell0_mappings to order by id/asc, which is what we do in the object code:\n\nhttps://github.com/openstack/nova/blob/f577ecbdbedce98b5341d03d5c0b26b67bb162a3/nova/objects/cell_mapping.py#L145","commit_id":"af21e952aafd5c532513f149a99b0a077e8755d8"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"c62545433e440b0818aece5900a813398f9ac4f1","unresolved":false,"context_lines":[{"line_number":806,"context_line":"            \u0027There are (cell\u003dx) number of unmigrated instances in each \u0027"},{"line_number":807,"context_line":"            \u0027cell: (%s\u003d1) (%s\u003d2).\u0027 % (self.cell_mappings[\u0027cell1\u0027].uuid,"},{"line_number":808,"context_line":"                                      self.cell_mappings[\u0027cell2\u0027].uuid),"},{"line_number":809,"context_line":"            result.details)"}],"source_content_type":"text/x-python","patch_set":8,"id":"bf659307_3f0c6893","line":809,"in_reply_to":"bf659307_cd99097a","updated":"2018-04-04 20:57:02.000000000","message":"Actually I shouldn\u0027t need to sort the results from the DB query. The results in the output are sorted by key, so I just need to do the same sort ordering in the test.","commit_id":"af21e952aafd5c532513f149a99b0a077e8755d8"}]}
