)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":10,"context_line":"API. Then the user could reset the instance keypair"},{"line_number":11,"context_line":"when rebuilding."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"APIImpact"},{"line_number":14,"context_line":"DocImpact"},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Implements blueprint: rebuild-keypair-reset"},{"line_number":17,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"3f4b6375_206a4119","line":14,"range":{"start_line":13,"start_character":0,"end_line":14,"end_character":9},"updated":"2017-11-04 01:06:21.000000000","message":"These tags can be removed. The DocImpact tag will actually generate a nova bug in launchpad and any documentation changes we need for this feature should be in this patch itself (API reference changes and release note).","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":10,"context_line":"API. Then the user could reset the instance keypair"},{"line_number":11,"context_line":"when rebuilding."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"APIImpact"},{"line_number":14,"context_line":"DocImpact"},{"line_number":15,"context_line":""},{"line_number":16,"context_line":"Implements blueprint: rebuild-keypair-reset"},{"line_number":17,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":12,"id":"3f4b6375_5c8be5be","line":14,"range":{"start_line":13,"start_character":0,"end_line":14,"end_character":9},"in_reply_to":"3f4b6375_206a4119","updated":"2017-11-04 13:43:46.000000000","message":"Done, next patch will remove this. And we already have a release note.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"fdfc9e9374d83abc7d3e8326d95fcc7cb8bf8ea9","unresolved":false,"context_lines":[{"line_number":9,"context_line":"This patch adds `key_name` param to instance rebuild"},{"line_number":10,"context_line":"API. Then the user could reset the instance keypair"},{"line_number":11,"context_line":"when rebuilding. If set key_name to None, the API"},{"line_number":12,"context_line":"will unset the keypair of instance."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"APIImpact"},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":14,"id":"1f485f77_994fbdbc","line":12,"range":{"start_line":12,"start_character":23,"end_line":12,"end_character":35},"updated":"2017-11-13 01:26:15.000000000","message":"s/of instance/of the instance","commit_id":"7ab490cc8345921adec154c89edc90b022127511"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b03016e48396e333cd43a1c3adbcddac22282dbf","unresolved":false,"context_lines":[{"line_number":9,"context_line":"This patch adds `key_name` param to instance rebuild"},{"line_number":10,"context_line":"API. Then the user could reset the instance keypair"},{"line_number":11,"context_line":"when rebuilding. If set key_name to None, the API"},{"line_number":12,"context_line":"will unset the keypair of instance."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"APIImpact"},{"line_number":15,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":14,"id":"1f485f77_7c2bcf93","line":12,"range":{"start_line":12,"start_character":23,"end_line":12,"end_character":35},"in_reply_to":"1f485f77_994fbdbc","updated":"2017-11-13 02:46:55.000000000","message":"Done","commit_id":"7ab490cc8345921adec154c89edc90b022127511"}],"api-ref/source/parameters.yaml":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fb6b5b097e3dd7a82d73266aab9df2075aa50204","unresolved":false,"context_lines":[{"line_number":3498,"context_line":"    Key pair name for rebuild API."},{"line_number":3499,"context_line":""},{"line_number":3500,"context_line":"    .. note:: Users within the same project are able to rebuild other"},{"line_number":3501,"context_line":"              user\u0027s instances in that project with a new keypair. See"},{"line_number":3502,"context_line":"              `Security impact"},{"line_number":3503,"context_line":"              \u003chttps://specs.openstack.org/openstack/nova-specs/specs/queens/approved/rebuild-keypair-reset.html#security-impact\u003e`_"},{"line_number":3504,"context_line":"              for more info."},{"line_number":3505,"context_line":"  in: body"},{"line_number":3506,"context_line":"  required: false"},{"line_number":3507,"context_line":"  type: string"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"1f485f77_36746235","line":3504,"range":{"start_line":3501,"start_character":67,"end_line":3504,"end_character":28},"updated":"2017-11-11 17:42:09.000000000","message":"Rather than making people go read a paragraph in the spec, let\u0027s just work the important part of that spec here, from:\n\n\"Keys are owned by users (which is the only resource that’s true of). Servers are owned by projects. Because of this a rebuild with a key_name is looking up the keypair by the user calling rebuild.\"","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"9eb2fde0002569fb2af2ebf9ce53bfefae73ca7c","unresolved":false,"context_lines":[{"line_number":3498,"context_line":"    Key pair name for rebuild API."},{"line_number":3499,"context_line":""},{"line_number":3500,"context_line":"    .. note:: Users within the same project are able to rebuild other"},{"line_number":3501,"context_line":"              user\u0027s instances in that project with a new keypair. See"},{"line_number":3502,"context_line":"              `Security impact"},{"line_number":3503,"context_line":"              \u003chttps://specs.openstack.org/openstack/nova-specs/specs/queens/approved/rebuild-keypair-reset.html#security-impact\u003e`_"},{"line_number":3504,"context_line":"              for more info."},{"line_number":3505,"context_line":"  in: body"},{"line_number":3506,"context_line":"  required: false"},{"line_number":3507,"context_line":"  type: string"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"1f485f77_5c1b7d1a","line":3504,"range":{"start_line":3501,"start_character":67,"end_line":3504,"end_character":28},"in_reply_to":"1f485f77_36746235","updated":"2017-11-12 02:37:50.000000000","message":"Done","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fb6b5b097e3dd7a82d73266aab9df2075aa50204","unresolved":false,"context_lines":[{"line_number":3508,"context_line":"  min_version: 2.54"},{"line_number":3509,"context_line":"key_name_rebuild_resp:"},{"line_number":3510,"context_line":"  description: |"},{"line_number":3511,"context_line":"    The name of associated key pair for one rebuilding instance."},{"line_number":3512,"context_line":"  in: body"},{"line_number":3513,"context_line":"  required: true"},{"line_number":3514,"context_line":"  type: string"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"1f485f77_168f2624","line":3511,"updated":"2017-11-11 17:42:09.000000000","message":"Let\u0027s use the same description from the key_name_resp parameter below.","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"9eb2fde0002569fb2af2ebf9ce53bfefae73ca7c","unresolved":false,"context_lines":[{"line_number":3508,"context_line":"  min_version: 2.54"},{"line_number":3509,"context_line":"key_name_rebuild_resp:"},{"line_number":3510,"context_line":"  description: |"},{"line_number":3511,"context_line":"    The name of associated key pair for one rebuilding instance."},{"line_number":3512,"context_line":"  in: body"},{"line_number":3513,"context_line":"  required: true"},{"line_number":3514,"context_line":"  type: string"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"1f485f77_3c18c11b","line":3511,"in_reply_to":"1f485f77_168f2624","updated":"2017-11-12 02:37:50.000000000","message":"Done","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"}],"api-ref/source/servers-actions.inc":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":485,"context_line":"  - personality.contents: contents"},{"line_number":486,"context_line":"  - preserve_ephemeral: preserve_ephemeral"},{"line_number":487,"context_line":"  - description: server_description"},{"line_number":488,"context_line":"  - key_name: key_name"},{"line_number":489,"context_line":""},{"line_number":490,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":491,"context_line":""}],"source_content_type":"text/x-c++src","patch_set":11,"id":"5f4e5783_4f8fe174","line":488,"updated":"2017-10-13 16:08:16.000000000","message":"This is going to need a new parameter in the docs since it needs the min_version tag to show that this is only available in the new microversion.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":485,"context_line":"  - personality.contents: contents"},{"line_number":486,"context_line":"  - preserve_ephemeral: preserve_ephemeral"},{"line_number":487,"context_line":"  - description: server_description"},{"line_number":488,"context_line":"  - key_name: key_name"},{"line_number":489,"context_line":""},{"line_number":490,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":491,"context_line":""}],"source_content_type":"text/x-c++src","patch_set":11,"id":"5f4e5783_5d71cd0b","line":488,"in_reply_to":"5f4e5783_4f8fe174","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":487,"context_line":"  - personality.contents: contents"},{"line_number":488,"context_line":"  - preserve_ephemeral: preserve_ephemeral"},{"line_number":489,"context_line":"  - description: server_description"},{"line_number":490,"context_line":"  - key_name: key_name"},{"line_number":491,"context_line":""},{"line_number":492,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":493,"context_line":""}],"source_content_type":"text/x-c++src","patch_set":12,"id":"3f4b6375_c0624d3e","line":490,"range":{"start_line":490,"start_character":14,"end_line":490,"end_character":22},"updated":"2017-11-04 01:06:21.000000000","message":"We need a new parameter definition for this with the min_version value set to the new microversion introduced in this change. That makes the API reference docs show that this parameter is only available starting with the new microversion.\n\nCall the parameter something like key_name_rebuild_req or something. The request parameter will be required\u003dfalse, the response parameter will be required\u003dtrue.\n\nYou\u0027ll also need it in the response parameters list.\n\nThe parameter gets defined here:\n\nhttps://github.com/openstack/nova/blob/master/api-ref/source/parameters.yaml\n\nRemember that parameters in that file are grouped by \"in:\" type (body, path, etc) and are in alphabetical order. You can build the API reference locally by doing \"tox -e api-ref\".\n\nAlso remember to note the distinction in the request parameter description from the spec:\n\nhttps://specs.openstack.org/openstack/nova-specs/specs/queens/approved/rebuild-keypair-reset.html#security-impact\n\nThat we need to point out the key_name is looked up using the current user request context, not the owner of the instance, since keys are owned by users but instances are owned by projects.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":487,"context_line":"  - personality.contents: contents"},{"line_number":488,"context_line":"  - preserve_ephemeral: preserve_ephemeral"},{"line_number":489,"context_line":"  - description: server_description"},{"line_number":490,"context_line":"  - key_name: key_name"},{"line_number":491,"context_line":""},{"line_number":492,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":493,"context_line":""}],"source_content_type":"text/x-c++src","patch_set":12,"id":"3f4b6375_fcb5f17e","line":490,"range":{"start_line":490,"start_character":14,"end_line":490,"end_character":22},"in_reply_to":"3f4b6375_c0624d3e","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":497,"context_line":"Response"},{"line_number":498,"context_line":"--------"},{"line_number":499,"context_line":""},{"line_number":500,"context_line":".. rest_parameters:: parameters.yaml"},{"line_number":501,"context_line":""},{"line_number":502,"context_line":"  - Location: server_location"},{"line_number":503,"context_line":"  - server: server"}],"source_content_type":"text/x-c++src","patch_set":12,"id":"3f4b6375_8058d589","line":500,"updated":"2017-11-04 01:06:21.000000000","message":"Need the key_name in the response too. See above.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":497,"context_line":"Response"},{"line_number":498,"context_line":"--------"},{"line_number":499,"context_line":""},{"line_number":500,"context_line":".. rest_parameters:: parameters.yaml"},{"line_number":501,"context_line":""},{"line_number":502,"context_line":"  - Location: server_location"},{"line_number":503,"context_line":"  - server: server"}],"source_content_type":"text/x-c++src","patch_set":12,"id":"3f4b6375_dcb8f575","line":500,"in_reply_to":"3f4b6375_8058d589","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"fdfc9e9374d83abc7d3e8326d95fcc7cb8bf8ea9","unresolved":false,"context_lines":[{"line_number":489,"context_line":"  - description: server_description"},{"line_number":490,"context_line":"  - key_name: key_name_rebuild_req"},{"line_number":491,"context_line":""},{"line_number":492,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":493,"context_line":""},{"line_number":494,"context_line":".. literalinclude:: ../../doc/api_samples/servers/v2.47/server-action-rebuild.json"},{"line_number":495,"context_line":"   :language: javascript"},{"line_number":496,"context_line":""},{"line_number":497,"context_line":"Response"},{"line_number":498,"context_line":"--------"}],"source_content_type":"text/x-c++src","patch_set":14,"id":"1f485f77_19d18dce","line":495,"range":{"start_line":492,"start_character":0,"end_line":495,"end_character":24},"updated":"2017-11-13 01:26:15.000000000","message":"should update example too","commit_id":"7ab490cc8345921adec154c89edc90b022127511"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b03016e48396e333cd43a1c3adbcddac22282dbf","unresolved":false,"context_lines":[{"line_number":489,"context_line":"  - description: server_description"},{"line_number":490,"context_line":"  - key_name: key_name_rebuild_req"},{"line_number":491,"context_line":""},{"line_number":492,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":493,"context_line":""},{"line_number":494,"context_line":".. literalinclude:: ../../doc/api_samples/servers/v2.47/server-action-rebuild.json"},{"line_number":495,"context_line":"   :language: javascript"},{"line_number":496,"context_line":""},{"line_number":497,"context_line":"Response"},{"line_number":498,"context_line":"--------"}],"source_content_type":"text/x-c++src","patch_set":14,"id":"1f485f77_bc2147b7","line":495,"range":{"start_line":492,"start_character":0,"end_line":495,"end_character":24},"in_reply_to":"1f485f77_19d18dce","updated":"2017-11-13 02:46:55.000000000","message":"Done","commit_id":"7ab490cc8345921adec154c89edc90b022127511"},{"author":{"_account_id":15888,"name":"Zhenyu Zheng","email":"zheng.zhenyu@outlook.com","username":"Kevin_Zheng"},"change_message_id":"fdfc9e9374d83abc7d3e8326d95fcc7cb8bf8ea9","unresolved":false,"context_lines":[{"line_number":537,"context_line":"  - tags: tags"},{"line_number":538,"context_line":"  - key_name: key_name_rebuild_resp"},{"line_number":539,"context_line":""},{"line_number":540,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":541,"context_line":""},{"line_number":542,"context_line":".. literalinclude:: ../../doc/api_samples/servers/v2.47/server-action-rebuild-resp.json"},{"line_number":543,"context_line":"   :language: javascript"},{"line_number":544,"context_line":""},{"line_number":545,"context_line":"Remove (Disassociate) Floating Ip (removeFloatingIp Action) (DEPRECATED)"},{"line_number":546,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-c++src","patch_set":14,"id":"1f485f77_f9d591ba","line":543,"range":{"start_line":540,"start_character":0,"end_line":543,"end_character":24},"updated":"2017-11-13 01:26:15.000000000","message":"ditto","commit_id":"7ab490cc8345921adec154c89edc90b022127511"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b03016e48396e333cd43a1c3adbcddac22282dbf","unresolved":false,"context_lines":[{"line_number":537,"context_line":"  - tags: tags"},{"line_number":538,"context_line":"  - key_name: key_name_rebuild_resp"},{"line_number":539,"context_line":""},{"line_number":540,"context_line":"**Example Rebuild Server (rebuild Action) (v2.47)**"},{"line_number":541,"context_line":""},{"line_number":542,"context_line":".. literalinclude:: ../../doc/api_samples/servers/v2.47/server-action-rebuild-resp.json"},{"line_number":543,"context_line":"   :language: javascript"},{"line_number":544,"context_line":""},{"line_number":545,"context_line":"Remove (Disassociate) Floating Ip (removeFloatingIp Action) (DEPRECATED)"},{"line_number":546,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-c++src","patch_set":14,"id":"1f485f77_9c2e8ba3","line":543,"range":{"start_line":540,"start_character":0,"end_line":543,"end_character":24},"in_reply_to":"1f485f77_f9d591ba","updated":"2017-11-13 02:46:55.000000000","message":"Done","commit_id":"7ab490cc8345921adec154c89edc90b022127511"}],"doc/api_samples/servers/v2.54/server-action-rebuild-resp.json":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":47,"context_line":"            \"meta_var\": \"meta_val\""},{"line_number":48,"context_line":"        },"},{"line_number":49,"context_line":"        \"name\": \"foobar\","},{"line_number":50,"context_line":"        \"key_name\": \"key\","},{"line_number":51,"context_line":"        \"description\" : \"description of foobar\","},{"line_number":52,"context_line":"        \"progress\": 0,"},{"line_number":53,"context_line":"        \"status\": \"ACTIVE\","}],"source_content_type":"application/json","patch_set":12,"id":"3f4b6375_20d801ed","line":50,"range":{"start_line":50,"start_character":21,"end_line":50,"end_character":24},"updated":"2017-11-04 01:06:21.000000000","message":"Can we use a more interesting name like \"new-key\" or something?","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":47,"context_line":"            \"meta_var\": \"meta_val\""},{"line_number":48,"context_line":"        },"},{"line_number":49,"context_line":"        \"name\": \"foobar\","},{"line_number":50,"context_line":"        \"key_name\": \"key\","},{"line_number":51,"context_line":"        \"description\" : \"description of foobar\","},{"line_number":52,"context_line":"        \"progress\": 0,"},{"line_number":53,"context_line":"        \"status\": \"ACTIVE\","}],"source_content_type":"application/json","patch_set":12,"id":"3f4b6375_9caefd2b","line":50,"range":{"start_line":50,"start_character":21,"end_line":50,"end_character":24},"in_reply_to":"3f4b6375_20d801ed","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"}],"doc/api_samples/servers/v2.54/server-action-rebuild.json":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":4,"context_line":"        \"accessIPv6\" : \"80fe::\","},{"line_number":5,"context_line":"        \"imageRef\" : \"70a599e0-31e7-49b7-b260-868f441e862b\","},{"line_number":6,"context_line":"        \"name\" : \"foobar\","},{"line_number":7,"context_line":"        \"key_name\": \"key\","},{"line_number":8,"context_line":"        \"description\" : \"description of foobar\","},{"line_number":9,"context_line":"        \"adminPass\" : \"seekr3t\","},{"line_number":10,"context_line":"        \"metadata\" : {"}],"source_content_type":"application/json","patch_set":12,"id":"3f4b6375_80e695af","line":7,"range":{"start_line":7,"start_character":21,"end_line":7,"end_character":24},"updated":"2017-11-04 01:06:21.000000000","message":"new-key to be more obvious this is a change.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":4,"context_line":"        \"accessIPv6\" : \"80fe::\","},{"line_number":5,"context_line":"        \"imageRef\" : \"70a599e0-31e7-49b7-b260-868f441e862b\","},{"line_number":6,"context_line":"        \"name\" : \"foobar\","},{"line_number":7,"context_line":"        \"key_name\": \"key\","},{"line_number":8,"context_line":"        \"description\" : \"description of foobar\","},{"line_number":9,"context_line":"        \"adminPass\" : \"seekr3t\","},{"line_number":10,"context_line":"        \"metadata\" : {"}],"source_content_type":"application/json","patch_set":12,"id":"3f4b6375_7ca90122","line":7,"range":{"start_line":7,"start_character":21,"end_line":7,"end_character":24},"in_reply_to":"3f4b6375_80e695af","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"}],"nova/api/openstack/compute/rest_api_version_history.rst":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":686,"context_line":""},{"line_number":687,"context_line":"2.54"},{"line_number":688,"context_line":"----"},{"line_number":689,"context_line":"  Allow the user to set the server key pair while rebuilding. And then use the"},{"line_number":690,"context_line":"  new key to login the server."}],"source_content_type":"text/x-rst","patch_set":11,"id":"5f4e5783_efefad1b","line":689,"updated":"2017-10-13 16:08:16.000000000","message":"Need a blank line before this.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":686,"context_line":""},{"line_number":687,"context_line":"2.54"},{"line_number":688,"context_line":"----"},{"line_number":689,"context_line":"  Allow the user to set the server key pair while rebuilding. And then use the"},{"line_number":690,"context_line":"  new key to login the server."}],"source_content_type":"text/x-rst","patch_set":11,"id":"5f4e5783_bdfb2177","line":689,"in_reply_to":"5f4e5783_efefad1b","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":686,"context_line":""},{"line_number":687,"context_line":"2.54"},{"line_number":688,"context_line":"----"},{"line_number":689,"context_line":"  Allow the user to set the server key pair while rebuilding. And then use the"},{"line_number":690,"context_line":"  new key to login the server."}],"source_content_type":"text/x-rst","patch_set":11,"id":"5f4e5783_2fe1452b","line":690,"range":{"start_line":689,"start_character":62,"end_line":690,"end_character":30},"updated":"2017-10-13 16:08:16.000000000","message":"I\u0027d remove this last sentence to avoid any confusion about nova actually logging into the instance.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":686,"context_line":""},{"line_number":687,"context_line":"2.54"},{"line_number":688,"context_line":"----"},{"line_number":689,"context_line":"  Allow the user to set the server key pair while rebuilding. And then use the"},{"line_number":690,"context_line":"  new key to login the server."}],"source_content_type":"text/x-rst","patch_set":11,"id":"5f4e5783_9df8657b","line":690,"range":{"start_line":689,"start_character":62,"end_line":690,"end_character":30},"in_reply_to":"5f4e5783_2fe1452b","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"}],"nova/api/openstack/compute/servers.py":[{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"9875df04c390957e20b35eff5797a42359ae5d93","unresolved":false,"context_lines":[{"line_number":878,"context_line":"    @wsgi.action(\u0027rebuild\u0027)"},{"line_number":879,"context_line":"    @validation.schema(schema_server_rebuild_v20, \u00272.0\u0027, \u00272.0\u0027)"},{"line_number":880,"context_line":"    @validation.schema(schema_server_rebuild, \u00272.1\u0027, \u00272.18\u0027)"},{"line_number":881,"context_line":"    @validation.schema(schema_server_rebuild_v219, \u00272.19\u0027, \u00272.42\u0027)"},{"line_number":882,"context_line":"    @validation.schema(schema_server_rebuild_v254, \u00272.54\u0027)"},{"line_number":883,"context_line":"    def _action_rebuild(self, req, id, body):"},{"line_number":884,"context_line":"        \"\"\"Rebuild an instance with the given attributes.\"\"\""}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_0569febc","line":881,"range":{"start_line":881,"start_character":62,"end_line":881,"end_character":64},"updated":"2017-10-05 19:07:16.000000000","message":"2.53 right?","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b00ffb70df1ce5f97a932540e5e986ee4e54a1fa","unresolved":false,"context_lines":[{"line_number":878,"context_line":"    @wsgi.action(\u0027rebuild\u0027)"},{"line_number":879,"context_line":"    @validation.schema(schema_server_rebuild_v20, \u00272.0\u0027, \u00272.0\u0027)"},{"line_number":880,"context_line":"    @validation.schema(schema_server_rebuild, \u00272.1\u0027, \u00272.18\u0027)"},{"line_number":881,"context_line":"    @validation.schema(schema_server_rebuild_v219, \u00272.19\u0027, \u00272.42\u0027)"},{"line_number":882,"context_line":"    @validation.schema(schema_server_rebuild_v254, \u00272.54\u0027)"},{"line_number":883,"context_line":"    def _action_rebuild(self, req, id, body):"},{"line_number":884,"context_line":"        \"\"\"Rebuild an instance with the given attributes.\"\"\""}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_5afc2971","line":881,"range":{"start_line":881,"start_character":62,"end_line":881,"end_character":64},"in_reply_to":"7f515b1d_0569febc","updated":"2017-10-09 14:05:27.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":959,"context_line":"        if CONF.api.enable_instance_password:"},{"line_number":960,"context_line":"            view[\u0027server\u0027][\u0027adminPass\u0027] \u003d password"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if api_version_request.is_supported(req,"},{"line_number":963,"context_line":"                                            min_version\u003d\u00272.54\u0027) and key_name:"},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"        robj \u003d wsgi.ResponseObject(view)"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_6f205d49","line":963,"range":{"start_line":962,"start_character":8,"end_line":963,"end_character":77},"updated":"2017-10-13 16:08:16.000000000","message":"Can we store a variable above so we don\u0027t have to do this same check twice?","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"31c75bb9f9a0fe9156a4ab99f98f40b712d9c17a","unresolved":false,"context_lines":[{"line_number":959,"context_line":"        if CONF.api.enable_instance_password:"},{"line_number":960,"context_line":"            view[\u0027server\u0027][\u0027adminPass\u0027] \u003d password"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if api_version_request.is_supported(req,"},{"line_number":963,"context_line":"                                            min_version\u003d\u00272.54\u0027) and key_name:"},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"        robj \u003d wsgi.ResponseObject(view)"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_dd3dbddd","line":963,"range":{"start_line":962,"start_character":8,"end_line":963,"end_character":77},"in_reply_to":"5f4e5783_6f205d49","updated":"2017-10-14 13:49:39.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"9875df04c390957e20b35eff5797a42359ae5d93","unresolved":false,"context_lines":[{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if api_version_request.is_supported(req,"},{"line_number":963,"context_line":"                                            min_version\u003d\u00272.54\u0027) and key_name:"},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"        robj \u003d wsgi.ResponseObject(view)"},{"line_number":967,"context_line":"        return self._add_location(robj)"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_a58b4a66","line":964,"updated":"2017-10-05 19:07:16.000000000","message":"Why is the view changed?","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"31c75bb9f9a0fe9156a4ab99f98f40b712d9c17a","unresolved":false,"context_lines":[{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if api_version_request.is_supported(req,"},{"line_number":963,"context_line":"                                            min_version\u003d\u00272.54\u0027) and key_name:"},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"        robj \u003d wsgi.ResponseObject(view)"},{"line_number":967,"context_line":"        return self._add_location(robj)"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_bd2681cd","line":964,"in_reply_to":"5f4e5783_2f16e5f2","updated":"2017-10-14 13:49:39.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b00ffb70df1ce5f97a932540e5e986ee4e54a1fa","unresolved":false,"context_lines":[{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if api_version_request.is_supported(req,"},{"line_number":963,"context_line":"                                            min_version\u003d\u00272.54\u0027) and key_name:"},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"        robj \u003d wsgi.ResponseObject(view)"},{"line_number":967,"context_line":"        return self._add_location(robj)"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_ba41dda8","line":964,"in_reply_to":"7f515b1d_a58b4a66","updated":"2017-10-09 14:05:27.000000000","message":"return with new key name","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if api_version_request.is_supported(req,"},{"line_number":963,"context_line":"                                            min_version\u003d\u00272.54\u0027) and key_name:"},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""},{"line_number":966,"context_line":"        robj \u003d wsgi.ResponseObject(view)"},{"line_number":967,"context_line":"        return self._add_location(robj)"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_2f16e5f2","line":964,"in_reply_to":"7f515b1d_ba41dda8","updated":"2017-10-13 16:08:16.000000000","message":"Add a comment in the code to avoid confusion.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":20722,"name":"Yikun Jiang","email":"yikunkero@gmail.com","username":"yikunkero"},"change_message_id":"b2331ccadcb8b9cc5e850233f028b18c237a025a","unresolved":false,"context_lines":[{"line_number":904,"context_line":""},{"line_number":905,"context_line":"        key_name \u003d rebuild_dict.get(\u0027key_name\u0027)"},{"line_number":906,"context_line":"        key_name_changed \u003d api_version_request.is_supported("},{"line_number":907,"context_line":"            req, min_version\u003d\u00272.54\u0027) and key_name"},{"line_number":908,"context_line":"        if key_name_changed:"},{"line_number":909,"context_line":"            kwargs[\u0027key_name\u0027] \u003d key_name"},{"line_number":910,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_f4f0a869","line":907,"range":{"start_line":907,"start_character":41,"end_line":907,"end_character":49},"updated":"2017-11-02 03:20:20.000000000","message":"Sorry, I\u0027m not sure that key_name\u003d\u0027\u0027 is a normal case or not.\nso, it seems \u0027key_name is not None\u0027 is better?","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"44893b8a1626a29b69d73c07f6b46c8129806317","unresolved":false,"context_lines":[{"line_number":904,"context_line":""},{"line_number":905,"context_line":"        key_name \u003d rebuild_dict.get(\u0027key_name\u0027)"},{"line_number":906,"context_line":"        key_name_changed \u003d api_version_request.is_supported("},{"line_number":907,"context_line":"            req, min_version\u003d\u00272.54\u0027) and key_name"},{"line_number":908,"context_line":"        if key_name_changed:"},{"line_number":909,"context_line":"            kwargs[\u0027key_name\u0027] \u003d key_name"},{"line_number":910,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_9cd740ef","line":907,"range":{"start_line":907,"start_character":41,"end_line":907,"end_character":49},"in_reply_to":"3f4b6375_f4f0a869","updated":"2017-11-02 20:17:28.000000000","message":"The request schema validates that if you specify a key_name, it must be at least length 1:\n\nhttps://github.com/openstack/nova/blob/f8c17e42b56a897107f28f39effea7f1ae9ef1ca/nova/api/validation/parameter_types.py#L270\n\nSo I think this check is fine.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":905,"context_line":"        key_name \u003d rebuild_dict.get(\u0027key_name\u0027)"},{"line_number":906,"context_line":"        key_name_changed \u003d api_version_request.is_supported("},{"line_number":907,"context_line":"            req, min_version\u003d\u00272.54\u0027) and key_name"},{"line_number":908,"context_line":"        if key_name_changed:"},{"line_number":909,"context_line":"            kwargs[\u0027key_name\u0027] \u003d key_name"},{"line_number":910,"context_line":""},{"line_number":911,"context_line":"        for request_attribute, instance_attribute in attr_map.items():"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_60b95977","line":908,"range":{"start_line":908,"start_character":11,"end_line":908,"end_character":27},"updated":"2017-11-04 01:06:21.000000000","message":"Hmm, this doesn\u0027t really mean the server\u0027s key_name changed. I could have created my server with key_name \u0027mykey\u0027 and rebuilt it with \u0027mykey\u0027, that wouldn\u0027t mean it changes. If a different user rebuilt my instance with their version of \u0027mykey\u0027 then it would be different but we don\u0027t really know that here.\n\nAlso, I just thought of this, but I guess we are not allowing to reset a key_name to None with this API change. We should be clear about that in the API reference for this parameter - if left unspecified, or set to None, it\u0027s ignored, meaning you can\u0027t *unset* the instance key_name during rebuild, only change it.\n\nNow we could support unsetting a key_name with some logic like:\n\nreset_key \u003d False\nif \u0027key_name\u0027 in rebuild_dict:\n   key_name \u003d rebuild_dict[\u0027key_name\u0027]\n   if key_name is None:\n     reset_key \u003d True\n   else:\n     # handle updating the key\n\nSo if the user does not specify a key_name in the request, we don\u0027t change anything. If they do specify a key_name and the value is None, that means unset the key on the instance, else update it.\n\nWe didn\u0027t discuss that in the spec so we should figure it out now and amend the spec later.\n\nML thread: http://lists.openstack.org/pipermail/openstack-dev/2017-November/124236.html\n\nI\u0027ll also ask about this at the summit next week.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":905,"context_line":"        key_name \u003d rebuild_dict.get(\u0027key_name\u0027)"},{"line_number":906,"context_line":"        key_name_changed \u003d api_version_request.is_supported("},{"line_number":907,"context_line":"            req, min_version\u003d\u00272.54\u0027) and key_name"},{"line_number":908,"context_line":"        if key_name_changed:"},{"line_number":909,"context_line":"            kwargs[\u0027key_name\u0027] \u003d key_name"},{"line_number":910,"context_line":""},{"line_number":911,"context_line":"        for request_attribute, instance_attribute in attr_map.items():"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_7c7ea1af","line":908,"range":{"start_line":908,"start_character":11,"end_line":908,"end_character":27},"in_reply_to":"3f4b6375_60b95977","updated":"2017-11-04 13:43:46.000000000","message":"\u003e Hmm, this doesn\u0027t really mean the server\u0027s key_name changed. I\n \u003e could have created my server with key_name \u0027mykey\u0027 and rebuilt it\n \u003e with \u0027mykey\u0027, that wouldn\u0027t mean it changes. If a different user\n \u003e rebuilt my instance with their version of \u0027mykey\u0027 then it would be\n \u003e different but we don\u0027t really know that here.\n \u003e \n \u003e Also, I just thought of this, but I guess we are not allowing to\n \u003e reset a key_name to None with this API change. We should be clear\n \u003e about that in the API reference for this parameter - if left\n \u003e unspecified, or set to None, it\u0027s ignored, meaning you can\u0027t\n \u003e *unset* the instance key_name during rebuild, only change it.\n\n\nwhat about `key_name_supplied` ?\n\n\n\n \u003e Now we could support unsetting a key_name with some logic like:\n \u003e \n \u003e reset_key \u003d False\n \u003e if \u0027key_name\u0027 in rebuild_dict:\n \u003e key_name \u003d rebuild_dict[\u0027key_name\u0027]\n \u003e if key_name is None:\n \u003e reset_key \u003d True\n \u003e else:\n \u003e # handle updating the key\n \u003e \n \u003e So if the user does not specify a key_name in the request, we don\u0027t\n \u003e change anything. If they do specify a key_name and the value is\n \u003e None, that means unset the key on the instance, else update it.\n \u003e \n \u003e We didn\u0027t discuss that in the spec so we should figure it out now\n \u003e and amend the spec later.\n \u003e \n \u003e ML thread: http://lists.openstack.org/pipermail/openstack-dev/2017-November/124236.html\n \u003e \n \u003e I\u0027ll also ask about this at the summit next week.\n\n\nSounds good, we can do it. But seems not good to the cloud only support key pair login.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"9f7db39409a89f2dd4819b45d0b78faf0e8d2bde","unresolved":false,"context_lines":[{"line_number":905,"context_line":"        key_name \u003d rebuild_dict.get(\u0027key_name\u0027)"},{"line_number":906,"context_line":"        key_name_changed \u003d api_version_request.is_supported("},{"line_number":907,"context_line":"            req, min_version\u003d\u00272.54\u0027) and key_name"},{"line_number":908,"context_line":"        if key_name_changed:"},{"line_number":909,"context_line":"            kwargs[\u0027key_name\u0027] \u003d key_name"},{"line_number":910,"context_line":""},{"line_number":911,"context_line":"        for request_attribute, instance_attribute in attr_map.items():"}],"source_content_type":"text/x-python","patch_set":12,"id":"1f485f77_1e24ef0c","line":908,"range":{"start_line":908,"start_character":11,"end_line":908,"end_character":27},"in_reply_to":"3f4b6375_680a228a","updated":"2017-11-10 06:24:08.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"839e560dea84d68da19e2fedb0dbe6993abb5085","unresolved":false,"context_lines":[{"line_number":905,"context_line":"        key_name \u003d rebuild_dict.get(\u0027key_name\u0027)"},{"line_number":906,"context_line":"        key_name_changed \u003d api_version_request.is_supported("},{"line_number":907,"context_line":"            req, min_version\u003d\u00272.54\u0027) and key_name"},{"line_number":908,"context_line":"        if key_name_changed:"},{"line_number":909,"context_line":"            kwargs[\u0027key_name\u0027] \u003d key_name"},{"line_number":910,"context_line":""},{"line_number":911,"context_line":"        for request_attribute, instance_attribute in attr_map.items():"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_680a228a","line":908,"range":{"start_line":908,"start_character":11,"end_line":908,"end_character":27},"in_reply_to":"3f4b6375_7c7ea1af","updated":"2017-11-08 05:51:37.000000000","message":"I brought this up during the summit and we agreed to allow unsetting a keypair. So the logic is:\n\n1. no key_name specified in the request, nothing changes\n2. key_name\u003dsomething_new means update the keypair\n3. key_name\u003dNone means unset the instance.key_name/keypairs.\n\nThen the API is explicit. No one might use #3, but it\u0027s there and it\u0027s clear.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":959,"context_line":"        if CONF.api.enable_instance_password:"},{"line_number":960,"context_line":"            view[\u0027server\u0027][\u0027adminPass\u0027] \u003d password"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if key_name_changed:"},{"line_number":963,"context_line":"            # NOTE(liuyulong): set the new key_name for the API response."},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_e0f6695d","line":962,"updated":"2017-11-04 01:06:21.000000000","message":"I don\u0027t think we want this to be conditional on if the key_name changed, only on the microversion.\n\nSo if I\u0027m doing a rebuild with the new microversion, we should always return the current instance.key_name in the response, even if I didn\u0027t change it.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":959,"context_line":"        if CONF.api.enable_instance_password:"},{"line_number":960,"context_line":"            view[\u0027server\u0027][\u0027adminPass\u0027] \u003d password"},{"line_number":961,"context_line":""},{"line_number":962,"context_line":"        if key_name_changed:"},{"line_number":963,"context_line":"            # NOTE(liuyulong): set the new key_name for the API response."},{"line_number":964,"context_line":"            view[\u0027server\u0027][\u0027key_name\u0027] \u003d key_name"},{"line_number":965,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_5c2765c8","line":962,"in_reply_to":"3f4b6375_e0f6695d","updated":"2017-11-04 13:43:46.000000000","message":"OK, done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"}],"nova/api/validation/parameter_types.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fb6b5b097e3dd7a82d73266aab9df2075aa50204","unresolved":false,"context_lines":[{"line_number":228,"context_line":""},{"line_number":229,"context_line":"name_or_empty_string_or_none \u003d {"},{"line_number":230,"context_line":"    \u0027oneOf\u0027: ["},{"line_number":231,"context_line":"        {\u0027type\u0027: \u0027string\u0027, \u0027minLength\u0027: 0, \u0027maxLength\u0027: 255},"},{"line_number":232,"context_line":"        {\u0027type\u0027: \u0027null\u0027},"},{"line_number":233,"context_line":"    ]"},{"line_number":234,"context_line":"}"}],"source_content_type":"text/x-python","patch_set":13,"id":"1f485f77_16dde613","line":231,"range":{"start_line":231,"start_character":27,"end_line":231,"end_character":41},"updated":"2017-11-11 17:42:09.000000000","message":"It seems odd to allow passing an empty string for the key_name. I think if a value is specified, it should be None or a non-empty string so that we\u0027re not ambiguous.","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"9eb2fde0002569fb2af2ebf9ce53bfefae73ca7c","unresolved":false,"context_lines":[{"line_number":228,"context_line":""},{"line_number":229,"context_line":"name_or_empty_string_or_none \u003d {"},{"line_number":230,"context_line":"    \u0027oneOf\u0027: ["},{"line_number":231,"context_line":"        {\u0027type\u0027: \u0027string\u0027, \u0027minLength\u0027: 0, \u0027maxLength\u0027: 255},"},{"line_number":232,"context_line":"        {\u0027type\u0027: \u0027null\u0027},"},{"line_number":233,"context_line":"    ]"},{"line_number":234,"context_line":"}"}],"source_content_type":"text/x-python","patch_set":13,"id":"1f485f77_fcd7c922","line":231,"range":{"start_line":231,"start_character":27,"end_line":231,"end_character":41},"in_reply_to":"1f485f77_16dde613","updated":"2017-11-12 02:37:50.000000000","message":"Done, change to name_or_none","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"}],"nova/compute/api.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":2917,"context_line":""},{"line_number":2918,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2919,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2920,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2921,"context_line":"                                                   context.user_id,"},{"line_number":2922,"context_line":"                                                   key_name)"},{"line_number":2923,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2924,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2925,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_cfb3d109","line":2922,"range":{"start_line":2920,"start_character":12,"end_line":2922,"end_character":60},"updated":"2017-10-13 16:08:16.000000000","message":"Might want to leave a comment in the code that we are intentionally using the user_id from the request context rather than the instance.user_id because users own keys but instances are owned by projects, and another user in the same project can rebuild an instance even if they didn\u0027t create it.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":2917,"context_line":""},{"line_number":2918,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2919,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2920,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2921,"context_line":"                                                   context.user_id,"},{"line_number":2922,"context_line":"                                                   key_name)"},{"line_number":2923,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2924,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2925,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_3d2df1fd","line":2922,"range":{"start_line":2920,"start_character":12,"end_line":2922,"end_character":60},"in_reply_to":"5f4e5783_cfb3d109","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":2920,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2921,"context_line":"                                                   context.user_id,"},{"line_number":2922,"context_line":"                                                   key_name)"},{"line_number":2923,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2924,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2925,"context_line":""},{"line_number":2926,"context_line":"        image_id, image \u003d self._get_image(context, image_href)"},{"line_number":2927,"context_line":"        self._check_auto_disk_config(image\u003dimage, **kwargs)"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_cf8191fd","line":2924,"range":{"start_line":2923,"start_character":12,"end_line":2924,"end_character":51},"updated":"2017-10-13 16:08:16.000000000","message":"I worry a bit about updating this before we actually do the rebuild, because if the rebuild fails then you\u0027e changed what we say is the keypair on the instance even though it won\u0027t be using it in the guest. We have the same issue with changing the instance.image_ref before the rebuild and if you\u0027re rebuilding a volume-backed instance, that image_ref is a lie because we don\u0027t change the image in the root disk in the volume.\n\nSo I\u0027m inclined to think we should pass the key_name through to the compute service which will handle updating it, although that would also mean that older computes (Pike computes) wouldn\u0027t have the code to know about updating the keypair...which would also be a bug. We can check the nova-compute service version and if it\u0027s not new enough we could fail the request saying that updating the keypair on this instance during rebuild is not yet supported.\n\nThis is probably a point worth discussing for how we want to handle this. Maybe bring it up in the mailing list.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"74ead3b933e6a1c413f4daabf8a65277d45955db","unresolved":false,"context_lines":[{"line_number":2920,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2921,"context_line":"                                                   context.user_id,"},{"line_number":2922,"context_line":"                                                   key_name)"},{"line_number":2923,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2924,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2925,"context_line":""},{"line_number":2926,"context_line":"        image_id, image \u003d self._get_image(context, image_href)"},{"line_number":2927,"context_line":"        self._check_auto_disk_config(image\u003dimage, **kwargs)"}],"source_content_type":"text/x-python","patch_set":11,"id":"3f4b6375_9cc2a033","line":2924,"range":{"start_line":2923,"start_character":12,"end_line":2924,"end_character":51},"in_reply_to":"5f4e5783_5d7b0dbd","updated":"2017-11-02 20:15:24.000000000","message":"\u003e This may start a new RPC version which does not state in the spec :).\n\nI don\u0027t worry about RPC API version changes really, and like you said, we already change a lot of fields on the instance before we even attempt the rebuild. Plus, if we did this in the compute, we\u0027d have to check to see if the compute is new enough to have the code for setting the key_name (we\u0027d have to do a service version check on the instance.host). So probably not worth it.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":2920,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2921,"context_line":"                                                   context.user_id,"},{"line_number":2922,"context_line":"                                                   key_name)"},{"line_number":2923,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2924,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2925,"context_line":""},{"line_number":2926,"context_line":"        image_id, image \u003d self._get_image(context, image_href)"},{"line_number":2927,"context_line":"        self._check_auto_disk_config(image\u003dimage, **kwargs)"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_5d7b0dbd","line":2924,"range":{"start_line":2923,"start_character":12,"end_line":2924,"end_character":51},"in_reply_to":"5f4e5783_cf8191fd","updated":"2017-10-14 13:46:09.000000000","message":"\u003e I worry a bit about updating this before we actually do the\n \u003e rebuild, because if the rebuild fails then you\u0027e changed what we\n \u003e say is the keypair on the instance even though it won\u0027t be using it\n \u003e in the guest. We have the same issue with changing the\n \u003e instance.image_ref before the rebuild and if you\u0027re rebuilding a\n \u003e volume-backed instance, that image_ref is a lie because we don\u0027t\n \u003e change the image in the root disk in the volume.\n\n\nActually we have updated all the supplied values in line 2974, not just image_ref. So there are so many inconsistent between nova DB and guest. But fortunately rebuild API is reentrant, users can call rebuild again when get failed or any inconsistent.\n\n\n \u003e So I\u0027m inclined to think we should pass the key_name through to the\n \u003e compute service which will handle updating it, although that would\n \u003e also mean that older computes (Pike computes) wouldn\u0027t have the\n \u003e code to know about updating the keypair...which would also be a\n \u003e bug. We can check the nova-compute service version and if it\u0027s not\n \u003e new enough we could fail the request saying that updating the\n \u003e keypair on this instance during rebuild is not yet supported.\n\n\nThis may start a new RPC version which does not state in the spec :).\n\n\n \u003e This is probably a point worth discussing for how we want to handle\n \u003e this. Maybe bring it up in the mailing list.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":2868,"context_line":"        preserve_ephemeral \u003d kwargs.get(\u0027preserve_ephemeral\u0027, False)"},{"line_number":2869,"context_line":"        auto_disk_config \u003d kwargs.get(\u0027auto_disk_config\u0027)"},{"line_number":2870,"context_line":""},{"line_number":2871,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2872,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2873,"context_line":"            # NOTE(liuyulong): we are intentionally using the user_id from"},{"line_number":2874,"context_line":"            # the request context rather than the instance.user_id because"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_a06871f4","line":2871,"updated":"2017-11-04 01:06:21.000000000","message":"Let\u0027s remember to change the logic here if we decide to allow unsetting a key_name.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":2868,"context_line":"        preserve_ephemeral \u003d kwargs.get(\u0027preserve_ephemeral\u0027, False)"},{"line_number":2869,"context_line":"        auto_disk_config \u003d kwargs.get(\u0027auto_disk_config\u0027)"},{"line_number":2870,"context_line":""},{"line_number":2871,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2872,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2873,"context_line":"            # NOTE(liuyulong): we are intentionally using the user_id from"},{"line_number":2874,"context_line":"            # the request context rather than the instance.user_id because"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_fc43b16a","line":2871,"in_reply_to":"3f4b6375_a06871f4","updated":"2017-11-04 13:43:46.000000000","message":"OK, write it in my notebook. : )","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":2878,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2879,"context_line":"                                                   context.user_id,"},{"line_number":2880,"context_line":"                                                   key_name)"},{"line_number":2881,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2882,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2883,"context_line":""},{"line_number":2884,"context_line":"        image_id, image \u003d self._get_image(context, image_href)"},{"line_number":2885,"context_line":"        self._check_auto_disk_config(image\u003dimage, **kwargs)"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_c0636d19","line":2882,"range":{"start_line":2881,"start_character":12,"end_line":2882,"end_character":51},"updated":"2017-11-04 01:06:21.000000000","message":"We should also update the instance.keypairs field:\n\ninstance.keypairs \u003d objects.KeyPairList(objects\u003d[key_pair])","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":2878,"context_line":"            key_pair \u003d objects.KeyPair.get_by_name(context,"},{"line_number":2879,"context_line":"                                                   context.user_id,"},{"line_number":2880,"context_line":"                                                   key_name)"},{"line_number":2881,"context_line":"            instance.key_name \u003d key_pair.name"},{"line_number":2882,"context_line":"            instance.key_data \u003d key_pair.public_key"},{"line_number":2883,"context_line":""},{"line_number":2884,"context_line":"        image_id, image \u003d self._get_image(context, image_href)"},{"line_number":2885,"context_line":"        self._check_auto_disk_config(image\u003dimage, **kwargs)"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_dc46b57b","line":2882,"range":{"start_line":2881,"start_character":12,"end_line":2882,"end_character":51},"in_reply_to":"3f4b6375_c0636d19","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"a9c4ba774a8cf908f102a5cb87231c1a78224264","unresolved":false,"context_lines":[{"line_number":2867,"context_line":"        auto_disk_config \u003d kwargs.get(\u0027auto_disk_config\u0027)"},{"line_number":2868,"context_line":""},{"line_number":2869,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2870,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2871,"context_line":"            if key_name:"},{"line_number":2872,"context_line":"                # NOTE(liuyulong): we are intentionally using the user_id from"},{"line_number":2873,"context_line":"                # the request context rather than the instance.user_id because"}],"source_content_type":"text/x-python","patch_set":15,"id":"1f485f77_7ad17dcd","line":2870,"updated":"2017-11-13 18:06:25.000000000","message":"is there danger if we don\u0027t pop this out of kwargs?","commit_id":"751f5dec112898bb4903848d5efc347fe48d8750"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"cfd9f5120d92990073d8b60fed80c34a2ff27c3d","unresolved":false,"context_lines":[{"line_number":2867,"context_line":"        auto_disk_config \u003d kwargs.get(\u0027auto_disk_config\u0027)"},{"line_number":2868,"context_line":""},{"line_number":2869,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2870,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2871,"context_line":"            if key_name:"},{"line_number":2872,"context_line":"                # NOTE(liuyulong): we are intentionally using the user_id from"},{"line_number":2873,"context_line":"                # the request context rather than the instance.user_id because"}],"source_content_type":"text/x-python","patch_set":15,"id":"1f485f77_7a461d7f","line":2870,"in_reply_to":"1f485f77_7ad17dcd","updated":"2017-11-13 18:10:19.000000000","message":"Not really, it looks like we pass kwargs through to the conductor rpc api client below but the kwargs parameter there is not actually used (we should probably clean that up separately at some point).","commit_id":"751f5dec112898bb4903848d5efc347fe48d8750"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"a9c4ba774a8cf908f102a5cb87231c1a78224264","unresolved":false,"context_lines":[{"line_number":2868,"context_line":""},{"line_number":2869,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2870,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2871,"context_line":"            if key_name:"},{"line_number":2872,"context_line":"                # NOTE(liuyulong): we are intentionally using the user_id from"},{"line_number":2873,"context_line":"                # the request context rather than the instance.user_id because"},{"line_number":2874,"context_line":"                # users own keys but instances are owned by projects, and"}],"source_content_type":"text/x-python","patch_set":15,"id":"1f485f77_fae44dae","line":2871,"updated":"2017-11-13 18:06:25.000000000","message":"micro nit: this is more correct to be \"if key_name is not None\", right?","commit_id":"751f5dec112898bb4903848d5efc347fe48d8750"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"cfd9f5120d92990073d8b60fed80c34a2ff27c3d","unresolved":false,"context_lines":[{"line_number":2868,"context_line":""},{"line_number":2869,"context_line":"        if \u0027key_name\u0027 in kwargs:"},{"line_number":2870,"context_line":"            key_name \u003d kwargs.pop(\u0027key_name\u0027)"},{"line_number":2871,"context_line":"            if key_name:"},{"line_number":2872,"context_line":"                # NOTE(liuyulong): we are intentionally using the user_id from"},{"line_number":2873,"context_line":"                # the request context rather than the instance.user_id because"},{"line_number":2874,"context_line":"                # users own keys but instances are owned by projects, and"}],"source_content_type":"text/x-python","patch_set":15,"id":"1f485f77_5a492189","line":2871,"in_reply_to":"1f485f77_fae44dae","updated":"2017-11-13 18:10:19.000000000","message":"Yeah.","commit_id":"751f5dec112898bb4903848d5efc347fe48d8750"}],"nova/tests/functional/api_sample_tests/test_servers.py":[{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"9875df04c390957e20b35eff5797a42359ae5d93","unresolved":false,"context_lines":[{"line_number":482,"context_line":"                             \u0027server-action-rebuild\u0027, params)"},{"line_number":483,"context_line":"        subs \u003d params.copy()"},{"line_number":484,"context_line":"        del subs[\u0027uuid\u0027]"},{"line_number":485,"context_line":"        self._verify_response(\u0027server-action-rebuild-resp\u0027, subs, resp, 202)"},{"line_number":486,"context_line":""},{"line_number":487,"context_line":""},{"line_number":488,"context_line":"class ServersCreateImageJsonTest(ServersSampleBase,"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_c501a6b1","line":485,"updated":"2017-10-05 19:07:16.000000000","message":"The get should show the new key name now, correct?","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"c91a49bbc723abc085d5f12fb4bd6e6c3c9f88d6","unresolved":false,"context_lines":[{"line_number":482,"context_line":"                             \u0027server-action-rebuild\u0027, params)"},{"line_number":483,"context_line":"        subs \u003d params.copy()"},{"line_number":484,"context_line":"        del subs[\u0027uuid\u0027]"},{"line_number":485,"context_line":"        self._verify_response(\u0027server-action-rebuild-resp\u0027, subs, resp, 202)"},{"line_number":486,"context_line":""},{"line_number":487,"context_line":""},{"line_number":488,"context_line":"class ServersCreateImageJsonTest(ServersSampleBase,"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_bd0fa135","line":485,"in_reply_to":"5f4e5783_cf96313f","updated":"2017-10-14 13:59:16.000000000","message":"yep","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":482,"context_line":"                             \u0027server-action-rebuild\u0027, params)"},{"line_number":483,"context_line":"        subs \u003d params.copy()"},{"line_number":484,"context_line":"        del subs[\u0027uuid\u0027]"},{"line_number":485,"context_line":"        self._verify_response(\u0027server-action-rebuild-resp\u0027, subs, resp, 202)"},{"line_number":486,"context_line":""},{"line_number":487,"context_line":""},{"line_number":488,"context_line":"class ServersCreateImageJsonTest(ServersSampleBase,"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_cf96313f","line":485,"in_reply_to":"7f515b1d_1afa3174","updated":"2017-10-13 16:08:16.000000000","message":"It does, that\u0027s what _verify_response does right? That\u0027s why we have key_name in the subs.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b00ffb70df1ce5f97a932540e5e986ee4e54a1fa","unresolved":false,"context_lines":[{"line_number":482,"context_line":"                             \u0027server-action-rebuild\u0027, params)"},{"line_number":483,"context_line":"        subs \u003d params.copy()"},{"line_number":484,"context_line":"        del subs[\u0027uuid\u0027]"},{"line_number":485,"context_line":"        self._verify_response(\u0027server-action-rebuild-resp\u0027, subs, resp, 202)"},{"line_number":486,"context_line":""},{"line_number":487,"context_line":""},{"line_number":488,"context_line":"class ServersCreateImageJsonTest(ServersSampleBase,"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_1afa3174","line":485,"in_reply_to":"7f515b1d_c501a6b1","updated":"2017-10-09 14:05:27.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":470,"context_line":"        params \u003d {"},{"line_number":471,"context_line":"            \u0027uuid\u0027: image,"},{"line_number":472,"context_line":"            \u0027name\u0027: \u0027foobar\u0027,"},{"line_number":473,"context_line":"            \u0027key_name\u0027: \u0027key\u0027,"},{"line_number":474,"context_line":"            \u0027description\u0027: \u0027description of foobar\u0027,"},{"line_number":475,"context_line":"            \u0027pass\u0027: \u0027seekr3t\u0027,"},{"line_number":476,"context_line":"            \u0027hostid\u0027: \u0027[a-f0-9]+\u0027,"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_0056252b","line":473,"range":{"start_line":473,"start_character":25,"end_line":473,"end_character":28},"updated":"2017-11-04 01:06:21.000000000","message":"\u0027new-key\u0027 to make it more obvious this is an update during a rebuild.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":470,"context_line":"        params \u003d {"},{"line_number":471,"context_line":"            \u0027uuid\u0027: image,"},{"line_number":472,"context_line":"            \u0027name\u0027: \u0027foobar\u0027,"},{"line_number":473,"context_line":"            \u0027key_name\u0027: \u0027key\u0027,"},{"line_number":474,"context_line":"            \u0027description\u0027: \u0027description of foobar\u0027,"},{"line_number":475,"context_line":"            \u0027pass\u0027: \u0027seekr3t\u0027,"},{"line_number":476,"context_line":"            \u0027hostid\u0027: \u0027[a-f0-9]+\u0027,"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_7c57c127","line":473,"range":{"start_line":473,"start_character":25,"end_line":473,"end_character":28},"in_reply_to":"3f4b6375_0056252b","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"}],"nova/tests/unit/api/openstack/compute/test_serversV21.py":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":2132,"context_line":"    def setUp(self):"},{"line_number":2133,"context_line":"        super(ServersControllerRebuildTestV254, self).setUp()"},{"line_number":2134,"context_line":"        fakes.stub_out_key_pair_funcs(self)"},{"line_number":2135,"context_line":"        self.req.api_version_request \u003d \\"},{"line_number":2136,"context_line":"            api_version_request.APIVersionRequest(\u00272.54\u0027)"},{"line_number":2137,"context_line":""},{"line_number":2138,"context_line":"    def test_rebuild_accepted_with_keypair_name(self):"},{"line_number":2139,"context_line":"        key_name \u003d \"key\""}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_0f08c98f","line":2136,"range":{"start_line":2135,"start_character":8,"end_line":2136,"end_character":57},"updated":"2017-10-13 16:08:16.000000000","message":"It would be good to have one negative tests in here that tries to rebuild a server with a key_name at microversion 2.53 to see the boundary testing.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":2132,"context_line":"    def setUp(self):"},{"line_number":2133,"context_line":"        super(ServersControllerRebuildTestV254, self).setUp()"},{"line_number":2134,"context_line":"        fakes.stub_out_key_pair_funcs(self)"},{"line_number":2135,"context_line":"        self.req.api_version_request \u003d \\"},{"line_number":2136,"context_line":"            api_version_request.APIVersionRequest(\u00272.54\u0027)"},{"line_number":2137,"context_line":""},{"line_number":2138,"context_line":"    def test_rebuild_accepted_with_keypair_name(self):"},{"line_number":2139,"context_line":"        key_name \u003d \"key\""}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_dd101dab","line":2136,"range":{"start_line":2135,"start_character":8,"end_line":2136,"end_character":57},"in_reply_to":"5f4e5783_0f08c98f","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":2135,"context_line":"        self.req.api_version_request \u003d \\"},{"line_number":2136,"context_line":"            api_version_request.APIVersionRequest(\u00272.54\u0027)"},{"line_number":2137,"context_line":""},{"line_number":2138,"context_line":"    def test_rebuild_accepted_with_keypair_name(self):"},{"line_number":2139,"context_line":"        key_name \u003d \"key\""},{"line_number":2140,"context_line":"        fake_get \u003d fakes.fake_compute_get(vm_state\u003dvm_states.ACTIVE,"},{"line_number":2141,"context_line":"                                          key_name\u003dkey_name,"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_afe9b5b7","line":2138,"updated":"2017-10-13 16:08:16.000000000","message":"I\u0027m not sure we actually need this test, it\u0027s redundant with the functional API samples test. I tend to just do negative testing with unit tests for stuff like this since the functional API samples tests are doing positive testing.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":2135,"context_line":"        self.req.api_version_request \u003d \\"},{"line_number":2136,"context_line":"            api_version_request.APIVersionRequest(\u00272.54\u0027)"},{"line_number":2137,"context_line":""},{"line_number":2138,"context_line":"    def test_rebuild_accepted_with_keypair_name(self):"},{"line_number":2139,"context_line":"        key_name \u003d \"key\""},{"line_number":2140,"context_line":"        fake_get \u003d fakes.fake_compute_get(vm_state\u003dvm_states.ACTIVE,"},{"line_number":2141,"context_line":"                                          key_name\u003dkey_name,"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_1d535541","line":2138,"in_reply_to":"5f4e5783_afe9b5b7","updated":"2017-10-14 13:46:09.000000000","message":"I\u0027d like to remain this case to improve the unit testing code coverage.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":2141,"context_line":"                                          key_name\u003dkey_name,"},{"line_number":2142,"context_line":"                                          project_id\u003dself.req_project_id,"},{"line_number":2143,"context_line":"                                          user_id\u003dself.req_user_id)"},{"line_number":2144,"context_line":"        self.stubs.Set(compute_api.API, \u0027get\u0027,"},{"line_number":2145,"context_line":"                       lambda api, *a, **k: fake_get(*a, **k))"},{"line_number":2146,"context_line":""},{"line_number":2147,"context_line":"        self.body[\u0027rebuild\u0027][\u0027key_name\u0027] \u003d key_name"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_8fcdd967","line":2144,"range":{"start_line":2144,"start_character":8,"end_line":2144,"end_character":22},"updated":"2017-10-13 16:08:16.000000000","message":"This uses mox under the covers and we don\u0027t want to use mox anymore since it\u0027s not safe for py35. Use mock.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":2141,"context_line":"                                          key_name\u003dkey_name,"},{"line_number":2142,"context_line":"                                          project_id\u003dself.req_project_id,"},{"line_number":2143,"context_line":"                                          user_id\u003dself.req_user_id)"},{"line_number":2144,"context_line":"        self.stubs.Set(compute_api.API, \u0027get\u0027,"},{"line_number":2145,"context_line":"                       lambda api, *a, **k: fake_get(*a, **k))"},{"line_number":2146,"context_line":""},{"line_number":2147,"context_line":"        self.body[\u0027rebuild\u0027][\u0027key_name\u0027] \u003d key_name"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_fd43d96a","line":2144,"range":{"start_line":2144,"start_character":8,"end_line":2144,"end_character":22},"in_reply_to":"5f4e5783_8fcdd967","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":2160,"context_line":"            self.controller._stop_server, req, \u0027test_inst\u0027, body)"},{"line_number":2161,"context_line":""},{"line_number":2162,"context_line":""},{"line_number":2163,"context_line":"class ServersControllerRebuildTestV254(ServersControllerRebuildInstanceTest):"},{"line_number":2164,"context_line":""},{"line_number":2165,"context_line":"    def setUp(self):"},{"line_number":2166,"context_line":"        super(ServersControllerRebuildTestV254, self).setUp()"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_40253dc1","line":2163,"range":{"start_line":2163,"start_character":6,"end_line":2163,"end_character":38},"updated":"2017-11-04 01:06:21.000000000","message":"We should have a test where you do a rebuild but don\u0027t specify a key_name and assert the key_name is in the response with the current instance.key_name value (which would be unchanged). With the way you have the API code written, you wouldn\u0027t return key_name in the response if you didn\u0027t pass it in the request, but as I said before, I think we should always return the key_name entry in the response body with the new microversion.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":2160,"context_line":"            self.controller._stop_server, req, \u0027test_inst\u0027, body)"},{"line_number":2161,"context_line":""},{"line_number":2162,"context_line":""},{"line_number":2163,"context_line":"class ServersControllerRebuildTestV254(ServersControllerRebuildInstanceTest):"},{"line_number":2164,"context_line":""},{"line_number":2165,"context_line":"    def setUp(self):"},{"line_number":2166,"context_line":"        super(ServersControllerRebuildTestV254, self).setUp()"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_1c368d04","line":2163,"range":{"start_line":2163,"start_character":6,"end_line":2163,"end_character":38},"in_reply_to":"3f4b6375_40253dc1","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":2168,"context_line":"        self.req.api_version_request \u003d \\"},{"line_number":2169,"context_line":"            api_version_request.APIVersionRequest(\u00272.54\u0027)"},{"line_number":2170,"context_line":""},{"line_number":2171,"context_line":"    def test_rebuild_accepted_with_keypair_name(self):"},{"line_number":2172,"context_line":"        key_name \u003d \"key\""},{"line_number":2173,"context_line":"        fake_get \u003d fakes.fake_compute_get(vm_state\u003dvm_states.ACTIVE,"},{"line_number":2174,"context_line":"                                          key_name\u003dkey_name,"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_c0312d0d","line":2171,"range":{"start_line":2171,"start_character":8,"end_line":2171,"end_character":47},"updated":"2017-11-04 01:06:21.000000000","message":"This is a redundant test with the functional API samples test isn\u0027t it? If so, we could remove this.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":2168,"context_line":"        self.req.api_version_request \u003d \\"},{"line_number":2169,"context_line":"            api_version_request.APIVersionRequest(\u00272.54\u0027)"},{"line_number":2170,"context_line":""},{"line_number":2171,"context_line":"    def test_rebuild_accepted_with_keypair_name(self):"},{"line_number":2172,"context_line":"        key_name \u003d \"key\""},{"line_number":2173,"context_line":"        fake_get \u003d fakes.fake_compute_get(vm_state\u003dvm_states.ACTIVE,"},{"line_number":2174,"context_line":"                                          key_name\u003dkey_name,"}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_bc0f7935","line":2171,"range":{"start_line":2171,"start_character":8,"end_line":2171,"end_character":47},"in_reply_to":"3f4b6375_c0312d0d","updated":"2017-11-04 13:43:46.000000000","message":"I think we can keep this to improve UT code coverage.","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":2193,"context_line":"                \"key_name\": \"key\""},{"line_number":2194,"context_line":"            },"},{"line_number":2195,"context_line":"        }"},{"line_number":2196,"context_line":"        self.assertRaises(exception.ValidationError,"},{"line_number":2197,"context_line":"                          self.controller._action_rebuild,"},{"line_number":2198,"context_line":"                          self.req, FAKE_UUID, body\u003dbody)"},{"line_number":2199,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_8037b5fe","line":2196,"updated":"2017-11-04 01:06:21.000000000","message":"Let\u0027s assert that the ValidationError is really for the key_name parameter, so do something like this:\n\nex \u003d self.assertRaises(exception.ValidationError,...)\nself.assertIn(\u0027key_name\u0027, six.text_type(ex))","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":2193,"context_line":"                \"key_name\": \"key\""},{"line_number":2194,"context_line":"            },"},{"line_number":2195,"context_line":"        }"},{"line_number":2196,"context_line":"        self.assertRaises(exception.ValidationError,"},{"line_number":2197,"context_line":"                          self.controller._action_rebuild,"},{"line_number":2198,"context_line":"                          self.req, FAKE_UUID, body\u003dbody)"},{"line_number":2199,"context_line":""}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4b6375_7c2c61ab","line":2196,"in_reply_to":"3f4b6375_8037b5fe","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fb6b5b097e3dd7a82d73266aab9df2075aa50204","unresolved":false,"context_lines":[{"line_number":2275,"context_line":"                # NOTE: because the api will call _get_server twice. The server"},{"line_number":2276,"context_line":"                # response will always be the same one. So we just use"},{"line_number":2277,"context_line":"                # objects.KeyPair.get_by_name to verify test."},{"line_number":2278,"context_line":"                self.assertFalse(key_get.called)"},{"line_number":2279,"context_line":""},{"line_number":2280,"context_line":"    def test_rebuild_with_too_large_keypair_name(self):"},{"line_number":2281,"context_line":"        body \u003d {"}],"source_content_type":"text/x-python","patch_set":13,"id":"1f485f77_16060688","line":2278,"range":{"start_line":2278,"start_character":16,"end_line":2278,"end_character":48},"updated":"2017-11-11 17:42:09.000000000","message":"Use key_get.assert_not_called() - if it fails, it\u0027s a better message than assertFalse would give us.","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"9eb2fde0002569fb2af2ebf9ce53bfefae73ca7c","unresolved":false,"context_lines":[{"line_number":2275,"context_line":"                # NOTE: because the api will call _get_server twice. The server"},{"line_number":2276,"context_line":"                # response will always be the same one. So we just use"},{"line_number":2277,"context_line":"                # objects.KeyPair.get_by_name to verify test."},{"line_number":2278,"context_line":"                self.assertFalse(key_get.called)"},{"line_number":2279,"context_line":""},{"line_number":2280,"context_line":"    def test_rebuild_with_too_large_keypair_name(self):"},{"line_number":2281,"context_line":"        body \u003d {"}],"source_content_type":"text/x-python","patch_set":13,"id":"1f485f77_dcdc0d48","line":2278,"range":{"start_line":2278,"start_character":16,"end_line":2278,"end_character":48},"in_reply_to":"1f485f77_16060688","updated":"2017-11-12 02:37:50.000000000","message":"Done","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"}],"nova/tests/unit/api/openstack/fakes.py":[{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"9875df04c390957e20b35eff5797a42359ae5d93","unresolved":false,"context_lines":[{"line_number":542,"context_line":"              },"},{"line_number":543,"context_line":"        \"cleaned\": cleaned,"},{"line_number":544,"context_line":"        \"services\": services,"},{"line_number":545,"context_line":"        \"tags\": []}"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":"    instance.update(info_cache)"},{"line_number":548,"context_line":"    instance[\u0027info_cache\u0027][\u0027instance_uuid\u0027] \u003d instance[\u0027uuid\u0027]"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_c5e5263a","line":545,"updated":"2017-10-05 19:07:16.000000000","message":"I don\u0027t understand why this changes","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b00ffb70df1ce5f97a932540e5e986ee4e54a1fa","unresolved":false,"context_lines":[{"line_number":542,"context_line":"              },"},{"line_number":543,"context_line":"        \"cleaned\": cleaned,"},{"line_number":544,"context_line":"        \"services\": services,"},{"line_number":545,"context_line":"        \"tags\": []}"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":"    instance.update(info_cache)"},{"line_number":548,"context_line":"    instance[\u0027info_cache\u0027][\u0027instance_uuid\u0027] \u003d instance[\u0027uuid\u0027]"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_fa8515ae","line":545,"in_reply_to":"7f515b1d_c5e5263a","updated":"2017-10-09 14:05:27.000000000","message":"The functional test will get failed if do not add this.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":542,"context_line":"              },"},{"line_number":543,"context_line":"        \"cleaned\": cleaned,"},{"line_number":544,"context_line":"        \"services\": services,"},{"line_number":545,"context_line":"        \"tags\": []}"},{"line_number":546,"context_line":""},{"line_number":547,"context_line":"    instance.update(info_cache)"},{"line_number":548,"context_line":"    instance[\u0027info_cache\u0027][\u0027instance_uuid\u0027] \u003d instance[\u0027uuid\u0027]"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_cffd116f","line":545,"in_reply_to":"7f515b1d_fa8515ae","updated":"2017-10-13 16:08:16.000000000","message":"Because tags are added in the response in 2.26 I think.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"}],"nova/tests/unit/compute/test_compute_api.py":[{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"9875df04c390957e20b35eff5797a42359ae5d93","unresolved":false,"context_lines":[{"line_number":3245,"context_line":"    @mock.patch.object(compute_api.API, \u0027_check_auto_disk_config\u0027)"},{"line_number":3246,"context_line":"    @mock.patch.object(compute_api.API, \u0027_checks_for_create_and_rebuild\u0027)"},{"line_number":3247,"context_line":"    @mock.patch.object(compute_api.API, \u0027_record_action_start\u0027)"},{"line_number":3248,"context_line":"    def test_rebuild_change_keypair(self, _record_action_start,"},{"line_number":3249,"context_line":"            _checks_for_create_and_rebuild, _check_auto_disk_config,"},{"line_number":3250,"context_line":"            _get_image, bdm_get_by_instance_uuid, get_flavor, instance_save,"},{"line_number":3251,"context_line":"            req_spec_get_by_inst_uuid, mock_get_keypair):"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_855f2ee4","line":3248,"updated":"2017-10-05 19:07:16.000000000","message":"I\u0027m really suspect with this many mocks here. How about we just do a functional test instead?","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"b00ffb70df1ce5f97a932540e5e986ee4e54a1fa","unresolved":false,"context_lines":[{"line_number":3245,"context_line":"    @mock.patch.object(compute_api.API, \u0027_check_auto_disk_config\u0027)"},{"line_number":3246,"context_line":"    @mock.patch.object(compute_api.API, \u0027_checks_for_create_and_rebuild\u0027)"},{"line_number":3247,"context_line":"    @mock.patch.object(compute_api.API, \u0027_record_action_start\u0027)"},{"line_number":3248,"context_line":"    def test_rebuild_change_keypair(self, _record_action_start,"},{"line_number":3249,"context_line":"            _checks_for_create_and_rebuild, _check_auto_disk_config,"},{"line_number":3250,"context_line":"            _get_image, bdm_get_by_instance_uuid, get_flavor, instance_save,"},{"line_number":3251,"context_line":"            req_spec_get_by_inst_uuid, mock_get_keypair):"}],"source_content_type":"text/x-python","patch_set":11,"id":"7f515b1d_dae0199a","line":3248,"in_reply_to":"7f515b1d_855f2ee4","updated":"2017-10-09 14:05:27.000000000","message":"I will add a new ut based on this to test new user_id checking exception.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":3245,"context_line":"    @mock.patch.object(compute_api.API, \u0027_check_auto_disk_config\u0027)"},{"line_number":3246,"context_line":"    @mock.patch.object(compute_api.API, \u0027_checks_for_create_and_rebuild\u0027)"},{"line_number":3247,"context_line":"    @mock.patch.object(compute_api.API, \u0027_record_action_start\u0027)"},{"line_number":3248,"context_line":"    def test_rebuild_change_keypair(self, _record_action_start,"},{"line_number":3249,"context_line":"            _checks_for_create_and_rebuild, _check_auto_disk_config,"},{"line_number":3250,"context_line":"            _get_image, bdm_get_by_instance_uuid, get_flavor, instance_save,"},{"line_number":3251,"context_line":"            req_spec_get_by_inst_uuid, mock_get_keypair):"}],"source_content_type":"text/x-python","patch_set":11,"id":"5f4e5783_9d5e2542","line":3248,"in_reply_to":"7f515b1d_dae0199a","updated":"2017-10-14 13:46:09.000000000","message":"After reconsider this, I\u0027d like to remain this case to improve the unit testing code coverage.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"}],"releasenotes/notes/bp-rebuild-keypair-reset-9ed45744bd85e358.yaml":[{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"69ceab597d983ce142af2c8cb019a9873fdc9b3a","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API, then it is"},{"line_number":5,"context_line":"    able to reset instance key pair."}],"source_content_type":"text/x-yaml","patch_set":11,"id":"5f4e5783_af1095a9","line":5,"range":{"start_line":4,"start_character":4,"end_line":5,"end_character":36},"updated":"2017-10-13 16:08:16.000000000","message":"Let\u0027s mention the microversion that this was added in, and also mention the thing about users within the same project being able to rebuild other user\u0027s instances in that project with a new keypair - this is intentional.","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"a1dfd86d4097fd15ce202e0e5c40597f90d2e082","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API, then it is"},{"line_number":5,"context_line":"    able to reset instance key pair."}],"source_content_type":"text/x-yaml","patch_set":11,"id":"5f4e5783_9d3d052d","line":5,"range":{"start_line":4,"start_character":4,"end_line":5,"end_character":36},"in_reply_to":"5f4e5783_af1095a9","updated":"2017-10-14 13:46:09.000000000","message":"Done","commit_id":"4591e1f2c6709b479c7e05eed740e36e33cb9ad6"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API (v2.54),"},{"line_number":5,"context_line":"    then it is able to reset instance key pair. It is worth to note that users"},{"line_number":6,"context_line":"    within the same project being able to rebuild other user\u0027s instances in"},{"line_number":7,"context_line":"    that project with a new keypair."}],"source_content_type":"text/x-yaml","patch_set":12,"id":"3f4b6375_002bc594","line":5,"range":{"start_line":5,"start_character":60,"end_line":5,"end_character":67},"updated":"2017-11-04 01:06:21.000000000","message":"noting","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API (v2.54),"},{"line_number":5,"context_line":"    then it is able to reset instance key pair. It is worth to note that users"},{"line_number":6,"context_line":"    within the same project being able to rebuild other user\u0027s instances in"},{"line_number":7,"context_line":"    that project with a new keypair."}],"source_content_type":"text/x-yaml","patch_set":12,"id":"3f4b6375_bc61b907","line":5,"range":{"start_line":5,"start_character":60,"end_line":5,"end_character":67},"in_reply_to":"3f4b6375_002bc594","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"815b766ff19c85dbd8a43094c7c1e2b32e85a2e1","unresolved":false,"context_lines":[{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API (v2.54),"},{"line_number":5,"context_line":"    then it is able to reset instance key pair. It is worth to note that users"},{"line_number":6,"context_line":"    within the same project being able to rebuild other user\u0027s instances in"},{"line_number":7,"context_line":"    that project with a new keypair."}],"source_content_type":"text/x-yaml","patch_set":12,"id":"3f4b6375_e02789c6","line":6,"range":{"start_line":6,"start_character":28,"end_line":6,"end_character":33},"updated":"2017-11-04 01:06:21.000000000","message":"are","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"3169d19ac0cec569e935c6aa01790ca8b39d008b","unresolved":false,"context_lines":[{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API (v2.54),"},{"line_number":5,"context_line":"    then it is able to reset instance key pair. It is worth to note that users"},{"line_number":6,"context_line":"    within the same project being able to rebuild other user\u0027s instances in"},{"line_number":7,"context_line":"    that project with a new keypair."}],"source_content_type":"text/x-yaml","patch_set":12,"id":"3f4b6375_9c5cbd4b","line":6,"range":{"start_line":6,"start_character":28,"end_line":6,"end_character":33},"in_reply_to":"3f4b6375_e02789c6","updated":"2017-11-04 13:43:46.000000000","message":"Done","commit_id":"c91a6d8fcab0bc2601a76fe18c5ab4b7b39d4f46"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"fb6b5b097e3dd7a82d73266aab9df2075aa50204","unresolved":false,"context_lines":[{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API (v2.54),"},{"line_number":5,"context_line":"    then it is able to reset instance key pair. It is worth to noting that"},{"line_number":6,"context_line":"    users within the same project are able to rebuild other user\u0027s instances"},{"line_number":7,"context_line":"    in that project with a new keypair."},{"line_number":8,"context_line":"    If set ``key_name`` to None in API body, nova will unset the keypair of"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"1f485f77_f666ca51","line":5,"range":{"start_line":5,"start_character":60,"end_line":5,"end_character":69},"updated":"2017-11-11 17:42:09.000000000","message":"Sorry, I meant, \"It is worth noting that...\".","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"},{"author":{"_account_id":9531,"name":"liuyulong","display_name":"LIU Yulong","email":"i@liuyulong.me","username":"LIU-Yulong"},"change_message_id":"9eb2fde0002569fb2af2ebf9ce53bfefae73ca7c","unresolved":false,"context_lines":[{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new param ``key_name`` was added to the instance rebuild API (v2.54),"},{"line_number":5,"context_line":"    then it is able to reset instance key pair. It is worth to noting that"},{"line_number":6,"context_line":"    users within the same project are able to rebuild other user\u0027s instances"},{"line_number":7,"context_line":"    in that project with a new keypair."},{"line_number":8,"context_line":"    If set ``key_name`` to None in API body, nova will unset the keypair of"}],"source_content_type":"text/x-yaml","patch_set":13,"id":"1f485f77_bce15101","line":5,"range":{"start_line":5,"start_character":60,"end_line":5,"end_character":69},"in_reply_to":"1f485f77_f666ca51","updated":"2017-11-12 02:37:50.000000000","message":"Done","commit_id":"c96a18b4b1b25d23dba1fcee1f15d2c4e171d01d"}]}
