)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"afffc6531dbf703f06dd963be1c70e59a0f5d4b4","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Add device_id when creating ports"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Currently, when nova is creating ports, we don\u0027t update the device_id"},{"line_number":10,"context_line":"until we bind the port much later in the process. Its better to set the"},{"line_number":11,"context_line":"device_id when we create the port for a variety of reasons, such as it"},{"line_number":12,"context_line":"stops other instances trying to use the port we just created."},{"line_number":13,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a430d35_bc1d9274","line":10,"range":{"start_line":10,"start_character":50,"end_line":10,"end_character":53},"updated":"2017-02-09 14:07:53.000000000","message":"nit: It\u0027s ?","commit_id":"d75701b85cb124d7c32fa0bed819b00fc9f8f7a3"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"afffc6531dbf703f06dd963be1c70e59a0f5d4b4","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Currently, when nova is creating ports, we don\u0027t update the device_id"},{"line_number":10,"context_line":"until we bind the port much later in the process. Its better to set the"},{"line_number":11,"context_line":"device_id when we create the port for a variety of reasons, such as it"},{"line_number":12,"context_line":"stops other instances trying to use the port we just created."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"The real reason it is changed here is because in a few edge cases Nova"},{"line_number":15,"context_line":"still fails to correctly clean up ports we created. By adding the"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"1a430d35_17c76196","line":12,"range":{"start_line":12,"start_character":0,"end_line":12,"end_character":44},"updated":"2017-02-09 14:07:53.000000000","message":"Hmm, how exactly does this work? \n\nMany operations on Neutron resources are currently racy. E.g. updating a port or a security group both suffer from the very same problem - last concurrent update wins and potentially overwrites the applied changes, as there is no support for conditional update enforced by e-tag or something similar in Networking API.","commit_id":"d75701b85cb124d7c32fa0bed819b00fc9f8f7a3"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"1cd28978be245c39f40900c3cba11c421aa63246","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Currently, when nova is creating ports, we don\u0027t update the device_id"},{"line_number":10,"context_line":"until we bind the port much later in the process. Its better to set the"},{"line_number":11,"context_line":"device_id when we create the port for a variety of reasons, such as it"},{"line_number":12,"context_line":"stops other instances trying to use the port we just created."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"The real reason it is changed here is because in a few edge cases Nova"},{"line_number":15,"context_line":"still fails to correctly clean up ports we created. By adding the"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"fa31d9ce_f84c6878","line":12,"range":{"start_line":12,"start_character":0,"end_line":12,"end_character":44},"in_reply_to":"1a430d35_17c76196","updated":"2017-02-10 10:02:36.000000000","message":"basically, as soon as this port appears in the API, its marked with device_id. Nova always checks for device_id before allowing an attach, as its always filled in, disaster averted.\n\nNow Neutron is cooking a compare and swap style update API, that I am hoping we can adopt soon to avoid the other races you mention. But thats a separate concern.","commit_id":"d75701b85cb124d7c32fa0bed819b00fc9f8f7a3"},{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"bc24f49231cdcc060b50d061943d5f8e15c19a47","unresolved":false,"context_lines":[{"line_number":9,"context_line":"Currently, when nova is creating ports, we don\u0027t update the device_id"},{"line_number":10,"context_line":"until we bind the port much later in the process. Its better to set the"},{"line_number":11,"context_line":"device_id when we create the port for a variety of reasons, such as it"},{"line_number":12,"context_line":"stops other instances trying to use the port we just created."},{"line_number":13,"context_line":""},{"line_number":14,"context_line":"The real reason it is changed here is because in a few edge cases Nova"},{"line_number":15,"context_line":"still fails to correctly clean up ports we created. By adding the"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":1,"id":"fa31d9ce_31f97981","line":12,"range":{"start_line":12,"start_character":0,"end_line":12,"end_character":44},"in_reply_to":"fa31d9ce_f84c6878","updated":"2017-02-13 09:00:11.000000000","message":"Makes sense, thank you for clarification!","commit_id":"d75701b85cb124d7c32fa0bed819b00fc9f8f7a3"}],"nova/network/neutronv2/api.py":[{"author":{"_account_id":6849,"name":"Roman Podoliaka","email":"roman.podoliaka@gmail.com","username":"rpodolyaka"},"change_message_id":"afffc6531dbf703f06dd963be1c70e59a0f5d4b4","unresolved":false,"context_lines":[{"line_number":369,"context_line":"            IpAddressGenerationFailure error."},{"line_number":370,"context_line":"        :raises: PortBindingFailed: If port binding failed."},{"line_number":371,"context_line":"        \"\"\""},{"line_number":372,"context_line":"        # Set the device_id so its clear who this port was created for,"},{"line_number":373,"context_line":"        # and to stop other instances trying to use it"},{"line_number":374,"context_line":"        port_req_body \u003d {\u0027port\u0027: {\u0027device_id\u0027: instance.uuid}}"},{"line_number":375,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":1,"id":"1a430d35_1c614605","line":372,"range":{"start_line":372,"start_character":31,"end_line":372,"end_character":34},"updated":"2017-02-09 14:07:53.000000000","message":"nit: it\u0027s?","commit_id":"d75701b85cb124d7c32fa0bed819b00fc9f8f7a3"}]}
