)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f5d4a3d73790d505cc5b87b2c59ebcce62f04ae","unresolved":false,"context_lines":[{"line_number":9,"context_line":"1) Change it to accommodate querying it for \u0027None\u0027 project_ids"},{"line_number":10,"context_line":"   in the \"--all-tenats\" case."},{"line_number":11,"context_line":"2) Because of the way we did the data migration for queued_for_delete"},{"line_number":12,"context_line":"   new records will be NULL while the ones that were migrated will be"},{"line_number":13,"context_line":"   false(). We need to accommodate both of these while returning"},{"line_number":14,"context_line":"   non-deleted instance_mappigns."},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"9fdfeff1_e304f180","line":12,"updated":"2019-02-06 13:49:34.000000000","message":"The online data migration is looking for old records where queued_for_delete is NULL:\n\nhttps://github.com/openstack/nova/blob/bcfd2439bab7cfad942d7e6a187df6edb1d1bf09/nova/objects/instance_mapping.py#L160\n\nNew instance mappings by default have queued_for_delete\u003dFalse:\n\nhttps://github.com/openstack/nova/blob/bcfd2439bab7cfad942d7e6a187df6edb1d1bf09/nova/objects/instance_mapping.py#L38\n\nSo I think the commit message and comment in the code is backward.","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"},{"author":{"_account_id":26936,"name":"Surya Seetharaman","email":"suryaseetharaman.9@gmail.com","username":"tssurya"},"change_message_id":"1d958558732d13d97697790206e9ee7c35c39989","unresolved":false,"context_lines":[{"line_number":9,"context_line":"1) Change it to accommodate querying it for \u0027None\u0027 project_ids"},{"line_number":10,"context_line":"   in the \"--all-tenats\" case."},{"line_number":11,"context_line":"2) Because of the way we did the data migration for queued_for_delete"},{"line_number":12,"context_line":"   new records will be NULL while the ones that were migrated will be"},{"line_number":13,"context_line":"   false(). We need to accommodate both of these while returning"},{"line_number":14,"context_line":"   non-deleted instance_mappigns."},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"9fdfeff1_5e20304a","line":12,"in_reply_to":"9fdfeff1_e304f180","updated":"2019-02-06 14:27:35.000000000","message":"\u003e The online data migration is looking for old records where\n \u003e queued_for_delete is NULL:\n \u003e \n \u003e https://github.com/openstack/nova/blob/bcfd2439bab7cfad942d7e6a187df6edb1d1bf09/nova/objects/instance_mapping.py#L160\n \u003e \n \u003e New instance mappings by default have queued_for_delete\u003dFalse:\n \u003e \n \u003e https://github.com/openstack/nova/blob/bcfd2439bab7cfad942d7e6a187df6edb1d1bf09/nova/objects/instance_mapping.py#L38\n \u003e \n\nno they don\u0027t :/. That\u0027s what I though at first. I just checked this on the new devstack. They are NULL by default in the database not false(). At least I don\u0027t know how the objects/sql db value  match/work. They for new instances are NULL which is why I have to also add the check for \"None\" in addition to false().\n\n \u003e So I think the commit message and comment in the code is backward.","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f888c1ab77df65c73fd41b936a9ab7a953c5ac1","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Modify InstanceMappingList.get_not_deleted_by_cell_and_project()"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"1) Change it to accommodate querying it for \u0027None\u0027 project_ids"},{"line_number":10,"context_line":"   in the \"--all-tenats\" case."},{"line_number":11,"context_line":"2) If the online data migration for populating queued_for_delete"},{"line_number":12,"context_line":"   has not been run for some reason, the the values could be NULL"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_f8b0ee8d","line":9,"range":{"start_line":9,"start_character":37,"end_line":9,"end_character":39},"updated":"2019-02-08 13:40:53.000000000","message":"nix","commit_id":"b0eb4c5f8c7768b2c5cefdb6c5b3e8688f65b1ba"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f888c1ab77df65c73fd41b936a9ab7a953c5ac1","unresolved":false,"context_lines":[{"line_number":9,"context_line":"1) Change it to accommodate querying it for \u0027None\u0027 project_ids"},{"line_number":10,"context_line":"   in the \"--all-tenats\" case."},{"line_number":11,"context_line":"2) If the online data migration for populating queued_for_delete"},{"line_number":12,"context_line":"   has not been run for some reason, the the values could be NULL"},{"line_number":13,"context_line":"   in the database for instance_mapping.queued_for_delete. Under"},{"line_number":14,"context_line":"   such circumstances, we assume that such mappings with NULL"},{"line_number":15,"context_line":"   queued_for_delete have *not* being queued_for_deletion."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_58ba5a6e","line":12,"range":{"start_line":12,"start_character":37,"end_line":12,"end_character":40},"updated":"2019-02-08 13:40:53.000000000","message":"then","commit_id":"b0eb4c5f8c7768b2c5cefdb6c5b3e8688f65b1ba"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f888c1ab77df65c73fd41b936a9ab7a953c5ac1","unresolved":false,"context_lines":[{"line_number":12,"context_line":"   has not been run for some reason, the the values could be NULL"},{"line_number":13,"context_line":"   in the database for instance_mapping.queued_for_delete. Under"},{"line_number":14,"context_line":"   such circumstances, we assume that such mappings with NULL"},{"line_number":15,"context_line":"   queued_for_delete have *not* being queued_for_deletion."},{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Related to blueprint handling-down-cell"},{"line_number":18,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9fdfeff1_b8aa6616","line":15,"range":{"start_line":15,"start_character":32,"end_line":15,"end_character":37},"updated":"2019-02-08 13:40:53.000000000","message":"been","commit_id":"b0eb4c5f8c7768b2c5cefdb6c5b3e8688f65b1ba"}],"nova/objects/instance_mapping.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f5d4a3d73790d505cc5b87b2c59ebcce62f04ae","unresolved":false,"context_lines":[{"line_number":261,"context_line":"            # Note that the project_id can be None in case"},{"line_number":262,"context_line":"            # instances are being listed for the all-tenants case."},{"line_number":263,"context_line":"            query \u003d query.filter_by(project_id\u003dproject_id)"},{"line_number":264,"context_line":"        # Both the values NULL (for newer instances) and"},{"line_number":265,"context_line":"        # False (for the older instances) mean that the instance"},{"line_number":266,"context_line":"        # is not queued for deletion."},{"line_number":267,"context_line":"        query \u003d (query.filter(or_("}],"source_content_type":"text/x-python","patch_set":1,"id":"9fdfeff1_03e1f5d0","line":264,"range":{"start_line":264,"start_character":36,"end_line":264,"end_character":41},"updated":"2019-02-06 13:49:34.000000000","message":"Shouldn\u0027t this be NULL for older instances?","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"},{"author":{"_account_id":26936,"name":"Surya Seetharaman","email":"suryaseetharaman.9@gmail.com","username":"tssurya"},"change_message_id":"1d958558732d13d97697790206e9ee7c35c39989","unresolved":false,"context_lines":[{"line_number":261,"context_line":"            # Note that the project_id can be None in case"},{"line_number":262,"context_line":"            # instances are being listed for the all-tenants case."},{"line_number":263,"context_line":"            query \u003d query.filter_by(project_id\u003dproject_id)"},{"line_number":264,"context_line":"        # Both the values NULL (for newer instances) and"},{"line_number":265,"context_line":"        # False (for the older instances) mean that the instance"},{"line_number":266,"context_line":"        # is not queued for deletion."},{"line_number":267,"context_line":"        query \u003d (query.filter(or_("}],"source_content_type":"text/x-python","patch_set":1,"id":"9fdfeff1_5ecef083","line":264,"range":{"start_line":264,"start_character":36,"end_line":264,"end_character":41},"in_reply_to":"9fdfeff1_03e1f5d0","updated":"2019-02-06 14:27:35.000000000","message":"in the database, this is not the case in the new devstack","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ae945fa6b506eb87d5c3c2b92766268805f183e3","unresolved":false,"context_lines":[{"line_number":261,"context_line":"            # Note that the project_id can be None in case"},{"line_number":262,"context_line":"            # instances are being listed for the all-tenants case."},{"line_number":263,"context_line":"            query \u003d query.filter_by(project_id\u003dproject_id)"},{"line_number":264,"context_line":"        # Both the values NULL (for newer instances) and"},{"line_number":265,"context_line":"        # False (for the older instances) mean that the instance"},{"line_number":266,"context_line":"        # is not queued for deletion."},{"line_number":267,"context_line":"        query \u003d (query.filter(or_("}],"source_content_type":"text/x-python","patch_set":1,"id":"9fdfeff1_8c466d4f","line":264,"range":{"start_line":264,"start_character":36,"end_line":264,"end_character":41},"in_reply_to":"9fdfeff1_5ecef083","updated":"2019-02-06 19:21:24.000000000","message":"With https://review.openstack.org/#/c/635185/ can we change the wording here to just be NULL for non-migrated records?\n\nThe \"both values mean..\" isn\u0027t really true since NULL can mean non-migrated mappings and we don\u0027t know if they are for deleted instances or not, so I think you agreed in IRC to just lump NULL in with False and those mappings could be returned even though the instance is actually deleted, but that will only show up in the API in the down-cell case and only while those instance mappings are not yet migrated, correct?","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"},{"author":{"_account_id":26936,"name":"Surya Seetharaman","email":"suryaseetharaman.9@gmail.com","username":"tssurya"},"change_message_id":"c87bb564a39b645bf55f48e3807539df6058a465","unresolved":false,"context_lines":[{"line_number":261,"context_line":"            # Note that the project_id can be None in case"},{"line_number":262,"context_line":"            # instances are being listed for the all-tenants case."},{"line_number":263,"context_line":"            query \u003d query.filter_by(project_id\u003dproject_id)"},{"line_number":264,"context_line":"        # Both the values NULL (for newer instances) and"},{"line_number":265,"context_line":"        # False (for the older instances) mean that the instance"},{"line_number":266,"context_line":"        # is not queued for deletion."},{"line_number":267,"context_line":"        query \u003d (query.filter(or_("}],"source_content_type":"text/x-python","patch_set":1,"id":"9fdfeff1_4aa4db08","line":264,"range":{"start_line":264,"start_character":36,"end_line":264,"end_character":41},"in_reply_to":"9fdfeff1_8c466d4f","updated":"2019-02-07 09:09:06.000000000","message":"correct, I will update the wording.","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f5d4a3d73790d505cc5b87b2c59ebcce62f04ae","unresolved":false,"context_lines":[{"line_number":262,"context_line":"            # instances are being listed for the all-tenants case."},{"line_number":263,"context_line":"            query \u003d query.filter_by(project_id\u003dproject_id)"},{"line_number":264,"context_line":"        # Both the values NULL (for newer instances) and"},{"line_number":265,"context_line":"        # False (for the older instances) mean that the instance"},{"line_number":266,"context_line":"        # is not queued for deletion."},{"line_number":267,"context_line":"        query \u003d (query.filter(or_("},{"line_number":268,"context_line":"            api_models.InstanceMapping.queued_for_delete \u003d\u003d false(),"}],"source_content_type":"text/x-python","patch_set":1,"id":"9fdfeff1_c3ea0dab","line":265,"range":{"start_line":265,"start_character":25,"end_line":265,"end_character":30},"updated":"2019-02-06 13:49:34.000000000","message":"newer?","commit_id":"1cc6525996cc2e2b98d449c790320f131f097c96"}],"nova/tests/functional/db/test_instance_mapping.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"2f888c1ab77df65c73fd41b936a9ab7a953c5ac1","unresolved":false,"context_lines":[{"line_number":366,"context_line":"                                               project_id\u003d\u0027fake-project-2\u0027,"},{"line_number":367,"context_line":"                                               cell_mapping\u003dcm,"},{"line_number":368,"context_line":"                                               instance_uuid\u003duuidsentinel.uid2,"},{"line_number":369,"context_line":"                                               queued_for_delete\u003dNone)"},{"line_number":370,"context_line":"        im2.create()"},{"line_number":371,"context_line":"        # testing if it accepts None project_id in the query and"},{"line_number":372,"context_line":"        # catches None queued for delete records."},{"line_number":373,"context_line":"        ims \u003d (instance_mapping.InstanceMappingList."}],"source_content_type":"text/x-python","patch_set":2,"id":"9fdfeff1_181ff270","line":370,"range":{"start_line":369,"start_character":47,"end_line":370,"end_character":20},"updated":"2019-02-08 13:40:53.000000000","message":"And because of the way this is handled:\n\nhttps://github.com/openstack/nova/blob/a6963fa6858289d048e4d27ce8e61637cd023f4c/nova/objects/instance_mapping.py#L105\n\nThe create() method should insert the record with None rather than False so we do get the OR condition in the query covered.","commit_id":"b0eb4c5f8c7768b2c5cefdb6c5b3e8688f65b1ba"}]}
