)]}'
{"specs/newton/approved/get-me-a-network.rst":[{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"7c0aaa3d2f8d9865a8075155a74893eaf0b8c1ce","unresolved":false,"context_lines":[{"line_number":60,"context_line":"a fixed IP associated with it. When requesting a specific port, the network"},{"line_number":61,"context_line":"that the port is in is implied in the create request."},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"In the last case (nothing is requested), Nova will use attempt to lookup an"},{"line_number":64,"context_line":"available network to use by searching for:"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"#. A private network for the project."}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_2101de05","line":63,"range":{"start_line":63,"start_character":51,"end_line":63,"end_character":54},"updated":"2016-02-23 16:16:15.000000000","message":"s/use //","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"222e2c1407da15762885bc6c798fc7b24f457e93","unresolved":false,"context_lines":[{"line_number":60,"context_line":"a fixed IP associated with it. When requesting a specific port, the network"},{"line_number":61,"context_line":"that the port is in is implied in the create request."},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"In the last case (nothing is requested), Nova will use attempt to lookup an"},{"line_number":64,"context_line":"available network to use by searching for:"},{"line_number":65,"context_line":""},{"line_number":66,"context_line":"#. A private network for the project."}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_3385ac06","line":63,"range":{"start_line":63,"start_character":51,"end_line":63,"end_character":54},"in_reply_to":"bae84128_2101de05","updated":"2016-02-23 17:37:59.000000000","message":"Done","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"7c0aaa3d2f8d9865a8075155a74893eaf0b8c1ce","unresolved":false,"context_lines":[{"line_number":111,"context_line":"* Specifying \u0027auto\u0027 with any other network values (ports, \u0027none\u0027 or a specific"},{"line_number":112,"context_line":"  network uuid)."},{"line_number":113,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":114,"context_line":"  network uuid)."},{"line_number":115,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":116,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":117,"context_line":"  node)."}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_e101b6b0","line":114,"updated":"2016-02-23 16:16:15.000000000","message":"The two cases above should also return a 400, right?","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"222e2c1407da15762885bc6c798fc7b24f457e93","unresolved":false,"context_lines":[{"line_number":111,"context_line":"* Specifying \u0027auto\u0027 with any other network values (ports, \u0027none\u0027 or a specific"},{"line_number":112,"context_line":"  network uuid)."},{"line_number":113,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":114,"context_line":"  network uuid)."},{"line_number":115,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":116,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":117,"context_line":"  node)."}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_f3950433","line":114,"in_reply_to":"bae84128_e101b6b0","updated":"2016-02-23 17:37:59.000000000","message":"Yeah, was implied, I\u0027ll make it explicit.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"d6a670eba7e439d1c063db079d370ffc7421a919","unresolved":false,"context_lines":[{"line_number":111,"context_line":"* Specifying \u0027auto\u0027 with any other network values (ports, \u0027none\u0027 or a specific"},{"line_number":112,"context_line":"  network uuid)."},{"line_number":113,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":114,"context_line":"  network uuid)."},{"line_number":115,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":116,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":117,"context_line":"  node)."}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_8f9a886c","line":114,"in_reply_to":"bae84128_f3950433","updated":"2016-02-23 19:51:54.000000000","message":"+1 for making it explicit.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"d6a670eba7e439d1c063db079d370ffc7421a919","unresolved":false,"context_lines":[{"line_number":116,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":117,"context_line":"  node)."},{"line_number":118,"context_line":"* If \u0027auto\u0027 is specified with Neutron and the project does not have a network"},{"line_number":119,"context_line":"  available but Neutron is not configured to provide auto-allocation."},{"line_number":120,"context_line":""},{"line_number":121,"context_line":"Compute API changes"},{"line_number":122,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_8fbf28a9","line":119,"updated":"2016-02-23 19:51:54.000000000","message":"If auto is specified, and we can determine during the lifecycle of the API request that we can\u0027t honor that, it should be a 400 as well.\n\nIf it fails after the API request has returned, the instance is sent to ERROR state.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"148dc5d2e2999331431736a3d550b7b5d7f97b88","unresolved":false,"context_lines":[{"line_number":131,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":132,"context_line":"network to use, then validate that:"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":135,"context_line":"* There is a default public external network and default subnet pool to use."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_571a0b7e","line":134,"range":{"start_line":134,"start_character":2,"end_line":134,"end_character":74},"updated":"2016-02-22 22:40:19.000000000","message":"Looks like this might not be configurable:\n\nhttps://github.com/openstack/neutron/blob/aadf2f30f84dff3d85f380a7ff4e16dbbb0c6bb0/neutron/plugins/common/constants.py#L41","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"d6a670eba7e439d1c063db079d370ffc7421a919","unresolved":false,"context_lines":[{"line_number":131,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":132,"context_line":"network to use, then validate that:"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":135,"context_line":"* There is a default public external network and default subnet pool to use."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_ef05147a","line":134,"range":{"start_line":134,"start_character":2,"end_line":134,"end_character":74},"in_reply_to":"bae84128_07382aee","updated":"2016-02-23 19:51:54.000000000","message":"Sure, it\u0027s just a safety measure for transition. And I agree that if this is considered mandatory for neutron, we stop checking at some point.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"7c0aaa3d2f8d9865a8075155a74893eaf0b8c1ce","unresolved":false,"context_lines":[{"line_number":131,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":132,"context_line":"network to use, then validate that:"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":135,"context_line":"* There is a default public external network and default subnet pool to use."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_41018269","line":134,"range":{"start_line":134,"start_character":2,"end_line":134,"end_character":74},"in_reply_to":"bae84128_2dc3baee","updated":"2016-02-23 16:16:15.000000000","message":"We\u0027ll still need to check for older versions of Neutron where it\u0027s not guaranteed to be enabled. But it\u0027s great that it will be uniformly enabled as people upgrade.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"0bc8fd94c0c525fe7a24c0af3fef13df8916f8ef","unresolved":false,"context_lines":[{"line_number":131,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":132,"context_line":"network to use, then validate that:"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":135,"context_line":"* There is a default public external network and default subnet pool to use."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_07382aee","line":134,"range":{"start_line":134,"start_character":2,"end_line":134,"end_character":74},"in_reply_to":"bae84128_41018269","updated":"2016-02-23 16:45:46.000000000","message":"yes, as far as Neutron is concerned I wouldn\u0027t want this to be configurable from Mitaka onward. Obviously Nova needs to operate with older Neutron servers, but then the check can be dropped in two releases from now.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"6a7a1cd9a20b8c8a710c86b22b5ccbef2e1f4e95","unresolved":false,"context_lines":[{"line_number":131,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":132,"context_line":"network to use, then validate that:"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":135,"context_line":"* There is a default public external network and default subnet pool to use."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_2dc3baee","line":134,"range":{"start_line":134,"start_character":2,"end_line":134,"end_character":74},"in_reply_to":"bae84128_571a0b7e","updated":"2016-02-22 23:40:48.000000000","message":"I thought the whole point of this was to make different clouds behave uniformly. If we provide a knob to enable/disable this then we\u0027re back to square one. That\u0027s why I did it the way I did, otherwise this was already configurable.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"00202968d542f8184d627fa479300104eac166f3","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_101fe9b7","line":140,"updated":"2016-02-23 00:07:30.000000000","message":"we could consider adding an API to validate the requirements but this API would lead to race-y behavior. What if the requirements change between the time you\u0027re validating and the time you\u0027re actually making the call to provision? That\u0027s why I ruled out adding any \u0027dry-run/check\u0027 API.\n\nWe could add it so long as you put in writing that you\u0027re not gonna come after us when this is going to bite you :)","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"52dd235eeae1a8f6e6d702fed5e73532066f0f5d","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_a29b3317","line":140,"in_reply_to":"bae84128_101fe9b7","updated":"2016-02-23 15:02:37.000000000","message":"Well, we\u0027ll already have the race in the nova API.  We\u0027re going to be validating that the extension is enabled, that the default external network exists, and the default shared subnet pool exists in nova-api before we cast off to compute. Then in compute we actually call the auto-allocated-topology API to create the network, which could fail if something changes by then, but such is life I guess...\n\nWe can\u0027t call the neutron API to allocate the network from nova API since we don\u0027t want to block the server create in nova-api on the neutron call.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"024e852a920baabaf2da6724128dbb2de985f6bd","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_4824fe5e","line":140,"in_reply_to":"bae84128_1397c8ec","updated":"2016-02-23 18:04:23.000000000","message":"As Matt described it is troublesome for users when failures occur after the point that the Nova API has returned a response so we want to verify as much before that as possible. But we also need to balance that against wanting to return a response as quickly as possible which means limiting calls to other services.\n\nI think the right balance is to check things that can be cached and of which there is little concern about cache invalidation. Checking if the extension is enabled is a one time check since we don\u0027t expect it to disappear after that. I don\u0027t know enough about the other two checks, are they global things or per project things? In either case they seem cacheable checks, perhaps with a refresh on a long period.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3453732c733ae728ba2ce2bae8cbc6cb6e3d48aa","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_99a81679","line":140,"in_reply_to":"bae84128_3e1e105f","updated":"2016-02-23 19:14:16.000000000","message":"Talking in the neutron meetup, Armando raises a decent point that if we did create the network from nova-api, it\u0027s a one-time cost per project. We could race if multiple server create requests come into the API at the same time for the same project, but I\u0027m told that neutron has a unique constraint in the DB and if the 2nd hits a constraint it rolls back and returns the network ID that was created (from the unique constraint for that project).\n\nSo with that we\u0027d have the validation built into the neutronclient.auto_allocate_topology_show call from the API. The downside is blocking the nova-api for server create on the first time for a project.\n\nI can\u0027t think of anything else in nova that does a one-time setup cost from the API. I\u0027ve been trying to think of this like boot from volume with cinder where we check status and make reservations to cinder in the API, then cast off to compute and actually try to create the volume (which can fail or timeout) and then we reschedule (or fail with NoValidHost). The difference in that case is boot from volume is per-project and per-instance, it\u0027s not a shared volume for each instance in the project.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"0712a6b01ee12ce81047c0bf709c29f6cd43fa3e","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_3e1e105f","line":140,"in_reply_to":"bae84128_4824fe5e","updated":"2016-02-23 18:38:45.000000000","message":"I\u0027ll add something to the Performance Impact section about potentially caching a positive result of the validation checks with a timeout.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"222e2c1407da15762885bc6c798fc7b24f457e93","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_1397c8ec","line":140,"in_reply_to":"bae84128_9260f602","updated":"2016-02-23 17:37:59.000000000","message":"I was wondering about quota issues myself (I\u0027m assuming that\u0027s what you meant with \"networking space from the subnet pool has exhausted?\"). Is there a way to check that from the API, like I see the subnetpool.default_quota attribute, but I\u0027m not sure how to determine what the usage is (which would also be racy).\n\nI do think there is valid in making sure the 3 main things are setup in nova-api so we can fail-fast:\n\n1. the extension is enabled\n2. the default external network is created\n3. the default shared subnetpool exists\n\nThis would allow nova to return an error response from the API rather than having the case that we cast off to compute (user gets a 202), we fail on compute node1 b/c things aren\u0027t setup in neutron, so we reschedule the instance build to compute node2 and fail there, and reschedule to compute node3 and fail there and finally set the instance state to ERROR.  And the user has to check the instance fault information to know what failed, but I don\u0027t think we actually expose the details so they\u0027ll have to open a support ticket to the admin to figure out what\u0027s going on.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"cbdd4756825b8eb2e67ef4d65cc342db05bcacff","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_aac2da31","line":140,"in_reply_to":"bae84128_99a81679","updated":"2016-02-23 20:07:41.000000000","message":"I\u0027m really hesitant to introduce any remote calls that create a resource in another service due to the potential time required. We\u0027ve been very conscious about avoiding that in the past despite the benefits it would provide in error reporting. The idea has still been that we will eventually find a decent means of exposing failures that occur after the API response has been provided(like tasks).","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"0bc8fd94c0c525fe7a24c0af3fef13df8916f8ef","unresolved":false,"context_lines":[{"line_number":137,"context_line":"  .. note:: Ideally the setup required on the Neutron side would be part of"},{"line_number":138,"context_line":"            the Neutron API so Nova could just ask if auto-allocate is"},{"line_number":139,"context_line":"            available without Nova needing to know all of these details, but"},{"line_number":140,"context_line":"            this could be considered a future enhancement."},{"line_number":141,"context_line":""},{"line_number":142,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":143,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_9260f602","line":140,"in_reply_to":"bae84128_a29b3317","updated":"2016-02-23 16:45:46.000000000","message":"I am assuming that you wouldn\u0027t want to check that the networking space from the subnet pool has exhausted?\n\nTo be honest I have mixed feeling about this check. It seems unnecessary, because these are deployments pre-requirements that any conscious admin would validate before rolling out their cloud publicly. \n\nIf you really want to have these checks in place though, it might be best if we worked out a less chatty way of dealing with this, because right now you\u0027d need to issue requests spanning multiple resources.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"00202968d542f8184d627fa479300104eac166f3","unresolved":false,"context_lines":[{"line_number":186,"context_line":"Ultimately it was decided that it is best to require API users to be explicit"},{"line_number":187,"context_line":"in the request with what they want (auto/none/uuid). And to make the user"},{"line_number":188,"context_line":"experience better in the CLI, the CLI will default to \u0027auto\u0027 when nothing is"},{"line_number":189,"context_line":"specified (and the server supports the microversion)."},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"Data model impact"},{"line_number":192,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_90e5b9dd","line":189,"updated":"2016-02-23 00:07:30.000000000","message":"To me the very definition of default is something that can be omitted, regardless of whether we\u0027re using the API, the CLI or the GUI directly. Therefore I find it odd to allow a user to \u0027specify a default\u0027.\n\nI feel that having the CLI behave differently from the API leads to inconsistencies in the user experience. I only voice my concern because it\u0027s the networking side of things we\u0027re talking about, that said if there\u0027s overwhelming consensus, then I won\u0027t interfere.\n\n[1] https://en.wikipedia.org/wiki/Default_(computer_science)","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":5441,"name":"Andrew Laski","email":"andrew@lascii.com","username":"alaski"},"change_message_id":"7c0aaa3d2f8d9865a8075155a74893eaf0b8c1ce","unresolved":false,"context_lines":[{"line_number":186,"context_line":"Ultimately it was decided that it is best to require API users to be explicit"},{"line_number":187,"context_line":"in the request with what they want (auto/none/uuid). And to make the user"},{"line_number":188,"context_line":"experience better in the CLI, the CLI will default to \u0027auto\u0027 when nothing is"},{"line_number":189,"context_line":"specified (and the server supports the microversion)."},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"Data model impact"},{"line_number":192,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_e7e54638","line":189,"in_reply_to":"bae84128_5d2fa887","updated":"2016-02-23 16:16:15.000000000","message":"I think it\u0027s worthwhile to be explicit in the API for two reasons:\n1. Because the default behavior is not consistent currently, though I know that\u0027s what\u0027s being addressed with this effort.\n2. Because we want to modify the API over time. If a default is changed we\u0027ve removed the ability for users to specify the behavior they were using unless we\u0027ve provided explicit means to request that behavior. At the API level we want to provide explicit ways to request different behaviors, and the default is provided by the CLI specifying that at this point in time it should specify a certain behavior without needing user input.","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"52dd235eeae1a8f6e6d702fed5e73532066f0f5d","unresolved":false,"context_lines":[{"line_number":186,"context_line":"Ultimately it was decided that it is best to require API users to be explicit"},{"line_number":187,"context_line":"in the request with what they want (auto/none/uuid). And to make the user"},{"line_number":188,"context_line":"experience better in the CLI, the CLI will default to \u0027auto\u0027 when nothing is"},{"line_number":189,"context_line":"specified (and the server supports the microversion)."},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"Data model impact"},{"line_number":192,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_5d2fa887","line":189,"in_reply_to":"bae84128_90e5b9dd","updated":"2016-02-23 15:02:37.000000000","message":"This came out of the discussion in the -dev ML thread here:\n\nhttp://lists.openstack.org/pipermail/openstack-dev/2016-February/087131.html","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"d6a670eba7e439d1c063db079d370ffc7421a919","unresolved":false,"context_lines":[{"line_number":186,"context_line":"Ultimately it was decided that it is best to require API users to be explicit"},{"line_number":187,"context_line":"in the request with what they want (auto/none/uuid). And to make the user"},{"line_number":188,"context_line":"experience better in the CLI, the CLI will default to \u0027auto\u0027 when nothing is"},{"line_number":189,"context_line":"specified (and the server supports the microversion)."},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"Data model impact"},{"line_number":192,"context_line":"-----------------"}],"source_content_type":"text/x-rst","patch_set":2,"id":"bae84128_af1e6cb8","line":189,"in_reply_to":"bae84128_e7e54638","updated":"2016-02-23 19:51:54.000000000","message":"Right, the 2 interfaces have 2 different audiences. For the API it\u0027s almost a one time cost to update your code and be done with it.\n\nWith the CLI that\u0027s something humans are hitting interactively all the time. So requiring a \u0027do-it\u003dtrue\u0027 parameter for the common case is something our users will hate us for (and has been raised on the mailing list).","commit_id":"bcfa5b339499421c8a53f105780c113841568848"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"8f6fd0ba5f68648a0182e515dda2fef82e8a53c6","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Neutron added the ``auto-allocated-topology`` API in Mitaka [1]_. Nova intends"},{"line_number":14,"context_line":"on using this API to automatically allocate a private network for a project"},{"line_number":15,"context_line":"when creating server instance if no specific network is provided in the create"},{"line_number":16,"context_line":"request and none are available to the project. This should also bring some"},{"line_number":17,"context_line":"feature parity for the server create flow between Neutron and nova-network."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":3,"id":"bae84128_fb5e2878","line":17,"range":{"start_line":16,"start_character":47,"end_line":17,"end_character":74},"updated":"2016-03-24 01:10:19.000000000","message":"I feel like this isn\u0027t clear unless we mention which nova-network manager. FlatManager doesn\u0027t/can\u0027t automatically create a private network for a project if none are available. Meaning, from my point of view there is already feature parity there as I\u0027m not so familiar with VlanManager.\n\nEdit: I went through the VlanManager code and I don\u0027t see that it ever can auto-create a network. Networks still must be created by the cloud operator using nova-manage and VlanManager will \"setup\" each network.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"9721260c07c6a2c41ceeb40343b0256a69fdf9ce","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Neutron added the ``auto-allocated-topology`` API in Mitaka [1]_. Nova intends"},{"line_number":14,"context_line":"on using this API to automatically allocate a private network for a project"},{"line_number":15,"context_line":"when creating server instance if no specific network is provided in the create"},{"line_number":16,"context_line":"request and none are available to the project. This should also bring some"},{"line_number":17,"context_line":"feature parity for the server create flow between Neutron and nova-network."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":3,"id":"ba0121b8_c148988d","line":17,"range":{"start_line":16,"start_character":47,"end_line":17,"end_character":74},"in_reply_to":"ba0121b8_9563481a","updated":"2016-04-01 20:07:07.000000000","message":"More details here:\n\nhttp://docs.openstack.org/mitaka/networking-guide/intro-os-networking-features.html\n\nIn a nutshell, networks are created on the \u0027fly\u0027, whilst the operator has to preconfigure a subnetpool (the range of IPs to be chosen from when creating tenant networks) and a floating ip range to allow direct access connectivity. This is the closest use case to the VLAN Manager one we could implement and keep the implementation relatively small at the same time. We can iterate and embrace different topology models, if need be, but this was the one we nailed at the Nova mid-cycle.\n\nAs for port-security, I think this has been answered, but basically, we inherit the default behavior.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3411f54a00c4185d60d38fe0174ac3addad9a41d","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Neutron added the ``auto-allocated-topology`` API in Mitaka [1]_. Nova intends"},{"line_number":14,"context_line":"on using this API to automatically allocate a private network for a project"},{"line_number":15,"context_line":"when creating server instance if no specific network is provided in the create"},{"line_number":16,"context_line":"request and none are available to the project. This should also bring some"},{"line_number":17,"context_line":"feature parity for the server create flow between Neutron and nova-network."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_efac6eef","line":17,"range":{"start_line":16,"start_character":47,"end_line":17,"end_character":74},"in_reply_to":"bae84128_fb5e2878","updated":"2016-03-25 19:10:11.000000000","message":"I\u0027ll make this more specific to VlanManager.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"4d98c5ced92883be6f209d3e5a4969e0828069cc","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Neutron added the ``auto-allocated-topology`` API in Mitaka [1]_. Nova intends"},{"line_number":14,"context_line":"on using this API to automatically allocate a private network for a project"},{"line_number":15,"context_line":"when creating server instance if no specific network is provided in the create"},{"line_number":16,"context_line":"request and none are available to the project. This should also bring some"},{"line_number":17,"context_line":"feature parity for the server create flow between Neutron and nova-network."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":3,"id":"ba0121b8_9563481a","line":17,"range":{"start_line":16,"start_character":47,"end_line":17,"end_character":74},"in_reply_to":"da0c15f0_7b882023","updated":"2016-03-29 14:12:02.000000000","message":"Melanie, the neutron spec is here:\n\nhttp://specs.openstack.org/openstack/neutron-specs/specs/mitaka/get-me-a-network.html\n\nThere are 4 options and what they implemented was #4.\n\nArmando can correct me if I\u0027m wrong, but there has to be a default external public network and a subnet pool available for this to work. If those are available, the API creates a private network for the project and carves out a subnet from that pool.\n\nA question that is now coming up this morning is whether or not that network would have port security enabled. HenryG was saying it wouldn\u0027t because they couldn\u0027t tell if the port security extension would be enabled. I\u0027m not sure what impacts this is going to have for the allocate network code in nova\u0027s neutronv2 API is yet, I haven\u0027t yet written a POC for that.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"87dbe0e018b49d31fc20de3fdc371669015587c8","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Neutron added the ``auto-allocated-topology`` API in Mitaka [1]_. Nova intends"},{"line_number":14,"context_line":"on using this API to automatically allocate a private network for a project"},{"line_number":15,"context_line":"when creating server instance if no specific network is provided in the create"},{"line_number":16,"context_line":"request and none are available to the project. This should also bring some"},{"line_number":17,"context_line":"feature parity for the server create flow between Neutron and nova-network."},{"line_number":18,"context_line":""},{"line_number":19,"context_line":""},{"line_number":20,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_7b882023","line":17,"range":{"start_line":16,"start_character":47,"end_line":17,"end_character":74},"in_reply_to":"da0c15f0_efac6eef","updated":"2016-03-25 21:39:38.000000000","message":"Sorry, I\u0027m having trouble understanding what the auto-allocated-topology does. Does it actually create networks? Or does it just setup topology on top of networks created by an operator? In nova-network, networks are never automatically created -- they must be created by a cloud operator. VlanManager uses the created networks to setup the topology per tenant automatically, IIUC.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"8f6fd0ba5f68648a0182e515dda2fef82e8a53c6","unresolved":false,"context_lines":[{"line_number":83,"context_line":"1. auto:"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"  * This means auto-allocate the network for me if one is not available to the"},{"line_number":86,"context_line":"    project. For nova-network this is the default and existing behavior. For"},{"line_number":87,"context_line":"    Neutron this means using the ``auto-allocated-topology`` API."},{"line_number":88,"context_line":"  * The \u0027auto\u0027 value cannot be used when specifying a port uuid because a port"},{"line_number":89,"context_line":"    implies a network that the project would already have access to."}],"source_content_type":"text/x-rst","patch_set":3,"id":"fa0719c6_65fabb76","line":86,"range":{"start_line":86,"start_character":42,"end_line":86,"end_character":71},"updated":"2016-03-24 01:10:19.000000000","message":"for VlanManager","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"33ef2ce5ca7ae97d389378181a53ece8aff47b76","unresolved":false,"context_lines":[{"line_number":83,"context_line":"1. auto:"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"  * This means auto-allocate the network for me if one is not available to the"},{"line_number":86,"context_line":"    project. For nova-network this is the default and existing behavior. For"},{"line_number":87,"context_line":"    Neutron this means using the ``auto-allocated-topology`` API."},{"line_number":88,"context_line":"  * The \u0027auto\u0027 value cannot be used when specifying a port uuid because a port"},{"line_number":89,"context_line":"    implies a network that the project would already have access to."}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_67223e03","line":86,"range":{"start_line":86,"start_character":42,"end_line":86,"end_character":71},"in_reply_to":"da0c15f0_6f87be61","updated":"2016-03-26 02:31:51.000000000","message":"It might be cleaner in the nova-network case if we simply don\u0027t set NetworkRequest.network_id if not neutron and \u0027auto\u0027 is requested. Then we don\u0027t have to touch the nova-network API code (I don\u0027t think anyway). The thing I don\u0027t like about that is then the REST API has to know how the network API is implemented, and that should be a black box interface. I think in the case of \u0027auto\u0027 for nova-network (and neutron), we\u0027ll just have to special-case \u0027auto\u0027 in deallocate_for_instance so we treat it like None.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3411f54a00c4185d60d38fe0174ac3addad9a41d","unresolved":false,"context_lines":[{"line_number":83,"context_line":"1. auto:"},{"line_number":84,"context_line":""},{"line_number":85,"context_line":"  * This means auto-allocate the network for me if one is not available to the"},{"line_number":86,"context_line":"    project. For nova-network this is the default and existing behavior. For"},{"line_number":87,"context_line":"    Neutron this means using the ``auto-allocated-topology`` API."},{"line_number":88,"context_line":"  * The \u0027auto\u0027 value cannot be used when specifying a port uuid because a port"},{"line_number":89,"context_line":"    implies a network that the project would already have access to."}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_6f87be61","line":86,"range":{"start_line":86,"start_character":42,"end_line":86,"end_character":71},"in_reply_to":"fa0719c6_65fabb76","updated":"2016-03-25 19:10:11.000000000","message":"Done","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"943285b61587ce57582cb24506636fba37f1f1cf","unresolved":false,"context_lines":[{"line_number":143,"context_line":""},{"line_number":144,"context_line":"The compute API code will not actually call the ``auto-allocated-topology``"},{"line_number":145,"context_line":"Neutron API since doing a GET on the API also creates the network, there is no"},{"line_number":146,"context_line":"dry-run type option. This is meant to make the operation atomic and idempotent"},{"line_number":147,"context_line":"in Neutron. However, because of that, it\u0027s a blocking call and nova-api will"},{"line_number":148,"context_line":"not block the server create request while Neutron sets up a network."},{"line_number":149,"context_line":""}],"source_content_type":"text/x-rst","patch_set":3,"id":"bae84128_285533c5","line":146,"updated":"2016-02-23 20:30:36.000000000","message":"we can provide one, if needed.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"652f0a57d4276269a0505f23bacc921601728408","unresolved":false,"context_lines":[{"line_number":143,"context_line":""},{"line_number":144,"context_line":"The compute API code will not actually call the ``auto-allocated-topology``"},{"line_number":145,"context_line":"Neutron API since doing a GET on the API also creates the network, there is no"},{"line_number":146,"context_line":"dry-run type option. This is meant to make the operation atomic and idempotent"},{"line_number":147,"context_line":"in Neutron. However, because of that, it\u0027s a blocking call and nova-api will"},{"line_number":148,"context_line":"not block the server create request while Neutron sets up a network."},{"line_number":149,"context_line":""}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_215e7676","line":146,"in_reply_to":"bae84128_285533c5","updated":"2016-03-26 00:04:35.000000000","message":"booya! https://review.openstack.org/#/c/284307/","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"943285b61587ce57582cb24506636fba37f1f1cf","unresolved":false,"context_lines":[{"line_number":175,"context_line":"          place based on a unique constraint for the project_id in the"},{"line_number":176,"context_line":"          ``auto_allocated_topologies`` table. So a second concurrent request"},{"line_number":177,"context_line":"          should fail and be rolled back, but the API will return the network"},{"line_number":178,"context_line":"          that was already created for that project."},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"Alternatives"},{"line_number":181,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"bae84128_a8af837b","line":178,"updated":"2016-02-23 20:30:36.000000000","message":"besides the concurrency issue, there\u0027s the aspect that deferring the call to the compute node increases the amount of requests issues to Neutron per given request. Say that we want to burst and create N servers at once, each compute will issue a port-create request; with this proposal we will have to issue a \u0027lookup\u0027 query too.\n\nThis results in doubling the number of requests at every given request. IMO, accepting a recurring cost rather than a one-cost is a counterintuitive design choice, especially if Neutron is already pounded as it is.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"ad730f309467b978ed29f665f2cf891df9876326","unresolved":false,"context_lines":[{"line_number":175,"context_line":"          place based on a unique constraint for the project_id in the"},{"line_number":176,"context_line":"          ``auto_allocated_topologies`` table. So a second concurrent request"},{"line_number":177,"context_line":"          should fail and be rolled back, but the API will return the network"},{"line_number":178,"context_line":"          that was already created for that project."},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"Alternatives"},{"line_number":181,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":3,"id":"bae84128_6bd3b560","line":178,"in_reply_to":"bae84128_a8af837b","updated":"2016-02-23 20:45:38.000000000","message":"To add more details, booting multiple instances with default networking may not necessarily be representative of the common use case, thus performance impact could be limited to this use case only.\n\nOn the other end, compute hosts already do network lookup prior to port allocation; so long as we\u0027re careful how the new request call is issued, we may be end up without an actual increase in number of calls.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"af6ce887a52e611bfec44c3f36353cb0955ced96","unresolved":false,"context_lines":[{"line_number":298,"context_line":"------------------"},{"line_number":299,"context_line":""},{"line_number":300,"context_line":"Anytime Nova is calling Neutron there is additional overhead. There will be"},{"line_number":301,"context_line":"three additional checks in the compute API for the network request validation"},{"line_number":302,"context_line":"in the case that \u0027auto\u0027 is specified and there are no available existing"},{"line_number":303,"context_line":"networks for the project:"},{"line_number":304,"context_line":""}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_e785ae59","line":301,"range":{"start_line":301,"start_character":0,"end_line":301,"end_character":5},"updated":"2016-03-26 02:11:29.000000000","message":"two:\n\n  1. that the extension is enabled\n  2. the dry-run validation call","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"af6ce887a52e611bfec44c3f36353cb0955ced96","unresolved":false,"context_lines":[{"line_number":305,"context_line":"1. That the ``auto-allocated-topology`` extension is enabled. The extensions"},{"line_number":306,"context_line":"   are already cached in nova.network.neutronv2.api.API so this should be"},{"line_number":307,"context_line":"   minimal overhead."},{"line_number":308,"context_line":"2. That there is a default public external network. To minimize this we filter"},{"line_number":309,"context_line":"   the network list like:"},{"line_number":310,"context_line":""},{"line_number":311,"context_line":"    ::"},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"    search_opts \u003d {\u0027router:external\u0027: True, \u0027is_default\u0027: True}"},{"line_number":314,"context_line":"    nets \u003d neutron.list_networks(**search_opts).get(\u0027networks\u0027, [])"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"3. That there is a default shared subnet pool. To minimize this we filter the"},{"line_number":317,"context_line":"   subnet pool list like:"},{"line_number":318,"context_line":""},{"line_number":319,"context_line":"    ::"},{"line_number":320,"context_line":""},{"line_number":321,"context_line":"    params \u003d {\u0027shared\u0027: True, \u0027is_default\u0027: True}"},{"line_number":322,"context_line":"    subnet_pools \u003d neutron.list_subnetpools(**params).get(\u0027subnetpools\u0027, [])"},{"line_number":323,"context_line":""},{"line_number":324,"context_line":""},{"line_number":325,"context_line":".. note:: Nova could offset the cost of doing this validation with Neutron by"}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_8797928f","line":322,"range":{"start_line":308,"start_character":0,"end_line":322,"end_character":76},"updated":"2016-03-26 02:11:29.000000000","message":"This becomes one call now.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"9721260c07c6a2c41ceeb40343b0256a69fdf9ce","unresolved":false,"context_lines":[{"line_number":305,"context_line":"1. That the ``auto-allocated-topology`` extension is enabled. The extensions"},{"line_number":306,"context_line":"   are already cached in nova.network.neutronv2.api.API so this should be"},{"line_number":307,"context_line":"   minimal overhead."},{"line_number":308,"context_line":"2. That there is a default public external network. To minimize this we filter"},{"line_number":309,"context_line":"   the network list like:"},{"line_number":310,"context_line":""},{"line_number":311,"context_line":"    ::"},{"line_number":312,"context_line":""},{"line_number":313,"context_line":"    search_opts \u003d {\u0027router:external\u0027: True, \u0027is_default\u0027: True}"},{"line_number":314,"context_line":"    nets \u003d neutron.list_networks(**search_opts).get(\u0027networks\u0027, [])"},{"line_number":315,"context_line":""},{"line_number":316,"context_line":"3. That there is a default shared subnet pool. To minimize this we filter the"},{"line_number":317,"context_line":"   subnet pool list like:"},{"line_number":318,"context_line":""},{"line_number":319,"context_line":"    ::"},{"line_number":320,"context_line":""},{"line_number":321,"context_line":"    params \u003d {\u0027shared\u0027: True, \u0027is_default\u0027: True}"},{"line_number":322,"context_line":"    subnet_pools \u003d neutron.list_subnetpools(**params).get(\u0027subnetpools\u0027, [])"},{"line_number":323,"context_line":""},{"line_number":324,"context_line":""},{"line_number":325,"context_line":".. note:: Nova could offset the cost of doing this validation with Neutron by"}],"source_content_type":"text/x-rst","patch_set":3,"id":"ba0121b8_0cf2c706","line":322,"range":{"start_line":308,"start_character":0,"end_line":322,"end_character":76},"in_reply_to":"da0c15f0_8797928f","updated":"2016-04-01 20:07:07.000000000","message":"you\u0027re welcome!","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"391646ff0b707d4d032f3d1fb783fdc5aecc4fe3","unresolved":false,"context_lines":[{"line_number":368,"context_line":"----------"},{"line_number":369,"context_line":""},{"line_number":370,"context_line":"* REST API changes in Nova for the microversion and auto/none/uuid logic."},{"line_number":371,"context_line":"* Updates in the compute API to not call network_api.validate_networks if"},{"line_number":372,"context_line":"  NetworkRequest.network_id \u003d\u003d \u0027none\u0027."},{"line_number":373,"context_line":"* Updates to nova.network.neutronv2.api.API.validate_networks method for the"},{"line_number":374,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":375,"context_line":"  potentially caching the results of the validation with Neutron."}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_05c5438d","line":372,"range":{"start_line":371,"start_character":2,"end_line":372,"end_character":38},"updated":"2016-03-25 20:07:41.000000000","message":"And updates to the compute manager to not call allocate_for_instance is network_id is \u0027none\u0027.\n\nThere will also be a change to the compute API such that we don\u0027t check the create:attach_network policy if network_id is \u0027none\u0027 since we don\u0027t care about the user\u0027s ability to attach a network if we\u0027re not going to do it anyway.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"af6ce887a52e611bfec44c3f36353cb0955ced96","unresolved":false,"context_lines":[{"line_number":373,"context_line":"* Updates to nova.network.neutronv2.api.API.validate_networks method for the"},{"line_number":374,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":375,"context_line":"  potentially caching the results of the validation with Neutron."},{"line_number":376,"context_line":"* Updates to nova.network.api.API.allocate_for_instance to fail if no network"},{"line_number":377,"context_line":"  info is allocated and NetworkRequest.network_id \u003d\u003d \u0027auto\u0027."},{"line_number":378,"context_line":"* Updates to nova.network.neutronv2.api.API.allocate_for_instance to"},{"line_number":379,"context_line":"  auto-allocate a network if none are specified and none are available for the"},{"line_number":380,"context_line":"  project."}],"source_content_type":"text/x-rst","patch_set":3,"id":"da0c15f0_c7a06aa2","line":377,"range":{"start_line":376,"start_character":2,"end_line":377,"end_character":60},"updated":"2016-03-26 02:11:29.000000000","message":"Hmm, need to think about this some more. It looks like if we raise a failure from here, it will result in a BuildAbortException which will attempt to deallocate networks, but I\u0027m not sure how nova-network managers are going to handle the \u0027auto\u0027 case in requested_networks.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"7d891df756ccf6234ecf169ffb092c8df553e585","unresolved":false,"context_lines":[{"line_number":373,"context_line":"* Updates to nova.network.neutronv2.api.API.validate_networks method for the"},{"line_number":374,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":375,"context_line":"  potentially caching the results of the validation with Neutron."},{"line_number":376,"context_line":"* Updates to nova.network.api.API.allocate_for_instance to fail if no network"},{"line_number":377,"context_line":"  info is allocated and NetworkRequest.network_id \u003d\u003d \u0027auto\u0027."},{"line_number":378,"context_line":"* Updates to nova.network.neutronv2.api.API.allocate_for_instance to"},{"line_number":379,"context_line":"  auto-allocate a network if none are specified and none are available for the"},{"line_number":380,"context_line":"  project."}],"source_content_type":"text/x-rst","patch_set":3,"id":"ba0121b8_87c35038","line":377,"range":{"start_line":376,"start_character":2,"end_line":377,"end_character":60},"in_reply_to":"da0c15f0_c7a06aa2","updated":"2016-04-01 20:47:16.000000000","message":"I think we\u0027ll just treat \u0027auto\u0027 like network_id\u003dNone in nova-network.","commit_id":"67e0073e4bba03ef7b30cfd552271c07bf5775ae"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"e9e074eaa6a247ac098b89428d693fc650e7caf2","unresolved":false,"context_lines":[{"line_number":17,"context_line":"feature parity for the server create flow between Neutron and the VlanManager"},{"line_number":18,"context_line":"in nova-network. There is still some deployer setup for networking in both"},{"line_number":19,"context_line":"cases, but after that the networking service handles automatically setting up"},{"line_number":20,"context_line":"the network topology for the project."},{"line_number":21,"context_line":""},{"line_number":22,"context_line":""},{"line_number":23,"context_line":"Problem description"}],"source_content_type":"text/x-rst","patch_set":4,"id":"ba0121b8_356ee796","line":20,"updated":"2016-04-01 23:33:53.000000000","message":"Thanks Matt and Armando -- that doc makes it especially clear how it works. There isn\u0027t as great of documentation of VlanManager in nova-net. Based on what I read on a blog [1], I have learned the cloud operator setup for each is as follows:\n\nNova-network VlanManager - Operator must \u0027nova-manage network create\u0027 a network for each tenant, providing the tenant ID and vlan. After this, bridges etc are created automatically per tenant when a request comes in.\n\nNeutron auto-allocated-topology - Operator must \u0027neutron net-create\u0027 a default external network and \u0027neutron subnetpool-create\u0027 at least one default subnet pool. After this, networks etc are created per tenant on-the-fly when a request comes in.\n\nMy point is I\u0027m trying to be very clear about how much parity there is. The features are similar but auto-allocated-topology seems significantly more automatic (from the operator perspective).\n\nThe parity point seems to be \"automatically allocate an IP on a tenant network to an instance.\" If that\u0027s the case, then I think I finally understand how these are equivalent.\n\n\n[1] https://www.mirantis.com/blog/openstack-networking-vlanmanager/","commit_id":"b64d22007f536cb4295b03d048aa81d6eaeaa2c2"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"deaaccbfe67a732229f18614e3cce125002c2581","unresolved":false,"context_lines":[{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 400 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_fe0de33e","line":123,"range":{"start_line":123,"start_character":66,"end_line":123,"end_character":69},"updated":"2016-04-26 15:39:19.000000000","message":"Should the 400 in the auto + neutron + api validation case be a 409 instead? The request was correct, but the system isn\u0027t configured to support auto-allocated-topology.","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ba7b695cca6fa5a4a41ce83b4ea7130bd9663018","unresolved":false,"context_lines":[{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 400 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_c22c69ae","line":123,"range":{"start_line":123,"start_character":66,"end_line":123,"end_character":69},"in_reply_to":"1a122d0e_fe0de33e","updated":"2016-04-27 20:04:32.000000000","message":"Yes, it\u0027s a valid request, but we can\u0027t handle it because things aren\u0027t setup, so 409.","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"5a2e614a0d5a0679656828e4aac3a52fa8488d3e","unresolved":false,"context_lines":[{"line_number":116,"context_line":"  network uuid) results in a 400 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 400 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 400 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_9bf5e1ee","line":125,"range":{"start_line":119,"start_character":0,"end_line":125,"end_character":34},"updated":"2016-04-26 14:54:38.000000000","message":"We might want to rethink the failure case here. The auto-allocated-topology extension in Neutron is optional, the operator doesn\u0027t need to enable it, or might take some time before enabling it after upgrading to this code. Currently if you don\u0027t specify a nic we automatically try to get one based on the available networks and if we can\u0027t find an available network you just don\u0027t get networking (the \u0027none\u0027 case). In the interest of backward compatibility, I\u0027m thinking we should fall back to that behavior if the user specified \u0027auto\u0027 but we can\u0027t auto-allocate a network, either because one isn\u0027t available or because the admin hasn\u0027t setup the auto-allocated-topology extension. Because python-novaclient will default to specify \u0027auto\u0027 if requesting this microversion and nothing is provided by the user (so the CLI transition is seamless for the novaclient user).","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"2214d19e268b4aa8ed975722467a547988979d8a","unresolved":false,"context_lines":[{"line_number":116,"context_line":"  network uuid) results in a 400 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 400 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 400 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_dec74296","line":125,"range":{"start_line":119,"start_character":0,"end_line":125,"end_character":34},"in_reply_to":"1a122d0e_9bf5e1ee","updated":"2016-04-26 18:25:28.000000000","message":"@Matt: the extension is not optional. It\u0027s gonna be there from Mitaka onwards whether an operator likes it or not.","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"d006d525e4fe15c833f598f50ef552c5a1218f78","unresolved":false,"context_lines":[{"line_number":116,"context_line":"  network uuid) results in a 400 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 400 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 400 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_3b012db0","line":125,"range":{"start_line":119,"start_character":0,"end_line":125,"end_character":34},"in_reply_to":"1a122d0e_9bf5e1ee","updated":"2016-04-26 14:58:25.000000000","message":"Or, given that we can fail in the Nova API during network validation with a specific error about auto not being available, maybe that\u0027s OK and in most cases your project would have a network available anyway, before we even check the auto-allocated-topology extension. This is a backward incompatible behavior change in the API though, which is what worries me.","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ba7b695cca6fa5a4a41ce83b4ea7130bd9663018","unresolved":false,"context_lines":[{"line_number":116,"context_line":"  network uuid) results in a 400 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 400 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 400 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_a2296d9d","line":125,"range":{"start_line":119,"start_character":0,"end_line":125,"end_character":34},"in_reply_to":"1a122d0e_dec74296","updated":"2016-04-27 20:04:32.000000000","message":"OK, the extension is not optional, but setting up the default network and subnet pool is, so we can\u0027t assume it\u0027s going to work (which is why we do the dry-run validation).\n\nAnyway, we agreed in this summit session:\n\nhttps://etherpad.openstack.org/p/newton-nova-neutron\n\nTo fail if the user requested \u0027auto\u0027 and we can\u0027t honor that request.","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":6062,"name":"jichenjc","email":"jichenjc@cn.ibm.com","username":"jichenjc"},"change_message_id":"d0f51cbb673f515c620e68b66e6d5672effa963f","unresolved":false,"context_lines":[{"line_number":242,"context_line":"  * JSON schema definition for the request body data if allowed"},{"line_number":243,"context_line":""},{"line_number":244,"context_line":"    * The server create API schema will be more restrictive with the network"},{"line_number":245,"context_line":"      uuid field which must not be one of \u0027none\u0027, \u0027auto\u0027 or a specific uuid."},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    ::"},{"line_number":248,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_83b7d338","line":245,"range":{"start_line":245,"start_character":28,"end_line":245,"end_character":31},"updated":"2016-04-29 18:37:24.000000000","message":"must be ?","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"dc564f9841c505f407c29b2d17499aa46f108e23","unresolved":false,"context_lines":[{"line_number":242,"context_line":"  * JSON schema definition for the request body data if allowed"},{"line_number":243,"context_line":""},{"line_number":244,"context_line":"    * The server create API schema will be more restrictive with the network"},{"line_number":245,"context_line":"      uuid field which must not be one of \u0027none\u0027, \u0027auto\u0027 or a specific uuid."},{"line_number":246,"context_line":""},{"line_number":247,"context_line":"    ::"},{"line_number":248,"context_line":""}],"source_content_type":"text/x-rst","patch_set":5,"id":"1a122d0e_6ee24503","line":245,"range":{"start_line":245,"start_character":28,"end_line":245,"end_character":31},"in_reply_to":"1a122d0e_83b7d338","updated":"2016-05-01 23:55:15.000000000","message":"Correct, good catch.","commit_id":"7dbd89cb44c13f558b2c8611f93ea584cdb94871"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"ffa8934623d7a8a054327fd1a9940865bbea2e4a","unresolved":false,"context_lines":[{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_4c548120","line":124,"range":{"start_line":124,"start_character":2,"end_line":124,"end_character":10},"updated":"2016-05-09 10:41:19.000000000","message":"Based on line 143, its neutron that returns 409 and Nova returns a 400 to its API user. Maybe we should be more precise here?","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_18085727","line":124,"range":{"start_line":124,"start_character":2,"end_line":124,"end_character":10},"in_reply_to":"dab17558_4c548120","updated":"2016-05-12 00:26:59.000000000","message":"Actually L143 is old, Nova also returns a 409 if auto-allocation isn\u0027t available. The request is valid, so it\u0027s not a 400, but the cloud isn\u0027t setup to support it, so we 409. This is what we decided at the summit when I brought this up.\n\nhttps://etherpad.openstack.org/p/newton-nova-neutron\n\nThis is the change:\n\nhttps://review.openstack.org/#/c/309574/\n\nAlso, keep in mind that the auto-allocated-topology stuff is only called iff there isn\u0027t a shared public network or private tenant network available, which should be the case in most clouds up to this point anyway since that\u0027s how auto network allocation from a nova standpoint has worked up until now.","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"ffa8934623d7a8a054327fd1a9940865bbea2e4a","unresolved":false,"context_lines":[{"line_number":137,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":138,"context_line":"network to use, then validate that:"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":141,"context_line":"* The ``auto-allocated-topology`` Neutron API passes with the *dry-run* option"},{"line_number":142,"context_line":"  which checks that there is a default public external network and default"},{"line_number":143,"context_line":"  subnet pool to use. If that setup is not ready, the API returns a 409 error"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_acbc0d6d","line":140,"range":{"start_line":140,"start_character":47,"end_line":140,"end_character":54},"updated":"2016-05-09 10:41:19.000000000","message":"Nit: maybe available? since it seems this in on my default now. So here we are only talking about if its a new enough neutron to have the extension.\n\nI assume if there is no extension, we also return a 400 to the user?","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":137,"context_line":"In the case of \u0027auto\u0027 and the Neutron API, if the project has no available"},{"line_number":138,"context_line":"network to use, then validate that:"},{"line_number":139,"context_line":""},{"line_number":140,"context_line":"* The ``auto-allocated-topology`` extension is enabled in the Neutron API."},{"line_number":141,"context_line":"* The ``auto-allocated-topology`` Neutron API passes with the *dry-run* option"},{"line_number":142,"context_line":"  which checks that there is a default public external network and default"},{"line_number":143,"context_line":"  subnet pool to use. If that setup is not ready, the API returns a 409 error"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_f86f53c1","line":140,"range":{"start_line":140,"start_character":47,"end_line":140,"end_character":54},"in_reply_to":"dab17558_acbc0d6d","updated":"2016-05-12 00:26:59.000000000","message":"Yes it\u0027s about it being available in a new enough neutron since they don\u0027t have microversions. It\u0027s not an optional extension though, so if the cloud has neutron mitaka it will be there.\n\nAs noted above, it\u0027s not a 400 from Nova though, it\u0027s a 409.\n\nI can change \u0027enabled\u0027 to \u0027available\u0027 though since that\u0027s more correct, since it\u0027s not optional.","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"ffa8934623d7a8a054327fd1a9940865bbea2e4a","unresolved":false,"context_lines":[{"line_number":141,"context_line":"* The ``auto-allocated-topology`` Neutron API passes with the *dry-run* option"},{"line_number":142,"context_line":"  which checks that there is a default public external network and default"},{"line_number":143,"context_line":"  subnet pool to use. If that setup is not ready, the API returns a 409 error"},{"line_number":144,"context_line":"  which Nova will raise back to the user as a 400 error."},{"line_number":145,"context_line":""},{"line_number":146,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":147,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_0024fdac","line":144,"updated":"2016-05-09 10:41:19.000000000","message":"Part of me wonders if this is actually a bad setup, and such should be a 5xx error, but I can see arguments either way.","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":141,"context_line":"* The ``auto-allocated-topology`` Neutron API passes with the *dry-run* option"},{"line_number":142,"context_line":"  which checks that there is a default public external network and default"},{"line_number":143,"context_line":"  subnet pool to use. If that setup is not ready, the API returns a 409 error"},{"line_number":144,"context_line":"  which Nova will raise back to the user as a 400 error."},{"line_number":145,"context_line":""},{"line_number":146,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"},{"line_number":147,"context_line":"not know if networking will be provided until we get to the compute node to"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_f8275360","line":144,"in_reply_to":"dab17558_0024fdac","updated":"2016-05-12 00:26:59.000000000","message":"I need to change this 400 to a 409. I think a 5xx is wrong since it\u0027s not really a server error.","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":363,"context_line":"in the case that \u0027auto\u0027 is specified and there are no available existing"},{"line_number":364,"context_line":"networks for the project:"},{"line_number":365,"context_line":""},{"line_number":366,"context_line":"1. That the ``auto-allocated-topology`` extension is enabled. The extensions"},{"line_number":367,"context_line":"   are already cached in nova.network.neutronv2.api.API so this should be"},{"line_number":368,"context_line":"   minimal overhead."},{"line_number":369,"context_line":"2. That the ``auto-allocated-topology`` API passes the *dry-run* validation"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_9819e724","line":366,"range":{"start_line":366,"start_character":53,"end_line":366,"end_character":60},"updated":"2016-05-12 00:26:59.000000000","message":"s/enabled/available/","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"ffa8934623d7a8a054327fd1a9940865bbea2e4a","unresolved":false,"context_lines":[{"line_number":367,"context_line":"   are already cached in nova.network.neutronv2.api.API so this should be"},{"line_number":368,"context_line":"   minimal overhead."},{"line_number":369,"context_line":"2. That the ``auto-allocated-topology`` API passes the *dry-run* validation"},{"line_number":370,"context_line":"   check."},{"line_number":371,"context_line":""},{"line_number":372,"context_line":""},{"line_number":373,"context_line":".. note:: Nova could offset the cost of doing this validation with Neutron by"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_c3079f7f","line":370,"updated":"2016-05-09 10:41:19.000000000","message":"Although thats only for the boot requests that happen before the auto generated network has been created for that tenant, I think?","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":367,"context_line":"   are already cached in nova.network.neutronv2.api.API so this should be"},{"line_number":368,"context_line":"   minimal overhead."},{"line_number":369,"context_line":"2. That the ``auto-allocated-topology`` API passes the *dry-run* validation"},{"line_number":370,"context_line":"   check."},{"line_number":371,"context_line":""},{"line_number":372,"context_line":""},{"line_number":373,"context_line":".. note:: Nova could offset the cost of doing this validation with Neutron by"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_18dcd744","line":370,"in_reply_to":"dab17558_c3079f7f","updated":"2016-05-12 00:26:59.000000000","message":"Yeah, we don\u0027t get that far on the second attempt for the same tenant since our \u0027normal\u0027 checks for available networks, which come before calling this dry-run API, will give us a network that was already allocated.","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":424,"context_line":"* Updates to nova.network.neutronv2.api.API.validate_networks method for the"},{"line_number":425,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":426,"context_line":"  potentially caching the results of the validation with Neutron."},{"line_number":427,"context_line":"* Updates to the compute manager to not call allocate_for_instance is"},{"line_number":428,"context_line":"  network_id is \u0027none\u0027."},{"line_number":429,"context_line":"* Updates to nova.network.api.API.allocate_for_instance to fail if no network"},{"line_number":430,"context_line":"  info is allocated and NetworkRequest.network_id \u003d\u003d \u0027auto\u0027."}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_38e55b08","line":427,"range":{"start_line":427,"start_character":67,"end_line":427,"end_character":69},"updated":"2016-05-12 00:26:59.000000000","message":"if","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"ffa8934623d7a8a054327fd1a9940865bbea2e4a","unresolved":false,"context_lines":[{"line_number":425,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":426,"context_line":"  potentially caching the results of the validation with Neutron."},{"line_number":427,"context_line":"* Updates to the compute manager to not call allocate_for_instance is"},{"line_number":428,"context_line":"  network_id is \u0027none\u0027."},{"line_number":429,"context_line":"* Updates to nova.network.api.API.allocate_for_instance to fail if no network"},{"line_number":430,"context_line":"  info is allocated and NetworkRequest.network_id \u003d\u003d \u0027auto\u0027."},{"line_number":431,"context_line":"* Updates to nova.network.neutronv2.api.API.allocate_for_instance to"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_433baf38","line":428,"updated":"2016-05-09 10:41:19.000000000","message":"Maybe just make allocate_for_instance a no op when it is called for this case?","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"e65ae3ba16404d7d6f6cb4bb2a0aca5d6bfb334e","unresolved":false,"context_lines":[{"line_number":425,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":426,"context_line":"  potentially caching the results of the validation with Neutron."},{"line_number":427,"context_line":"* Updates to the compute manager to not call allocate_for_instance is"},{"line_number":428,"context_line":"  network_id is \u0027none\u0027."},{"line_number":429,"context_line":"* Updates to nova.network.api.API.allocate_for_instance to fail if no network"},{"line_number":430,"context_line":"  info is allocated and NetworkRequest.network_id \u003d\u003d \u0027auto\u0027."},{"line_number":431,"context_line":"* Updates to nova.network.neutronv2.api.API.allocate_for_instance to"}],"source_content_type":"text/x-rst","patch_set":6,"id":"dab17558_58981f78","line":428,"in_reply_to":"dab17558_433baf38","updated":"2016-05-12 00:26:59.000000000","message":"This is what I have today:\n\nhttps://review.openstack.org/#/c/309638/5/nova/compute/manager.py\n\nI figured it was easier to do it in one place in the compute manager than in several places in the network API, because for nova-network we have to cast to the network manager which would then have to check this, and I think there are at least two allocate_for_instance implementations for nova-network depending on the network manager that you\u0027re using.","commit_id":"96e659e23bab824e2c8bbfd31fbc35ca16b3d07f"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"94f742009e1fa6bb30bb2080a4f6bf5e33b3f6a6","unresolved":false,"context_lines":[{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_9f04bf7e","line":125,"updated":"2016-05-13 20:43:00.000000000","message":"is it worth elaborate on how you intend to handle the case where there\u0027s multiple interfaces involved?","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"d8a7dd031f0b2551bfa96fe34dd4f396f10bd01c","unresolved":false,"context_lines":[{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_6dd4c3bc","line":125,"in_reply_to":"dab17558_4279cefb","updated":"2016-05-14 20:10:43.000000000","message":"Oh, I wasn\u0027t going to support it, since it wouldn\u0027t make sense as we\u0027d only create the one network. I figured the 2nd bullet in this list would cover that but it could be more explicit, so I\u0027ll add that.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"56400c07c369aa0c529f4b64dd09cfd3b27d9909","unresolved":false,"context_lines":[{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_4279cefb","line":125,"in_reply_to":"dab17558_6747c477","updated":"2016-05-14 16:23:31.000000000","message":"I meant when doing something like this:\n\nnova boot --flavor foo --image foo --nic net-id\u003dauto --nic net-id\u003dauto","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_6747c477","line":125,"in_reply_to":"dab17558_9f04bf7e","updated":"2016-05-14 14:32:42.000000000","message":"I\u0027m not sure what you mean by multiple interfaces. Do you mean booting a server with net_id\u003d\u0027auto\u0027 and port_id\u003d\u0027foo\u0027? Or with attaching a port to the instance after it\u0027s booted?","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"94f742009e1fa6bb30bb2080a4f6bf5e33b3f6a6","unresolved":false,"context_lines":[{"line_number":143,"context_line":"  the extension will be available and enabled."},{"line_number":144,"context_line":"* The ``auto-allocated-topology`` Neutron API passes with the *dry-run* option"},{"line_number":145,"context_line":"  which checks that there is a default public external network and default"},{"line_number":146,"context_line":"  subnet pool to use. If that setup is not ready, the API returns a 409 error"},{"line_number":147,"context_line":"  which Nova will raise back to the user as a 409 error."},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_df83e7ca","line":146,"updated":"2016-05-13 20:43:00.000000000","message":"I\u0027d be more generic here and omit the specific prep steps (internals of dry-run API call) required for dry-run to pass like you did above by referring to the deployer impact down below. But at the time of writing what you say is accurate. In the future we may want to expand on the ability for Neutron to provision topologies differently which means the prep steps involved may change from one model to another and thus the dry-run actual implementation may differ.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":143,"context_line":"  the extension will be available and enabled."},{"line_number":144,"context_line":"* The ``auto-allocated-topology`` Neutron API passes with the *dry-run* option"},{"line_number":145,"context_line":"  which checks that there is a default public external network and default"},{"line_number":146,"context_line":"  subnet pool to use. If that setup is not ready, the API returns a 409 error"},{"line_number":147,"context_line":"  which Nova will raise back to the user as a 409 error."},{"line_number":148,"context_line":""},{"line_number":149,"context_line":"In the case of \u0027auto\u0027 and nova-network, the validation is a no-op since we will"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_27349cf9","line":146,"in_reply_to":"dab17558_df83e7ca","updated":"2016-05-14 14:32:42.000000000","message":"Given what\u0027s available today, I\u0027d prefer to just leave this specific to how it\u0027s meant to work with the APIs that we have. If Nova is going to need to support new behaviors for this in the future that would be a separate blueprint.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"94f742009e1fa6bb30bb2080a4f6bf5e33b3f6a6","unresolved":false,"context_lines":[{"line_number":183,"context_line":"extension is enabled."},{"line_number":184,"context_line":""},{"line_number":185,"context_line":".. note:: There will be a potential for races on the compute node when"},{"line_number":186,"context_line":"          auto-allocating the network in Neutron. This is a one-time operation"},{"line_number":187,"context_line":"          per project so the first server create for a project that requests"},{"line_number":188,"context_line":"          auto-allocation will create the network. If concurrent requests"},{"line_number":189,"context_line":"          for the same project are made, Neutron has a rollback mechanism in"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_3f8f93cd","line":186,"updated":"2016-05-13 20:43:00.000000000","message":"especially when booting multiple instances with a single boot command.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":183,"context_line":"extension is enabled."},{"line_number":184,"context_line":""},{"line_number":185,"context_line":".. note:: There will be a potential for races on the compute node when"},{"line_number":186,"context_line":"          auto-allocating the network in Neutron. This is a one-time operation"},{"line_number":187,"context_line":"          per project so the first server create for a project that requests"},{"line_number":188,"context_line":"          auto-allocation will create the network. If concurrent requests"},{"line_number":189,"context_line":"          for the same project are made, Neutron has a rollback mechanism in"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_271bfc81","line":186,"in_reply_to":"dab17558_3f8f93cd","updated":"2016-05-14 14:32:42.000000000","message":"I can add those words. Note that we are looking to move some of this out of the compute and into conductor, John is working on a spec for that here:\n\nhttps://review.openstack.org/#/c/313001/\n\nThat should help address some of the issues with races and the cost of failing and rescheduling once we hit a compute.\n\nI won\u0027t know the real impact of booting multiple instances with auto-allocation at the same time until I get the REST API changes done and run some Tempest tests.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"94f742009e1fa6bb30bb2080a4f6bf5e33b3f6a6","unresolved":false,"context_lines":[{"line_number":190,"context_line":"          place based on a unique constraint for the project_id in the"},{"line_number":191,"context_line":"          ``auto_allocated_topologies`` table. So a second concurrent request"},{"line_number":192,"context_line":"          should fail and be rolled back, but the API will return the network"},{"line_number":193,"context_line":"          that was already created for that project."},{"line_number":194,"context_line":""},{"line_number":195,"context_line":"Alternatives"},{"line_number":196,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_5f4ff7bc","line":193,"updated":"2016-05-13 20:43:00.000000000","message":"In other words, the provisioning call is idempotent and in case of concurrent requests the first one committing the request wins. Nova is not required to implemtn any retry mechanism","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":190,"context_line":"          place based on a unique constraint for the project_id in the"},{"line_number":191,"context_line":"          ``auto_allocated_topologies`` table. So a second concurrent request"},{"line_number":192,"context_line":"          should fail and be rolled back, but the API will return the network"},{"line_number":193,"context_line":"          that was already created for that project."},{"line_number":194,"context_line":""},{"line_number":195,"context_line":"Alternatives"},{"line_number":196,"context_line":"------------"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_c725d0c2","line":193,"in_reply_to":"dab17558_5f4ff7bc","updated":"2016-05-14 14:32:42.000000000","message":"I can add those words for clarity.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"94f742009e1fa6bb30bb2080a4f6bf5e33b3f6a6","unresolved":false,"context_lines":[{"line_number":396,"context_line":"* Ensure the public external network is the default external network."},{"line_number":397,"context_line":"* The deployment must contain a default subnet pool: one ipv4 pool, or one ipv6"},{"line_number":398,"context_line":"  pool, or one of each. The ``subnet_allocation`` extension is required for"},{"line_number":399,"context_line":"  this."},{"line_number":400,"context_line":""},{"line_number":401,"context_line":"There is a devstack change to enable this also which can be used as a"},{"line_number":402,"context_line":"reference. [3]_"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_1a429d3e","line":399,"updated":"2016-05-13 20:43:00.000000000","message":"I\u0027d refer to [1] for further details.\n\nhttp://docs.openstack.org/mitaka/networking-guide/intro-os-networking-features.html","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":396,"context_line":"* Ensure the public external network is the default external network."},{"line_number":397,"context_line":"* The deployment must contain a default subnet pool: one ipv4 pool, or one ipv6"},{"line_number":398,"context_line":"  pool, or one of each. The ``subnet_allocation`` extension is required for"},{"line_number":399,"context_line":"  this."},{"line_number":400,"context_line":""},{"line_number":401,"context_line":"There is a devstack change to enable this also which can be used as a"},{"line_number":402,"context_line":"reference. [3]_"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_2202ca09","line":399,"in_reply_to":"dab17558_1a429d3e","updated":"2016-05-14 14:32:42.000000000","message":"Good idea, I\u0027ll add that.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"94f742009e1fa6bb30bb2080a4f6bf5e33b3f6a6","unresolved":false,"context_lines":[{"line_number":446,"context_line":"  to the Nova REST API."},{"line_number":447,"context_line":"* Unit tests for all changes."},{"line_number":448,"context_line":"* Functional tests for the REST API microversion changes."},{"line_number":449,"context_line":"* Tempest tests for the full end-to-end scenario with Nova / Neutron."},{"line_number":450,"context_line":""},{"line_number":451,"context_line":"The Nova changes will be made in the following order so we can test the HEAD of"},{"line_number":452,"context_line":"the branch with the Tempest changes:"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_5a6385dc","line":449,"updated":"2016-05-13 20:43:00.000000000","message":"we have an API test in the neutron tree already which we can use as starting point for this.\n\nhttps://review.openstack.org/#/c/277683/","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":446,"context_line":"  to the Nova REST API."},{"line_number":447,"context_line":"* Unit tests for all changes."},{"line_number":448,"context_line":"* Functional tests for the REST API microversion changes."},{"line_number":449,"context_line":"* Tempest tests for the full end-to-end scenario with Nova / Neutron."},{"line_number":450,"context_line":""},{"line_number":451,"context_line":"The Nova changes will be made in the following order so we can test the HEAD of"},{"line_number":452,"context_line":"the branch with the Tempest changes:"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_021ea662","line":449,"in_reply_to":"dab17558_5a6385dc","updated":"2016-05-14 14:32:42.000000000","message":"Yup, I\u0027ll probably use that to do the setup in the Tempest scenario so the validation passes when we do the boot request to Nova.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":504,"context_line":"    extension is enabled in Neutron. It also requires the default public"},{"line_number":505,"context_line":"    network and subnet pool setup so this will require a feature toggle in"},{"line_number":506,"context_line":"    Tempest (devstack enables this already so it will work in the gate jobs)."},{"line_number":507,"context_line":"    Should also test that a second boot with the same project using \u0027auto\u0027"},{"line_number":508,"context_line":"    doesn\u0027t auto-allocate a new unique network, it should re-use the same one"},{"line_number":509,"context_line":"    from the first request. We could also test booting multiple instances"},{"line_number":510,"context_line":"    from the same project using \u0027auto\u0027 and make sure it\u0027s atomic."},{"line_number":511,"context_line":""},{"line_number":512,"context_line":""},{"line_number":513,"context_line":""}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_22292a8a","line":510,"range":{"start_line":507,"start_character":4,"end_line":510,"end_character":65},"updated":"2016-05-14 14:32:42.000000000","message":"These are two additional tests so make them sub-items in this list.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"188fbd16151945c036de037ad6e8c1bd2dfbd96f","unresolved":false,"context_lines":[{"line_number":516,"context_line":""},{"line_number":517,"context_line":"* API: http://developer.openstack.org/api-ref-compute-v2.1.html#createServer"},{"line_number":518,"context_line":"* CLI: http://docs.openstack.org/cli-reference/nova.html#nova-boot"},{"line_number":519,"context_line":"* The `Networking Guide`_ should be updated as part of the Neutron work [1]_."},{"line_number":520,"context_line":""},{"line_number":521,"context_line":"References"},{"line_number":522,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_7a292989","line":519,"updated":"2016-05-13 20:40:27.000000000","message":"It is already updated.\n\nhttp://docs.openstack.org/networking-guide/intro-os-networking-features.html","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":516,"context_line":""},{"line_number":517,"context_line":"* API: http://developer.openstack.org/api-ref-compute-v2.1.html#createServer"},{"line_number":518,"context_line":"* CLI: http://docs.openstack.org/cli-reference/nova.html#nova-boot"},{"line_number":519,"context_line":"* The `Networking Guide`_ should be updated as part of the Neutron work [1]_."},{"line_number":520,"context_line":""},{"line_number":521,"context_line":"References"},{"line_number":522,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_a2351adc","line":519,"in_reply_to":"dab17558_7a292989","updated":"2016-05-14 14:32:42.000000000","message":"Cool, as Armando noted above, I\u0027ll reference this for deployer impact and remove it from doc impact.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6524,"name":"Henry Gessau","email":"HenryG@gessau.net","username":"gessau"},"change_message_id":"188fbd16151945c036de037ad6e8c1bd2dfbd96f","unresolved":false,"context_lines":[{"line_number":528,"context_line":""},{"line_number":529,"context_line":".. _microversion thread in the openstack-dev ML: http://lists.openstack.org/pipermail/openstack-dev/2016-February/086437.html"},{"line_number":530,"context_line":".. _operator feedback thread: http://lists.openstack.org/pipermail/openstack-operators/2016-February/009637.html"},{"line_number":531,"context_line":".. _Networking Guide: http://docs.openstack.org/liberty/networking-guide/"},{"line_number":532,"context_line":""},{"line_number":533,"context_line":""},{"line_number":534,"context_line":"History"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_5f07f71b","line":531,"range":{"start_line":531,"start_character":48,"end_line":531,"end_character":55},"updated":"2016-05-13 20:40:27.000000000","message":"Nit: Remove \u0027liberty/\u0027 from this link to get to the most recent version of the guide.","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"6741d4fc70823e951c9f2d6705e5ed8987609cfe","unresolved":false,"context_lines":[{"line_number":528,"context_line":""},{"line_number":529,"context_line":".. _microversion thread in the openstack-dev ML: http://lists.openstack.org/pipermail/openstack-dev/2016-February/086437.html"},{"line_number":530,"context_line":".. _operator feedback thread: http://lists.openstack.org/pipermail/openstack-operators/2016-February/009637.html"},{"line_number":531,"context_line":".. _Networking Guide: http://docs.openstack.org/liberty/networking-guide/"},{"line_number":532,"context_line":""},{"line_number":533,"context_line":""},{"line_number":534,"context_line":"History"}],"source_content_type":"text/x-rst","patch_set":8,"id":"dab17558_e22f2286","line":531,"range":{"start_line":531,"start_character":48,"end_line":531,"end_character":55},"in_reply_to":"dab17558_5f07f71b","updated":"2016-05-14 14:32:42.000000000","message":"Done","commit_id":"a473fd26348ab55f8847c11d3fdf837da4420afe"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"7b61a588bb211fd4cf5f41f682d5671cda39081a","unresolved":false,"context_lines":[{"line_number":431,"context_line":"* REST API changes in Nova for the microversion and auto/none/uuid logic."},{"line_number":432,"context_line":"* Updates in the compute API to not call network_api.validate_networks if"},{"line_number":433,"context_line":"  NetworkRequest.network_id \u003d\u003d \u0027none\u0027."},{"line_number":434,"context_line":"* Updates in the compute API such that we don\u0027t check the create:attach_network"},{"line_number":435,"context_line":"  policy if network_id is \u0027none\u0027 since we don\u0027t care about the user\u0027s ability"},{"line_number":436,"context_line":"  to attach a network if we\u0027re not going to do it anyway."},{"line_number":437,"context_line":"* Updates to nova.network.neutronv2.api.API.validate_networks method for the"},{"line_number":438,"context_line":"  \u0027auto\u0027 case when no networks are requested and none are available. Also"},{"line_number":439,"context_line":"  potentially caching the results of the validation with Neutron."}],"source_content_type":"text/x-rst","patch_set":9,"id":"dab17558_6212120b","line":436,"range":{"start_line":434,"start_character":2,"end_line":436,"end_character":57},"updated":"2016-05-14 15:02:17.000000000","message":"This is a v2.0 only policy check which doesn\u0027t apply here, so needs to be removed.","commit_id":"88c067d3e9b102040c517cb88dbdfa3a2c30bb64"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"b7b240e5307171ad463c71210f8acbafaf51331c","unresolved":false,"context_lines":[{"line_number":285,"context_line":"                        }"},{"line_number":286,"context_line":"                    }"},{"line_number":287,"context_line":"                },"},{"line_number":288,"context_line":"                \u0027required\u0027: [\u0027name\u0027, \u0027flavorRef\u0027],"},{"line_number":289,"context_line":"                \u0027additionalProperties\u0027: False,"},{"line_number":290,"context_line":"            },"},{"line_number":291,"context_line":"        },"}],"source_content_type":"text/x-rst","patch_set":10,"id":"dab17558_cd6def33","line":288,"range":{"start_line":288,"start_character":16,"end_line":288,"end_character":50},"updated":"2016-05-14 19:57:36.000000000","message":"\u0027networks\u0027 should be in here also since with this microversion you need to specify something for networking. python-novaclient will default to specifying:\n\n  networks\u003d[{\u0027uuid\u0027: \u0027auto\u0027}]\n\nIf nothing is specified on the CLI.","commit_id":"63dd5b3fa58ba2dff047a64bfc6553e3cb8e953a"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"a2a3ea67dd2122c6502deb1ab393b3db8444b000","unresolved":false,"context_lines":[{"line_number":274,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":275,"context_line":"                                              {\u0027type\u0027: \u0027null\u0027}]"},{"line_number":276,"context_line":"                                },"},{"line_number":277,"context_line":"                                \u0027uuid\u0027: {"},{"line_number":278,"context_line":"                                    \u0027oneOf\u0027: [{\u0027type\u0027: \u0027string\u0027,"},{"line_number":279,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":280,"context_line":"                                              {\u0027type\u0027: \u0027string\u0027,"}],"source_content_type":"text/x-rst","patch_set":12,"id":"dab17558_8db64788","line":277,"range":{"start_line":277,"start_character":33,"end_line":277,"end_character":37},"updated":"2016-05-14 20:33:27.000000000","message":"I\u0027m not sure if this also needs:\n\n  {\u0027type\u0027: \u0027null\u0027}\n\nLike with port, meaning you don\u0027t need to specify a uuid. But parameter_types.ip_address doesn\u0027t have {\u0027type\u0027: \u0027null\u0027} and you can get by with not requesting a fixed IP address, so it seems fine to omit it.","commit_id":"b84bf73980b40a22701b4b51f6f4110db1f01fe0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"ad1f36c85f8e211c75fe3d129480e29636ecb256","unresolved":false,"context_lines":[{"line_number":274,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":275,"context_line":"                                              {\u0027type\u0027: \u0027null\u0027}]"},{"line_number":276,"context_line":"                                },"},{"line_number":277,"context_line":"                                \u0027uuid\u0027: {"},{"line_number":278,"context_line":"                                    \u0027oneOf\u0027: [{\u0027type\u0027: \u0027string\u0027,"},{"line_number":279,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":280,"context_line":"                                              {\u0027type\u0027: \u0027string\u0027,"}],"source_content_type":"text/x-rst","patch_set":12,"id":"dab17558_cd77afd2","line":277,"range":{"start_line":277,"start_character":33,"end_line":277,"end_character":37},"in_reply_to":"dab17558_8db64788","updated":"2016-05-14 20:43:19.000000000","message":"Oh I suppose you do because oneOf makes it a choice and null needs to be one of the choices.","commit_id":"b84bf73980b40a22701b4b51f6f4110db1f01fe0"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"bc34f3e7bf44ebc39415e7a89a9d2d24e5791fa1","unresolved":false,"context_lines":[{"line_number":57,"context_line":"#. Request a specific network (or duplicate networks as of Juno [2]_)."},{"line_number":58,"context_line":"#. Request a specific fixed IP and network (Nova will create a port in that"},{"line_number":59,"context_line":"   network and use the fixed IP address)."},{"line_number":60,"context_line":"#. Not providing anything on the create request."},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"You cannot request a fixed IP and a port together because the port already has"},{"line_number":63,"context_line":"a fixed IP associated with it. When requesting a specific port, the network"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_e6aa8d18","line":60,"updated":"2016-05-15 14:42:26.000000000","message":"I\u0027m not actually sure about this one, it looks like nova requires a network uuid to be provided if you don\u0027t specify a port:\n\nhttps://github.com/openstack/nova/blob/master/nova/api/openstack/compute/servers.py#L476\n\nI don\u0027t see python-novaclient passing anything by default though for the network ID so I\u0027m not sure how this is working, and the neutron v2 API in nova handles not getting a network ID.","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1b8acae991c55100e8e2ecd3763619f0f89f944e","unresolved":false,"context_lines":[{"line_number":57,"context_line":"#. Request a specific network (or duplicate networks as of Juno [2]_)."},{"line_number":58,"context_line":"#. Request a specific fixed IP and network (Nova will create a port in that"},{"line_number":59,"context_line":"   network and use the fixed IP address)."},{"line_number":60,"context_line":"#. Not providing anything on the create request."},{"line_number":61,"context_line":""},{"line_number":62,"context_line":"You cannot request a fixed IP and a port together because the port already has"},{"line_number":63,"context_line":"a fixed IP associated with it. When requesting a specific port, the network"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_816d6b9b","line":60,"in_reply_to":"dab17558_e6aa8d18","updated":"2016-05-15 16:03:58.000000000","message":"Duh, I was staring at this too long, if nothing is requested then there is nothing in the for loop to process.","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"7e38b5015655c890f38061d73221147da5c3157d","unresolved":false,"context_lines":[{"line_number":113,"context_line":""},{"line_number":114,"context_line":"* If nothing is specified on the request for networks, a 400 will be returned."},{"line_number":115,"context_line":"* Specifying \u0027auto\u0027 with any other network values (ports, \u0027none\u0027, \u0027auto\u0027 or a"},{"line_number":116,"context_line":"  specific network uuid) results in a 400 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 400 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_1c072a82","line":116,"range":{"start_line":116,"start_character":38,"end_line":116,"end_character":41},"updated":"2016-05-15 01:50:00.000000000","message":"Should this be a 409?","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"7e38b5015655c890f38061d73221147da5c3157d","unresolved":false,"context_lines":[{"line_number":115,"context_line":"* Specifying \u0027auto\u0027 with any other network values (ports, \u0027none\u0027, \u0027auto\u0027 or a"},{"line_number":116,"context_line":"  specific network uuid) results in a 400 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 400 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_7cfe366c","line":118,"range":{"start_line":118,"start_character":29,"end_line":118,"end_character":32},"updated":"2016-05-15 01:50:00.000000000","message":"409?","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"77c91935270769421b5184e011b0dcfacc275015","unresolved":false,"context_lines":[{"line_number":276,"context_line":"                                },"},{"line_number":277,"context_line":"                                \u0027uuid\u0027: {"},{"line_number":278,"context_line":"                                    \u0027oneOf\u0027: [{\u0027type\u0027: \u0027string\u0027,"},{"line_number":279,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":280,"context_line":"                                              {\u0027type\u0027: \u0027string\u0027,"},{"line_number":281,"context_line":"                                               \u0027enum\u0027: [\u0027none\u0027, \u0027auto\u0027]},"},{"line_number":282,"context_line":"                                              {\u0027type\u0027: \u0027null\u0027}]"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_a8f4d9ce","line":279,"range":{"start_line":279,"start_character":58,"end_line":279,"end_character":62},"updated":"2016-05-14 21:42:15.000000000","message":"Blarg, we might not be able to enforce uuid here because of:\n\nhttps://review.openstack.org/#/c/9381/\n\nSo you can specify something like br-00000000-0000-0000-0000-000000000000 today and we\u0027ll strip it and allow it. Changing this to format: uuid would be a breaking API change in that case.\n\nThis was the original bug:\n\nhttps://bugs.launchpad.net/nova/+bug/1021370\n\nThat\u0027s pretty old, does Neutron still allow a network with an id that is prefixed with \u0027br-\u0027?","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3834d93fcbd3e4301ef6cbde0ee8ffbd7804bbcd","unresolved":false,"context_lines":[{"line_number":276,"context_line":"                                },"},{"line_number":277,"context_line":"                                \u0027uuid\u0027: {"},{"line_number":278,"context_line":"                                    \u0027oneOf\u0027: [{\u0027type\u0027: \u0027string\u0027,"},{"line_number":279,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":280,"context_line":"                                              {\u0027type\u0027: \u0027string\u0027,"},{"line_number":281,"context_line":"                                               \u0027enum\u0027: [\u0027none\u0027, \u0027auto\u0027]},"},{"line_number":282,"context_line":"                                              {\u0027type\u0027: \u0027null\u0027}]"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_df03990e","line":279,"range":{"start_line":279,"start_character":58,"end_line":279,"end_character":62},"in_reply_to":"dab17558_01ecdb27","updated":"2016-05-16 19:51:02.000000000","message":"Yeah, as was sorted out in the dev list:\n\nhttp://lists.openstack.org/pipermail/openstack-dev/2016-May/095051.html\n\nWe\u0027ll drop support for that in this microversion.","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":748,"name":"Armando Migliaccio","email":"armamig@gmail.com","username":"armando-migliaccio"},"change_message_id":"11f4207e0a2bc4e4bcf0313aec2fd837d2007e7d","unresolved":false,"context_lines":[{"line_number":276,"context_line":"                                },"},{"line_number":277,"context_line":"                                \u0027uuid\u0027: {"},{"line_number":278,"context_line":"                                    \u0027oneOf\u0027: [{\u0027type\u0027: \u0027string\u0027,"},{"line_number":279,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":280,"context_line":"                                              {\u0027type\u0027: \u0027string\u0027,"},{"line_number":281,"context_line":"                                               \u0027enum\u0027: [\u0027none\u0027, \u0027auto\u0027]},"},{"line_number":282,"context_line":"                                              {\u0027type\u0027: \u0027null\u0027}]"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_01ecdb27","line":279,"range":{"start_line":279,"start_character":58,"end_line":279,"end_character":62},"in_reply_to":"dab17558_a8f4d9ce","updated":"2016-05-15 15:38:49.000000000","message":"I was actually never aware of that, it seems a corner case to support one specific implementation of one specific plugin","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"1b6e74749d68c5127e8047ea16473fca5950adbf","unresolved":false,"context_lines":[{"line_number":276,"context_line":"                                },"},{"line_number":277,"context_line":"                                \u0027uuid\u0027: {"},{"line_number":278,"context_line":"                                    \u0027oneOf\u0027: [{\u0027type\u0027: \u0027string\u0027,"},{"line_number":279,"context_line":"                                               \u0027format\u0027: \u0027uuid\u0027},"},{"line_number":280,"context_line":"                                              {\u0027type\u0027: \u0027string\u0027,"},{"line_number":281,"context_line":"                                               \u0027enum\u0027: [\u0027none\u0027, \u0027auto\u0027]},"},{"line_number":282,"context_line":"                                              {\u0027type\u0027: \u0027null\u0027}]"}],"source_content_type":"text/x-rst","patch_set":13,"id":"dab17558_c8ce7d82","line":279,"range":{"start_line":279,"start_character":58,"end_line":279,"end_character":62},"in_reply_to":"dab17558_a8f4d9ce","updated":"2016-05-14 21:48:53.000000000","message":"Looks like that couldn\u0027t be the case now:\n\nhttps://github.com/openstack/neutron/blob/6bdbff27a8327e8fc5a9897046af3aeecbbb28d2/neutron/db/model_base.py#L33","commit_id":"c942fb6d04ee3e18be845c9ce11b2f612d37cd83"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"d79006c6c2ef4a5ce949166885ddb345f60a9942","unresolved":false,"context_lines":[{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":14,"id":"dab17558_57dabb78","line":125,"range":{"start_line":124,"start_character":12,"end_line":125,"end_character":34},"updated":"2016-05-17 16:34:13.000000000","message":"I was originally thinking we\u0027d set the instance to ERROR because of you can\u0027t auto-allocate the network via neuron then something is busted and it\u0027s not going to work for any compute. But that\u0027s an edge case given we validate with the dry-run call to Neutron from nova-api before casting to the scheduler to pick a node to build the instance.\n\nHowever, as I was reviewing John\u0027s spec about refactoring allocate_for_instance:\n\nhttps://review.openstack.org/#/c/313001/2/specs/newton/approved/prep-for-network-aware-scheduling.rst@72\n\nI realized that we have a problem with landing on a mitaka compute that is running the neutronv2.api code that doesn\u0027t have the allocate_for_instance changes for get me a network. So in that case, if no network is available, the instance wouldn\u0027t get networking (like the none case in this spec).\n\nI can think of two not so great solutions:\n\n1. From the nova-api we check the compute service versions and if they aren\u0027t at the newton version yet that has this code, then we fail if auto is requested. That sucks for the user.\n\n2. We add a scheduler filter that checks compute node capabilities, or uses flavor extra specs in the existing ComputeCapabilitiesFilter, but that would also suck because it would require extra specs. A new scheduler filter for just get me a network could filter out hosts that don\u0027t support auto-allocated-topology when \u0027auto\u0027 is in the request spec. Then you wouldn\u0027t need that scheduler filter after you\u0027ve fully upgraded your computes to Newton.","commit_id":"7a7740bcc2afc5acde01c5d0b5c408ca1204c009"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"266706b19ce85cb5e86bbc9ad41ebb2f139a34c0","unresolved":false,"context_lines":[{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":14,"id":"dab17558_d7306ba0","line":125,"range":{"start_line":124,"start_character":12,"end_line":125,"end_character":34},"in_reply_to":"dab17558_57dabb78","updated":"2016-05-17 16:37:24.000000000","message":"I think we should do #1, basically no auto creating of networks until all compute nodes are upgraded.\n\nWe can still auto use existing networks as before, so I think this is fine. Basically, you can\u0027t use the new feature until your upgrade is complete.","commit_id":"7a7740bcc2afc5acde01c5d0b5c408ca1204c009"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"554ffa4f3d0240dd7db9e5b6a02d4fe7f7a6f212","unresolved":false,"context_lines":[{"line_number":121,"context_line":"  node)."},{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":""},{"line_number":127,"context_line":"Compute API changes"},{"line_number":128,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":14,"id":"dab17558_68a0ba90","line":125,"range":{"start_line":124,"start_character":12,"end_line":125,"end_character":34},"in_reply_to":"dab17558_d7306ba0","updated":"2016-05-17 17:46:56.000000000","message":"Yep, #1 is the best we can do at this point, other than saying this doesn\u0027t work until Ocata.\n\nNote that you don\u0027t have to do the check past newton. So, land the thing that checks the service version to make newton work and then you can remove it in ocata when the ambiguity is gone.","commit_id":"7a7740bcc2afc5acde01c5d0b5c408ca1204c009"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"3a528f7c62cbc9a2b4abb161d466aa2434b28739","unresolved":false,"context_lines":[{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":"* Another failure scenario would be that Neutron is new enough and is setup"},{"line_number":127,"context_line":"  to support auto-allocated-topology, but the deployment still has compute"},{"line_number":128,"context_line":"  nodes that are not running the allocation code for creating the network"},{"line_number":129,"context_line":"  resources automatically. Because of this, we will have to restrict the"},{"line_number":130,"context_line":"  ability to use the new microversion with \u0027auto\u0027 or \u0027none\u0027 values for network"},{"line_number":131,"context_line":"  uuid to when all of the compute services are running the version that adds"},{"line_number":132,"context_line":"  that support. If \u0027auto\u0027 or \u0027none\u0027 is requested but the minimum compute"},{"line_number":133,"context_line":"  service version is not high enough, the request will fail in the API. Once"},{"line_number":134,"context_line":"  all of the computes are upgraded to a Newton version that supports"},{"line_number":135,"context_line":"  auto-allocation from the compute node, then the request will be honored."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"Compute API changes"},{"line_number":138,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"bab6814e_1b012eaf","line":135,"range":{"start_line":126,"start_character":2,"end_line":135,"end_character":74},"updated":"2016-05-18 20:39:56.000000000","message":"Here is a problem with this: we said that with this microversion we require a network uuid, either auto/none/specific network id. The API won\u0027t default to auto, but the CLI will if nothing is specifically requested.\n\nSo when someone gets this microversion change in novaclient and the server supports the microversion, the CLI by default is going to start requesting it with \u0027auto\u0027. Now if the deployment has any mitaka computes, it\u0027s going to fail.\n\nThe client then has to:\n\n1. Request a specific network ID.\n\n2. Request a specific microversion \u003c than this one, at least until they know the server can accommodate it.\n\nNeither of those options are great, and it makes me wonder if we need to hold off on the API changes for this until Ocata.","commit_id":"e4723e55efebcbd3b518ebe869a1ba6b8fa46149"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"73e833e2db063b9d56686534f4fe2c245679bed0","unresolved":false,"context_lines":[{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":"* Another failure scenario would be that Neutron is new enough and is setup"},{"line_number":127,"context_line":"  to support auto-allocated-topology, but the deployment still has compute"},{"line_number":128,"context_line":"  nodes that are not running the allocation code for creating the network"},{"line_number":129,"context_line":"  resources automatically. Because of this, we will have to restrict the"},{"line_number":130,"context_line":"  ability to use the new microversion with \u0027auto\u0027 or \u0027none\u0027 values for network"},{"line_number":131,"context_line":"  uuid to when all of the compute services are running the version that adds"},{"line_number":132,"context_line":"  that support. If \u0027auto\u0027 or \u0027none\u0027 is requested but the minimum compute"},{"line_number":133,"context_line":"  service version is not high enough, the request will fail in the API. Once"},{"line_number":134,"context_line":"  all of the computes are upgraded to a Newton version that supports"},{"line_number":135,"context_line":"  auto-allocation from the compute node, then the request will be honored."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"Compute API changes"},{"line_number":138,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"bab6814e_9b9ebe54","line":135,"range":{"start_line":126,"start_character":2,"end_line":135,"end_character":74},"in_reply_to":"bab6814e_1b012eaf","updated":"2016-05-18 20:44:46.000000000","message":"Here is another solution. If the minimum compute service version isn\u0027t Newton, then we change \u0027auto\u0027 to None in the NetworkRequest.network_id object which gets passed to the computes and they handle it as they do today - which would also work for Mitaka computes.","commit_id":"e4723e55efebcbd3b518ebe869a1ba6b8fa46149"},{"author":{"_account_id":6873,"name":"Matt Riedemann","email":"mriedem.os@gmail.com","username":"mriedem"},"change_message_id":"eec5468e5b221904237488494028470484996b2b","unresolved":false,"context_lines":[{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":"* Another failure scenario would be that Neutron is new enough and is setup"},{"line_number":127,"context_line":"  to support auto-allocated-topology, but the deployment still has compute"},{"line_number":128,"context_line":"  nodes that are not running the allocation code for creating the network"},{"line_number":129,"context_line":"  resources automatically. Because of this, we will have to restrict the"},{"line_number":130,"context_line":"  ability to use the new microversion with \u0027auto\u0027 or \u0027none\u0027 values for network"},{"line_number":131,"context_line":"  uuid to when all of the compute services are running the version that adds"},{"line_number":132,"context_line":"  that support. If \u0027auto\u0027 or \u0027none\u0027 is requested but the minimum compute"},{"line_number":133,"context_line":"  service version is not high enough, the request will fail in the API. Once"},{"line_number":134,"context_line":"  all of the computes are upgraded to a Newton version that supports"},{"line_number":135,"context_line":"  auto-allocation from the compute node, then the request will be honored."},{"line_number":136,"context_line":""},{"line_number":137,"context_line":"Compute API changes"},{"line_number":138,"context_line":"-------------------"}],"source_content_type":"text/x-rst","patch_set":15,"id":"bab6814e_fe6898bc","line":135,"range":{"start_line":126,"start_character":2,"end_line":135,"end_character":74},"in_reply_to":"bab6814e_9b9ebe54","updated":"2016-05-18 21:00:21.000000000","message":"Dan Smith and I talked about just changing \u0027auto\u0027 to None when the computes are up to date, we\u0027re going to go with that solution.","commit_id":"e4723e55efebcbd3b518ebe869a1ba6b8fa46149"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"dabea0d5e6948a63662f2a1415677be1def464e5","unresolved":false,"context_lines":[{"line_number":115,"context_line":"* Specifying \u0027auto\u0027 with any other network values (ports, \u0027none\u0027, \u0027auto\u0027 or a"},{"line_number":116,"context_line":"  specific network uuid) results in a 409 response."},{"line_number":117,"context_line":"* Specifying \u0027none\u0027 with any other network values (ports, \u0027auto\u0027 or a specific"},{"line_number":118,"context_line":"  network uuid) results in a 409 response."},{"line_number":119,"context_line":"* If \u0027auto\u0027 is specified and nova-network fails to provide networking, fail the"},{"line_number":120,"context_line":"  instance build request (which may trigger a reschedule to another compute"},{"line_number":121,"context_line":"  node)."}],"source_content_type":"text/x-rst","patch_set":16,"id":"bab6814e_ce1bf1c8","line":118,"updated":"2016-05-20 18:38:18.000000000","message":"409 is really a state conflict on the server side, which is not what this is. \n\nThese are 400 Bad Request.","commit_id":"cd365d63a2318a7f6c1df5b1595d2bdea5f26865"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"dabea0d5e6948a63662f2a1415677be1def464e5","unresolved":false,"context_lines":[{"line_number":122,"context_line":"* If \u0027auto\u0027 is specified, and Nova can determine during the lifecycle of the"},{"line_number":123,"context_line":"  API request that it cannot honor auto-allocating the network, a 409 is"},{"line_number":124,"context_line":"  returned. If auto-allocation fails after the API request has returned, the"},{"line_number":125,"context_line":"  instance is sent to ERROR state."},{"line_number":126,"context_line":"* Another failure scenario would be that Neutron is new enough and is setup"},{"line_number":127,"context_line":"  to support auto-allocated-topology, but the deployment still has compute"},{"line_number":128,"context_line":"  nodes that are not running the allocation code for creating the network"}],"source_content_type":"text/x-rst","patch_set":16,"id":"bab6814e_ce72d110","line":125,"updated":"2016-05-20 18:38:18.000000000","message":"also a 400","commit_id":"cd365d63a2318a7f6c1df5b1595d2bdea5f26865"},{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"dabea0d5e6948a63662f2a1415677be1def464e5","unresolved":false,"context_lines":[{"line_number":273,"context_line":""},{"line_number":274,"context_line":"  * Normal http response code: 202"},{"line_number":275,"context_line":""},{"line_number":276,"context_line":"  * Expected error http response code(s): 400, 403, 409, 413"},{"line_number":277,"context_line":""},{"line_number":278,"context_line":"  * URL for the resource"},{"line_number":279,"context_line":""}],"source_content_type":"text/x-rst","patch_set":16,"id":"bab6814e_eee355a2","line":276,"updated":"2016-05-20 18:38:18.000000000","message":"I don\u0027t think either 409 or 413 should be here.","commit_id":"cd365d63a2318a7f6c1df5b1595d2bdea5f26865"}]}
