)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"987cb9179e23c189bfafc9f6ee23e2d9dc6cf6f6","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Grzegorz Grasza \u003cgrzegorz.grasza@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-12-12 18:01:14 +0100"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add new dbsync command online_data_migration"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"To limit downtime during upgrades, data migrations will be done online"},{"line_number":10,"context_line":"with migration scripts that could be run during normal operation of an"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a6eadb0_195a1984","line":7,"updated":"2016-12-12 23:13:58.000000000","message":"Do you know why nova\u0027s command is plural, \u0027online_data_migrations\u0027 ?","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Grzegorz Grasza \u003cgrzegorz.grasza@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-12-12 18:01:14 +0100"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add new dbsync command online_data_migration"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"To limit downtime during upgrades, data migrations will be done online"},{"line_number":10,"context_line":"with migration scripts that could be run during normal operation of an"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a6eadb0_4bf01291","line":7,"in_reply_to":"1a6eadb0_195a1984","updated":"2016-12-19 14:42:57.000000000","message":"No, but online_data_migration is what is consistently used in ironic specs right now...","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Grzegorz Grasza \u003cgrzegorz.grasza@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-12-19 18:21:51 +0100"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add new dbsync command online_data_migration"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"To limit downtime during upgrades, data migrations will be done online"},{"line_number":10,"context_line":"with migration scripts that could be run during normal operation of an"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"1a6eadb0_3c4b1ab2","line":7,"updated":"2016-12-19 23:32:07.000000000","message":"to be consistent with nova\u0027s, I think we should s/online_data_migration/online_data_migrations/.","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"c5c883f0e3f460a833a4f44fb204e21115da569c","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Grzegorz Grasza \u003cgrzegorz.grasza@intel.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2016-12-19 18:21:51 +0100"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add new dbsync command online_data_migration"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"To limit downtime during upgrades, data migrations will be done online"},{"line_number":10,"context_line":"with migration scripts that could be run during normal operation of an"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"ba5201f7_4c83f0cc","line":7,"in_reply_to":"1a6eadb0_3c4b1ab2","updated":"2017-01-02 09:12:08.000000000","message":"Done","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"}],"doc/source/cli/ironic-dbsync.rst":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":191,"context_line":"or to the version specified with the :option:`--revision` option."},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"The command returns 2 (error) if the database is not compatible with the most"},{"line_number":194,"context_line":"recent version. If this happens, the `ironic-dbsync online_data_migrations`"},{"line_number":195,"context_line":"command should be run using the previous version of ironic, before upgrading"},{"line_number":196,"context_line":"and running this command."},{"line_number":197,"context_line":""},{"line_number":198,"context_line":"If there are no existing tables, then new tables are created, beginning"}],"source_content_type":"text/x-rst","patch_set":63,"id":"ff346bd7_1dddfb13","line":195,"range":{"start_line":194,"start_character":16,"end_line":195,"end_character":58},"updated":"2017-07-24 12:28:48.000000000","message":"I think we should be more explicit about the order. If one has already upgraded the code and packages, this will bring some trouble.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"97a60b32a1937a22ca93ba61c6fc95d8ce9ebd62","unresolved":false,"context_lines":[{"line_number":191,"context_line":"or to the version specified with the :option:`--revision` option."},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"The command returns 2 (error) if the database is not compatible with the most"},{"line_number":194,"context_line":"recent version. If this happens, the `ironic-dbsync online_data_migrations`"},{"line_number":195,"context_line":"command should be run using the previous version of ironic, before upgrading"},{"line_number":196,"context_line":"and running this command."},{"line_number":197,"context_line":""},{"line_number":198,"context_line":"If there are no existing tables, then new tables are created, beginning"}],"source_content_type":"text/x-rst","patch_set":63,"id":"ff346bd7_2d384a9e","line":195,"range":{"start_line":194,"start_character":16,"end_line":195,"end_character":58},"in_reply_to":"ff346bd7_1dddfb13","updated":"2017-07-25 21:55:25.000000000","message":"I reworded things; let me know what you think.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"7e319149f6c556be1eb5bd520ded5c8f5a42b222","unresolved":false,"context_lines":[{"line_number":126,"context_line":""},{"line_number":127,"context_line":"* 127 (error) if max-count is not a positive value"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"* 2 (error) if the database is not compatible with this release. This command"},{"line_number":130,"context_line":"  needs to be run using the previous release of ironic, before upgrading and"},{"line_number":131,"context_line":"  running it with this release."},{"line_number":132,"context_line":""}],"source_content_type":"text/x-rst","patch_set":67,"id":"df3967d1_ba2127fe","line":129,"updated":"2017-08-01 14:37:31.000000000","message":"nit - so no error code 2 yet :)","commit_id":"f1e573f4bb60ebba4348f3820d191c281134c5cb"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d2f85e2dd460342a76f0339308dd04ba4d4a3c4","unresolved":false,"context_lines":[{"line_number":126,"context_line":""},{"line_number":127,"context_line":"* 127 (error) if max-count is not a positive value"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"* 2 (error) if the database is not compatible with this release. This command"},{"line_number":130,"context_line":"  needs to be run using the previous release of ironic, before upgrading and"},{"line_number":131,"context_line":"  running it with this release."},{"line_number":132,"context_line":""}],"source_content_type":"text/x-rst","patch_set":67,"id":"df3967d1_2b84c70b","line":129,"in_reply_to":"df3967d1_ba2127fe","updated":"2017-08-01 15:56:20.000000000","message":"Darn, I tried to slip that in. Right, I didn\u0027t feel like adding a comment to remember to add this in, in Queens. Let me know if you think I should. (I figure folks won\u0027t get this error so it doesn\u0027t matter.)","commit_id":"f1e573f4bb60ebba4348f3820d191c281134c5cb"}],"doc/source/cmds/ironic-dbsync.rst":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":194,"context_line":""},{"line_number":195,"context_line":".. option:: -h, --help"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"  Show help for version and exit."},{"line_number":198,"context_line":""},{"line_number":199,"context_line":".. option:: --max-count \u003cNUMBER\u003e"},{"line_number":200,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"1a6eadb0_217245e6","line":197,"updated":"2016-12-12 22:47:30.000000000","message":"s/version/online_data_migration/","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":194,"context_line":""},{"line_number":195,"context_line":".. option:: -h, --help"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"  Show help for version and exit."},{"line_number":198,"context_line":""},{"line_number":199,"context_line":".. option:: --max-count \u003cNUMBER\u003e"},{"line_number":200,"context_line":""}],"source_content_type":"text/x-rst","patch_set":4,"id":"1a6eadb0_6b122eb6","line":197,"in_reply_to":"1a6eadb0_217245e6","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"ace0262b63d49fe561adddeb3e7e3d5389e41107","unresolved":false,"context_lines":[{"line_number":194,"context_line":""},{"line_number":195,"context_line":".. option:: -h, --help"},{"line_number":196,"context_line":""},{"line_number":197,"context_line":"  Show help for onlina_data_migration and exit."},{"line_number":198,"context_line":""},{"line_number":199,"context_line":".. option:: --max-count \u003cNUMBER\u003e"},{"line_number":200,"context_line":""}],"source_content_type":"text/x-rst","patch_set":7,"id":"1a6eadb0_aff8e0c5","line":197,"range":{"start_line":197,"start_character":21,"end_line":197,"end_character":22},"updated":"2016-12-19 16:10:36.000000000","message":"Small typo: s/onlina/online","commit_id":"d393b1077e3a158fc463fd2694a62059dc01b1bb"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ca1c77a9d45cb07d3ecef35bfdf22275e50a8ad","unresolved":false,"context_lines":[{"line_number":200,"context_line":""},{"line_number":201,"context_line":"  Specify maximum number of objects to migrate."},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."}],"source_content_type":"text/x-rst","patch_set":8,"id":"1a6eadb0_08227201","line":203,"updated":"2016-12-20 15:49:59.000000000","message":"one other thing (i can wordsmith this later too). The max-count description is for \u0027objects\u0027, yet no \u0027object\u0027 is mentioned in this paragraph.","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":19213,"name":"Szymon Borkowski","email":"szymon.borkowski@intel.com","username":"sborkows"},"change_message_id":"46a51bc5cf802ed135e94fd10940069323844e05","unresolved":false,"context_lines":[{"line_number":200,"context_line":""},{"line_number":201,"context_line":"  Specify maximum number of objects to migrate."},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."}],"source_content_type":"text/x-rst","patch_set":8,"id":"1a6eadb0_a00b3323","line":203,"in_reply_to":"1a6eadb0_08227201","updated":"2016-12-21 09:27:58.000000000","message":"Maybe s/objects/rows in the max-count description?","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"c5c883f0e3f460a833a4f44fb204e21115da569c","unresolved":false,"context_lines":[{"line_number":200,"context_line":""},{"line_number":201,"context_line":"  Specify maximum number of objects to migrate."},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."}],"source_content_type":"text/x-rst","patch_set":8,"id":"ba5201f7_2c65cc44","line":203,"in_reply_to":"1a6eadb0_a00b3323","updated":"2017-01-02 09:12:08.000000000","message":"I changed it to objects instead, it will be consistent with the command help text and code itself.","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":8,"id":"1a6eadb0_dc8866c9","line":206,"updated":"2016-12-19 23:32:07.000000000","message":"maybe s/It will not/It will return 1 and only/\n\nIt can probably be reworded better, but I\u0027m only suggesting a minimal change here :)","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"c5c883f0e3f460a833a4f44fb204e21115da569c","unresolved":false,"context_lines":[{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":8,"id":"ba5201f7_0cc72813","line":206,"in_reply_to":"1a6eadb0_48738a15","updated":"2017-01-02 09:12:08.000000000","message":"Done","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ca1c77a9d45cb07d3ecef35bfdf22275e50a8ad","unresolved":false,"context_lines":[{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":8,"id":"1a6eadb0_48738a15","line":206,"in_reply_to":"1a6eadb0_a211aeb1","updated":"2016-12-20 15:49:59.000000000","message":"That works for me.","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":19213,"name":"Szymon Borkowski","email":"szymon.borkowski@intel.com","username":"sborkows"},"change_message_id":"287b0a743094451f9170fcb520f6990e28ca3c7b","unresolved":false,"context_lines":[{"line_number":203,"context_line":"This command will migrate data in database rows to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"not return with 0 (success) until all rows are migrated."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":8,"id":"1a6eadb0_a211aeb1","line":206,"in_reply_to":"1a6eadb0_dc8866c9","updated":"2016-12-20 10:43:22.000000000","message":"Maybe: \"It will return 1 (not completed) until all rows are migrated, then 0 (success).\"","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"return 1 (not completed) until all rows are migrated, then 0 (success)."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":17,"id":"ba5201f7_2112070a","line":205,"updated":"2017-01-10 21:56:53.000000000","message":"s/process only a specified amount of data/migrate the specified number of objects/","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"return 1 (not completed) until all rows are migrated, then 0 (success)."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":17,"id":"9a57fde8_441122ac","line":205,"in_reply_to":"ba5201f7_2112070a","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":203,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"return 1 (not completed) until all rows are migrated, then 0 (success)."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":17,"id":"ba5201f7_c12bfb31","line":206,"updated":"2017-01-10 21:56:53.000000000","message":"s/rows/objects/","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":203,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":204,"context_line":"If run with the :option:`--max-count` option, the script will process only"},{"line_number":205,"context_line":"a specified amount of data. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"return 1 (not completed) until all rows are migrated, then 0 (success)."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":17,"id":"9a57fde8_84230a05","line":206,"in_reply_to":"ba5201f7_c12bfb31","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"5d90a8d5ba6092357e38ac86289680bf83f90ffa","unresolved":false,"context_lines":[{"line_number":205,"context_line":"specified number of objects. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"return 1 (not completed) until all objects are migrated, then 0 (success)."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":31,"id":"5a3905b3_b5ec5f90","line":208,"range":{"start_line":208,"start_character":13,"end_line":208,"end_character":16},"updated":"2017-01-23 12:53:51.000000000","message":"nit: s/has/must/ or even better, \"MUST\" :)","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d4f438b7c75328f804c5adf232bdb2c2323664f","unresolved":false,"context_lines":[{"line_number":205,"context_line":"specified number of objects. In that case, it should be run in a loop. It will"},{"line_number":206,"context_line":"return 1 (not completed) until all objects are migrated, then 0 (success)."},{"line_number":207,"context_line":""},{"line_number":208,"context_line":"This command has to be successfully run before upgrading to a future release."}],"source_content_type":"text/x-rst","patch_set":31,"id":"1a1ced50_0c333763","line":208,"range":{"start_line":208,"start_character":13,"end_line":208,"end_character":16},"in_reply_to":"5a3905b3_b5ec5f90","updated":"2017-03-23 01:27:03.000000000","message":"Done","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":198,"context_line":""},{"line_number":199,"context_line":".. option:: --max-count \u003cNUMBER\u003e"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"  Specify maximum number of objects (a positive value) to migrate. Optional."},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":204,"context_line":""}],"source_content_type":"text/x-rst","patch_set":42,"id":"ffe62b97_b53eba88","line":201,"updated":"2017-03-27 20:37:39.000000000","message":"It would be handy to specify the default behavior here, if a maximum is not specified.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":198,"context_line":""},{"line_number":199,"context_line":".. option:: --max-count \u003cNUMBER\u003e"},{"line_number":200,"context_line":""},{"line_number":201,"context_line":"  Specify maximum number of objects (a positive value) to migrate. Optional."},{"line_number":202,"context_line":""},{"line_number":203,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":204,"context_line":""}],"source_content_type":"text/x-rst","patch_set":42,"id":"ffe62b97_f0709e0a","line":201,"in_reply_to":"ffe62b97_b53eba88","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"36484620847e51f730da24e0e331395e8d8eb518","unresolved":false,"context_lines":[{"line_number":113,"context_line":""},{"line_number":114,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"If the :option:`--max-count` option is specified, this is the maximum number"},{"line_number":117,"context_line":"of objects that will be migrated. In this case, the command should be run in a"},{"line_number":118,"context_line":"loop until all objects are migrated. If the option is not specified, all the"},{"line_number":119,"context_line":"objects will be migrated, in batches of 50 at a time."},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"It returns:"},{"line_number":122,"context_line":""}],"source_content_type":"text/x-rst","patch_set":43,"id":"ffe62b97_1711b152","line":119,"range":{"start_line":116,"start_character":0,"end_line":119,"end_character":53},"updated":"2017-03-28 23:24:48.000000000","message":"nit: This description seems to be duplicate of what is present at L111-L112","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"58144913e246e7950e40eed9dd5bc5d0bf4cc8ea","unresolved":false,"context_lines":[{"line_number":113,"context_line":""},{"line_number":114,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"If the :option:`--max-count` option is specified, this is the maximum number"},{"line_number":117,"context_line":"of objects that will be migrated. In this case, the command should be run in a"},{"line_number":118,"context_line":"loop until all objects are migrated. If the option is not specified, all the"},{"line_number":119,"context_line":"objects will be migrated, in batches of 50 at a time."},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"It returns:"},{"line_number":122,"context_line":""}],"source_content_type":"text/x-rst","patch_set":43,"id":"ffe62b97_4ade6bda","line":119,"range":{"start_line":116,"start_character":0,"end_line":119,"end_character":53},"in_reply_to":"ffe62b97_1711b152","updated":"2017-03-29 00:47:19.000000000","message":"L111-112 is actually a subset of this; It only describes the option. This contains more information to describe what the command does.\n\nWhat do you suggest changing?","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"afef51d015dc78a73139e920e9d0d98d5db80610","unresolved":false,"context_lines":[{"line_number":113,"context_line":""},{"line_number":114,"context_line":"This command will migrate objects in the database to the most recent version."},{"line_number":115,"context_line":""},{"line_number":116,"context_line":"If the :option:`--max-count` option is specified, this is the maximum number"},{"line_number":117,"context_line":"of objects that will be migrated. In this case, the command should be run in a"},{"line_number":118,"context_line":"loop until all objects are migrated. If the option is not specified, all the"},{"line_number":119,"context_line":"objects will be migrated, in batches of 50 at a time."},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"It returns:"},{"line_number":122,"context_line":""}],"source_content_type":"text/x-rst","patch_set":43,"id":"ffe62b97_9afee168","line":119,"range":{"start_line":116,"start_character":0,"end_line":119,"end_character":53},"in_reply_to":"ffe62b97_4ade6bda","updated":"2017-03-29 17:13:39.000000000","message":"Ah okay. I was going to suggest adding \"the command should be run in loop\" to the description at L111-112 as that\u0027s the only different sentence in the subset description. But yes if we usually have subset description the current one looks good.","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"}],"ironic/cmd/dbsync.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"5af8198cf6d567477e2d1505b44973138d305dac","unresolved":false,"context_lines":[{"line_number":31,"context_line":"# NOTE(xek): Perform online data migrations for the release in batches."},{"line_number":32,"context_line":"# Each migration script is a function which takes one argument - max number"},{"line_number":33,"context_line":"# of objects to migrate."},{"line_number":34,"context_line":"ONLINE_MIGRATIONS \u003d ()"},{"line_number":35,"context_line":""},{"line_number":36,"context_line":""},{"line_number":37,"context_line":"class DBCommand(object):"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_1cb49df0","line":34,"updated":"2016-12-08 15:02:07.000000000","message":"I\u0027m curious as to what these migration scripts/functions are going to be. We shouldn\u0027t merge this code w/o something working.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c1658630a80c1df842303b7cfb13571f976e66e0","unresolved":false,"context_lines":[{"line_number":51,"context_line":"    def create_schema(self):"},{"line_number":52,"context_line":"        migration.create_schema()"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"    def _run_migration(self, max_count):"},{"line_number":55,"context_line":"        ran \u003d 0"},{"line_number":56,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":57,"context_line":"            count \u003d max_count - ran"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_2a7aab88","line":54,"updated":"2016-12-09 20:32:32.000000000","message":"This needs a docstring IMO, even though it\u0027s being used as a private method.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":51,"context_line":"    def create_schema(self):"},{"line_number":52,"context_line":"        migration.create_schema()"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":"    def _run_migration(self, max_count):"},{"line_number":55,"context_line":"        ran \u003d 0"},{"line_number":56,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":57,"context_line":"            count \u003d max_count - ran"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_af2cd7ac","line":54,"in_reply_to":"3a71b18c_2a7aab88","updated":"2016-12-12 16:46:34.000000000","message":"Done","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c1658630a80c1df842303b7cfb13571f976e66e0","unresolved":false,"context_lines":[{"line_number":73,"context_line":"                    break"},{"line_number":74,"context_line":"        return ran"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":77,"context_line":"        \"\"\"Perform online data migrations for the release in batches.\"\"\""},{"line_number":78,"context_line":"        if max_count is not None:"},{"line_number":79,"context_line":"            unlimited \u003d False"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_cabbf70d","line":76,"updated":"2016-12-09 20:32:32.000000000","message":"I\u0027d like to see the ability to do a dry run of this command. That way, you could see how many rows would be affected by the change before doing it.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":73,"context_line":"                    break"},{"line_number":74,"context_line":"        return ran"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":77,"context_line":"        \"\"\"Perform online data migrations for the release in batches.\"\"\""},{"line_number":78,"context_line":"        if max_count is not None:"},{"line_number":79,"context_line":"            unlimited \u003d False"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_41287733","line":76,"in_reply_to":"3a71b18c_cabbf70d","updated":"2016-12-12 16:46:34.000000000","message":"You can already specify the maximum number of rows affected.\n\nWhat would be a use case for this? I\u0027m asking, since I see at least 2 drawbacks:\n\n* doing dry-runs would have to be implemented each time a new migration function is implemented,\n* it could make the operator believe that it is safe, while it may still impose a considerable load on the database.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"5af8198cf6d567477e2d1505b44973138d305dac","unresolved":false,"context_lines":[{"line_number":74,"context_line":"        return ran"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":77,"context_line":"        \"\"\"Perform online data migrations for the release in batches.\"\"\""},{"line_number":78,"context_line":"        if max_count is not None:"},{"line_number":79,"context_line":"            unlimited \u003d False"},{"line_number":80,"context_line":"            if max_count \u003c 1:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_56035376","line":77,"updated":"2016-12-08 15:02:07.000000000","message":"would be good to document what max_count is.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c1658630a80c1df842303b7cfb13571f976e66e0","unresolved":false,"context_lines":[{"line_number":74,"context_line":"        return ran"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":77,"context_line":"        \"\"\"Perform online data migrations for the release in batches.\"\"\""},{"line_number":78,"context_line":"        if max_count is not None:"},{"line_number":79,"context_line":"            unlimited \u003d False"},{"line_number":80,"context_line":"            if max_count \u003c 1:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_aa66bbea","line":77,"in_reply_to":"3a71b18c_56035376","updated":"2016-12-09 20:32:32.000000000","message":"Yes. Also, expanding the docstring with a summary here would be useful.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":74,"context_line":"        return ran"},{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":77,"context_line":"        \"\"\"Perform online data migrations for the release in batches.\"\"\""},{"line_number":78,"context_line":"        if max_count is not None:"},{"line_number":79,"context_line":"            unlimited \u003d False"},{"line_number":80,"context_line":"            if max_count \u003c 1:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_97bbad0e","line":77,"in_reply_to":"3a71b18c_aa66bbea","updated":"2016-12-12 16:46:34.000000000","message":"Done","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c1658630a80c1df842303b7cfb13571f976e66e0","unresolved":false,"context_lines":[{"line_number":83,"context_line":"        else:"},{"line_number":84,"context_line":"            unlimited \u003d True"},{"line_number":85,"context_line":"            max_count \u003d 50"},{"line_number":86,"context_line":"            print(_(\u0027Running batches of %i until complete.\u0027) % max_count)"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        ran \u003d None"},{"line_number":89,"context_line":"        while ran is None or ran !\u003d 0:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_ca5217de","line":86,"updated":"2016-12-09 20:32:32.000000000","message":"Why not allow the user to specify the batch number but have the program run until completion? Picking 50 seems arbitrary.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":83,"context_line":"        else:"},{"line_number":84,"context_line":"            unlimited \u003d True"},{"line_number":85,"context_line":"            max_count \u003d 50"},{"line_number":86,"context_line":"            print(_(\u0027Running batches of %i until complete.\u0027) % max_count)"},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        ran \u003d None"},{"line_number":89,"context_line":"        while ran is None or ran !\u003d 0:"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_f7d5c142","line":86,"in_reply_to":"3a71b18c_ca5217de","updated":"2016-12-12 16:46:34.000000000","message":"Some operators want to run this in a set time-frame, like at night. It may happen, that a migration takes longer than that. Exiting the program is in my opinion the simplest way to make the command user friendly and simple at the same time.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"c1658630a80c1df842303b7cfb13571f976e66e0","unresolved":false,"context_lines":[{"line_number":91,"context_line":"            if not unlimited:"},{"line_number":92,"context_line":"                break"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"        sys.exit(1 if ran else 0)"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_8a73bf7f","line":94,"updated":"2016-12-09 20:32:32.000000000","message":"This seems flipped. 1 is a general error exit code, 0 means everything went fine.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":91,"context_line":"            if not unlimited:"},{"line_number":92,"context_line":"                break"},{"line_number":93,"context_line":""},{"line_number":94,"context_line":"        sys.exit(1 if ran else 0)"},{"line_number":95,"context_line":""},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_048e8d2d","line":94,"in_reply_to":"3a71b18c_8a73bf7f","updated":"2016-12-12 16:46:34.000000000","message":"Agreed, that is in case when we run \"unlimited\". When we migrate in batches, we return 0 only if all migrations are complete.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"5af8198cf6d567477e2d1505b44973138d305dac","unresolved":false,"context_lines":[{"line_number":129,"context_line":""},{"line_number":130,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":131,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":132,"context_line":"        help\u003d_(\"Perform online data migrations for the release in batches.\"))"},{"line_number":133,"context_line":"    parser.add_argument(\u0027--max_count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027,"},{"line_number":134,"context_line":"                        type\u003dint, help\u003d_(\u0027Max number of objects to migrate.\u0027))"},{"line_number":135,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_16be3bff","line":132,"updated":"2016-12-08 15:02:07.000000000","message":"maybe s/release in batches/release, in batches/","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":129,"context_line":""},{"line_number":130,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":131,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":132,"context_line":"        help\u003d_(\"Perform online data migrations for the release in batches.\"))"},{"line_number":133,"context_line":"    parser.add_argument(\u0027--max_count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027,"},{"line_number":134,"context_line":"                        type\u003dint, help\u003d_(\u0027Max number of objects to migrate.\u0027))"},{"line_number":135,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_b7dfc9d4","line":132,"in_reply_to":"3a71b18c_16be3bff","updated":"2016-12-12 16:46:34.000000000","message":"Done","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"5af8198cf6d567477e2d1505b44973138d305dac","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":132,"context_line":"        help\u003d_(\"Perform online data migrations for the release in batches.\"))"},{"line_number":133,"context_line":"    parser.add_argument(\u0027--max_count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027,"},{"line_number":134,"context_line":"                        type\u003dint, help\u003d_(\u0027Max number of objects to migrate.\u0027))"},{"line_number":135,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_365257de","line":134,"updated":"2016-12-08 15:02:07.000000000","message":"is this the number per batch, or the total number of objects to migrate?\n\nShould we have a default if the user doesn\u0027t specify this?\n\nI looked at the code -- if not specified, all objects are migrated (in batches of 50). If specified, this is the maximum number of objects to migrate per command. I\u0027d call it \u0027max_objects\u0027 instead of \u0027max_count\u0027. \n\nI didn\u0027t try this (yet). If a user invokes \u0027dbsync online-data-migration --max_count 100\u0027 in a loop -- how/when do they know to stop invoking the command?","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"86956b6aab424691ce5296ca8a55240e32c01582","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":132,"context_line":"        help\u003d_(\"Perform online data migrations for the release in batches.\"))"},{"line_number":133,"context_line":"    parser.add_argument(\u0027--max_count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027,"},{"line_number":134,"context_line":"                        type\u003dint, help\u003d_(\u0027Max number of objects to migrate.\u0027))"},{"line_number":135,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_df04d7c7","line":134,"in_reply_to":"3a71b18c_365257de","updated":"2016-12-08 15:53:13.000000000","message":"in discussion with jroll, he mentioned that nova\u0027s version uses --limit, we might want to do the same.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":131,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":132,"context_line":"        help\u003d_(\"Perform online data migrations for the release in batches.\"))"},{"line_number":133,"context_line":"    parser.add_argument(\u0027--max_count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027,"},{"line_number":134,"context_line":"                        type\u003dint, help\u003d_(\u0027Max number of objects to migrate.\u0027))"},{"line_number":135,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":136,"context_line":""},{"line_number":137,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a71b18c_5703d541","line":134,"in_reply_to":"3a71b18c_df04d7c7","updated":"2016-12-12 16:46:34.000000000","message":"nova also uses max_count:\nhttps://github.com/openstack/nova/blob/master/nova/cmd/manage.py#L900\n\nI extended this with description of how the return value of the program changes.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"43298244c1324530f440f406b2ae89e24fd11749","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        \"\"\""},{"line_number":65,"context_line":"        ran \u003d 0"},{"line_number":66,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":67,"context_line":"            count \u003d max_count - ran"},{"line_number":68,"context_line":"            try:"},{"line_number":69,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":70,"context_line":"            except Exception:"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_8296ad92","line":67,"range":{"start_line":67,"start_character":20,"end_line":67,"end_character":29},"updated":"2016-12-13 05:37:22.000000000","message":"With current online_migrations() code, max_count always reaches here with integer value. A check for None might be needed depending on the parameter validation convention.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        \"\"\""},{"line_number":65,"context_line":"        ran \u003d 0"},{"line_number":66,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":67,"context_line":"            count \u003d max_count - ran"},{"line_number":68,"context_line":"            try:"},{"line_number":69,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":70,"context_line":"            except Exception:"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_c0917354","line":67,"range":{"start_line":67,"start_character":20,"end_line":67,"end_character":29},"in_reply_to":"1a6eadb0_8296ad92","updated":"2016-12-19 14:42:57.000000000","message":"You\u0027re right, we should just assume this is an integer.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"63fb657cd6d0820b34dd3b3406042161d6b8e9b8","unresolved":false,"context_lines":[{"line_number":64,"context_line":"        \"\"\""},{"line_number":65,"context_line":"        ran \u003d 0"},{"line_number":66,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":67,"context_line":"            count \u003d max_count - ran"},{"line_number":68,"context_line":"            try:"},{"line_number":69,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":70,"context_line":"            except Exception:"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_aa536e6b","line":67,"range":{"start_line":67,"start_character":20,"end_line":67,"end_character":29},"in_reply_to":"1a6eadb0_c0917354","updated":"2016-12-19 16:10:22.000000000","message":"OK","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"43298244c1324530f440f406b2ae89e24fd11749","unresolved":false,"context_lines":[{"line_number":67,"context_line":"            count \u003d max_count - ran"},{"line_number":68,"context_line":"            try:"},{"line_number":69,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":70,"context_line":"            except Exception:"},{"line_number":71,"context_line":"                print(_(\"Error attempting to run %(migration)s\") %"},{"line_number":72,"context_line":"                      {\u0027migration\u0027: data_migration.__name__})"},{"line_number":73,"context_line":"                found \u003d done \u003d 0"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_bd62e8d6","line":70,"range":{"start_line":70,"start_character":19,"end_line":70,"end_character":28},"updated":"2016-12-13 05:37:22.000000000","message":"If there\u0027s an exception, \u0027ran\u0027 doesn\u0027t increment; there could be a loop trying to migrate rows. Don\u0027t know if a retry counter to avoid the loop is worth it, though.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"63fb657cd6d0820b34dd3b3406042161d6b8e9b8","unresolved":false,"context_lines":[{"line_number":67,"context_line":"            count \u003d max_count - ran"},{"line_number":68,"context_line":"            try:"},{"line_number":69,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":70,"context_line":"            except Exception:"},{"line_number":71,"context_line":"                print(_(\"Error attempting to run %(migration)s\") %"},{"line_number":72,"context_line":"                      {\u0027migration\u0027: data_migration.__name__})"},{"line_number":73,"context_line":"                found \u003d done \u003d 0"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_0a4b82b1","line":70,"range":{"start_line":70,"start_character":19,"end_line":70,"end_character":28},"in_reply_to":"1a6eadb0_2325d1ad","updated":"2016-12-19 16:10:22.000000000","message":"OK","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":67,"context_line":"            count \u003d max_count - ran"},{"line_number":68,"context_line":"            try:"},{"line_number":69,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":70,"context_line":"            except Exception:"},{"line_number":71,"context_line":"                print(_(\"Error attempting to run %(migration)s\") %"},{"line_number":72,"context_line":"                      {\u0027migration\u0027: data_migration.__name__})"},{"line_number":73,"context_line":"                found \u003d done \u003d 0"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_2325d1ad","line":70,"range":{"start_line":70,"start_character":19,"end_line":70,"end_character":28},"in_reply_to":"1a6eadb0_bd62e8d6","updated":"2016-12-19 14:42:57.000000000","message":"I think I should just reraise the exception here. Let me know what you think.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"43298244c1324530f440f406b2ae89e24fd11749","unresolved":false,"context_lines":[{"line_number":77,"context_line":"                        \u0027migrated\u0027) % {\u0027total\u0027: found,"},{"line_number":78,"context_line":"                                       \u0027migration\u0027: data_migration.__name__,"},{"line_number":79,"context_line":"                                       \u0027done\u0027: done})"},{"line_number":80,"context_line":"            if max_count is not None:"},{"line_number":81,"context_line":"                ran +\u003d done"},{"line_number":82,"context_line":"                if ran \u003e\u003d max_count:"},{"line_number":83,"context_line":"                    break"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_1dee7c22","line":80,"range":{"start_line":80,"start_character":12,"end_line":80,"end_character":37},"updated":"2016-12-13 05:37:22.000000000","message":"This expression is always True. If for some reason max_count is None, a check is also needed in line 67 to avoid exception.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":77,"context_line":"                        \u0027migrated\u0027) % {\u0027total\u0027: found,"},{"line_number":78,"context_line":"                                       \u0027migration\u0027: data_migration.__name__,"},{"line_number":79,"context_line":"                                       \u0027done\u0027: done})"},{"line_number":80,"context_line":"            if max_count is not None:"},{"line_number":81,"context_line":"                ran +\u003d done"},{"line_number":82,"context_line":"                if ran \u003e\u003d max_count:"},{"line_number":83,"context_line":"                    break"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_e09e6f62","line":80,"range":{"start_line":80,"start_character":12,"end_line":80,"end_character":37},"in_reply_to":"1a6eadb0_1dee7c22","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"63fb657cd6d0820b34dd3b3406042161d6b8e9b8","unresolved":false,"context_lines":[{"line_number":77,"context_line":"                        \u0027migrated\u0027) % {\u0027total\u0027: found,"},{"line_number":78,"context_line":"                                       \u0027migration\u0027: data_migration.__name__,"},{"line_number":79,"context_line":"                                       \u0027done\u0027: done})"},{"line_number":80,"context_line":"            if max_count is not None:"},{"line_number":81,"context_line":"                ran +\u003d done"},{"line_number":82,"context_line":"                if ran \u003e\u003d max_count:"},{"line_number":83,"context_line":"                    break"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_8ad5d2ba","line":80,"range":{"start_line":80,"start_character":12,"end_line":80,"end_character":37},"in_reply_to":"1a6eadb0_e09e6f62","updated":"2016-12-19 16:10:22.000000000","message":"OK","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":95,"context_line":"            batches of 50, until completion."},{"line_number":96,"context_line":"        :raises: exits with 127 if user specifies a number \u003c 1"},{"line_number":97,"context_line":"        :returns: exits with 1 when objects were migrated and the command needs"},{"line_number":98,"context_line":"            to be re-run, exits with 0 when all migrations are complete."},{"line_number":99,"context_line":"        \"\"\""},{"line_number":100,"context_line":"        if max_count is not None:"},{"line_number":101,"context_line":"            unlimited \u003d False"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_4e2be930","line":98,"updated":"2016-12-12 22:47:30.000000000","message":"maybe s/re-run/re-run (because there are more objects that need to be migrated)/","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":95,"context_line":"            batches of 50, until completion."},{"line_number":96,"context_line":"        :raises: exits with 127 if user specifies a number \u003c 1"},{"line_number":97,"context_line":"        :returns: exits with 1 when objects were migrated and the command needs"},{"line_number":98,"context_line":"            to be re-run, exits with 0 when all migrations are complete."},{"line_number":99,"context_line":"        \"\"\""},{"line_number":100,"context_line":"        if max_count is not None:"},{"line_number":101,"context_line":"            unlimited \u003d False"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_239a31c6","line":98,"in_reply_to":"1a6eadb0_4e2be930","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":100,"context_line":"        if max_count is not None:"},{"line_number":101,"context_line":"            unlimited \u003d False"},{"line_number":102,"context_line":"            if max_count \u003c 1:"},{"line_number":103,"context_line":"                print(_(\u0027Must supply a positive value for max_number.\u0027))"},{"line_number":104,"context_line":"                sys.exit(127)"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            unlimited \u003d True"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_2eddcd42","line":103,"updated":"2016-12-12 22:47:30.000000000","message":"s/max_number/max-count/","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":100,"context_line":"        if max_count is not None:"},{"line_number":101,"context_line":"            unlimited \u003d False"},{"line_number":102,"context_line":"            if max_count \u003c 1:"},{"line_number":103,"context_line":"                print(_(\u0027Must supply a positive value for max_number.\u0027))"},{"line_number":104,"context_line":"                sys.exit(127)"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            unlimited \u003d True"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_c3d97d85","line":103,"in_reply_to":"1a6eadb0_2eddcd42","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":111,"context_line":"        while ran is None or ran !\u003d 0:"},{"line_number":112,"context_line":"            ran \u003d self._run_migration(max_count)"},{"line_number":113,"context_line":"            if not unlimited:  # exit with proper value when run in batch mode"},{"line_number":114,"context_line":"                sys.exit(0 if ran \u003c max_count else 1)"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_0e09f195","line":114,"updated":"2016-12-12 22:47:30.000000000","message":"It might just be me, but I\u0027d prefer that there was one \u0027exit\u0027/return line for this method (outside the while loop)","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":111,"context_line":"        while ran is None or ran !\u003d 0:"},{"line_number":112,"context_line":"            ran \u003d self._run_migration(max_count)"},{"line_number":113,"context_line":"            if not unlimited:  # exit with proper value when run in batch mode"},{"line_number":114,"context_line":"                sys.exit(0 if ran \u003c max_count else 1)"},{"line_number":115,"context_line":""},{"line_number":116,"context_line":""},{"line_number":117,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_0390d5eb","line":114,"in_reply_to":"1a6eadb0_0e09f195","updated":"2016-12-19 14:42:57.000000000","message":"I reformatted this section to be more clear.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":153,"context_line":"    parser.add_argument("},{"line_number":154,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":155,"context_line":"        help\u003d_(\"Max number of objects to migrate. The script will not return\""},{"line_number":156,"context_line":"               \" with 0 (success) until all rows are migrated.\"))"},{"line_number":157,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":158,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_aef2bd98","line":155,"updated":"2016-12-12 22:47:30.000000000","message":"s/Max/Maximum/ (cuz we shouldn\u0027t use abbreviations)/","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":152,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":153,"context_line":"    parser.add_argument("},{"line_number":154,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":155,"context_line":"        help\u003d_(\"Max number of objects to migrate. The script will not return\""},{"line_number":156,"context_line":"               \" with 0 (success) until all rows are migrated.\"))"},{"line_number":157,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":158,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_23b5d1cf","line":155,"in_reply_to":"1a6eadb0_aef2bd98","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":153,"context_line":"    parser.add_argument("},{"line_number":154,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":155,"context_line":"        help\u003d_(\"Max number of objects to migrate. The script will not return\""},{"line_number":156,"context_line":"               \" with 0 (success) until all rows are migrated.\"))"},{"line_number":157,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":158,"context_line":""},{"line_number":159,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_2e35cd45","line":156,"updated":"2016-12-12 22:47:30.000000000","message":"s/rows are/objects have been/\n\nMaybe we should mention that it returns 1 otherwise. Not sure if it is worth mentioning 127 for +ve number.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":153,"context_line":"    parser.add_argument("},{"line_number":154,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":155,"context_line":"        help\u003d_(\"Max number of objects to migrate. The script will not return\""},{"line_number":156,"context_line":"               \" with 0 (success) until all rows are migrated.\"))"},{"line_number":157,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":158,"context_line":""},{"line_number":159,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6eadb0_0373754e","line":156,"in_reply_to":"1a6eadb0_2e35cd45","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"ace0262b63d49fe561adddeb3e7e3d5389e41107","unresolved":false,"context_lines":[{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":159,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The script will return\""},{"line_number":160,"context_line":"               \" with 1 error code until all objects have been migrated.\""},{"line_number":161,"context_line":"               \" It will return with code 0 (success) after migrations\""},{"line_number":162,"context_line":"               \" are finished or there is no data to migrate.\"))"},{"line_number":163,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"}],"source_content_type":"text/x-python","patch_set":7,"id":"1a6eadb0_8a45d218","line":160,"range":{"start_line":160,"start_character":0,"end_line":160,"end_character":73},"updated":"2016-12-19 16:10:36.000000000","message":"Looks OK. For the second sentence maybe this could also be an option:\n\"The script will return with 1 error code while there are still pending objects to be migrated.\"","commit_id":"d393b1077e3a158fc463fd2694a62059dc01b1bb"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":82,"context_line":"                break"},{"line_number":83,"context_line":"        return ran"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":86,"context_line":"        \"\"\"Perform online data migrations for the release in batches."},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        When specifying a max_count, only the specified number of migrations"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a6eadb0_3bcddfb7","line":85,"updated":"2016-12-19 23:32:07.000000000","message":"this code is odd (in my opinion). You can\u0027t get the user\u0027s --max_count value from here. This function is being called from L185 with no arguments. You can get the value of max_count via CONF.command.max_count.","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"c5c883f0e3f460a833a4f44fb204e21115da569c","unresolved":false,"context_lines":[{"line_number":82,"context_line":"                break"},{"line_number":83,"context_line":"        return ran"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"    def online_migrations(self, max_count\u003dNone):"},{"line_number":86,"context_line":"        \"\"\"Perform online data migrations for the release in batches."},{"line_number":87,"context_line":""},{"line_number":88,"context_line":"        When specifying a max_count, only the specified number of migrations"}],"source_content_type":"text/x-python","patch_set":8,"id":"ba5201f7_0c12c8b4","line":85,"in_reply_to":"1a6eadb0_3bcddfb7","updated":"2017-01-02 09:12:08.000000000","message":"Done","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":153,"context_line":""},{"line_number":154,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":155,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":156,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":159,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The script will return\""}],"source_content_type":"text/x-python","patch_set":8,"id":"1a6eadb0_571191ae","line":156,"updated":"2016-12-19 23:32:07.000000000","message":"I wonder how much of the help string for max-count should be moved here. It may become more obvious later :)","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":159,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The script will return\""},{"line_number":160,"context_line":"               \" with 1 error code while there are still pending objects to\""},{"line_number":161,"context_line":"               \" be migrated. It will return with code 0 (success) after\""},{"line_number":162,"context_line":"               \" migrations are finished or there is no data to migrate.\"))"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a6eadb0_d7f7618a","line":159,"updated":"2016-12-19 23:32:07.000000000","message":"We should mention the default value for this. Something like \u0027If unspecified, all objects are migrated.\u0027","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":159,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The script will return\""},{"line_number":160,"context_line":"               \" with 1 error code while there are still pending objects to\""},{"line_number":161,"context_line":"               \" be migrated. It will return with code 0 (success) after\""},{"line_number":162,"context_line":"               \" migrations are finished or there is no data to migrate.\"))"},{"line_number":163,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a6eadb0_3c031a11","line":160,"updated":"2016-12-19 23:32:07.000000000","message":"maybe s/The script will return with 1 error code while/The command returns code 1 (error) if/","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":159,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The script will return\""},{"line_number":160,"context_line":"               \" with 1 error code while there are still pending objects to\""},{"line_number":161,"context_line":"               \" be migrated. It will return with code 0 (success) after\""},{"line_number":162,"context_line":"               \" migrations are finished or there is no data to migrate.\"))"},{"line_number":163,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":164,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"1a6eadb0_b7802548","line":161,"updated":"2016-12-19 23:32:07.000000000","message":"s/It will return with/It returns/","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"471a24903046f40ebd71850502a96ee76511090c","unresolved":false,"context_lines":[{"line_number":159,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The script will return\""},{"line_number":160,"context_line":"               \" with 1 error code while there are still pending objects to\""},{"line_number":161,"context_line":"               \" be migrated. It will return with code 0 (success) after\""},{"line_number":162,"context_line":"               \" migrations are finished or there is no data to migrate.\"))"},{"line_number":163,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_migrations)"},{"line_number":164,"context_line":""},{"line_number":165,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"1a6eadb0_7c3592f5","line":162,"updated":"2016-12-19 23:32:07.000000000","message":"s/is/are/  (\u0027data\u0027 is plural)","commit_id":"8d1d0792cdb0abf956ea3568c1e0007139d61108"},{"author":{"_account_id":22724,"name":"Galyna Zholtkevych","email":"galynazholtkevych1991@gmail.com","username":"gzholtkevych"},"change_message_id":"b338f714b0b1fbf3670e4144d4a7d3e8b18d74b6","unresolved":false,"context_lines":[{"line_number":101,"context_line":"            unlimited \u003d False"},{"line_number":102,"context_line":"            if max_count \u003c 1:"},{"line_number":103,"context_line":"                print(_(\u0027Must supply a positive value for max-count.\u0027))"},{"line_number":104,"context_line":"                sys.exit(127)"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            unlimited \u003d True"},{"line_number":107,"context_line":"            max_count \u003d 50"}],"source_content_type":"text/x-python","patch_set":9,"id":"1a6eadb0_7641e162","line":104,"range":{"start_line":104,"start_character":16,"end_line":104,"end_character":29},"updated":"2016-12-21 10:40:37.000000000","message":"127 exit code means that the command is not found (but the command exists), which does not comply meaning of exit codes and may cause misunderstanding. \n\nWDYT about 128 exit code? http://www.tldp.org/LDP/abs/html/exitcodes.html\nIf the user reads that the command is invalid, it is more understandable (IMO) for him","commit_id":"2e487bafa51879a0cc9e11ef79f3d3eb1d0e1dd6"},{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"e58bf2966e56f41102ce614096a6c23a0d86e326","unresolved":false,"context_lines":[{"line_number":101,"context_line":"            unlimited \u003d False"},{"line_number":102,"context_line":"            if max_count \u003c 1:"},{"line_number":103,"context_line":"                print(_(\u0027Must supply a positive value for max-count.\u0027))"},{"line_number":104,"context_line":"                sys.exit(127)"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            unlimited \u003d True"},{"line_number":107,"context_line":"            max_count \u003d 50"}],"source_content_type":"text/x-python","patch_set":9,"id":"1a6eadb0_eafa5376","line":104,"range":{"start_line":104,"start_character":16,"end_line":104,"end_character":29},"in_reply_to":"1a6eadb0_7641e162","updated":"2016-12-21 16:07:19.000000000","message":"Exit codes 128+ should be used for special purposes [1]. IMHO the print message makes clear the reason for exiting with 127. We should not use 0 (all objects migrated) or 1 (pending objects to migrate) though.\n[1] https://www.gnu.org/software/libc/manual/html_node/Exit-Status.html","commit_id":"2e487bafa51879a0cc9e11ef79f3d3eb1d0e1dd6"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2a0ddb1c90d28c43efa585bc135a25e1abd1e188","unresolved":false,"context_lines":[{"line_number":101,"context_line":"            unlimited \u003d False"},{"line_number":102,"context_line":"            if max_count \u003c 1:"},{"line_number":103,"context_line":"                print(_(\u0027Must supply a positive value for max-count.\u0027))"},{"line_number":104,"context_line":"                sys.exit(127)"},{"line_number":105,"context_line":"        else:"},{"line_number":106,"context_line":"            unlimited \u003d True"},{"line_number":107,"context_line":"            max_count \u003d 50"}],"source_content_type":"text/x-python","patch_set":9,"id":"da4df55a_ba2af57c","line":104,"range":{"start_line":104,"start_character":16,"end_line":104,"end_character":29},"in_reply_to":"1a6eadb0_eafa5376","updated":"2016-12-21 20:34:26.000000000","message":"The exit values used here are consistent with what nova\u0027s online_data_migrations command does [1], so even though not ideal, I\u0027m \"happy\" with ironic being consistent with nova.\n\n[1] https://github.com/openstack/nova/blob/6d486ffe464898d040e662c13067cb8ee23fe6bf/nova/cmd/manage.py#L913","commit_id":"2e487bafa51879a0cc9e11ef79f3d3eb1d0e1dd6"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"d00898aedac061d87dd8d3551021fe5f9ba0ac2b","unresolved":false,"context_lines":[{"line_number":152,"context_line":"    parser.set_defaults(func\u003dcommand_object.create_schema)"},{"line_number":153,"context_line":""},{"line_number":154,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":155,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":156,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"}],"source_content_type":"text/x-python","patch_set":9,"id":"1a6eadb0_121fcb08","line":155,"updated":"2016-12-21 14:40:39.000000000","message":"Let\u0027s make this online_data_migrations (plural) to match nova, please.","commit_id":"2e487bafa51879a0cc9e11ef79f3d3eb1d0e1dd6"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2a0ddb1c90d28c43efa585bc135a25e1abd1e188","unresolved":false,"context_lines":[{"line_number":152,"context_line":"    parser.set_defaults(func\u003dcommand_object.create_schema)"},{"line_number":153,"context_line":""},{"line_number":154,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":155,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":156,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"}],"source_content_type":"text/x-python","patch_set":9,"id":"da4df55a_5a34a9dd","line":155,"in_reply_to":"1a6eadb0_121fcb08","updated":"2016-12-21 20:34:26.000000000","message":"+1 (we updated the RFE to reflect this.)","commit_id":"2e487bafa51879a0cc9e11ef79f3d3eb1d0e1dd6"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"b2d8a0f8679045696b8937de2f03191b61c1dd07","unresolved":false,"context_lines":[{"line_number":152,"context_line":"    parser.set_defaults(func\u003dcommand_object.create_schema)"},{"line_number":153,"context_line":""},{"line_number":154,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":155,"context_line":"        \u0027online_data_migration\u0027,"},{"line_number":156,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":157,"context_line":"    parser.add_argument("},{"line_number":158,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"}],"source_content_type":"text/x-python","patch_set":9,"id":"ba5201f7_acd8dcf0","line":155,"in_reply_to":"da4df55a_5a34a9dd","updated":"2017-01-02 09:12:22.000000000","message":"Done","commit_id":"2e487bafa51879a0cc9e11ef79f3d3eb1d0e1dd6"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"b62e520264bd72735b458660f04ccb9154c35c44","unresolved":false,"context_lines":[{"line_number":63,"context_line":""},{"line_number":64,"context_line":"        :param: max_count: maximum number of objects (rows) to migrate."},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"        :returns: The object (rows) migrations count, which is \u003c\u003d max_count."},{"line_number":67,"context_line":"        \"\"\""},{"line_number":68,"context_line":"        ran \u003d 0"},{"line_number":69,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_dcd05556","line":66,"updated":"2017-01-03 12:43:57.000000000","message":"I think that \"Number of migrated rows, \u003c\u003dmax_count\" looks more descriptive","commit_id":"07cbf8aa9a2da86cf82c1c4e68fa18e31863b17b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"2389c88cd1a7edb8ff23a32cf26f2753dc805aa7","unresolved":false,"context_lines":[{"line_number":63,"context_line":""},{"line_number":64,"context_line":"        :param: max_count: maximum number of objects (rows) to migrate."},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"        :returns: The object (rows) migrations count, which is \u003c\u003d max_count."},{"line_number":67,"context_line":"        \"\"\""},{"line_number":68,"context_line":"        ran \u003d 0"},{"line_number":69,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_3808a291","line":66,"in_reply_to":"ba5201f7_dcd05556","updated":"2017-01-10 08:28:31.000000000","message":"Done","commit_id":"07cbf8aa9a2da86cf82c1c4e68fa18e31863b17b"},{"author":{"_account_id":10206,"name":"Madhuri Kumari","email":"madhuri.kumari@intel.com","username":"Madhuri"},"change_message_id":"4e50b275d16f3cb50230aa482efb1db089b4a65a","unresolved":false,"context_lines":[{"line_number":66,"context_line":"        :returns: The object (rows) migrations count, which is \u003c\u003d max_count."},{"line_number":67,"context_line":"        \"\"\""},{"line_number":68,"context_line":"        ran \u003d 0"},{"line_number":69,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":70,"context_line":"            count \u003d max_count - ran"},{"line_number":71,"context_line":"            try:"},{"line_number":72,"context_line":"                found, done \u003d data_migration(count)"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_c2096733","line":69,"range":{"start_line":69,"start_character":30,"end_line":69,"end_character":47},"updated":"2017-01-02 11:25:40.000000000","message":"This is empty set. Where is it populated?","commit_id":"07cbf8aa9a2da86cf82c1c4e68fa18e31863b17b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"2389c88cd1a7edb8ff23a32cf26f2753dc805aa7","unresolved":false,"context_lines":[{"line_number":66,"context_line":"        :returns: The object (rows) migrations count, which is \u003c\u003d max_count."},{"line_number":67,"context_line":"        \"\"\""},{"line_number":68,"context_line":"        ran \u003d 0"},{"line_number":69,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":70,"context_line":"            count \u003d max_count - ran"},{"line_number":71,"context_line":"            try:"},{"line_number":72,"context_line":"                found, done \u003d data_migration(count)"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_def77ff3","line":69,"range":{"start_line":69,"start_character":30,"end_line":69,"end_character":47},"in_reply_to":"ba5201f7_c2096733","updated":"2017-01-10 08:28:31.000000000","message":"I added the first migration, which populates the version column.","commit_id":"07cbf8aa9a2da86cf82c1c4e68fa18e31863b17b"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"b62e520264bd72735b458660f04ccb9154c35c44","unresolved":false,"context_lines":[{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        if max_count is not None:"},{"line_number":105,"context_line":"            unlimited \u003d False"},{"line_number":106,"context_line":"            if max_count \u003c 1:"},{"line_number":107,"context_line":"                print(_(\u0027Must supply a positive value for max-count.\u0027))"},{"line_number":108,"context_line":"                sys.exit(127)"},{"line_number":109,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_bc1631ef","line":106,"updated":"2017-01-03 12:43:57.000000000","message":"I think there\u0027s a mix up of max_count and batch_size values; Running in batches is great in terms of performance, and it should be allowed even if max_count is set. Maybe there should be 2 parameters - batch_size and max_count, where unset max_count would mean unlimited? If batch_size would be greater than max_count it could be set to max_count.\n\nSuch approach would eliminate situations like setting max_count to 10000 which could result in DB\u0027s misbehavior.","commit_id":"07cbf8aa9a2da86cf82c1c4e68fa18e31863b17b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"2389c88cd1a7edb8ff23a32cf26f2753dc805aa7","unresolved":false,"context_lines":[{"line_number":103,"context_line":""},{"line_number":104,"context_line":"        if max_count is not None:"},{"line_number":105,"context_line":"            unlimited \u003d False"},{"line_number":106,"context_line":"            if max_count \u003c 1:"},{"line_number":107,"context_line":"                print(_(\u0027Must supply a positive value for max-count.\u0027))"},{"line_number":108,"context_line":"                sys.exit(127)"},{"line_number":109,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":12,"id":"ba5201f7_2186aeb9","line":106,"in_reply_to":"ba5201f7_bc1631ef","updated":"2017-01-10 08:28:31.000000000","message":"We want to have a syntax compatible with nova. I think we can add this additional parameter later when there is a need from the operators, in a backward compatible way.","commit_id":"07cbf8aa9a2da86cf82c1c4e68fa18e31863b17b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"# NOTE(xek): Perform online data migrations for the release in batches."},{"line_number":36,"context_line":"# Each migration script is a function which takes one argument - max number"},{"line_number":37,"context_line":"# of objects to migrate."},{"line_number":38,"context_line":"ONLINE_MIGRATIONS \u003d ("},{"line_number":39,"context_line":"    dbapi.backfill_version_column,"},{"line_number":40,"context_line":")"}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_81f2d398","line":37,"updated":"2017-01-10 21:56:53.000000000","message":"What does the function return, raise? Looks like it returns a 2-tuple.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"# NOTE(xek): Perform online data migrations for the release in batches."},{"line_number":36,"context_line":"# Each migration script is a function which takes one argument - max number"},{"line_number":37,"context_line":"# of objects to migrate."},{"line_number":38,"context_line":"ONLINE_MIGRATIONS \u003d ("},{"line_number":39,"context_line":"    dbapi.backfill_version_column,"},{"line_number":40,"context_line":")"}],"source_content_type":"text/x-python","patch_set":17,"id":"9a57fde8_e494d6e9","line":37,"in_reply_to":"ba5201f7_81f2d398","updated":"2017-01-12 15:09:13.000000000","message":"updated the comment","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        migration.create_schema()"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    def online_migrations(self):"},{"line_number":61,"context_line":"        self._run_online_migrations(CONF.command.max_count)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def _run_migration(self, max_count):"},{"line_number":64,"context_line":"        \"\"\"Runs the list of migration functions."}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_41e70b12","line":61,"updated":"2017-01-10 21:56:53.000000000","message":"s/CONF/max_count\u003dCONF/","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":58,"context_line":"        migration.create_schema()"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    def online_migrations(self):"},{"line_number":61,"context_line":"        self._run_online_migrations(CONF.command.max_count)"},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"    def _run_migration(self, max_count):"},{"line_number":64,"context_line":"        \"\"\"Runs the list of migration functions."}],"source_content_type":"text/x-python","patch_set":17,"id":"9a57fde8_4449228b","line":61,"in_reply_to":"ba5201f7_41e70b12","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":69,"context_line":""},{"line_number":70,"context_line":"        :param: max_count: maximum number of objects (rows) to migrate."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"        :returns: Number of migrated object (rows), \u003c\u003d max_count."},{"line_number":73,"context_line":"        \"\"\""},{"line_number":74,"context_line":"        ran \u003d 0"},{"line_number":75,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_21b767f6","line":72,"updated":"2017-01-10 21:56:53.000000000","message":"s/object/objects/","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":69,"context_line":""},{"line_number":70,"context_line":"        :param: max_count: maximum number of objects (rows) to migrate."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":"        :returns: Number of migrated object (rows), \u003c\u003d max_count."},{"line_number":73,"context_line":"        \"\"\""},{"line_number":74,"context_line":"        ran \u003d 0"},{"line_number":75,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"}],"source_content_type":"text/x-python","patch_set":17,"id":"9a57fde8_24441e73","line":72,"in_reply_to":"ba5201f7_21b767f6","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ccb6bfedaf7fa5f4e1c32f4800fbe9ada902ec36","unresolved":false,"context_lines":[{"line_number":83,"context_line":""},{"line_number":84,"context_line":"        :returns: Number of migrated objects (rows), \u003c\u003d max_count."},{"line_number":85,"context_line":"        \"\"\""},{"line_number":86,"context_line":"        ran \u003d 0"},{"line_number":87,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":88,"context_line":"            count \u003d max_count - ran"},{"line_number":89,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_33014a06","line":86,"updated":"2017-01-16 21:42:59.000000000","message":"i\u0027m starting to nit now :)\n\ns/ran/migrated/ or num_migrated, num_processed.","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ccb6bfedaf7fa5f4e1c32f4800fbe9ada902ec36","unresolved":false,"context_lines":[{"line_number":87,"context_line":"        for data_migration in ONLINE_MIGRATIONS:"},{"line_number":88,"context_line":"            count \u003d max_count - ran"},{"line_number":89,"context_line":"            try:"},{"line_number":90,"context_line":"                found, done \u003d data_migration(count)"},{"line_number":91,"context_line":"            except Exception:"},{"line_number":92,"context_line":"                print(_(\"Error attempting to run %(migration)s\") %"},{"line_number":93,"context_line":"                      {\u0027migration\u0027: data_migration.__name__})"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_1330cee7","line":90,"updated":"2017-01-16 21:42:59.000000000","message":"nit: we tend to use \u0027found\u0027 as a Boolean. Maybe \u0027total\u0027?","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ccb6bfedaf7fa5f4e1c32f4800fbe9ada902ec36","unresolved":false,"context_lines":[{"line_number":126,"context_line":"                sys.exit(127)"},{"line_number":127,"context_line":"        else:"},{"line_number":128,"context_line":"            unlimited \u003d True"},{"line_number":129,"context_line":"            max_count \u003d 50"},{"line_number":130,"context_line":"            print(_(\u0027Running batches of %i until complete.\u0027) % max_count)"},{"line_number":131,"context_line":""},{"line_number":132,"context_line":"        ran \u003d None"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_589c350f","line":129,"updated":"2017-01-16 21:42:59.000000000","message":"we\u0027re using this cuz nova uses this, right? (Or is there a better reason?) Might be worth adding a comment about it cuz someone is bound to ask later.","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"5d90a8d5ba6092357e38ac86289680bf83f90ffa","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        # NOTE(xek): we have to run this check after updating the schema, since"},{"line_number":49,"context_line":"        # the current release may have updated the models with new fields."},{"line_number":50,"context_line":"        if not dbapi.check_versions():"},{"line_number":51,"context_line":"            print(_(\u0027Database not compatible with the new release, please run\u0027"},{"line_number":52,"context_line":"                    \u0027 online_data_migrations in the previous release before\u0027"},{"line_number":53,"context_line":"                    \u0027 upgrading.\u0027))"},{"line_number":54,"context_line":"            sys.exit(1)"}],"source_content_type":"text/x-python","patch_set":31,"id":"5a3905b3_d5e52238","line":51,"updated":"2017-01-23 12:53:51.000000000","message":"Nit: s/not/is not/, and maybe s/Database/The database/ or \u0027the %(db_name)s is not compatible... \n\nI feel like we can provide more information to an operator.  If there is a way to indicate what the new and old versions are, that would be awesome++","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d4f438b7c75328f804c5adf232bdb2c2323664f","unresolved":false,"context_lines":[{"line_number":48,"context_line":"        # NOTE(xek): we have to run this check after updating the schema, since"},{"line_number":49,"context_line":"        # the current release may have updated the models with new fields."},{"line_number":50,"context_line":"        if not dbapi.check_versions():"},{"line_number":51,"context_line":"            print(_(\u0027Database not compatible with the new release, please run\u0027"},{"line_number":52,"context_line":"                    \u0027 online_data_migrations in the previous release before\u0027"},{"line_number":53,"context_line":"                    \u0027 upgrading.\u0027))"},{"line_number":54,"context_line":"            sys.exit(1)"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a1ced50_716c8435","line":51,"in_reply_to":"5a3905b3_d5e52238","updated":"2017-03-23 01:27:03.000000000","message":"yes, it would be awesome. I think we can figure out the new/current version; I don\u0027t know how we could figure out the old version -- we could guess by looking at the data in the DB? (ewww)","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"0c93cac921a16664e9be1481f3f3c1a579120287","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                                       \u0027migration\u0027: data_migration.__name__,"},{"line_number":100,"context_line":"                                       \u0027done\u0027: done})"},{"line_number":101,"context_line":"            ran +\u003d done"},{"line_number":102,"context_line":"            if ran \u003e\u003d max_count:"},{"line_number":103,"context_line":"                break"},{"line_number":104,"context_line":"        return ran"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":31,"id":"1a430d35_68cd8384","line":102,"range":{"start_line":102,"start_character":19,"end_line":102,"end_character":21},"updated":"2017-02-07 18:41:26.000000000","message":"L140 should be \u003c\u003d because of this\n\nwe can break when ran \u003d\u003d max_count, and then we\u0027d exit 1 in error","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"e08a01d18f10f8fa2ccc1fb85d0751387d3b82ea","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                                       \u0027migration\u0027: data_migration.__name__,"},{"line_number":100,"context_line":"                                       \u0027done\u0027: done})"},{"line_number":101,"context_line":"            ran +\u003d done"},{"line_number":102,"context_line":"            if ran \u003e\u003d max_count:"},{"line_number":103,"context_line":"                break"},{"line_number":104,"context_line":"        return ran"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":31,"id":"1a430d35_9e9660ee","line":102,"range":{"start_line":102,"start_character":19,"end_line":102,"end_character":21},"in_reply_to":"1a430d35_68cd8384","updated":"2017-02-07 22:53:30.000000000","message":"I feel like \u003e\u003d makes sense here, since if somehow done returns a larger number than is submitted in (which seems unlikely... but still), then this will loop again and never exit.","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d4f438b7c75328f804c5adf232bdb2c2323664f","unresolved":false,"context_lines":[{"line_number":99,"context_line":"                                       \u0027migration\u0027: data_migration.__name__,"},{"line_number":100,"context_line":"                                       \u0027done\u0027: done})"},{"line_number":101,"context_line":"            ran +\u003d done"},{"line_number":102,"context_line":"            if ran \u003e\u003d max_count:"},{"line_number":103,"context_line":"                break"},{"line_number":104,"context_line":"        return ran"},{"line_number":105,"context_line":""}],"source_content_type":"text/x-python","patch_set":31,"id":"1a1ced50_71256407","line":102,"range":{"start_line":102,"start_character":19,"end_line":102,"end_character":21},"in_reply_to":"1a430d35_9e9660ee","updated":"2017-03-23 01:27:03.000000000","message":"I\u0027m fine either way. Probably ran \u003d\u003d max_count is sufficient, but I\u0027m not yet familiar enough with the code to know whether there might be some off-by-x issues.","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":13295,"name":"Mario Villaplana","email":"mario.villaplana@gmail.com","username":"mariojv"},"change_message_id":"0c93cac921a16664e9be1481f3f3c1a579120287","unresolved":false,"context_lines":[{"line_number":137,"context_line":"        else:"},{"line_number":138,"context_line":"            ran \u003d self._run_migration(max_count)"},{"line_number":139,"context_line":"            # exit with proper value when run in batch mode"},{"line_number":140,"context_line":"            sys.exit(0 if ran \u003c max_count else 1)"},{"line_number":141,"context_line":""},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a430d35_48228753","line":140,"range":{"start_line":140,"start_character":30,"end_line":140,"end_character":31},"updated":"2017-02-07 18:41:26.000000000","message":"this should be \u003c\u003d, right?\n\nalso, a unit test for that edge case would be good","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d4f438b7c75328f804c5adf232bdb2c2323664f","unresolved":false,"context_lines":[{"line_number":137,"context_line":"        else:"},{"line_number":138,"context_line":"            ran \u003d self._run_migration(max_count)"},{"line_number":139,"context_line":"            # exit with proper value when run in batch mode"},{"line_number":140,"context_line":"            sys.exit(0 if ran \u003c max_count else 1)"},{"line_number":141,"context_line":""},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a1ced50_66392cd7","line":140,"range":{"start_line":140,"start_character":30,"end_line":140,"end_character":31},"in_reply_to":"1a430d35_1e8b50c4","updated":"2017-03-23 01:27:03.000000000","message":"No, it should be \u003c. It is odd; let me think about a different way that makes it clearer. It is \u003c because if max_count objects had been migrated, it is possible that there are more objects that *need* to be migrated. Only when \u003c max_count objects were migrated, do we know that there are no more. (because if there had been more, then ran \u003d\u003d max_count.)","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"e08a01d18f10f8fa2ccc1fb85d0751387d3b82ea","unresolved":false,"context_lines":[{"line_number":137,"context_line":"        else:"},{"line_number":138,"context_line":"            ran \u003d self._run_migration(max_count)"},{"line_number":139,"context_line":"            # exit with proper value when run in batch mode"},{"line_number":140,"context_line":"            sys.exit(0 if ran \u003c max_count else 1)"},{"line_number":141,"context_line":""},{"line_number":142,"context_line":""},{"line_number":143,"context_line":"def add_command_parsers(subparsers):"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a430d35_1e8b50c4","line":140,"range":{"start_line":140,"start_character":30,"end_line":140,"end_character":31},"in_reply_to":"1a430d35_48228753","updated":"2017-02-07 22:53:30.000000000","message":"Good catch, +1","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":36,"context_line":"# NOTE(xek): Perform online data migrations for the release, in batches."},{"line_number":37,"context_line":"# Each migration script is a function which takes one argument -- max number"},{"line_number":38,"context_line":"# of objects to migrate, and returns a 2-tuple (the total amount of objects"},{"line_number":39,"context_line":"# that need to be migrated at the start of the procedure, the amount migrated)."},{"line_number":40,"context_line":"# If a release doesn\u0027t require any data migrations, this will be an empty"},{"line_number":41,"context_line":"# tuple."},{"line_number":42,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_9502966e","line":39,"updated":"2017-03-27 20:37:39.000000000","message":"It kind of looks like you wrote this as a tuple itself, but I\u0027d appreciate an \"and\" in there.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":36,"context_line":"# NOTE(xek): Perform online data migrations for the release, in batches."},{"line_number":37,"context_line":"# Each migration script is a function which takes one argument -- max number"},{"line_number":38,"context_line":"# of objects to migrate, and returns a 2-tuple (the total amount of objects"},{"line_number":39,"context_line":"# that need to be migrated at the start of the procedure, the amount migrated)."},{"line_number":40,"context_line":"# If a release doesn\u0027t require any data migrations, this will be an empty"},{"line_number":41,"context_line":"# tuple."},{"line_number":42,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_ce25040b","line":39,"in_reply_to":"ffe62b97_9502966e","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":38,"context_line":"# of objects to migrate, and returns a 2-tuple (the total amount of objects"},{"line_number":39,"context_line":"# that need to be migrated at the start of the procedure, the amount migrated)."},{"line_number":40,"context_line":"# If a release doesn\u0027t require any data migrations, this will be an empty"},{"line_number":41,"context_line":"# tuple."},{"line_number":42,"context_line":"#"},{"line_number":43,"context_line":"# Example of a function docstring:"},{"line_number":44,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_f5de820f","line":41,"updated":"2017-03-27 20:37:39.000000000","message":"An empty tuple as in no values (,) and thus not a 2-tuple, or an empty tuple as in a 2-tuple with zero-values (0, 0)?","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":38,"context_line":"# of objects to migrate, and returns a 2-tuple (the total amount of objects"},{"line_number":39,"context_line":"# that need to be migrated at the start of the procedure, the amount migrated)."},{"line_number":40,"context_line":"# If a release doesn\u0027t require any data migrations, this will be an empty"},{"line_number":41,"context_line":"# tuple."},{"line_number":42,"context_line":"#"},{"line_number":43,"context_line":"# Example of a function docstring:"},{"line_number":44,"context_line":"#"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_4e31f459","line":41,"in_reply_to":"ffe62b97_f5de820f","updated":"2017-03-28 18:36:48.000000000","message":"Thx, I clarified.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":47,"context_line":"#"},{"line_number":48,"context_line":"#        :param max_count: The maximum number of objects to migrate. Must be"},{"line_number":49,"context_line":"#                          \u003e\u003d 0. If zero, all the objects will be migrated."},{"line_number":50,"context_line":"#        :returns: A 2-tuple, 1. the total number of objects that need to be"},{"line_number":51,"context_line":"#                  migrated (at the beginning of this call) and 2. the number"},{"line_number":52,"context_line":"#                  of migrated objects."},{"line_number":53,"context_line":"#        \"\"\""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_d51a5eca","line":50,"updated":"2017-03-27 20:37:39.000000000","message":"The inline numbered list in this example makes it difficult to read, as I read the first \"1.\" as the end of a nonsense sentence. If you just drop the numbering, in favor of the word \"including\", then I think the intent will be much more clear.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":47,"context_line":"#"},{"line_number":48,"context_line":"#        :param max_count: The maximum number of objects to migrate. Must be"},{"line_number":49,"context_line":"#                          \u003e\u003d 0. If zero, all the objects will be migrated."},{"line_number":50,"context_line":"#        :returns: A 2-tuple, 1. the total number of objects that need to be"},{"line_number":51,"context_line":"#                  migrated (at the beginning of this call) and 2. the number"},{"line_number":52,"context_line":"#                  of migrated objects."},{"line_number":53,"context_line":"#        \"\"\""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_cef7448b","line":50,"in_reply_to":"ffe62b97_d51a5eca","updated":"2017-03-28 18:36:48.000000000","message":"Sorry for being the guinea pig, I wasn\u0027t sure what the best way was to represent the tuple information. Let me know what you think now.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":108,"context_line":"        for migration_func in ONLINE_MIGRATIONS:"},{"line_number":109,"context_line":"            num_to_migrate \u003d max_count - total_migrated"},{"line_number":110,"context_line":"            try:"},{"line_number":111,"context_line":"                total_to_do, num_migrated \u003d migration_func(num_to_migrate)"},{"line_number":112,"context_line":"            except Exception as e:"},{"line_number":113,"context_line":"                sys.stderr.write(_(\"Error while running %(migration)s(%(n)i): \""},{"line_number":114,"context_line":"                                   \"%(err)s.\\n\") %"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_78e829e1","line":111,"updated":"2017-03-27 20:37:39.000000000","message":"Why not just pass max_count here? Could new objects be created between the time this calculation occurs and the time the actual migrations are performed, potentially allowing this method to return successfully without realizing that there are new objects that need to be migrated?","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":108,"context_line":"        for migration_func in ONLINE_MIGRATIONS:"},{"line_number":109,"context_line":"            num_to_migrate \u003d max_count - total_migrated"},{"line_number":110,"context_line":"            try:"},{"line_number":111,"context_line":"                total_to_do, num_migrated \u003d migration_func(num_to_migrate)"},{"line_number":112,"context_line":"            except Exception as e:"},{"line_number":113,"context_line":"                sys.stderr.write(_(\"Error while running %(migration)s(%(n)i): \""},{"line_number":114,"context_line":"                                   \"%(err)s.\\n\") %"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_23b00c43","line":111,"in_reply_to":"ffe62b97_78e829e1","updated":"2017-03-28 18:36:48.000000000","message":"max_count is the maximum number of objects to migrate (in total, not per migration function). Say max_count\u003d100 and for the first migration_func1, 75 objects were migrated. If this is second migration_func2, we only want to migrate at most 25 objects. If I pass in max_count, it could migrate 100 which is too much.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":116,"context_line":"                                  \u0027n\u0027: num_to_migrate, \u0027err\u0027: e})"},{"line_number":117,"context_line":"                raise"},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"            if total_to_do \u003e 0:"},{"line_number":120,"context_line":"                print(_(\u0027For %(migration)s(), %(total)i objects need to be \u0027"},{"line_number":121,"context_line":"                        \u0027migrated; of that, %(done)i were migrated.\u0027) %"},{"line_number":122,"context_line":"                      {\u0027migration\u0027: migration_func.__name__,"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_35a98a23","line":119,"updated":"2017-03-27 20:37:39.000000000","message":"I\u0027m not sure I understand why you would want to suppress this output when there are no migrations remaining? Wouldn\u0027t you still want to know how many objects were migrated?","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":116,"context_line":"                                  \u0027n\u0027: num_to_migrate, \u0027err\u0027: e})"},{"line_number":117,"context_line":"                raise"},{"line_number":118,"context_line":""},{"line_number":119,"context_line":"            if total_to_do \u003e 0:"},{"line_number":120,"context_line":"                print(_(\u0027For %(migration)s(), %(total)i objects need to be \u0027"},{"line_number":121,"context_line":"                        \u0027migrated; of that, %(done)i were migrated.\u0027) %"},{"line_number":122,"context_line":"                      {\u0027migration\u0027: migration_func.__name__,"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_78a242b0","line":119,"in_reply_to":"ffe62b97_35a98a23","updated":"2017-03-28 18:36:48.000000000","message":"Well, there were 0 objects that needed to be migrated, so 0 objects were migrated. I don\u0027t care either way, so I\u0027ll print these out too.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":118,"context_line":""},{"line_number":119,"context_line":"            if total_to_do \u003e 0:"},{"line_number":120,"context_line":"                print(_(\u0027For %(migration)s(), %(total)i objects need to be \u0027"},{"line_number":121,"context_line":"                        \u0027migrated; of that, %(done)i were migrated.\u0027) %"},{"line_number":122,"context_line":"                      {\u0027migration\u0027: migration_func.__name__,"},{"line_number":123,"context_line":"                       \u0027total\u0027: total_to_do,"},{"line_number":124,"context_line":"                       \u0027done\u0027: num_migrated})"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_d5f6de63","line":121,"updated":"2017-03-27 20:37:39.000000000","message":"The language here makes perfect sense on it\u0027s own, and I believe would appear as:\n\n  For backfill_version_column(), 87 objects need to be migrated; of that, 25 were migrated.\n  For backfill_version_column(), 62 objects need to be migrated; of that, 25 were migrated.\n  For backfill_version_column(), 37 objects need to be migrated; of that, 25 were migrated.\n  For backfill_version_column(), 12 objects need to be migrated; of that, 12 were migrated.\n\nBut I think it could be simplified to just:\n\n  %(migration)s() migrated %(done)i of %(total)i objects.\n\nSo, the same runs would appear as:\n\n  backfill_version_column() migrated 25 of 87 objects.\n  backfill_version_column() migrated 25 of 62 objects.\n  backfill_version_column() migrated 25 of 37 objects.\n  backfill_version_column() migrated 12 of 12 objects.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":118,"context_line":""},{"line_number":119,"context_line":"            if total_to_do \u003e 0:"},{"line_number":120,"context_line":"                print(_(\u0027For %(migration)s(), %(total)i objects need to be \u0027"},{"line_number":121,"context_line":"                        \u0027migrated; of that, %(done)i were migrated.\u0027) %"},{"line_number":122,"context_line":"                      {\u0027migration\u0027: migration_func.__name__,"},{"line_number":123,"context_line":"                       \u0027total\u0027: total_to_do,"},{"line_number":124,"context_line":"                       \u0027done\u0027: num_migrated})"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_d8ceee58","line":121,"in_reply_to":"ffe62b97_d5f6de63","updated":"2017-03-28 18:36:48.000000000","message":"nice.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                #   2. whether there are other migration functions and whether"},{"line_number":133,"context_line":"                #      they need to do any object migrations (not so easy to"},{"line_number":134,"context_line":"                #      check)"},{"line_number":135,"context_line":"                finished_migrating \u003d False"},{"line_number":136,"context_line":"                break"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":"        return finished_migrating"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_4ce4833c","line":135,"updated":"2017-03-27 22:38:49.000000000","message":"You could eliminate this variable by just returning False here.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                #   2. whether there are other migration functions and whether"},{"line_number":133,"context_line":"                #      they need to do any object migrations (not so easy to"},{"line_number":134,"context_line":"                #      check)"},{"line_number":135,"context_line":"                finished_migrating \u003d False"},{"line_number":136,"context_line":"                break"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":"        return finished_migrating"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_78636243","line":135,"in_reply_to":"ffe62b97_4ce4833c","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":135,"context_line":"                finished_migrating \u003d False"},{"line_number":136,"context_line":"                break"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":"        return finished_migrating"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    def _run_online_data_migrations(self, max_count\u003dNone):"},{"line_number":141,"context_line":"        \"\"\"Perform online data migrations for the release, in batches."}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_0cd43b47","line":138,"updated":"2017-03-27 22:38:49.000000000","message":"This appears to always be true at this point, so just return True?","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":135,"context_line":"                finished_migrating \u003d False"},{"line_number":136,"context_line":"                break"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":"        return finished_migrating"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"    def _run_online_data_migrations(self, max_count\u003dNone):"},{"line_number":141,"context_line":"        \"\"\"Perform online data migrations for the release, in batches."}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_9870660a","line":138,"in_reply_to":"ffe62b97_0cd43b47","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        \"\"\""},{"line_number":157,"context_line":"        finished_migrating \u003d False"},{"line_number":158,"context_line":"        if max_count is None:"},{"line_number":159,"context_line":"            max_count \u003d 50"},{"line_number":160,"context_line":"            print(_(\u0027Running batches of %i until migrations have been \u0027"},{"line_number":161,"context_line":"                    \u0027completed.\u0027) % max_count)"},{"line_number":162,"context_line":"            while not finished_migrating:"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_d8be15b3","line":159,"updated":"2017-03-27 20:37:39.000000000","message":"Shouldn\u0027t this just be the default value in the option configuration, and thus become non-optional here?","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":156,"context_line":"        \"\"\""},{"line_number":157,"context_line":"        finished_migrating \u003d False"},{"line_number":158,"context_line":"        if max_count is None:"},{"line_number":159,"context_line":"            max_count \u003d 50"},{"line_number":160,"context_line":"            print(_(\u0027Running batches of %i until migrations have been \u0027"},{"line_number":161,"context_line":"                    \u0027completed.\u0027) % max_count)"},{"line_number":162,"context_line":"            while not finished_migrating:"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_d52237b9","line":159,"in_reply_to":"ffe62b97_d8be15b3","updated":"2017-03-28 18:36:48.000000000","message":"No, max_count is the maximum number of objects to migrate in total, not per migration function. I\u0027ll try to clarify that.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":165,"context_line":"            sys.exit(0)"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"        if max_count \u003c 1:"},{"line_number":168,"context_line":"            sys.stderr.write(_(\u0027\"max-count\" must be a positive value.\\n\u0027))"},{"line_number":169,"context_line":"            sys.exit(127)"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"        finished_migrating \u003d self._run_migration_functions(max_count)"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_18991d78","line":168,"updated":"2017-03-27 20:37:39.000000000","message":".\n\n  print(\u0027\"max-count\" must be a positive value.\u0027, file\u003dsys.stderr)","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":165,"context_line":"            sys.exit(0)"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"        if max_count \u003c 1:"},{"line_number":168,"context_line":"            sys.stderr.write(_(\u0027\"max-count\" must be a positive value.\\n\u0027))"},{"line_number":169,"context_line":"            sys.exit(127)"},{"line_number":170,"context_line":""},{"line_number":171,"context_line":"        finished_migrating \u003d self._run_migration_functions(max_count)"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_50574a59","line":168,"in_reply_to":"ffe62b97_18991d78","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"61d8166773db36fa2e15b2ff9cca4fa1a355d89a","unresolved":false,"context_lines":[{"line_number":214,"context_line":"        \u0027online_data_migrations\u0027,"},{"line_number":215,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":216,"context_line":"    parser.add_argument("},{"line_number":217,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":218,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The command returns code\""},{"line_number":219,"context_line":"               \" 1 (error) if there are still pending objects to\""},{"line_number":220,"context_line":"               \" be migrated. It returns code 0 (success) after\""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_18d59de5","line":217,"updated":"2017-03-27 20:37:39.000000000","message":"I beleive if you specify:\n\n  min\u003d1, default\u003d50,\n\nThen you don\u0027t have to do your own input validation, etc.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":214,"context_line":"        \u0027online_data_migrations\u0027,"},{"line_number":215,"context_line":"        help\u003d_(\"Perform online data migrations for the release, in batches.\"))"},{"line_number":216,"context_line":"    parser.add_argument("},{"line_number":217,"context_line":"        \u0027--max-count\u0027, metavar\u003d\u0027\u003cnumber\u003e\u0027, dest\u003d\u0027max_count\u0027, type\u003dint,"},{"line_number":218,"context_line":"        help\u003d_(\"Maximum number of objects to migrate. The command returns code\""},{"line_number":219,"context_line":"               \" 1 (error) if there are still pending objects to\""},{"line_number":220,"context_line":"               \" be migrated. It returns code 0 (success) after\""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_75612ba9","line":217,"in_reply_to":"ffe62b97_18d59de5","updated":"2017-03-28 18:36:48.000000000","message":"min doesn\u0027t work. And the default is not 50, it is \u0027all\u0027 objects, whatever that number is.)","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":219,"context_line":"               \" 1 (error) if there are still pending objects to\""},{"line_number":220,"context_line":"               \" be migrated. It returns code 0 (success) after\""},{"line_number":221,"context_line":"               \" migrations are finished or there are no data to migrate.\""},{"line_number":222,"context_line":"               \" If unspecified, all objects are migrated.\"))"},{"line_number":223,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_data_migrations)"},{"line_number":224,"context_line":""},{"line_number":225,"context_line":""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_0cd55b1c","line":222,"updated":"2017-03-27 22:38:49.000000000","message":"Most of this text belongs with the command help in L215, not with this specific option. In other words, the *option* doesn\u0027t have return codes or it\u0027s own behaviors -- the command does.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":219,"context_line":"               \" 1 (error) if there are still pending objects to\""},{"line_number":220,"context_line":"               \" be migrated. It returns code 0 (success) after\""},{"line_number":221,"context_line":"               \" migrations are finished or there are no data to migrate.\""},{"line_number":222,"context_line":"               \" If unspecified, all objects are migrated.\"))"},{"line_number":223,"context_line":"    parser.set_defaults(func\u003dcommand_object.online_data_migrations)"},{"line_number":224,"context_line":""},{"line_number":225,"context_line":""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_35c963ab","line":222,"in_reply_to":"ffe62b97_0cd55b1c","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"36484620847e51f730da24e0e331395e8d8eb518","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                     \u0027total\u0027: total_to_do,"},{"line_number":122,"context_line":"                     \u0027done\u0027: num_migrated})"},{"line_number":123,"context_line":"            total_migrated +\u003d num_migrated"},{"line_number":124,"context_line":"            if total_migrated \u003e\u003d max_count:"},{"line_number":125,"context_line":"                # NOTE(rloo). There is no look-ahead. All we know is that we\u0027ve"},{"line_number":126,"context_line":"                # migrated max_count. It is possible that the migrations are"},{"line_number":127,"context_line":"                # done and that there aren\u0027t any more to migrate after this,"}],"source_content_type":"text/x-python","patch_set":43,"id":"ffe62b97_2ddc64e2","line":124,"range":{"start_line":124,"start_character":30,"end_line":124,"end_character":32},"updated":"2017-03-28 23:24:48.000000000","message":"should this be \u0027\u003c\u0027, otherwise if total_migrated \u003e\u003d max_count that means it has migrated all rows and so should return true?","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"},{"author":{"_account_id":19593,"name":"Anup Navare","email":"anup.d.navare@intel.com","username":"anup"},"change_message_id":"afef51d015dc78a73139e920e9d0d98d5db80610","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                     \u0027total\u0027: total_to_do,"},{"line_number":122,"context_line":"                     \u0027done\u0027: num_migrated})"},{"line_number":123,"context_line":"            total_migrated +\u003d num_migrated"},{"line_number":124,"context_line":"            if total_migrated \u003e\u003d max_count:"},{"line_number":125,"context_line":"                # NOTE(rloo). There is no look-ahead. All we know is that we\u0027ve"},{"line_number":126,"context_line":"                # migrated max_count. It is possible that the migrations are"},{"line_number":127,"context_line":"                # done and that there aren\u0027t any more to migrate after this,"}],"source_content_type":"text/x-python","patch_set":43,"id":"ffe62b97_3a86b5ba","line":124,"range":{"start_line":124,"start_character":30,"end_line":124,"end_character":32},"in_reply_to":"ffe62b97_0ac4e3f3","updated":"2017-03-29 17:13:39.000000000","message":"I get it, but docstring suggests the function returns True if all migrations are done and False otherwise, so by that i thought it meant return False until the total_migrated don\u0027t reach max_count. May be it\u0027s just me but i feel it can be re-worded to \"return false if count exceeds max_count\" or something similar, wdyt?","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"58144913e246e7950e40eed9dd5bc5d0bf4cc8ea","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                     \u0027total\u0027: total_to_do,"},{"line_number":122,"context_line":"                     \u0027done\u0027: num_migrated})"},{"line_number":123,"context_line":"            total_migrated +\u003d num_migrated"},{"line_number":124,"context_line":"            if total_migrated \u003e\u003d max_count:"},{"line_number":125,"context_line":"                # NOTE(rloo). There is no look-ahead. All we know is that we\u0027ve"},{"line_number":126,"context_line":"                # migrated max_count. It is possible that the migrations are"},{"line_number":127,"context_line":"                # done and that there aren\u0027t any more to migrate after this,"}],"source_content_type":"text/x-python","patch_set":43,"id":"ffe62b97_0ac4e3f3","line":124,"range":{"start_line":124,"start_character":30,"end_line":124,"end_character":32},"in_reply_to":"ffe62b97_2ddc64e2","updated":"2017-03-29 00:47:19.000000000","message":"No, the code is correct. (In fact, \u003d\u003d is probably correct but I wanted to err on the side of \u003e\u003d, just in case). I only want to migrate AT MOST max_count objects. So if total_migrated (the total number of objects migrated so far) is \u003e\u003d max_count, we should stop.\n\nDoes that make sense? How can I make the code clearer?","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2604c8fcc67781dd0b8fbc9ab185c4e324ab029d","unresolved":false,"context_lines":[{"line_number":121,"context_line":"                     \u0027total\u0027: total_to_do,"},{"line_number":122,"context_line":"                     \u0027done\u0027: num_migrated})"},{"line_number":123,"context_line":"            total_migrated +\u003d num_migrated"},{"line_number":124,"context_line":"            if total_migrated \u003e\u003d max_count:"},{"line_number":125,"context_line":"                # NOTE(rloo). There is no look-ahead. All we know is that we\u0027ve"},{"line_number":126,"context_line":"                # migrated max_count. It is possible that the migrations are"},{"line_number":127,"context_line":"                # done and that there aren\u0027t any more to migrate after this,"}],"source_content_type":"text/x-python","patch_set":43,"id":"bff0334d_e187eb60","line":124,"range":{"start_line":124,"start_character":30,"end_line":124,"end_character":32},"in_reply_to":"ffe62b97_3a86b5ba","updated":"2017-04-08 03:46:40.000000000","message":"I modified the docstring and the comment below. Let me know if it still isn\u0027t clear and what might help.","commit_id":"88aa47bd0296b09039c0117259128a7f6c1ff9a2"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"5dc092ff6047be8eabcd1a410faefd6eb917b892","unresolved":false,"context_lines":[{"line_number":102,"context_line":"        :param: max_count: the maximum number of objects (rows) to migrate;"},{"line_number":103,"context_line":"            a value \u003e\u003d 1."},{"line_number":104,"context_line":"        :raises: Exception from the migration function"},{"line_number":105,"context_line":"        :returns: False if max_count objects have been migrated (since at that"},{"line_number":106,"context_line":"            point, it is unknown whether all migrations are done). Returns"},{"line_number":107,"context_line":"            True if migrations are all done (i.e. fewer than max_count objects"},{"line_number":108,"context_line":"            were migrated when the migrations are done)."}],"source_content_type":"text/x-python","patch_set":45,"id":"bff0334d_6253ab18","line":105,"updated":"2017-04-10 23:38:48.000000000","message":"Now it got really complex. I appreciate the content here, since it described what\u0027s going on pretty well.\nHow about starting with one short sentence \"Boolean value indicating if migrations are completed. \", and then further explanation of True and False conditions?","commit_id":"45b443cd1789c1de32d35a5eaeddd9bb9ea467a9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"6b3e5079641e8ce84c197229b1c863ec324b876b","unresolved":false,"context_lines":[{"line_number":102,"context_line":"        :param: max_count: the maximum number of objects (rows) to migrate;"},{"line_number":103,"context_line":"            a value \u003e\u003d 1."},{"line_number":104,"context_line":"        :raises: Exception from the migration function"},{"line_number":105,"context_line":"        :returns: False if max_count objects have been migrated (since at that"},{"line_number":106,"context_line":"            point, it is unknown whether all migrations are done). Returns"},{"line_number":107,"context_line":"            True if migrations are all done (i.e. fewer than max_count objects"},{"line_number":108,"context_line":"            were migrated when the migrations are done)."}],"source_content_type":"text/x-python","patch_set":45,"id":"7ffa3b31_083828d1","line":105,"in_reply_to":"bff0334d_6253ab18","updated":"2017-04-14 03:35:07.000000000","message":"Done","commit_id":"45b443cd1789c1de32d35a5eaeddd9bb9ea467a9"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"568a331f72f81331a4251974953e8bbeb8c185a1","unresolved":false,"context_lines":[{"line_number":59,"context_line":"#        \"\"\""},{"line_number":60,"context_line":"ONLINE_MIGRATIONS \u003d ("},{"line_number":61,"context_line":"    # Added in Pike"},{"line_number":62,"context_line":"    dbapi.backfill_version_column,"},{"line_number":63,"context_line":")"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":52,"id":"7f231b9d_5c950786","line":62,"updated":"2017-06-16 17:16:02.000000000","message":"Should this be deleted in the Queens cycle?","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"3d288df4e44b595a3bbbf54d24ef7ae66e54b2ee","unresolved":false,"context_lines":[{"line_number":59,"context_line":"#        \"\"\""},{"line_number":60,"context_line":"ONLINE_MIGRATIONS \u003d ("},{"line_number":61,"context_line":"    # Added in Pike"},{"line_number":62,"context_line":"    dbapi.backfill_version_column,"},{"line_number":63,"context_line":")"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":52,"id":"7f231b9d_769d53ba","line":62,"in_reply_to":"7f231b9d_5c950786","updated":"2017-06-19 16:18:18.000000000","message":"Good question. i notice in nova, that they leave them all. i am wondering whether leaving them in would help with operators wanting to upgrade/skip more than one release at a time. (Not sure though and it\u0027d be a cold upgrade).\n\nSo i was hedging my bets and not being explicit yet about whether/when we want to delete it, although I may have left comments in the code about when they can be deleted so there may be some inconsistency here... I will check.","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4c4eb64d3bdfc09b6a56570a6a24dcf299cef77f","unresolved":false,"context_lines":[{"line_number":59,"context_line":"#        \"\"\""},{"line_number":60,"context_line":"ONLINE_MIGRATIONS \u003d ("},{"line_number":61,"context_line":"    # Added in Pike"},{"line_number":62,"context_line":"    dbapi.backfill_version_column,"},{"line_number":63,"context_line":")"},{"line_number":64,"context_line":""},{"line_number":65,"context_line":""}],"source_content_type":"text/x-python","patch_set":52,"id":"5f201791_28552651","line":62,"in_reply_to":"7f231b9d_769d53ba","updated":"2017-06-20 21:42:51.000000000","message":"I thought about it and yes, we should delete it.","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":81,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":82,"context_line":"        # NOTE(xek): we have to run this check after updating the schema, since"},{"line_number":83,"context_line":"        # the current release may have updated the models with new fields."},{"line_number":84,"context_line":"        self._check_versions()"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def revision(self):"},{"line_number":87,"context_line":"        migration.revision(CONF.command.message, CONF.command.autogenerate)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_c3f790f5","line":84,"updated":"2017-07-24 12:28:48.000000000","message":"Not sure I get why we need to check this. The error will be shown if we try to migrate for more than one release? This could mean that one of the columns could be dropped, and the online migrations won\u0027t pass. Otherwise, this check should always succeed.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"97a60b32a1937a22ca93ba61c6fc95d8ce9ebd62","unresolved":false,"context_lines":[{"line_number":81,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":82,"context_line":"        # NOTE(xek): we have to run this check after updating the schema, since"},{"line_number":83,"context_line":"        # the current release may have updated the models with new fields."},{"line_number":84,"context_line":"        self._check_versions()"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def revision(self):"},{"line_number":87,"context_line":"        migration.revision(CONF.command.message, CONF.command.autogenerate)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_f30d9135","line":84,"in_reply_to":"ff346bd7_02232107","updated":"2017-07-25 21:55:25.000000000","message":"So we want to do the check *before* the upgrade.\n\nArgh. The problem is that the check is done by using the *version* column. Which doesn\u0027t exist yet :-(. I\u0027ve commented it out. Alternatively, I could remove the check and add it in Queens, but since it is written, tested, and reviewed by some people, it seems better to just comment it out. (And yeah, less work for me too!)","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":81,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":82,"context_line":"        # NOTE(xek): we have to run this check after updating the schema, since"},{"line_number":83,"context_line":"        # the current release may have updated the models with new fields."},{"line_number":84,"context_line":"        self._check_versions()"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def revision(self):"},{"line_number":87,"context_line":"        migration.revision(CONF.command.message, CONF.command.autogenerate)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_d9e1b200","line":84,"in_reply_to":"ff346bd7_c3f790f5","updated":"2017-07-24 21:16:48.000000000","message":"Let\u0027s say we have 3 releases, v1, v2, v3. Running v1, upgrade to v2 via new rolling upgrades process [1], EXCEPT they didn\u0027t do step 7 (\u0027ironic-dbsync online_data_migration\u0027). Now they try to upgrade to v3; they get the new source code, and run \u0027ironic-dbsync upgrade\u0027. This check should fail. if e.g. there are any objects in the DB with (old) versions from v1 that are not supported in v2.\n\nIf a column (an object field) was dropped, the object itself would still exist but with a different version, right? I think that would be supported with this mechanism? (What scenario were you thinking of?). If e.g. we have ObjectFoo v10 in v1; deprecated column in Foo v11 in v2, and deleted column in Foo v12 in v3, if \u0027ironic-dbsync online_data_migration\u0027 wasn\u0027t called as described above, this would error if there was a Foo in v10.\n\n[1] http://specs.openstack.org/openstack/ironic-specs/specs/not-implemented/support-rolling-upgrade.html#rolling-upgrade-process","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3c7ce61e5f29404fdb67ca8043a5bb9d870ecbc4","unresolved":false,"context_lines":[{"line_number":81,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":82,"context_line":"        # NOTE(xek): we have to run this check after updating the schema, since"},{"line_number":83,"context_line":"        # the current release may have updated the models with new fields."},{"line_number":84,"context_line":"        self._check_versions()"},{"line_number":85,"context_line":""},{"line_number":86,"context_line":"    def revision(self):"},{"line_number":87,"context_line":"        migration.revision(CONF.command.message, CONF.command.autogenerate)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_02232107","line":84,"in_reply_to":"ff346bd7_d9e1b200","updated":"2017-07-25 15:03:04.000000000","message":"right, we\u0027ve upgraded to v2, forgot to do online migration, and are trying to upgrade to v3 (in v3 a column is dropped, dbsync finished). we see this error, and run the online migration on v2. and it fails because the old column is removed.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                total_to_do, num_migrated \u003d migration_func(context,"},{"line_number":126,"context_line":"                                                           num_to_migrate)"},{"line_number":127,"context_line":"            except Exception as e:"},{"line_number":128,"context_line":"                print(_(\"Error while running %(migration)s(%(n)i): %(err)s.\")"},{"line_number":129,"context_line":"                      % {\u0027migration\u0027: migration_func.__name__,"},{"line_number":130,"context_line":"                         \u0027n\u0027: num_to_migrate, \u0027err\u0027: e},"},{"line_number":131,"context_line":"                      file\u003dsys.stderr)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_43e1609a","line":128,"range":{"start_line":128,"start_character":61,"end_line":128,"end_character":62},"updated":"2017-07-24 12:28:48.000000000","message":"not sure that\u0027s a useful piece of information for a user, as we don\u0027t know with which row did this migration start. Maybe we could return an ID of a row where the failure happened from migration_func? (dunno if it\u0027s something easily achievable, just a question)","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"97a60b32a1937a22ca93ba61c6fc95d8ce9ebd62","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                total_to_do, num_migrated \u003d migration_func(context,"},{"line_number":126,"context_line":"                                                           num_to_migrate)"},{"line_number":127,"context_line":"            except Exception as e:"},{"line_number":128,"context_line":"                print(_(\"Error while running %(migration)s(%(n)i): %(err)s.\")"},{"line_number":129,"context_line":"                      % {\u0027migration\u0027: migration_func.__name__,"},{"line_number":130,"context_line":"                         \u0027n\u0027: num_to_migrate, \u0027err\u0027: e},"},{"line_number":131,"context_line":"                      file\u003dsys.stderr)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_f33b51c5","line":128,"range":{"start_line":128,"start_character":61,"end_line":128,"end_character":62},"in_reply_to":"ff346bd7_0251e162","updated":"2017-07-25 21:55:25.000000000","message":"done","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                total_to_do, num_migrated \u003d migration_func(context,"},{"line_number":126,"context_line":"                                                           num_to_migrate)"},{"line_number":127,"context_line":"            except Exception as e:"},{"line_number":128,"context_line":"                print(_(\"Error while running %(migration)s(%(n)i): %(err)s.\")"},{"line_number":129,"context_line":"                      % {\u0027migration\u0027: migration_func.__name__,"},{"line_number":130,"context_line":"                         \u0027n\u0027: num_to_migrate, \u0027err\u0027: e},"},{"line_number":131,"context_line":"                      file\u003dsys.stderr)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_59c26235","line":128,"range":{"start_line":128,"start_character":61,"end_line":128,"end_character":62},"in_reply_to":"ff346bd7_43e1609a","updated":"2017-07-24 21:16:48.000000000","message":"I think the idea is that the migration_func shouldn\u0027t fail :-) We can only hope that e provides more information about why it failed. I suppose we could \u0027dictate\u0027 that this migration functions need to be in a try, and raise a new kind of ironic exception? I am wondering if it is overkill but this is all new... So we don\u0027t know if it is due to a specific row ID in the db, or developer error. \n\nI can remove the \u0027num_to_migrate\u0027 in the print statement. I think it was put there to provide more info for debugging purposes.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3c7ce61e5f29404fdb67ca8043a5bb9d870ecbc4","unresolved":false,"context_lines":[{"line_number":125,"context_line":"                total_to_do, num_migrated \u003d migration_func(context,"},{"line_number":126,"context_line":"                                                           num_to_migrate)"},{"line_number":127,"context_line":"            except Exception as e:"},{"line_number":128,"context_line":"                print(_(\"Error while running %(migration)s(%(n)i): %(err)s.\")"},{"line_number":129,"context_line":"                      % {\u0027migration\u0027: migration_func.__name__,"},{"line_number":130,"context_line":"                         \u0027n\u0027: num_to_migrate, \u0027err\u0027: e},"},{"line_number":131,"context_line":"                      file\u003dsys.stderr)"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_0251e162","line":128,"range":{"start_line":128,"start_character":61,"end_line":128,"end_character":62},"in_reply_to":"ff346bd7_59c26235","updated":"2017-07-25 15:03:04.000000000","message":"Yeah, I think makes sense to remove this, as it won\u0027t help much in a lot of cases :)","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        :raises: SystemExit. With exit code of:"},{"line_number":167,"context_line":"            0: when all migrations are complete."},{"line_number":168,"context_line":"            1: when objects were migrated and the command needs to be"},{"line_number":169,"context_line":"               re-run (because there are more objects to be migrated)"},{"line_number":170,"context_line":"            127: if max_count is \u003c 1"},{"line_number":171,"context_line":"        :raises: Exception from a migration function"},{"line_number":172,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_d503c70c","line":169,"range":{"start_line":169,"start_character":37,"end_line":169,"end_character":40},"updated":"2017-07-24 12:28:48.000000000","message":"might be","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"97a60b32a1937a22ca93ba61c6fc95d8ce9ebd62","unresolved":false,"context_lines":[{"line_number":166,"context_line":"        :raises: SystemExit. With exit code of:"},{"line_number":167,"context_line":"            0: when all migrations are complete."},{"line_number":168,"context_line":"            1: when objects were migrated and the command needs to be"},{"line_number":169,"context_line":"               re-run (because there are more objects to be migrated)"},{"line_number":170,"context_line":"            127: if max_count is \u003c 1"},{"line_number":171,"context_line":"        :raises: Exception from a migration function"},{"line_number":172,"context_line":"        \"\"\""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_5370dda5","line":169,"range":{"start_line":169,"start_character":37,"end_line":169,"end_character":40},"in_reply_to":"ff346bd7_d503c70c","updated":"2017-07-25 21:55:25.000000000","message":"Done","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        help\u003d_(\"Perform online data migrations for the release. If \""},{"line_number":239,"context_line":"               \"--max-count is specified, at most max-count objects will be \""},{"line_number":240,"context_line":"               \"migrated. If not specified, all objects will be migrated, \""},{"line_number":241,"context_line":"               \"in batches of 50. \""},{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_15182f1b","line":241,"range":{"start_line":241,"start_character":30,"end_line":241,"end_character":32},"updated":"2017-07-24 12:28:48.000000000","message":"Is there any point in giving this info? as we run migrations until all of them are done anyway","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        help\u003d_(\"Perform online data migrations for the release. If \""},{"line_number":239,"context_line":"               \"--max-count is specified, at most max-count objects will be \""},{"line_number":240,"context_line":"               \"migrated. If not specified, all objects will be migrated, \""},{"line_number":241,"context_line":"               \"in batches of 50. \""},{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_59f02291","line":241,"range":{"start_line":241,"start_character":30,"end_line":241,"end_character":32},"in_reply_to":"ff346bd7_15182f1b","updated":"2017-07-24 21:16:48.000000000","message":"I think the idea is to let the operators know that this isn\u0027t one big DB transaction that will cause everything that tries to access the DB to freeze until it is finished. So this migration can be \u0027safely\u0027 done in the background while the services are running and users are using it.\n\nIs it the actual \u002750\u0027 that you don\u0027t think is necessary, or the whole \u0027in batches of 50\u0027? I\u0027m fine with removing \u0027the 50\u0027 (and/or rewording?)","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3c7ce61e5f29404fdb67ca8043a5bb9d870ecbc4","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        help\u003d_(\"Perform online data migrations for the release. If \""},{"line_number":239,"context_line":"               \"--max-count is specified, at most max-count objects will be \""},{"line_number":240,"context_line":"               \"migrated. If not specified, all objects will be migrated, \""},{"line_number":241,"context_line":"               \"in batches of 50. \""},{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_62eaed75","line":241,"range":{"start_line":241,"start_character":30,"end_line":241,"end_character":32},"in_reply_to":"ff346bd7_59f02291","updated":"2017-07-25 15:03:04.000000000","message":"not sure here, I guess I\u0027ll rely on you here :)","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"97a60b32a1937a22ca93ba61c6fc95d8ce9ebd62","unresolved":false,"context_lines":[{"line_number":238,"context_line":"        help\u003d_(\"Perform online data migrations for the release. If \""},{"line_number":239,"context_line":"               \"--max-count is specified, at most max-count objects will be \""},{"line_number":240,"context_line":"               \"migrated. If not specified, all objects will be migrated, \""},{"line_number":241,"context_line":"               \"in batches of 50. \""},{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_6d6e5296","line":241,"range":{"start_line":241,"start_character":30,"end_line":241,"end_character":32},"in_reply_to":"ff346bd7_62eaed75","updated":"2017-07-25 21:55:25.000000000","message":"I reworded it a bit and removed the \u002750\u0027. Let me know what you think.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""},{"line_number":245,"context_line":"               \"This command should be run (for example in a loop) until code \""},{"line_number":246,"context_line":"               \"0 is returned. It returns 127 (error) if max-count is \u003c 1. \""},{"line_number":247,"context_line":"               \"It returns 2 (error) if the database is not compatible with \""},{"line_number":248,"context_line":"               \"this release. If this happens, this command should be run \""},{"line_number":249,"context_line":"               \"using the previous release of ironic, before upgrading and \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_f52a4be5","line":246,"range":{"start_line":245,"start_character":16,"end_line":246,"end_character":29},"updated":"2017-07-24 12:28:48.000000000","message":"I\u0027m not sure we should recommend a loop here. I\u0027d think this can be run any time prior to upgrade to next release, whenever an operator thinks there is no significant load on db and online migrations can be done smoothly without affecting performance of eg api requests.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3c7ce61e5f29404fdb67ca8043a5bb9d870ecbc4","unresolved":false,"context_lines":[{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""},{"line_number":245,"context_line":"               \"This command should be run (for example in a loop) until code \""},{"line_number":246,"context_line":"               \"0 is returned. It returns 127 (error) if max-count is \u003c 1. \""},{"line_number":247,"context_line":"               \"It returns 2 (error) if the database is not compatible with \""},{"line_number":248,"context_line":"               \"this release. If this happens, this command should be run \""},{"line_number":249,"context_line":"               \"using the previous release of ironic, before upgrading and \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_95ff4d00","line":246,"range":{"start_line":245,"start_character":16,"end_line":246,"end_character":29},"in_reply_to":"ff346bd7_39143ea0","updated":"2017-07-25 15:03:04.000000000","message":"yup, ++ to removing in the loop. maybe we should say that the only requirement here is that we migrate all of the records prior to upgrading to the next release.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"97a60b32a1937a22ca93ba61c6fc95d8ce9ebd62","unresolved":false,"context_lines":[{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""},{"line_number":245,"context_line":"               \"This command should be run (for example in a loop) until code \""},{"line_number":246,"context_line":"               \"0 is returned. It returns 127 (error) if max-count is \u003c 1. \""},{"line_number":247,"context_line":"               \"It returns 2 (error) if the database is not compatible with \""},{"line_number":248,"context_line":"               \"this release. If this happens, this command should be run \""},{"line_number":249,"context_line":"               \"using the previous release of ironic, before upgrading and \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_2d060ad0","line":246,"range":{"start_line":245,"start_character":16,"end_line":246,"end_character":29},"in_reply_to":"ff346bd7_95ff4d00","updated":"2017-07-25 21:55:25.000000000","message":"Done","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":242,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":243,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":244,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""},{"line_number":245,"context_line":"               \"This command should be run (for example in a loop) until code \""},{"line_number":246,"context_line":"               \"0 is returned. It returns 127 (error) if max-count is \u003c 1. \""},{"line_number":247,"context_line":"               \"It returns 2 (error) if the database is not compatible with \""},{"line_number":248,"context_line":"               \"this release. If this happens, this command should be run \""},{"line_number":249,"context_line":"               \"using the previous release of ironic, before upgrading and \""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_39143ea0","line":246,"range":{"start_line":245,"start_character":16,"end_line":246,"end_character":29},"in_reply_to":"ff346bd7_f52a4be5","updated":"2017-07-24 21:16:48.000000000","message":"the loop was in the \u0027for example\u0027 but if it seems like we are recommending it, I can delete \u0027(for example in a loop)\u0027.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":78,"context_line":"            sys.exit(2)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def upgrade(self):"},{"line_number":81,"context_line":"        # TODO(rloo): enable this in Queens because we want the check done"},{"line_number":82,"context_line":"        # before someone tries to upgrade to Queens."},{"line_number":83,"context_line":"        # It won\u0027t work now because the check looks at the value in the new"},{"line_number":84,"context_line":"        # \u0027version\u0027 column for all objects. And this column doesn\u0027t exist until"},{"line_number":85,"context_line":"        # *after* an upgrade to this Pike release (i.e., after this"},{"line_number":86,"context_line":"        # \u0027ironic-dbsync upgrade\u0027 is run)."},{"line_number":87,"context_line":"        # self._check_versions()"},{"line_number":88,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"    def revision(self):"}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_708da530","line":87,"range":{"start_line":81,"start_character":8,"end_line":87,"end_character":32},"updated":"2017-07-28 09:17:33.000000000","message":"Is this check the only one that\u0027s going to be here, or do you intend to add more each release? I think the problem here is, upgrade gets run on a newer code, so the checks for online migrations will also be from newer code, and they\u0027ll never pass, as those online migrations can be done only after the schema upgrade...","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a1fced35ab2785972e996b67c93d912c616e5cbe","unresolved":false,"context_lines":[{"line_number":78,"context_line":"            sys.exit(2)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def upgrade(self):"},{"line_number":81,"context_line":"        # TODO(rloo): enable this in Queens because we want the check done"},{"line_number":82,"context_line":"        # before someone tries to upgrade to Queens."},{"line_number":83,"context_line":"        # It won\u0027t work now because the check looks at the value in the new"},{"line_number":84,"context_line":"        # \u0027version\u0027 column for all objects. And this column doesn\u0027t exist until"},{"line_number":85,"context_line":"        # *after* an upgrade to this Pike release (i.e., after this"},{"line_number":86,"context_line":"        # \u0027ironic-dbsync upgrade\u0027 is run)."},{"line_number":87,"context_line":"        # self._check_versions()"},{"line_number":88,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"    def revision(self):"}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_5bd38139","line":87,"range":{"start_line":81,"start_character":8,"end_line":87,"end_character":32},"in_reply_to":"df3967d1_452161fb","updated":"2017-07-31 18:39:26.000000000","message":"To clarify, vdrok was concerned about adding new checks that checked for things other than the version column. This check only looks at the version column to make sure the object versions are compatible, so it\u0027ll work for future releases.","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":78,"context_line":"            sys.exit(2)"},{"line_number":79,"context_line":""},{"line_number":80,"context_line":"    def upgrade(self):"},{"line_number":81,"context_line":"        # TODO(rloo): enable this in Queens because we want the check done"},{"line_number":82,"context_line":"        # before someone tries to upgrade to Queens."},{"line_number":83,"context_line":"        # It won\u0027t work now because the check looks at the value in the new"},{"line_number":84,"context_line":"        # \u0027version\u0027 column for all objects. And this column doesn\u0027t exist until"},{"line_number":85,"context_line":"        # *after* an upgrade to this Pike release (i.e., after this"},{"line_number":86,"context_line":"        # \u0027ironic-dbsync upgrade\u0027 is run)."},{"line_number":87,"context_line":"        # self._check_versions()"},{"line_number":88,"context_line":"        migration.upgrade(CONF.command.revision)"},{"line_number":89,"context_line":""},{"line_number":90,"context_line":"    def revision(self):"}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_452161fb","line":87,"range":{"start_line":81,"start_character":8,"end_line":87,"end_character":32},"in_reply_to":"ff346bd7_708da530","updated":"2017-07-31 15:45:56.000000000","message":"This is the only check that I am aware of.","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a1fced35ab2785972e996b67c93d912c616e5cbe","unresolved":false,"context_lines":[{"line_number":215,"context_line":"               \"not compatible with this version. If this happens, the \""},{"line_number":216,"context_line":"               \"\u0027ironic-dbsync online_data_migrations\u0027 command should be run \""},{"line_number":217,"context_line":"               \"using the previous version of ironic, before upgrading and \""},{"line_number":218,"context_line":"               \"running this command.\"))"},{"line_number":219,"context_line":"    parser.set_defaults(func\u003dcommand_object.upgrade)"},{"line_number":220,"context_line":"    parser.add_argument(\u0027--revision\u0027, nargs\u003d\u0027?\u0027)"},{"line_number":221,"context_line":""}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_7b03e643","line":218,"updated":"2017-07-31 18:39:26.000000000","message":"Ugh. I just realized that this is nonsensical in the Pike release, since there is no Ocata ironic-dbsync online_data_migrations :-( Will have to add this in later, in Queens release.","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":243,"context_line":""},{"line_number":244,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":245,"context_line":"        \u0027online_data_migrations\u0027,"},{"line_number":246,"context_line":"        help\u003d_(\"Perform online data migrations for the release. If \""},{"line_number":247,"context_line":"               \"--max-count is specified, at most max-count objects will be \""},{"line_number":248,"context_line":"               \"migrated. If not specified, all objects will be migrated \""},{"line_number":249,"context_line":"               \"(in batches to avoid locking the database for long periods of \""},{"line_number":250,"context_line":"               \"time). \""},{"line_number":251,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":252,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":253,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""},{"line_number":254,"context_line":"               \"Before upgrading to a newer release, this command must be run \""},{"line_number":255,"context_line":"               \"until code 0 is returned. \""},{"line_number":256,"context_line":"               \"It returns 127 (error) if max-count is \u003c 1. \""},{"line_number":257,"context_line":"               \"It returns 2 (error) if the database is not compatible with \""},{"line_number":258,"context_line":"               \"this release. If this happens, this command should be run \""}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_b0754dfc","line":255,"range":{"start_line":246,"start_character":16,"end_line":255,"end_character":41},"updated":"2017-07-28 09:17:33.000000000","message":"Maybe this description should go to the docs too, instead of the one that\u0027s there now?","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":243,"context_line":""},{"line_number":244,"context_line":"    parser \u003d subparsers.add_parser("},{"line_number":245,"context_line":"        \u0027online_data_migrations\u0027,"},{"line_number":246,"context_line":"        help\u003d_(\"Perform online data migrations for the release. If \""},{"line_number":247,"context_line":"               \"--max-count is specified, at most max-count objects will be \""},{"line_number":248,"context_line":"               \"migrated. If not specified, all objects will be migrated \""},{"line_number":249,"context_line":"               \"(in batches to avoid locking the database for long periods of \""},{"line_number":250,"context_line":"               \"time). \""},{"line_number":251,"context_line":"               \"The command returns code 0 (success) after migrations are \""},{"line_number":252,"context_line":"               \"finished or there are no data to migrate. It returns code \""},{"line_number":253,"context_line":"               \"1 (error) if there are still pending objects to be migrated. \""},{"line_number":254,"context_line":"               \"Before upgrading to a newer release, this command must be run \""},{"line_number":255,"context_line":"               \"until code 0 is returned. \""},{"line_number":256,"context_line":"               \"It returns 127 (error) if max-count is \u003c 1. \""},{"line_number":257,"context_line":"               \"It returns 2 (error) if the database is not compatible with \""},{"line_number":258,"context_line":"               \"this release. If this happens, this command should be run \""}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_6552256a","line":255,"range":{"start_line":246,"start_character":16,"end_line":255,"end_character":41},"in_reply_to":"ff346bd7_b0754dfc","updated":"2017-07-31 15:45:56.000000000","message":"Ah yes, that \u0027loop\u0027 is mentioned in the docs too. Will update.","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"}],"ironic/common/release_mappings.py":[{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":116,"context_line":"              a set of supported versions."},{"line_number":117,"context_line":"    \"\"\""},{"line_number":118,"context_line":"    if not releases:"},{"line_number":119,"context_line":"        releases \u003d set(RELEASE_MAPPING)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    versions \u003d {}"},{"line_number":122,"context_line":"    for release in releases:"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_750d3b3d","line":119,"range":{"start_line":119,"start_character":19,"end_line":119,"end_character":39},"updated":"2017-07-24 12:28:48.000000000","message":"any reason we need to convert it to set rather than just using the RELEASE_MAPPING in the loop on L122?","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":116,"context_line":"              a set of supported versions."},{"line_number":117,"context_line":"    \"\"\""},{"line_number":118,"context_line":"    if not releases:"},{"line_number":119,"context_line":"        releases \u003d set(RELEASE_MAPPING)"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    versions \u003d {}"},{"line_number":122,"context_line":"    for release in releases:"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_3f7e69e4","line":119,"range":{"start_line":119,"start_character":19,"end_line":119,"end_character":39},"in_reply_to":"ff346bd7_750d3b3d","updated":"2017-07-24 21:16:48.000000000","message":"I\u0027m not sure why I did that. Maybe I had \u0027sets\u0027 on my brain. Good catch. (If anything, I should check the releases parameter value but I don\u0027t think that is worth doing either.)","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":79,"context_line":"            \u0027Node\u0027: [\u00271.21\u0027],"},{"line_number":80,"context_line":"            \u0027Conductor\u0027: [\u00271.2\u0027],"},{"line_number":81,"context_line":"            \u0027Chassis\u0027: [\u00271.3\u0027],"},{"line_number":82,"context_line":"            \u0027Port\u0027: [\u00271.7\u0027],"},{"line_number":83,"context_line":"            \u0027Portgroup\u0027: [\u00271.3\u0027],"},{"line_number":84,"context_line":"            \u0027VolumeConnector\u0027: [\u00271.0\u0027],"},{"line_number":85,"context_line":"            \u0027VolumeTarget\u0027: [\u00271.0\u0027],"}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_cbda6276","line":82,"range":{"start_line":82,"start_character":21,"end_line":82,"end_character":26},"updated":"2017-07-28 09:17:33.000000000","message":"should we also add \u00271.6\u0027 here? as in code we should support backporting to/upgrading from version 1.6? or maybe I just don\u0027t completely understand what this list should contain.\n\nOh, or should it be done in https://review.openstack.org/477694?","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":79,"context_line":"            \u0027Node\u0027: [\u00271.21\u0027],"},{"line_number":80,"context_line":"            \u0027Conductor\u0027: [\u00271.2\u0027],"},{"line_number":81,"context_line":"            \u0027Chassis\u0027: [\u00271.3\u0027],"},{"line_number":82,"context_line":"            \u0027Port\u0027: [\u00271.7\u0027],"},{"line_number":83,"context_line":"            \u0027Portgroup\u0027: [\u00271.3\u0027],"},{"line_number":84,"context_line":"            \u0027VolumeConnector\u0027: [\u00271.0\u0027],"},{"line_number":85,"context_line":"            \u0027VolumeTarget\u0027: [\u00271.0\u0027],"}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_e5505535","line":82,"range":{"start_line":82,"start_character":21,"end_line":82,"end_character":26},"in_reply_to":"ff346bd7_cbda6276","updated":"2017-07-31 15:45:56.000000000","message":"No, we don\u0027t add 1.6 here. These versions are the versions of the objects in that release. \u0027master\u0027 is odd in the sense that this is where the versions will change -- but master is a placeholder for the next release.\n\nsupport for older versions is implied, via the versions in the \u0027from\u0027 release are supposed in versions in the \u0027to\u0027 release. We don\u0027t indicate \nthose supported/deprecated object versions.\n\nNo, it shouldn\u0027t be done in https://review.openstack.org/486934 either.\n\nShould I add something to L43 (and if so, what would work that would clarify it for you?)","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":105,"context_line":"def get_object_versions(releases\u003dNone, objects\u003dNone):"},{"line_number":106,"context_line":"    \"\"\"Gets the supported versions for all objects."},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    Supported versions are from the RELEASE_MAPPINGs."},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    :param releases: a list of release names; if empty/None, versions from all"},{"line_number":111,"context_line":"                     releases are returned (the default)."}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_4bd9d254","line":108,"range":{"start_line":108,"start_character":4,"end_line":108,"end_character":13},"updated":"2017-07-28 09:17:33.000000000","message":"do i understand correctly that supported here means that we can backport to this version and accept object of this version?","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":105,"context_line":"def get_object_versions(releases\u003dNone, objects\u003dNone):"},{"line_number":106,"context_line":"    \"\"\"Gets the supported versions for all objects."},{"line_number":107,"context_line":""},{"line_number":108,"context_line":"    Supported versions are from the RELEASE_MAPPINGs."},{"line_number":109,"context_line":""},{"line_number":110,"context_line":"    :param releases: a list of release names; if empty/None, versions from all"},{"line_number":111,"context_line":"                     releases are returned (the default)."}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_0076a7a5","line":108,"range":{"start_line":108,"start_character":4,"end_line":108,"end_character":13},"in_reply_to":"ff346bd7_4bd9d254","updated":"2017-07-31 15:45:56.000000000","message":"yes\n\nWould it make it clearer if I \u0027redefined\u0027 \u0027supported\u0027 to mean/include \u0027actual version\u0027 and \u0027deprecated versions\u0027 of an object?","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":116,"context_line":"              a set of supported versions."},{"line_number":117,"context_line":"    \"\"\""},{"line_number":118,"context_line":"    if not releases:"},{"line_number":119,"context_line":"        releases \u003d RELEASE_MAPPING.keys()"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    versions \u003d {}"},{"line_number":122,"context_line":"    for release in releases:"}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_6b2ed6fb","line":119,"range":{"start_line":119,"start_character":35,"end_line":119,"end_character":39},"updated":"2017-07-28 09:17:33.000000000","message":"nit - I suppose we can iterate only on named releases here? anyway, this should not slow down things much","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":116,"context_line":"              a set of supported versions."},{"line_number":117,"context_line":"    \"\"\""},{"line_number":118,"context_line":"    if not releases:"},{"line_number":119,"context_line":"        releases \u003d RELEASE_MAPPING.keys()"},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"    versions \u003d {}"},{"line_number":122,"context_line":"    for release in releases:"}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_e02cc39a","line":119,"range":{"start_line":119,"start_character":35,"end_line":119,"end_character":39},"in_reply_to":"ff346bd7_6b2ed6fb","updated":"2017-07-31 15:45:56.000000000","message":"No, we need to iterate on all releases, to make sure we don\u0027t miss any object versions. This is to support intermediate versions of ironic; versions that are between named versions.) Eg, I guess we had an intermediate 8.0 version. It doesn\u0027t have any, but it could have had an object version that changed from 7.0. If it did, we\u0027d want to include that.","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"170ebdc385df5d2e33c91c2d2e28ce8da9446e10","unresolved":false,"context_lines":[{"line_number":121,"context_line":"              a set of supported versions."},{"line_number":122,"context_line":"    \"\"\""},{"line_number":123,"context_line":"    if not releases:"},{"line_number":124,"context_line":"        releases \u003d RELEASE_MAPPING.keys()"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"    versions \u003d {}"},{"line_number":127,"context_line":"    for release in releases:"}],"source_content_type":"text/x-python","patch_set":66,"id":"df3967d1_0b78ec27","line":124,"updated":"2017-08-01 10:54:24.000000000","message":"nit: keys() is redundant (also this is not going to be a list in python 3, but it\u0027s fine for this case)","commit_id":"249ff05c471e223445635fdb2665576640c5d578"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"8a162eba4b7495ca8b01cfc85e5812b6721de45c","unresolved":false,"context_lines":[{"line_number":121,"context_line":"              a set of supported versions."},{"line_number":122,"context_line":"    \"\"\""},{"line_number":123,"context_line":"    if not releases:"},{"line_number":124,"context_line":"        releases \u003d RELEASE_MAPPING.keys()"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"    versions \u003d {}"},{"line_number":127,"context_line":"    for release in releases:"}],"source_content_type":"text/x-python","patch_set":66,"id":"df3967d1_b7bf03cf","line":124,"in_reply_to":"df3967d1_0b78ec27","updated":"2017-08-01 13:24:22.000000000","message":"Oh, I always forget that :-(","commit_id":"249ff05c471e223445635fdb2665576640c5d578"}],"ironic/db/api.py":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":815,"context_line":"        \"\"\""},{"line_number":816,"context_line":""},{"line_number":817,"context_line":"    @abc.abstractmethod"},{"line_number":818,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":819,"context_line":"        \"\"\"Backfill the version column with Newton versions.\"\"\""}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_3addcc70","line":818,"updated":"2017-01-10 21:56:53.000000000","message":"Would you please explain how these methods will work with the new dbsync command, in the rolling upgrades process?\n\nMy guess is\n1. if a db migration has to be done as part of an upgrade, we will have to add the (abstract) method here, and then add the implementation to db/sqlalchemy/api.py (and/or to any other implementations of this class.) This method is only valid for one particular release, right? Which is why it is hardcoded (in this case) with \u0027Newton\u0027? \n2. after adding this new method, it has to be added to dbsync.ONLINE_MIGRATIONS\n\nFor the next release (ie when newton -\u003e ocata upgrade is not supported):\n1. we delete this method\n2. we delete it from dbsync.ONLINE_MIGRATIONS\nOR do we leave them cuz they shouldn\u0027t hurt?\n\nAlso, to make sure I understand (because I think I am a bit confused): is the rolling upgrades code that you are proposing (all the patches, not just this one) supporting mitaka-\u003enewton, OR newton-\u003eocata, or both?","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":815,"context_line":"        \"\"\""},{"line_number":816,"context_line":""},{"line_number":817,"context_line":"    @abc.abstractmethod"},{"line_number":818,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":819,"context_line":"        \"\"\"Backfill the version column with Newton versions.\"\"\""}],"source_content_type":"text/x-python","patch_set":17,"id":"9a57fde8_479e8457","line":818,"in_reply_to":"ba5201f7_3addcc70","updated":"2017-01-12 15:09:13.000000000","message":"I uploaded some dev documentation for review, which should cover why and how to do online migrations.\n\nI think we should remove them in the next release, but it doesn\u0027t hurt if we forget about doing this. It\u0027s the same for RPC compatibility and object\u0027s make_compatible methods.\n\nI\u0027m testing only Newton to Ocata migrations. Rolling upgrade from Mitaka to Newton could work by accident but its not tested.\nRight now we are testing with the following POC patch. We already found at least one bug and will start submitting fixes soon.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"ba5201f7_e1063f84","line":820,"updated":"2017-01-10 21:56:53.000000000","message":"We should document max_count. And what it returns and raises, if anything.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"9a57fde8_270c2094","line":820,"in_reply_to":"ba5201f7_e1063f84","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ccb6bfedaf7fa5f4e1c32f4800fbe9ada902ec36","unresolved":false,"context_lines":[{"line_number":822,"context_line":"        specified in the BASE_RELEASE - the oldest supported release from which"},{"line_number":823,"context_line":"        an upgrade can be performed."},{"line_number":824,"context_line":""},{"line_number":825,"context_line":"        :returns: A Boolean."},{"line_number":826,"context_line":"        \"\"\""},{"line_number":827,"context_line":""},{"line_number":828,"context_line":"    @abc.abstractmethod"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_f8c6c166","line":825,"updated":"2017-01-16 21:42:59.000000000","message":"To be clear, returns True if object versions are \u003e\u003d with BASE_RELEASE; False if any are older. Right?","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"a690751125192a485e9eb8c313453dee810dcf0d","unresolved":false,"context_lines":[{"line_number":881,"context_line":""},{"line_number":882,"context_line":"    @abc.abstractmethod"},{"line_number":883,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":884,"context_line":"        \"\"\"Backfill the version column with Newton versions."},{"line_number":885,"context_line":""},{"line_number":886,"context_line":"        :param max_count: The maximum number of objects to migrate"},{"line_number":887,"context_line":"        :returns: A 2-tuple, containing the total amount of objects to migrate"}],"source_content_type":"text/x-python","patch_set":35,"id":"ba2be162_e3ecc92b","line":884,"updated":"2017-03-06 20:18:07.000000000","message":"s/newton/ocata/","commit_id":"abc7bdfe359a592c1d1cd42282355b5feb17cc68"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"0b744f1132de10350a7afdd18a748b3d29d72f66","unresolved":false,"context_lines":[{"line_number":881,"context_line":""},{"line_number":882,"context_line":"    @abc.abstractmethod"},{"line_number":883,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":884,"context_line":"        \"\"\"Backfill the version column with Newton versions."},{"line_number":885,"context_line":""},{"line_number":886,"context_line":"        :param max_count: The maximum number of objects to migrate"},{"line_number":887,"context_line":"        :returns: A 2-tuple, containing the total amount of objects to migrate"}],"source_content_type":"text/x-python","patch_set":35,"id":"1a1ced50_6c12eb58","line":884,"in_reply_to":"ba2be162_e3ecc92b","updated":"2017-03-21 21:24:18.000000000","message":"Done","commit_id":"abc7bdfe359a592c1d1cd42282355b5feb17cc68"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":901,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":902,"context_line":"        \"\"\"Backfill the version column with Ocata versions."},{"line_number":903,"context_line":""},{"line_number":904,"context_line":"        The version column was added to all the resource tables in this"},{"line_number":905,"context_line":"        release (via \u0027ironic-dbsync upgrade\u0027). After upgrading (from Ocata to"},{"line_number":906,"context_line":"        Pike), the \u0027ironic-dbsync online_data_migrations\u0027 command will invoke"},{"line_number":907,"context_line":"        this method to populate (backfill) the version columns. The version"},{"line_number":908,"context_line":"        used will be the object version prior to this column being added."}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_6b17f6a5","line":905,"range":{"start_line":904,"start_character":67,"end_line":905,"end_character":15},"updated":"2017-07-28 09:17:33.000000000","message":"which one?","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":901,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":902,"context_line":"        \"\"\"Backfill the version column with Ocata versions."},{"line_number":903,"context_line":""},{"line_number":904,"context_line":"        The version column was added to all the resource tables in this"},{"line_number":905,"context_line":"        release (via \u0027ironic-dbsync upgrade\u0027). After upgrading (from Ocata to"},{"line_number":906,"context_line":"        Pike), the \u0027ironic-dbsync online_data_migrations\u0027 command will invoke"},{"line_number":907,"context_line":"        this method to populate (backfill) the version columns. The version"},{"line_number":908,"context_line":"        used will be the object version prior to this column being added."}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_a0823b4e","line":905,"range":{"start_line":904,"start_character":67,"end_line":905,"end_character":15},"in_reply_to":"ff346bd7_6b17f6a5","updated":"2017-07-31 15:45:56.000000000","message":"Pike.\n\nI guess I should clarify it, in case this patch never lands in Pike...","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":905,"context_line":"        release (via \u0027ironic-dbsync upgrade\u0027). After upgrading (from Ocata to"},{"line_number":906,"context_line":"        Pike), the \u0027ironic-dbsync online_data_migrations\u0027 command will invoke"},{"line_number":907,"context_line":"        this method to populate (backfill) the version columns. The version"},{"line_number":908,"context_line":"        used will be the object version prior to this column being added."},{"line_number":909,"context_line":""},{"line_number":910,"context_line":"        :param max_count: The maximum number of objects to migrate. Must be"},{"line_number":911,"context_line":"                          \u003e\u003d 0. If zero, all the objects will be migrated."}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_6b7c96eb","line":908,"range":{"start_line":908,"start_character":40,"end_line":908,"end_character":72},"updated":"2017-07-28 09:17:33.000000000","message":"or is the \u0027from the pinning set in config\u0027 would be more general?","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":905,"context_line":"        release (via \u0027ironic-dbsync upgrade\u0027). After upgrading (from Ocata to"},{"line_number":906,"context_line":"        Pike), the \u0027ironic-dbsync online_data_migrations\u0027 command will invoke"},{"line_number":907,"context_line":"        this method to populate (backfill) the version columns. The version"},{"line_number":908,"context_line":"        used will be the object version prior to this column being added."},{"line_number":909,"context_line":""},{"line_number":910,"context_line":"        :param max_count: The maximum number of objects to migrate. Must be"},{"line_number":911,"context_line":"                          \u003e\u003d 0. If zero, all the objects will be migrated."}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_800df73f","line":908,"range":{"start_line":908,"start_character":40,"end_line":908,"end_character":72},"in_reply_to":"ff346bd7_6b7c96eb","updated":"2017-07-31 15:45:56.000000000","message":"that works too.","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"170ebdc385df5d2e33c91c2d2e28ce8da9446e10","unresolved":false,"context_lines":[{"line_number":897,"context_line":"                  False otherwise."},{"line_number":898,"context_line":"        \"\"\""},{"line_number":899,"context_line":""},{"line_number":900,"context_line":"    @abc.abstractmethod"},{"line_number":901,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":902,"context_line":"        \"\"\"Backfill the version column with Ocata versions."},{"line_number":903,"context_line":""}],"source_content_type":"text/x-python","patch_set":66,"id":"df3967d1_2b79702e","line":900,"updated":"2017-08-01 10:54:24.000000000","message":"unrelated: I wonder if we should stop pretend that we\u0027re going to have different db backends, other than sqlalchemy..","commit_id":"249ff05c471e223445635fdb2665576640c5d578"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"8a162eba4b7495ca8b01cfc85e5812b6721de45c","unresolved":false,"context_lines":[{"line_number":897,"context_line":"                  False otherwise."},{"line_number":898,"context_line":"        \"\"\""},{"line_number":899,"context_line":""},{"line_number":900,"context_line":"    @abc.abstractmethod"},{"line_number":901,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":902,"context_line":"        \"\"\"Backfill the version column with Ocata versions."},{"line_number":903,"context_line":""}],"source_content_type":"text/x-python","patch_set":66,"id":"df3967d1_17780f28","line":900,"in_reply_to":"df3967d1_2b79702e","updated":"2017-08-01 13:24:22.000000000","message":"Good point. I don\u0027t think it hurts to have this level of indirection (seems like good design blah blah). If OpenStack decides there is only going to be one, though, then I think we won\u0027t need to pretend any more. Otherwise I\u0027m fine leaving it as is. :-)","commit_id":"249ff05c471e223445635fdb2665576640c5d578"}],"ironic/db/sqlalchemy/api.py":[{"author":{"_account_id":22860,"name":"Solio Sarabia","email":"solio.sarabia@intel.com","username":"ssarabia"},"change_message_id":"d4743d8239678aa78af35bff9cb6e5968df2c513","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"from ironic.common import exception"},{"line_number":36,"context_line":"from ironic.common.i18n import _, _LW"},{"line_number":37,"context_line":"from ironic.common import release_mappings as versions"},{"line_number":38,"context_line":"from ironic.common import states"},{"line_number":39,"context_line":"from ironic.conf import CONF"},{"line_number":40,"context_line":"from ironic.db import api"}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_43d636c4","line":37,"range":{"start_line":37,"start_character":26,"end_line":37,"end_character":42},"updated":"2017-01-10 18:39:04.000000000","message":"I can\u0027t find release_mappings in the code.\nShould this module be added in the patch?","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"dffb688b001d6983b91b8ec661760482066274dc","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"from ironic.common import exception"},{"line_number":36,"context_line":"from ironic.common.i18n import _, _LW"},{"line_number":37,"context_line":"from ironic.common import release_mappings as versions"},{"line_number":38,"context_line":"from ironic.common import states"},{"line_number":39,"context_line":"from ironic.conf import CONF"},{"line_number":40,"context_line":"from ironic.db import api"}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_da284088","line":37,"range":{"start_line":37,"start_character":26,"end_line":37,"end_character":42},"in_reply_to":"ba5201f7_43d636c4","updated":"2017-01-10 21:52:04.000000000","message":"+1. And since Jenkins passes without it, I believe a unit test for backfill_version_column would be useful.\n\nI believe it is a legacy after: https://review.openstack.org/#/c/407997/1","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":34,"context_line":""},{"line_number":35,"context_line":"from ironic.common import exception"},{"line_number":36,"context_line":"from ironic.common.i18n import _, _LW"},{"line_number":37,"context_line":"from ironic.common import release_mappings as versions"},{"line_number":38,"context_line":"from ironic.common import states"},{"line_number":39,"context_line":"from ironic.conf import CONF"},{"line_number":40,"context_line":"from ironic.db import api"}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_61d6cfc4","line":37,"range":{"start_line":37,"start_character":26,"end_line":37,"end_character":42},"in_reply_to":"ba5201f7_43d636c4","updated":"2017-01-10 21:56:53.000000000","message":"Solio -- release_mappings is from https://review.openstack.org/#/c/407491/. If you pulled down this patch with its dependencies, you should see release_mappings.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":1048,"context_line":"                migrated +\u003d count_hit"},{"line_number":1049,"context_line":"                if max_count and migrated \u003e\u003d max_count:"},{"line_number":1050,"context_line":"                    break"},{"line_number":1051,"context_line":"        return total, migrated"}],"source_content_type":"text/x-python","patch_set":17,"id":"ba5201f7_97e05198","line":1051,"updated":"2017-01-10 21:56:53.000000000","message":"what is total supposed to be? It won\u0027t be the total number of objects that needed to be migrated, cuz of the break at line 1050.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":1048,"context_line":"                migrated +\u003d count_hit"},{"line_number":1049,"context_line":"                if max_count and migrated \u003e\u003d max_count:"},{"line_number":1050,"context_line":"                    break"},{"line_number":1051,"context_line":"        return total, migrated"}],"source_content_type":"text/x-python","patch_set":17,"id":"9a57fde8_0abf21d1","line":1051,"in_reply_to":"ba5201f7_97e05198","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"fe63772b7255f39e97aea05a8626f8300f8f565d","unresolved":false,"context_lines":[{"line_number":1033,"context_line":"            if count \u003d\u003d 0:"},{"line_number":1034,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1035,"context_line":""},{"line_number":1036,"context_line":"    def check_versions(self):"},{"line_number":1037,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1038,"context_line":"        for Model in models.Base.__subclasses__():"},{"line_number":1039,"context_line":"            if Model.__name__ in old_object_versions:"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_3e910e48","line":1036,"updated":"2017-01-17 00:14:44.000000000","message":"The name of the function does not really explain what is it doing; I think a comment describing behavior and returned value would be great","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7f3b74128b872f4408268ac66ba66dfd1669b794","unresolved":false,"context_lines":[{"line_number":1033,"context_line":"            if count \u003d\u003d 0:"},{"line_number":1034,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1035,"context_line":""},{"line_number":1036,"context_line":"    def check_versions(self):"},{"line_number":1037,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1038,"context_line":"        for Model in models.Base.__subclasses__():"},{"line_number":1039,"context_line":"            if Model.__name__ in old_object_versions:"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_e9e412e1","line":1036,"in_reply_to":"7a3c09a3_3e910e48","updated":"2017-01-17 14:55:41.000000000","message":"This method is already documented in ironic/db/api.py","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"fe63772b7255f39e97aea05a8626f8300f8f565d","unresolved":false,"context_lines":[{"line_number":1034,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1035,"context_line":""},{"line_number":1036,"context_line":"    def check_versions(self):"},{"line_number":1037,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1038,"context_line":"        for Model in models.Base.__subclasses__():"},{"line_number":1039,"context_line":"            if Model.__name__ in old_object_versions:"},{"line_number":1040,"context_line":"                supported_version \u003d decimal.Decimal("}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_9eae8296","line":1037,"updated":"2017-01-17 00:14:44.000000000","message":"wouldn\u0027t it be better if there was a model array created here?\n\nmodels_old_version \u003d [m for m in models.Base.__subclasses__() if m.__name__ in versions.BASE_RELEASE[\u0027objects\u0027]]","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"49ff2955dba2df59a3d45a9635ab01f5788c2934","unresolved":false,"context_lines":[{"line_number":1034,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1035,"context_line":""},{"line_number":1036,"context_line":"    def check_versions(self):"},{"line_number":1037,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1038,"context_line":"        for Model in models.Base.__subclasses__():"},{"line_number":1039,"context_line":"            if Model.__name__ in old_object_versions:"},{"line_number":1040,"context_line":"                supported_version \u003d decimal.Decimal("}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_1d38b83c","line":1037,"in_reply_to":"7a3c09a3_9eae8296","updated":"2017-01-17 15:04:54.000000000","message":"I\u0027m not sure, I\u0027ve seen people argue whether one or the other is more pythonic... It would definitely make sense if the result would be used in more then one place.","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"fe63772b7255f39e97aea05a8626f8300f8f565d","unresolved":false,"context_lines":[{"line_number":1035,"context_line":""},{"line_number":1036,"context_line":"    def check_versions(self):"},{"line_number":1037,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1038,"context_line":"        for Model in models.Base.__subclasses__():"},{"line_number":1039,"context_line":"            if Model.__name__ in old_object_versions:"},{"line_number":1040,"context_line":"                supported_version \u003d decimal.Decimal("},{"line_number":1041,"context_line":"                    old_object_versions[Model.__name__])"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_3e8aee1b","line":1038,"updated":"2017-01-17 00:14:44.000000000","message":"I don\u0027t like this variable name starting from capital letter","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"49ff2955dba2df59a3d45a9635ab01f5788c2934","unresolved":false,"context_lines":[{"line_number":1035,"context_line":""},{"line_number":1036,"context_line":"    def check_versions(self):"},{"line_number":1037,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1038,"context_line":"        for Model in models.Base.__subclasses__():"},{"line_number":1039,"context_line":"            if Model.__name__ in old_object_versions:"},{"line_number":1040,"context_line":"                supported_version \u003d decimal.Decimal("},{"line_number":1041,"context_line":"                    old_object_versions[Model.__name__])"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_7d47fcbb","line":1038,"in_reply_to":"7a3c09a3_3e8aee1b","updated":"2017-01-17 15:04:54.000000000","message":"Done","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":23883,"name":"Joanna Taryma","email":"joanna.taryma@intel.com","username":"jtaryma"},"change_message_id":"fe63772b7255f39e97aea05a8626f8300f8f565d","unresolved":false,"context_lines":[{"line_number":1051,"context_line":"        MAPPING \u003d versions.RELEASE_MAPPING[\u0027newton\u0027][\u0027objects\u0027]"},{"line_number":1052,"context_line":"        Models \u003d [Model for Model in models.Base.__subclasses__()"},{"line_number":1053,"context_line":"                  if Model.__name__ in MAPPING]  # backfill only Newton objects"},{"line_number":1054,"context_line":"        for Model in Models:"},{"line_number":1055,"context_line":"            with _session_for_read():"},{"line_number":1056,"context_line":"                query \u003d model_query(Model).filter(Model.version.is_(None))"},{"line_number":1057,"context_line":"                count_all \u003d query.count()"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_7e97163a","line":1054,"updated":"2017-01-17 00:14:44.000000000","message":"ditto (capital letter)","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"49ff2955dba2df59a3d45a9635ab01f5788c2934","unresolved":false,"context_lines":[{"line_number":1051,"context_line":"        MAPPING \u003d versions.RELEASE_MAPPING[\u0027newton\u0027][\u0027objects\u0027]"},{"line_number":1052,"context_line":"        Models \u003d [Model for Model in models.Base.__subclasses__()"},{"line_number":1053,"context_line":"                  if Model.__name__ in MAPPING]  # backfill only Newton objects"},{"line_number":1054,"context_line":"        for Model in Models:"},{"line_number":1055,"context_line":"            with _session_for_read():"},{"line_number":1056,"context_line":"                query \u003d model_query(Model).filter(Model.version.is_(None))"},{"line_number":1057,"context_line":"                count_all \u003d query.count()"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_9d44a8b7","line":1054,"in_reply_to":"7a3c09a3_7e97163a","updated":"2017-01-17 15:04:54.000000000","message":"Done","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ccb6bfedaf7fa5f4e1c32f4800fbe9ada902ec36","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"            with _session_for_read():"},{"line_number":1056,"context_line":"                query \u003d model_query(Model).filter(Model.version.is_(None))"},{"line_number":1057,"context_line":"                count_all \u003d query.count()"},{"line_number":1058,"context_line":"            total +\u003d count_all"},{"line_number":1059,"context_line":"        for Model in Models:"},{"line_number":1060,"context_line":"            with _session_for_write():"},{"line_number":1061,"context_line":"                query \u003d model_query(Model).filter(Model.version.is_(None))"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_533336ab","line":1058,"updated":"2017-01-16 21:42:59.000000000","message":"my only question with splitting this up into two loops is that the total count could be off because between the two loops, an object could have gotten updated/migrated. I mean, I think that it is possible that total could be \u003e what actually needs to be migrated by this script. I don\u0027t know if that matters much or not. Right now, all you do is print out this value. But if someone is using the number for debugging (or someone changes the code and uses this value to eg compare total vs migrated) there could be some off-by-one-or-a-few numbers.","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7f3b74128b872f4408268ac66ba66dfd1669b794","unresolved":false,"context_lines":[{"line_number":1055,"context_line":"            with _session_for_read():"},{"line_number":1056,"context_line":"                query \u003d model_query(Model).filter(Model.version.is_(None))"},{"line_number":1057,"context_line":"                count_all \u003d query.count()"},{"line_number":1058,"context_line":"            total +\u003d count_all"},{"line_number":1059,"context_line":"        for Model in Models:"},{"line_number":1060,"context_line":"            with _session_for_write():"},{"line_number":1061,"context_line":"                query \u003d model_query(Model).filter(Model.version.is_(None))"}],"source_content_type":"text/x-python","patch_set":25,"id":"7a3c09a3_1daef897","line":1058,"in_reply_to":"7a3c09a3_533336ab","updated":"2017-01-17 14:55:41.000000000","message":"I agree, though this error impact will be minimized, because only the new release version is running by the time this script is run. I think in our (upgrade) usage case, the worst scenario will be that not enough objects are migrated (since some could be migrated or simply deleted by another process), so the script will be run one more extra time. It will happen transparently when used with the --max_count parameter.","commit_id":"1c8426341ae9b0c5543b32b3d9d7413eaa3f2f5b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7c24f282095366c42a2502771c73cf5088a5a8fa","unresolved":false,"context_lines":[{"line_number":1066,"context_line":"                    {model.version: MAPPING[model.__name__]})"},{"line_number":1067,"context_line":"            migrated +\u003d count_hit"},{"line_number":1068,"context_line":"            if max_count and migrated \u003e\u003d max_count:"},{"line_number":1069,"context_line":"                break"},{"line_number":1070,"context_line":"        return total, migrated"}],"source_content_type":"text/x-python","patch_set":27,"id":"7a3c09a3_d0cc3cbd","line":1069,"updated":"2017-01-17 22:05:00.000000000","message":"I was thinking about this issue of getting the total first, then doing the changes, and how the total number may not be accurate any more.\n\nI\u0027m not totally concerned about this particular method. What I am concerned about is copy/paste in the future, if someone chooses to use this as a model for their own migration script.\n\nI was going to propose a solution so that the total is more accurate, but maybe I am expecting/asking too much, so I\u0027ll be ok if we add a note here that we know that the total may not be quite accurate but will be good enough.","commit_id":"1ca586cdc9e26f870bdf0b0cb10051884cc10052"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"cfe2ed01bfc927d6b61caf7981d77d44bfca841f","unresolved":false,"context_lines":[{"line_number":1066,"context_line":"                    {model.version: MAPPING[model.__name__]})"},{"line_number":1067,"context_line":"            migrated +\u003d count_hit"},{"line_number":1068,"context_line":"            if max_count and migrated \u003e\u003d max_count:"},{"line_number":1069,"context_line":"                break"},{"line_number":1070,"context_line":"        return total, migrated"}],"source_content_type":"text/x-python","patch_set":27,"id":"5a3905b3_975fb071","line":1069,"in_reply_to":"7a3c09a3_d0cc3cbd","updated":"2017-01-19 14:50:43.000000000","message":"I added a note.","commit_id":"1ca586cdc9e26f870bdf0b0cb10051884cc10052"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"41e9b4456d41c9fb45f1a45c29fead048a815985","unresolved":false,"context_lines":[{"line_number":1065,"context_line":"            if count \u003d\u003d 0:"},{"line_number":1066,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"    def check_versions(self):"},{"line_number":1069,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1070,"context_line":"        for model in models.Base.__subclasses__():"},{"line_number":1071,"context_line":"            if model.__name__ in old_object_versions:"}],"source_content_type":"text/x-python","patch_set":31,"id":"3a461143_6b279a12","line":1068,"updated":"2017-01-26 18:05:51.000000000","message":"Are there any unit tests for this?","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d4f438b7c75328f804c5adf232bdb2c2323664f","unresolved":false,"context_lines":[{"line_number":1065,"context_line":"            if count \u003d\u003d 0:"},{"line_number":1066,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"    def check_versions(self):"},{"line_number":1069,"context_line":"        old_object_versions \u003d versions.BASE_RELEASE[\u0027objects\u0027]"},{"line_number":1070,"context_line":"        for model in models.Base.__subclasses__():"},{"line_number":1071,"context_line":"            if model.__name__ in old_object_versions:"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a1ced50_02074882","line":1068,"in_reply_to":"3a461143_6b279a12","updated":"2017-03-23 01:27:03.000000000","message":"Done","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"41e9b4456d41c9fb45f1a45c29fead048a815985","unresolved":false,"context_lines":[{"line_number":1077,"context_line":"                    return False"},{"line_number":1078,"context_line":"        return True"},{"line_number":1079,"context_line":""},{"line_number":1080,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":1081,"context_line":"        total \u003d 0"},{"line_number":1082,"context_line":"        migrated \u003d 0"},{"line_number":1083,"context_line":"        # backfill only Newton objects"}],"source_content_type":"text/x-python","patch_set":31,"id":"3a461143_ab2182fd","line":1080,"updated":"2017-01-26 18:05:51.000000000","message":"Are there any unit tests for this?","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"7d4f438b7c75328f804c5adf232bdb2c2323664f","unresolved":false,"context_lines":[{"line_number":1077,"context_line":"                    return False"},{"line_number":1078,"context_line":"        return True"},{"line_number":1079,"context_line":""},{"line_number":1080,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":1081,"context_line":"        total \u003d 0"},{"line_number":1082,"context_line":"        migrated \u003d 0"},{"line_number":1083,"context_line":"        # backfill only Newton objects"}],"source_content_type":"text/x-python","patch_set":31,"id":"1a1ced50_220a848a","line":1080,"in_reply_to":"3a461143_ab2182fd","updated":"2017-03-23 01:27:03.000000000","message":"Done","commit_id":"6b805a9eba32309435bea1dc5fea9faac653570d"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"a690751125192a485e9eb8c313453dee810dcf0d","unresolved":false,"context_lines":[{"line_number":1099,"context_line":"        total \u003d 0"},{"line_number":1100,"context_line":"        migrated \u003d 0"},{"line_number":1101,"context_line":"        # backfill only Newton objects"},{"line_number":1102,"context_line":"        MAPPING \u003d versions.RELEASE_MAPPING[\u0027newton\u0027][\u0027objects\u0027]"},{"line_number":1103,"context_line":"        sql_models \u003d [model for model in models.Base.__subclasses__()"},{"line_number":1104,"context_line":"                      if model.__name__ in MAPPING]"},{"line_number":1105,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":35,"id":"ba2be162_83e6ad42","line":1102,"updated":"2017-03-06 20:18:07.000000000","message":"s/newton/ocata/","commit_id":"abc7bdfe359a592c1d1cd42282355b5feb17cc68"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"0b744f1132de10350a7afdd18a748b3d29d72f66","unresolved":false,"context_lines":[{"line_number":1099,"context_line":"        total \u003d 0"},{"line_number":1100,"context_line":"        migrated \u003d 0"},{"line_number":1101,"context_line":"        # backfill only Newton objects"},{"line_number":1102,"context_line":"        MAPPING \u003d versions.RELEASE_MAPPING[\u0027newton\u0027][\u0027objects\u0027]"},{"line_number":1103,"context_line":"        sql_models \u003d [model for model in models.Base.__subclasses__()"},{"line_number":1104,"context_line":"                      if model.__name__ in MAPPING]"},{"line_number":1105,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":35,"id":"1a1ced50_cc275fb4","line":1102,"in_reply_to":"ba2be162_83e6ad42","updated":"2017-03-21 21:24:18.000000000","message":"Done","commit_id":"abc7bdfe359a592c1d1cd42282355b5feb17cc68"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":29,"context_line":"from oslo_utils import strutils"},{"line_number":30,"context_line":"from oslo_utils import timeutils"},{"line_number":31,"context_line":"from oslo_utils import uuidutils"},{"line_number":32,"context_line":"from sqlalchemy.orm.exc import NoResultFound, MultipleResultsFound"},{"line_number":33,"context_line":"from sqlalchemy.orm import joinedload"},{"line_number":34,"context_line":"from sqlalchemy import sql"},{"line_number":35,"context_line":""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_6ccf4756","side":"PARENT","line":32,"updated":"2017-03-27 22:38:49.000000000","message":"Just an aside -- I don\u0027t review much Ironic code, but I\u0027m surprised that ironic doesn\u0027t follow pep8\u0027s H301 and H302.","commit_id":"07ea034f21daf45a808bc6df4f31cec92f1e7e44"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":29,"context_line":"from oslo_utils import strutils"},{"line_number":30,"context_line":"from oslo_utils import timeutils"},{"line_number":31,"context_line":"from oslo_utils import uuidutils"},{"line_number":32,"context_line":"from sqlalchemy.orm.exc import NoResultFound, MultipleResultsFound"},{"line_number":33,"context_line":"from sqlalchemy.orm import joinedload"},{"line_number":34,"context_line":"from sqlalchemy import sql"},{"line_number":35,"context_line":""}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_899c96c0","side":"PARENT","line":32,"in_reply_to":"ffe62b97_6ccf4756","updated":"2017-03-28 18:36:48.000000000","message":"I thought ironic did too. Looks like sqlalchemy is an exception for H301 [1]. Not sure about H302, did it get removed?\n\n[1] https://docs.openstack.org/developer/hacking/#imports","commit_id":"07ea034f21daf45a808bc6df4f31cec92f1e7e44"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":1142,"context_line":"        return True"},{"line_number":1143,"context_line":""},{"line_number":1144,"context_line":"    @oslo_db_api.retry_on_deadlock"},{"line_number":1145,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":1146,"context_line":"        \"\"\"Backfill the version column with Ocata versions."},{"line_number":1147,"context_line":""},{"line_number":1148,"context_line":"        The version column was added to all the resource tables in this"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_6c262718","line":1145,"updated":"2017-03-27 22:38:49.000000000","message":"There are EIGHT variables in this method.that are basically responsible for counting various things:\n\n  1. total\n  2. migrated\n  3. count_all\n  4. max_count\n  5. count_hit\n  6. max_left\n  7. num_objs\n  8. num\n\nAnd after reading through the entire method, and looking back at this list, I couldn\u0027t tell you what most of these variables are used for... which tells me that this method needs to be HEAVILY refactored, and (likely) better variable names chosen (or simply eliminated) throughout.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":1142,"context_line":"        return True"},{"line_number":1143,"context_line":""},{"line_number":1144,"context_line":"    @oslo_db_api.retry_on_deadlock"},{"line_number":1145,"context_line":"    def backfill_version_column(self, max_count):"},{"line_number":1146,"context_line":"        \"\"\"Backfill the version column with Ocata versions."},{"line_number":1147,"context_line":""},{"line_number":1148,"context_line":"        The version column was added to all the resource tables in this"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_50dceae2","line":1145,"in_reply_to":"ffe62b97_6c262718","updated":"2017-03-28 18:36:48.000000000","message":"I think it is down to 5 or 6; I forgot already. Let me know if it still bothers you.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":1172,"context_line":"                count_all \u003d query.count()"},{"line_number":1173,"context_line":"            total +\u003d count_all"},{"line_number":1174,"context_line":""},{"line_number":1175,"context_line":"        if total \u003d\u003d 0 or max_count \u003c 0:"},{"line_number":1176,"context_line":"            return total, migrated"},{"line_number":1177,"context_line":""},{"line_number":1178,"context_line":"        # NOTE(xek): Each of these operations happen in different transactions."}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_6cf8677a","line":1175,"updated":"2017-03-27 22:38:49.000000000","message":"This second condition should be impossible.\n\n  if not total:","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":1172,"context_line":"                count_all \u003d query.count()"},{"line_number":1173,"context_line":"            total +\u003d count_all"},{"line_number":1174,"context_line":""},{"line_number":1175,"context_line":"        if total \u003d\u003d 0 or max_count \u003c 0:"},{"line_number":1176,"context_line":"            return total, migrated"},{"line_number":1177,"context_line":""},{"line_number":1178,"context_line":"        # NOTE(xek): Each of these operations happen in different transactions."}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_dae49e0f","line":1175,"in_reply_to":"ffe62b97_6cf8677a","updated":"2017-03-28 18:36:48.000000000","message":"Done","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":1186,"context_line":"        # By the time this script is run, only the new release version is"},{"line_number":1187,"context_line":"        # running, so the impact of this error will be minimal - the operator"},{"line_number":1188,"context_line":"        # will run this script more than once to ensure that all data have been"},{"line_number":1189,"context_line":"        # migrated. This will happen transparently when --max_count is used."},{"line_number":1190,"context_line":"        max_left \u003d max_count or total"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_ec31175c","line":1189,"updated":"2017-03-27 22:38:49.000000000","message":"Only when --max-count is used? My understanding is that will always be true.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":1186,"context_line":"        # By the time this script is run, only the new release version is"},{"line_number":1187,"context_line":"        # running, so the impact of this error will be minimal - the operator"},{"line_number":1188,"context_line":"        # will run this script more than once to ensure that all data have been"},{"line_number":1189,"context_line":"        # migrated. This will happen transparently when --max_count is used."},{"line_number":1190,"context_line":"        max_left \u003d max_count or total"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_69bef2b4","line":1189,"in_reply_to":"ffe62b97_ec31175c","updated":"2017-03-28 18:36:48.000000000","message":"Hmm. To be honest, I don\u0027t know what this last sentence (the \u0027This\u0027) refers to. I\u0027m going to delete it...","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"5bc2171b9f4b2e0a0b05b3f5092577a322160cb2","unresolved":false,"context_lines":[{"line_number":1187,"context_line":"        # running, so the impact of this error will be minimal - the operator"},{"line_number":1188,"context_line":"        # will run this script more than once to ensure that all data have been"},{"line_number":1189,"context_line":"        # migrated. This will happen transparently when --max_count is used."},{"line_number":1190,"context_line":"        max_left \u003d max_count or total"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        for model in sql_models:"},{"line_number":1193,"context_line":"            count_hit \u003d 0"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_ac378f4d","line":1190,"updated":"2017-03-27 22:38:49.000000000","message":"Why would max count be falsey? I assume this will always evaluate as\n\n  max_left \u003d max_count","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":1187,"context_line":"        # running, so the impact of this error will be minimal - the operator"},{"line_number":1188,"context_line":"        # will run this script more than once to ensure that all data have been"},{"line_number":1189,"context_line":"        # migrated. This will happen transparently when --max_count is used."},{"line_number":1190,"context_line":"        max_left \u003d max_count or total"},{"line_number":1191,"context_line":""},{"line_number":1192,"context_line":"        for model in sql_models:"},{"line_number":1193,"context_line":"            count_hit \u003d 0"}],"source_content_type":"text/x-python","patch_set":42,"id":"ffe62b97_4459d38b","line":1190,"in_reply_to":"ffe62b97_ac378f4d","updated":"2017-03-28 18:36:48.000000000","message":"If max_count is zero, it means migrate all of them, where all \u003d\u003d total.\n\nI could change it to if max_count \u003d\u003d 0: max_left \u003d total. but if i did that, I would bet that someone would say to do what is here. I\u0027ll add a comment.","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"568a331f72f81331a4251974953e8bbeb8c185a1","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"from ironic.common import exception"},{"line_number":37,"context_line":"from ironic.common.i18n import _"},{"line_number":38,"context_line":"from ironic.common import release_mappings as versions"},{"line_number":39,"context_line":"from ironic.common import states"},{"line_number":40,"context_line":"from ironic.conf import CONF"},{"line_number":41,"context_line":"from ironic.db import api"}],"source_content_type":"text/x-python","patch_set":52,"id":"7f231b9d_7c768372","line":38,"updated":"2017-06-16 17:16:02.000000000","message":"Nit: Not sure why change name from \u0027release_mappings\u0027 to \u0027versions\u0027","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4c4eb64d3bdfc09b6a56570a6a24dcf299cef77f","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"from ironic.common import exception"},{"line_number":37,"context_line":"from ironic.common.i18n import _"},{"line_number":38,"context_line":"from ironic.common import release_mappings as versions"},{"line_number":39,"context_line":"from ironic.common import states"},{"line_number":40,"context_line":"from ironic.conf import CONF"},{"line_number":41,"context_line":"from ironic.db import api"}],"source_content_type":"text/x-python","patch_set":52,"id":"5f201791_43dcc473","line":38,"in_reply_to":"7f231b9d_1b5d2a78","updated":"2017-06-20 21:42:51.000000000","message":"I made this change where it was \u0027easy\u0027 to do :-)","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"3d288df4e44b595a3bbbf54d24ef7ae66e54b2ee","unresolved":false,"context_lines":[{"line_number":35,"context_line":""},{"line_number":36,"context_line":"from ironic.common import exception"},{"line_number":37,"context_line":"from ironic.common.i18n import _"},{"line_number":38,"context_line":"from ironic.common import release_mappings as versions"},{"line_number":39,"context_line":"from ironic.common import states"},{"line_number":40,"context_line":"from ironic.conf import CONF"},{"line_number":41,"context_line":"from ironic.db import api"}],"source_content_type":"text/x-python","patch_set":52,"id":"7f231b9d_1b5d2a78","line":38,"in_reply_to":"7f231b9d_7c768372","updated":"2017-06-19 16:18:18.000000000","message":"because other code does this, but I agree with you, release_mappings is easier for me :-)","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"568a331f72f81331a4251974953e8bbeb8c185a1","unresolved":false,"context_lines":[{"line_number":1125,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"    def check_versions(self):"},{"line_number":1128,"context_line":"        \"\"\"Checks the whole database for incompatible objects."},{"line_number":1129,"context_line":""},{"line_number":1130,"context_line":"        This scans all the tables in search of objects older then those"},{"line_number":1131,"context_line":"        specified in `ironic.common.release_mapping.BASE_RELEASE` -- the oldest"}],"source_content_type":"text/x-python","patch_set":52,"id":"7f231b9d_dc30f758","line":1128,"updated":"2017-06-16 17:16:02.000000000","message":"I don\u0027t think this is correct.\n\nOur versions go like:\n\n 1.1, 1.2, ..., 1.9, 1.10, 1.11\n\nSo 1.11 \u003e 1.2\n\nBut in decimal: 1.2 \u003e 1.11","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4c4eb64d3bdfc09b6a56570a6a24dcf299cef77f","unresolved":false,"context_lines":[{"line_number":1125,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"    def check_versions(self):"},{"line_number":1128,"context_line":"        \"\"\"Checks the whole database for incompatible objects."},{"line_number":1129,"context_line":""},{"line_number":1130,"context_line":"        This scans all the tables in search of objects older then those"},{"line_number":1131,"context_line":"        specified in `ironic.common.release_mapping.BASE_RELEASE` -- the oldest"}],"source_content_type":"text/x-python","patch_set":52,"id":"5f201791_23c2e886","line":1128,"in_reply_to":"5f201791_5ef4a95b","updated":"2017-06-20 21:42:51.000000000","message":"So just to recap -- I need to check that the DB version is not equal to *any* of the supported versions, not just the lowest-supported version, since we are doing string compares instead of a \u003c. Eg, object in Release N-1 could be in v1.4, and object in Release N could be in v1.5. I can\u0027t just compare db-version with 1.4, need to also check it isn\u0027t 1.5.","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2eda182761814f521373f77d205ab189c5597966","unresolved":false,"context_lines":[{"line_number":1125,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"    def check_versions(self):"},{"line_number":1128,"context_line":"        \"\"\"Checks the whole database for incompatible objects."},{"line_number":1129,"context_line":""},{"line_number":1130,"context_line":"        This scans all the tables in search of objects older then those"},{"line_number":1131,"context_line":"        specified in `ironic.common.release_mapping.BASE_RELEASE` -- the oldest"}],"source_content_type":"text/x-python","patch_set":52,"id":"5f201791_5ef4a95b","line":1128,"in_reply_to":"5f201791_b89195f4","updated":"2017-06-20 14:42:01.000000000","message":"Just had an irc discussion with Julia and she had a great idea. Just check for versions !\u003d supported versions, a string comparison in SQL :-)\nI need to think about the case where version \u003e supported version -- I\u0027m not sure that could ever happen though (cuz, you know, it isn\u0027t supported yet!)","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"c07b86fbc558d9b37d1afa2d334068b5b8e526dc","unresolved":false,"context_lines":[{"line_number":1125,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"    def check_versions(self):"},{"line_number":1128,"context_line":"        \"\"\"Checks the whole database for incompatible objects."},{"line_number":1129,"context_line":""},{"line_number":1130,"context_line":"        This scans all the tables in search of objects older then those"},{"line_number":1131,"context_line":"        specified in `ironic.common.release_mapping.BASE_RELEASE` -- the oldest"}],"source_content_type":"text/x-python","patch_set":52,"id":"5f201791_b89195f4","line":1128,"in_reply_to":"7f231b9d_160a9f1e","updated":"2017-06-20 13:55:03.000000000","message":"I looked into this. I don\u0027t know much about sql, looked at the available functions there, and didn\u0027t see anything that would process the version string the way we\u0027d like (or at least, I didn\u0027t figure out any obvious way that would be performant).\n\nMy thinking now is to store the version as an integer, which would make this check really easy. oslo_utils.versionutils has some functions to convert from/to int (so eg 1.3\u003d\u003d1003, 1.345\u003d1345, 1.3.5\u003d1003005). The VersionObject layer would continue to treat it as a string (I\u0027m not touching ovo code, that would be suicide); it\u0027d just be an integer in the DB.\n\nWhat do people think? Do people think the version value should be the string? Can I modify the version column to be an Integer (instead of a String) now or is it too late? That code landed Jun 9...\n\nAlternatively, I can grab all the records from the DB and go through them one by one. This check is done every time \u0027dbsync upgrade\u0027 or \u0027dbsync online_data_migration\u0027 is called. At what point (#objects/rows) would this noticeably slow down for operators?","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"3d288df4e44b595a3bbbf54d24ef7ae66e54b2ee","unresolved":false,"context_lines":[{"line_number":1125,"context_line":"                raise exception.VolumeTargetNotFound(target\u003dident)"},{"line_number":1126,"context_line":""},{"line_number":1127,"context_line":"    def check_versions(self):"},{"line_number":1128,"context_line":"        \"\"\"Checks the whole database for incompatible objects."},{"line_number":1129,"context_line":""},{"line_number":1130,"context_line":"        This scans all the tables in search of objects older then those"},{"line_number":1131,"context_line":"        specified in `ironic.common.release_mapping.BASE_RELEASE` -- the oldest"}],"source_content_type":"text/x-python","patch_set":52,"id":"7f231b9d_160a9f1e","line":1128,"in_reply_to":"7f231b9d_dc30f758","updated":"2017-06-19 16:18:18.000000000","message":"Boo hoo hoo.\n\nGood catch :-)","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"ad836df3d1e6bf3403c1103a733e2d804813a611","unresolved":false,"context_lines":[{"line_number":1141,"context_line":"                supported_version \u003d decimal.Decimal("},{"line_number":1142,"context_line":"                    base_object_versions[model.__name__])"},{"line_number":1143,"context_line":"                query \u003d model_query(model).filter("},{"line_number":1144,"context_line":"                    sql.cast(model.version, Numeric(9, 2)) \u003c supported_version)"},{"line_number":1145,"context_line":"                if query.count():"},{"line_number":1146,"context_line":"                    return False"},{"line_number":1147,"context_line":"        return True"}],"source_content_type":"text/x-python","patch_set":52,"id":"5f201791_d809f131","line":1144,"updated":"2017-06-20 13:56:53.000000000","message":"This is also wrong if we assume that a version can be in the form 1.2.3 :-(. I suspect we will never use versions like that but we\u0027ve also never explicitly said anything.","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":1171,"context_line":"        sql_models \u003d [model for model in models.Base.__subclasses__()"},{"line_number":1172,"context_line":"                      if model.__name__ in mapping]"},{"line_number":1173,"context_line":"        for model in sql_models:"},{"line_number":1174,"context_line":"            with _session_for_read():"},{"line_number":1175,"context_line":"                query \u003d model_query(model).filter(model.version.is_(None))"},{"line_number":1176,"context_line":"                total_to_migrate +\u003d query.count()"},{"line_number":1177,"context_line":""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_38c9ea77","line":1174,"range":{"start_line":1174,"start_character":17,"end_line":1174,"end_character":36},"updated":"2017-07-24 12:28:48.000000000","message":"hrm, there is a session_for_read inside the model_qery, do we need one more here?","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":1171,"context_line":"        sql_models \u003d [model for model in models.Base.__subclasses__()"},{"line_number":1172,"context_line":"                      if model.__name__ in mapping]"},{"line_number":1173,"context_line":"        for model in sql_models:"},{"line_number":1174,"context_line":"            with _session_for_read():"},{"line_number":1175,"context_line":"                query \u003d model_query(model).filter(model.version.is_(None))"},{"line_number":1176,"context_line":"                total_to_migrate +\u003d query.count()"},{"line_number":1177,"context_line":""}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_9900ca36","line":1174,"range":{"start_line":1174,"start_character":17,"end_line":1174,"end_character":36},"in_reply_to":"ff346bd7_38c9ea77","updated":"2017-07-24 21:16:48.000000000","message":"good catch. True, it isn\u0027t needed. It won\u0027t hurt but yeah.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"6b9f98b7487e3e82ebcfbe54bf643f352ffdd0f1","unresolved":false,"context_lines":[{"line_number":1191,"context_line":"        # operator will run this script more than once to ensure that all"},{"line_number":1192,"context_line":"        # data have been migrated."},{"line_number":1193,"context_line":""},{"line_number":1194,"context_line":"        # If max_count is zero, we want to migrate all the objects."},{"line_number":1195,"context_line":"        max_to_migrate \u003d max_count or total_to_migrate"},{"line_number":1196,"context_line":""},{"line_number":1197,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_f82a42e5","line":1194,"range":{"start_line":1194,"start_character":26,"end_line":1194,"end_character":30},"updated":"2017-07-24 12:28:48.000000000","message":"None? Or rather, from what I see in code, we always pass a value \u003e\u003d 1 or 50 if it was not specified.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"3c7ce61e5f29404fdb67ca8043a5bb9d870ecbc4","unresolved":false,"context_lines":[{"line_number":1191,"context_line":"        # operator will run this script more than once to ensure that all"},{"line_number":1192,"context_line":"        # data have been migrated."},{"line_number":1193,"context_line":""},{"line_number":1194,"context_line":"        # If max_count is zero, we want to migrate all the objects."},{"line_number":1195,"context_line":"        max_to_migrate \u003d max_count or total_to_migrate"},{"line_number":1196,"context_line":""},{"line_number":1197,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_f5d7b94e","line":1194,"range":{"start_line":1194,"start_character":26,"end_line":1194,"end_character":30},"in_reply_to":"ff346bd7_bcaedce4","updated":"2017-07-25 15:03:04.000000000","message":"ok, gotcha.","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e7538caf261561fb70a72c46e7a4fcb4ad3470d9","unresolved":false,"context_lines":[{"line_number":1191,"context_line":"        # operator will run this script more than once to ensure that all"},{"line_number":1192,"context_line":"        # data have been migrated."},{"line_number":1193,"context_line":""},{"line_number":1194,"context_line":"        # If max_count is zero, we want to migrate all the objects."},{"line_number":1195,"context_line":"        max_to_migrate \u003d max_count or total_to_migrate"},{"line_number":1196,"context_line":""},{"line_number":1197,"context_line":"        for model in sql_models:"}],"source_content_type":"text/x-python","patch_set":63,"id":"ff346bd7_bcaedce4","line":1194,"range":{"start_line":1194,"start_character":26,"end_line":1194,"end_character":30},"in_reply_to":"ff346bd7_f82a42e5","updated":"2017-07-24 21:16:48.000000000","message":"That would work too, but since max_count is an integer, I am just using zero to flag that. If I use None, what would zero mean? (None isn\u0027t passed either, should I just remove these checks and not add code to migrate \u0027everything\u0027 at once?). I want a description for these functions that all future migration functions can adhere to. (See dbsync.py, L50-58).","commit_id":"4dfafdfbe092301811b68a05735f6db0464da4e8"},{"author":{"_account_id":12356,"name":"Vladyslav Drok","email":"vdrok@mirantis.com","username":"vdrok"},"change_message_id":"f29a5752281900b3fcd9052e77b22ec6af27ae5b","unresolved":false,"context_lines":[{"line_number":1140,"context_line":"                if not supported_versions:"},{"line_number":1141,"context_line":"                    continue"},{"line_number":1142,"context_line":"                query \u003d model_query(model).filter("},{"line_number":1143,"context_line":"                    sql.or_(model.version \u003d\u003d sql.null(),"},{"line_number":1144,"context_line":"                            model.version.notin_(supported_versions)))"},{"line_number":1145,"context_line":"                if query.count():"},{"line_number":1146,"context_line":"                    return False"}],"source_content_type":"text/x-python","patch_set":65,"id":"ff346bd7_66028b0c","line":1143,"range":{"start_line":1143,"start_character":28,"end_line":1143,"end_character":55},"updated":"2017-07-28 09:17:33.000000000","message":"is this one needed? I think None should not be in supported_versions","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"a3b3fd1da84c98c016dbbad864590c631a4d3ccb","unresolved":false,"context_lines":[{"line_number":1140,"context_line":"                if not supported_versions:"},{"line_number":1141,"context_line":"                    continue"},{"line_number":1142,"context_line":"                query \u003d model_query(model).filter("},{"line_number":1143,"context_line":"                    sql.or_(model.version \u003d\u003d sql.null(),"},{"line_number":1144,"context_line":"                            model.version.notin_(supported_versions)))"},{"line_number":1145,"context_line":"                if query.count():"},{"line_number":1146,"context_line":"                    return False"}],"source_content_type":"text/x-python","patch_set":65,"id":"df3967d1_60ae932f","line":1143,"range":{"start_line":1143,"start_character":28,"end_line":1143,"end_character":55},"in_reply_to":"ff346bd7_66028b0c","updated":"2017-07-31 15:45:56.000000000","message":"Unfortunately, it is needed. The .notin_() doesn\u0027t take into account the null values: http://docs.sqlalchemy.org/en/latest/core/sqlelement.html#sqlalchemy.sql.operators.ColumnOperators.notin_","commit_id":"984724d0f82623cb704877ab67e15e9dfee538a1"}],"ironic/tests/unit/db/test_api.py":[{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"6e106703f512fa57d957a060f032970557bf5358","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":52,"id":"7f231b9d_8757e2ca","updated":"2017-06-15 21:42:55.000000000","message":"This seems to be testing:  ironic/db/sqlalchemy/api.py\n\nWhy don\u0027t the tests go in: ironic/tests/unit/db/sqlalchemy/test_api.py  ?","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":14760,"name":"John L. Villalovos","email":"openstack.org@sodarock.com","username":"jlvillal"},"change_message_id":"08d43270e639111e2eb0099e5b869f973b1fe5a6","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":52,"id":"7f231b9d_c72f1a3d","in_reply_to":"7f231b9d_8757e2ca","updated":"2017-06-15 21:44:42.000000000","message":"I think this might be the thing that has always confused me on our unit tests and the database tests. Where they seem to be in the wrong directory in my simplistic view.","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"338f4d10b6705c5872b370cb27346fc7887280cc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":52,"id":"7f231b9d_12e4323b","in_reply_to":"7f231b9d_c72f1a3d","updated":"2017-06-15 22:25:02.000000000","message":"I agree that there isn\u0027t total consistency. Hard to say whether it was unintentional, and/or some of the directories changed on the code side but test side didn\u0027t. This particular file is consistent with what is there already; I think if we want to fix, someone should move them all (or the ones that make sense to be moved).\n\nOf all the things that confuse me, this is one of the less confusing things though :)","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"}],"releasenotes/notes/dbsync-online_data_migration-edcf0b1cc3667582.yaml":[{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"5af8198cf6d567477e2d1505b44973138d305dac","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introducing dbsync online_data_migration command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - dbsync online_data_migration command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3a71b18c_363177ed","line":3,"updated":"2016-12-08 15:02:07.000000000","message":"s/Introducing/Introduces/","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introducing dbsync online_data_migration command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - dbsync online_data_migration command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"}],"source_content_type":"text/x-yaml","patch_set":2,"id":"1a6eadb0_5cad7187","line":3,"in_reply_to":"3a71b18c_363177ed","updated":"2016-12-12 16:46:34.000000000","message":"Done","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"5af8198cf6d567477e2d1505b44973138d305dac","unresolved":false,"context_lines":[{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"},{"line_number":7,"context_line":"    converted to the newest format. It must be run"},{"line_number":8,"context_line":"    before starting a new upgrade to the next named"},{"line_number":9,"context_line":"    release."}],"source_content_type":"text/x-yaml","patch_set":2,"id":"3a71b18c_b6b4a7d1","line":9,"updated":"2016-12-08 15:02:07.000000000","message":"We should update https://github.com/openstack/ironic/blob/master/doc/source/cmds/ironic-dbsync.rst\n\nand then maybe put a pointer to that page here. Something like \u0027For more information about this command, see http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html\u0027.","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"854eab081612781c09ec074b171a649c55b1802c","unresolved":false,"context_lines":[{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"},{"line_number":7,"context_line":"    converted to the newest format. It must be run"},{"line_number":8,"context_line":"    before starting a new upgrade to the next named"},{"line_number":9,"context_line":"    release."}],"source_content_type":"text/x-yaml","patch_set":2,"id":"1a6eadb0_6d6c399d","line":9,"in_reply_to":"3a71b18c_b6b4a7d1","updated":"2016-12-12 16:46:34.000000000","message":"Done","commit_id":"4b1716eda5d6e2bbfa96f0f73d6a60df74164ca9"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces dbsync online_data_migration command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - dbsync online_data_migration command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"},{"line_number":7,"context_line":"    converted to the newest format. It must be run"},{"line_number":8,"context_line":"    before starting a new upgrade to the next named"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"1a6eadb0_0ecc9134","line":5,"updated":"2016-12-12 22:47:30.000000000","message":"i wonder if we should do \u0027ironic dbsync online_data_migration\u0027 command ...","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"987cb9179e23c189bfafc9f6ee23e2d9dc6cf6f6","unresolved":false,"context_lines":[{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces dbsync online_data_migration command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - dbsync online_data_migration command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"},{"line_number":7,"context_line":"    converted to the newest format. It must be run"},{"line_number":8,"context_line":"    before starting a new upgrade to the next named"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"1a6eadb0_596d7131","line":5,"in_reply_to":"1a6eadb0_0ecc9134","updated":"2016-12-12 23:13:58.000000000","message":"Oh, it is s/dbsync/ironic-dbsync/","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces dbsync online_data_migration command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - dbsync online_data_migration command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are"},{"line_number":7,"context_line":"    converted to the newest format. It must be run"},{"line_number":8,"context_line":"    before starting a new upgrade to the next named"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"1a6eadb0_ebdb9eeb","line":5,"in_reply_to":"1a6eadb0_596d7131","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"2ad0974c885baf4a12fddd7990a7c259811c98b0","unresolved":false,"context_lines":[{"line_number":8,"context_line":"    before starting a new upgrade to the next named"},{"line_number":9,"context_line":"    release."},{"line_number":10,"context_line":"    For more information about this command, see"},{"line_number":11,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"1a6eadb0_4e5f6972","line":11,"updated":"2016-12-12 22:47:30.000000000","message":"nit, missing period at end.","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"13cae3cb42c403a1fa23bd062dfe915991d48bed","unresolved":false,"context_lines":[{"line_number":8,"context_line":"    before starting a new upgrade to the next named"},{"line_number":9,"context_line":"    release."},{"line_number":10,"context_line":"    For more information about this command, see"},{"line_number":11,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html"}],"source_content_type":"text/x-yaml","patch_set":4,"id":"1a6eadb0_0bd9baf3","line":11,"in_reply_to":"1a6eadb0_4e5f6972","updated":"2016-12-19 14:42:57.000000000","message":"Done","commit_id":"60be54b6bb0bb37712873351fa599e2345418536"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces dbsync online_data_migrations command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - ironic-dbsync online_data_migrations command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are converted"}],"source_content_type":"text/x-yaml","patch_set":17,"id":"ba5201f7_a1a51748","line":3,"updated":"2017-01-10 21:56:53.000000000","message":"I\u0027m not sure how useful this prelude is but if we want it, I think s/dbsync/ironic-dbsync/\n\nWe could put \u0027ironic-dbsync online_data_migrations\u0027 within quotation marks or something, here and at line 5.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces dbsync online_data_migrations command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - ironic-dbsync online_data_migrations command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are converted"}],"source_content_type":"text/x-yaml","patch_set":17,"id":"9a57fde8_b04684bd","line":3,"in_reply_to":"ba5201f7_a1a51748","updated":"2017-01-12 15:09:13.000000000","message":"Done","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4ed0316982bfd7cd45d845ed764179fa69e0078c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"ba5201f7_013b43ec","line":11,"updated":"2017-01-10 21:56:53.000000000","message":"I looked at the release notes, I think we should add an entry in \u0027features\u0027 too, since it is a new feature. (It could be part of the overall rolling upgrades feature, but just in case, I don\u0027t want to forget mentioning it.)","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":14250,"name":"Grzegorz Grasza","email":"xek@redhat.com","username":"xek"},"change_message_id":"7ff0a0342c755573e9ad8f46ca4669060a8558ef","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"9a57fde8_703c1c30","line":11,"in_reply_to":"ba5201f7_013b43ec","updated":"2017-01-12 15:09:13.000000000","message":"I\u0027ll add the features entry it in the documentation patch.","commit_id":"10f47576637b2178ef2c1de8371ac3a1b96cee56"},{"author":{"_account_id":10343,"name":"Jim Rollenhagen","email":"jim@jimrollenhagen.com","username":"jimrollenhagen"},"change_message_id":"a690751125192a485e9eb8c313453dee810dcf0d","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces \u0027ironic-dbsync online_data_migrations\u0027 command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - ironic-dbsync online_data_migrations command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are converted"}],"source_content_type":"text/x-yaml","patch_set":35,"id":"ba2be162_c32a652f","line":3,"updated":"2017-03-06 20:18:07.000000000","message":"We tend to write preludes shortly before we release, otherwise it just gets all jumbled. I\u0027d prefer to just leave this out of this patch.","commit_id":"abc7bdfe359a592c1d1cd42282355b5feb17cc68"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"0b744f1132de10350a7afdd18a748b3d29d72f66","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"prelude: \u003e"},{"line_number":3,"context_line":"    Introduces \u0027ironic-dbsync online_data_migrations\u0027 command."},{"line_number":4,"context_line":"upgrade:"},{"line_number":5,"context_line":"  - ironic-dbsync online_data_migrations command should be run"},{"line_number":6,"context_line":"    after each upgrade to ensure all DB records are converted"}],"source_content_type":"text/x-yaml","patch_set":35,"id":"1a1ced50_2c2393a8","line":3,"in_reply_to":"ba2be162_c32a652f","updated":"2017-03-21 21:24:18.000000000","message":"Done","commit_id":"abc7bdfe359a592c1d1cd42282355b5feb17cc68"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"f3e51138970cb4cd7f6dd6ce32c7218716dd1be6","unresolved":false,"context_lines":[{"line_number":3,"context_line":"  - The new ``ironic-dbsync online_data_migrations`` command should be"},{"line_number":4,"context_line":"    run after each upgrade to ensure all DB records are converted to the"},{"line_number":5,"context_line":"    newest format. It must be run before starting a new upgrade to the"},{"line_number":6,"context_line":"    next named release. For more information about this command, see"},{"line_number":7,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html."}],"source_content_type":"text/x-yaml","patch_set":42,"id":"ffe62b97_acbaef6a","line":6,"updated":"2017-03-27 22:48:12.000000000","message":"\u003e It must be run before starting a new upgrade to the next named release.\n\nThis either needs to expand substantially on when the command should be run, or (even better), the referenced documentation needs to go into more detail about when the command should be run (which it does not, at least in this patch).","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":3,"context_line":"  - The new ``ironic-dbsync online_data_migrations`` command should be"},{"line_number":4,"context_line":"    run after each upgrade to ensure all DB records are converted to the"},{"line_number":5,"context_line":"    newest format. It must be run before starting a new upgrade to the"},{"line_number":6,"context_line":"    next named release. For more information about this command, see"},{"line_number":7,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html."}],"source_content_type":"text/x-yaml","patch_set":42,"id":"ffe62b97_ffed11b7","line":6,"in_reply_to":"ffe62b97_acbaef6a","updated":"2017-03-28 18:36:48.000000000","message":"Yes, it is a bit confusing to follow. There is documentation with more details but it doesn\u0027t exist yet [1]. I\u0027m going to review/update all the release notes associated with rolling upgrades, at the end of all these patches (if there is an end :))\n\n[1] https://review.openstack.org/#/c/416565/","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":4,"name":"Dolph Mathews","email":"dolph.mathews@gmail.com","username":"dolph"},"change_message_id":"f3e51138970cb4cd7f6dd6ce32c7218716dd1be6","unresolved":false,"context_lines":[{"line_number":4,"context_line":"    run after each upgrade to ensure all DB records are converted to the"},{"line_number":5,"context_line":"    newest format. It must be run before starting a new upgrade to the"},{"line_number":6,"context_line":"    next named release. For more information about this command, see"},{"line_number":7,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html."}],"source_content_type":"text/x-yaml","patch_set":42,"id":"ffe62b97_0cc0bbe0","line":7,"updated":"2017-03-27 22:48:12.000000000","message":"The trailing period breaks this link. I assume we can use real RST-style links in release notes?","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"e91d7457b6b5afb0d89c9021c934853acf63935f","unresolved":false,"context_lines":[{"line_number":4,"context_line":"    run after each upgrade to ensure all DB records are converted to the"},{"line_number":5,"context_line":"    newest format. It must be run before starting a new upgrade to the"},{"line_number":6,"context_line":"    next named release. For more information about this command, see"},{"line_number":7,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html."}],"source_content_type":"text/x-yaml","patch_set":42,"id":"ffe62b97_7fe901b5","line":7,"in_reply_to":"ffe62b97_0cc0bbe0","updated":"2017-03-28 18:36:48.000000000","message":"It works for me. When I click on it [1], it goes to the dbsync page?\n\n[1] http://docs-draft.openstack.org/56/408556/42/check/gate-ironic-releasenotes/4bab858//releasenotes/build/html/unreleased.html#upgrade-notes","commit_id":"9d838aa6cca92b133b170fa523870d30ffac024b"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"b60da567714fa512cd12d590c2b63a8117c096fb","unresolved":false,"context_lines":[{"line_number":2,"context_line":"upgrade:"},{"line_number":3,"context_line":"  - The new ``ironic-dbsync online_data_migrations`` command should be"},{"line_number":4,"context_line":"    run after each upgrade to ensure all DB records are converted to the"},{"line_number":5,"context_line":"    newest format. It must be run before starting a new upgrade to the"},{"line_number":6,"context_line":"    next named release. For more information about this command, see"},{"line_number":7,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html."}],"source_content_type":"text/x-yaml","patch_set":52,"id":"7f231b9d_941b9dc8","line":5,"range":{"start_line":5,"start_character":41,"end_line":5,"end_character":55},"updated":"2017-06-15 15:36:38.000000000","message":"nit: I feel like maybe \"starting the software as part of\" might be a better way to stress use, since the command would have to be installed anyway to run, unless pinned, which might be something we should consider detailing as part of the upgrade note?  Maybe?","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"},{"author":{"_account_id":6618,"name":"Ruby Loo","email":"opensrloo@gmail.com","username":"rloo"},"change_message_id":"4c4eb64d3bdfc09b6a56570a6a24dcf299cef77f","unresolved":false,"context_lines":[{"line_number":2,"context_line":"upgrade:"},{"line_number":3,"context_line":"  - The new ``ironic-dbsync online_data_migrations`` command should be"},{"line_number":4,"context_line":"    run after each upgrade to ensure all DB records are converted to the"},{"line_number":5,"context_line":"    newest format. It must be run before starting a new upgrade to the"},{"line_number":6,"context_line":"    next named release. For more information about this command, see"},{"line_number":7,"context_line":"    http://docs.openstack.org/developer/ironic/cmds/ironic-dbsync.html."}],"source_content_type":"text/x-yaml","patch_set":52,"id":"5f201791_83f2dc05","line":5,"range":{"start_line":5,"start_character":41,"end_line":5,"end_character":55},"in_reply_to":"7f231b9d_941b9dc8","updated":"2017-06-20 21:42:51.000000000","message":"Done","commit_id":"384e022bbda4448d41b7509aaf046fae14d06c14"}]}
